...
- Names representing types must be nouns and written in mixed case starting with upper case. E.g., StoragePool
- Variable names must be in mixed case starting with lower case, E.g., virtualRouter
- Names representing constants (final variables) must be all uppercase using underscore to separate words. E.g., MAX_TEMPLATE_SIZE_MB
- Names representing methods must be verbs and written in mixed case starting with lower case. E.g., copyTemplateToZone
- Abbreviations and acronyms should not be uppercase when used as name. E.g., startElbVm
- Private class variables should have underscore prefix. E.g., _downloadTimer. Exception: Transfer Objects (TOs), Database objects (VOs), Command objects:- private class variables in these classes have no underscores. The exception is justified since these are usually logged and are more readable without underscores.
- Static variables are prefixed with s_. E.g., s_logger
- is prefix should be used for boolean variables and methods. E.g., isFinished
- Exception classes should be suffixed with Exception.
- Default interface implementations can be prefixed by Default or if intended to be subclassed, suffixed by Base. E.g., DefaultExternalNetworkElement or NetworkElementBase
- There are various naming conventions used to convey the design patterns common in Cloudstack, listed in the Appendix.
- Object Naming Convention and guidelines for logs, API description, documentation and comments, refer to Object Naming and Title Case Convention
Files, Layout and whitespace
...
{"serverDuration": 144, "requestCorrelationId": "c96d70d58e73ad0d"}