Planimate Coding Standards
Jump to navigation
Jump to search
Below is a collection of Planimate coding standards that will help models interact with each other and make model handover easier.
All information below is up for discussion, please use this page's talk page for the discussion
Naming Conventions
Rick has put together an article on naming conventions that will one day be enforced. This article describes how the naming strings should be constructed but doesn't provide guidelines on what should be in the naming string. Below are some proposals that can help identify an entities use
String Prefix
- ui_ for user interface related elements
- as_ for application service related elements
- tbl_ for table data objects
- lbl_ for label data objects
- att_ for attribute data objects
- calc_ for calculated data
- inp_ for input data
- meta_ for model structure related data objects
The prefixes can be combined, ie. tbl_inp_ is an input table, table_calc_ is an output table.
General Practice
- Don't mix application code (UI etc) with modelling code, keep them in separate areas.
- Mixing can be confusing when it comes to debugging. Your user interface shouldn't effect the model
- Separate Application data structures from modelling data structures
- For the same reasons as above.
- Build your model data structures to suit the code, not a user view