FileDocCategorySizeDatePackage
BusinessDelegateFactory.javaAPI DocExample787Mon Nov 24 09:24:10 GMT 2003com.oreilly.patterns.chapter9

BusinessDelegateFactory

public class BusinessDelegateFactory extends Object

Fields Summary
private static boolean
useLogging
Constructors Summary
Methods Summary
public static booleangetLogStatus()

    return useLogging;
  
public static PatientManagementDelegategetPatientManagementDelegate()


     
                  
    PatientManagementDelegate delegate = 
        new PatientManagementDelegateImpl();
    return (PatientManagementDelegate)wrap(delegate);   
  
public static voidstartLogging()

    useLogging = true;
  
public static voidstopLogging()

    useLogging = false;
  
private static java.lang.Objectwrap(java.lang.Object o)

    if(useLogging)
      return DelegateLoggingWrapper.decorate(o);
    return o;