The Artima Developer Community
Sponsored Link

Interface Design by Bill Venners
Use classes primarily as blueprints for objects

Advertisement

Interface Design | Contents | Previous | Next

Occasionally, bundles of class methods or bundles of constants Use class members to control access to objects, provide utility methods, or offer bundles of constants. Examples of controlling access to objects, static factory methods, singleton pattern. Hmm, providing access to objects seems to all fall under the category of static factory methods.

  • Guideline: Provide convenience constants.



  • Google
      Web Artima.com   
    Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use