Claims
- 1. A method for enforcing internationalization, comprising:
receiving a message from a client program, wherein the message includes keys and parameters; passing the keys and parameters to a translation subroutine, wherein the translation subroutine translates the message into a localized message; and calling a pre-logging subroutine, wherein the pre-logging subroutine is capable of determining whether the message is localized, and wherein the pre-logging subroutine rejects a non-localized message.
- 2. The method of claim 1, wherein the passing step includes creating a message template for the keys and parameters in a developer's native language.
- 3. The method of claim 2, wherein the passing step further includes translating the message template in the developer's native language into a message template in a user's native language.
- 4. The method of claim 1, further comprising logging the localized message.
- 5. The method of claim 1, wherein the calling step includes calling a helper method for operational logging.
- 6. The method of claim 1, wherein the calling step includes calling a helper method that processes operational log messages.
- 7. The method of claim 1, wherein the passing step includes translating the message into a user's native language by a localized message factory.
- 8. A logging system application programming interface (API), comprising:
one or more translation subroutine that receives keys and parameters of a message, wherein the one or more translation subroutine translates the message into a localized message; one or more pre-logging subroutines capable of determining whether the message is a localized message, wherein the one or more pre-logging subroutines rejects a non-localized message; and a raw logging interface that writes the message to a log.
- 9. The logging system API of claim 8, wherein if the message is localized, the one or more pre-logging subroutines pass strings of the localized message to the raw logging interface to be logged.
- 10. The logging system API of claim 8, wherein the one or more translation subroutine creates a message template for the keys and parameters.
- 11. The logging system API of claim 8, wherein the one or more pre-logging subroutines are helper methods for operational logging.
- 12. The logging system API of claim 8, wherein the one or more pre-logging subroutines process operational log messages.
- 13. The logging system API of claim 8, wherein the translation subroutine is implemented by a localized message factory.
- 14. A computer readable medium providing instructions for enforcing internationalization, the instructions comprising:
receiving a message from a client program, wherein the message includes keys and parameters; passing the keys and parameters to a translation subroutine, wherein the translation subroutine translates the message into a localized message; and calling a pre-logging subroutine, wherein the pre-logging subroutine is capable of determining whether the message is localized, and wherein the pre-logging subroutine rejects a non-localized message.
- 15. The computer readable medium of claim 14, wherein the instructions for passing include instructions for creating a message template for the keys and parameters in a developer's native language.
- 16. The computer readable medium of claim 15, wherein the instructions for passing further include instructions for translating the message template in the developer's native language into a message template in a user's native language.
- 17. The computer readable medium of claim 14, further comprising instructions for logging the localized message.
- 18. The computer readable medium of claim 14, wherein the instructions for calling include instructions for calling a helper method for operational logging.
- 19. The computer readable medium of claim 14, wherein the instructions for calling include instructions for calling a helper method that processes operational log messages.
- 20. The computer readable medium of claim 14, wherein the instructions for passing include instructions for translating the message into a user's native language by a localized message factory.
CROSS-REFERENCE TO RELATED APPLICATIONS
[0001] This patent application is related to U.S. patent application, entitled “API to Increase Debug Log Performance,” and filed on the same day herewith.