Constant Data Manager Pattern
Application objects access different types of constant data items such as data file names, button labels, maximum and minimum range values, error codes and error messages, etc. Instead of allowing the constant data to be present in different objects, the Constant Data Manager pattern recommends all such data, which is considered
as constant in an application, be kept in a separate object and accessed by other objects in the application. This type of separation provides an easy to maintain, centralized repository for the constant data in an application.
public class FlightDM {
public static final String FLIGHT_INPUT_FILE = "FLT.dat";
public static final int VALID_AFTER = 22;
}
page revision: 0, last edited: 17 Mar 2008 13:21