next up previous contents index
Next: 4.2 Naming Methods Up: 4 Style Guide Previous: 4 Style Guide   Contents   Index


4.1 Environment organization

4.1.1 Namespaces

New namespaces should be used for separate categories of concepts. Occasionally, these are the kind that should automatically included in their enclosing namespace (which can be further inherited up to the lobby). This is done simply by placing the new namespace object in a delegate slot.

4.1.2 Exemplars or Value Objects

These represent objects such as specific colors with well-known names, or cloneable objects with useful default values. Generally these should have capitalized names if they are cloneable, and can be capitalized or lowercase if not. For cases with a large group of such value objects, like colors, there usually should involve a separate namespace to avoid cluttering up the surrounding one. This also helps with naming the use of a value if the intuitive interpretation of its name is dependent on context.

Brian Rice 2005-11-21