Changes between Version 69 and Version 70 of DeveloperGuidelines/CodeConventions


Ignore:
Timestamp:
01/22/18 21:17:37 (7 years ago)
Author:
Dominic König
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • DeveloperGuidelines/CodeConventions

    v69 v70  
    5454* Function names for the global namespace should start with an "s3_" prefix (if they are not module-specific) or with the module prefix plus underscore.
    5555* Names for Eden-specific methods in subclasses of web2py classes also start with "s3_".
    56 * should have the suffix "S3"
    57 * Names for Eden-specific subclasses of web2py classes and all classes which over-ride existing classes start with "S3",
    58 * All other classes defined in Eden end with "S3" (e.g. AuthS3 vs. S3Resource).
    59 * CamelCase is for class names only
    60 * Constant names are all-uppercase and with underscores as word separator
    61 * everything else (including table names and field names) should be all-lowercase with underscores as word separator
     56* Names for Eden-specific subclasses of web2py classes and all classes which over-ride existing classes should have the suffix "S3".
     57* All other classes defined in Eden start with "S3", e.g. S3Resource (a genuine Eden class) vs. AuthS3 (a subclass of a web2py class).
     58* Class names start with an uppercase letter.
     59* CamelCase is for class names only.
     60* Constant names are all-uppercase and with underscores as word separator.
     61* everything else (including table names and field names) should be all-lowercase with underscores as word separator.
    6262* Names should be obvious and explicit, but not overly verbose (i.e. as long as they need to be to not make people think). They shouldn't require someone to look in another file or solve a puzzle to figure out what they mean, but shouldn't take too long to write. Avoid inventing new acronyms. e.g. bad: {{{ s3_prm_lkp, method_that_allows_us_to_create_a_gis_layer }}}, good: {{{ s3_personnel_search, create_gis_layer }}}
    6363