org.designwizard.patternchecker
Class SingletonPatternChecker
java.lang.Object
org.designwizard.patternchecker.SingletonPatternChecker
- All Implemented Interfaces:
- PatternChecker
public class SingletonPatternChecker
- extends java.lang.Object
- implements PatternChecker
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
VERIFIED_PATTERN_NAME
public static final java.lang.String VERIFIED_PATTERN_NAME
- See Also:
- Constant Field Values
PUBLIC_CONSTRUCTOR_ERROR
public static final java.lang.String PUBLIC_CONSTRUCTOR_ERROR
- See Also:
- Constant Field Values
MULTIPLE_SINGLETON_FIELDS_ERROR
public static final java.lang.String MULTIPLE_SINGLETON_FIELDS_ERROR
- See Also:
- Constant Field Values
GET_INSTANCE_NOT_FOUND_ERROR
public static final java.lang.String GET_INSTANCE_NOT_FOUND_ERROR
- See Also:
- Constant Field Values
NO_SINGLETON_FIELDS_ERROR
public static final java.lang.String NO_SINGLETON_FIELDS_ERROR
- See Also:
- Constant Field Values
GET_INSTANCE_FIELD_MISS_WARN
public static final java.lang.String GET_INSTANCE_FIELD_MISS_WARN
- See Also:
- Constant Field Values
SingletonPatternChecker
public SingletonPatternChecker(ClassNode classEntity)
getVeredict
public boolean getVeredict()
- Specified by:
getVeredict
in interface PatternChecker
- Returns:
true
if the pattern is correctly implemented by the design; false
otherwise.
setDesign
public void setDesign(DesignIF design)
- Description copied from interface:
PatternChecker
- Sets the design to be checked by this
PatternChecker
.
- Specified by:
setDesign
in interface PatternChecker
- Parameters:
design
- the new design.
verify
public CheckingResult verify()
- Description copied from interface:
PatternChecker
- Verifies whether the design implements the pattern which is checked by
this
PatternChecker
.
- Specified by:
verify
in interface PatternChecker
- Returns:
- the result of the verification.