01: /*
02: * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
03: */
04: package com.tc.aspectwerkz.expression;
05:
06: import java.io.Serializable;
07:
08: /**
09: * Type safe enum for the different matching types.
10: *
11: * @author <a href="mailto:jboner@codehaus.org">Jonas BonŽr </a>
12: */
13: public class SubtypePatternType implements Serializable {
14:
15: public static final SubtypePatternType NOT_HIERARCHICAL = new SubtypePatternType(
16: "NOT_HIERARCHICAL");
17:
18: public static final SubtypePatternType MATCH_ON_ALL_METHODS = new SubtypePatternType(
19: "MATCH_ON_ALL_METHODS");
20:
21: public static final SubtypePatternType MATCH_ON_BASE_TYPE_METHODS_ONLY = new SubtypePatternType(
22: "MATCH_ON_BASE_TYPE_METHODS_ONLY");
23:
24: private final String myName;
25:
26: /**
27: * Creates a new instance
28: *
29: * @param name
30: */
31: private SubtypePatternType(final String name) {
32: myName = name;
33: }
34:
35: /**
36: * Returns the string representation.
37: *
38: * @return the string representation
39: */
40: public String toString() {
41: return myName;
42: }
43: }
|