01: // THIS SOFTWARE IS PROVIDED BY SOFTARIS PTY.LTD. AND OTHER METABOSS
02: // CONTRIBUTORS ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING,
03: // BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
04: // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SOFTARIS PTY.LTD.
05: // OR OTHER METABOSS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
06: // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
07: // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
08: // OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
09: // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
10: // NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
11: // EVEN IF SOFTARIS PTY.LTD. OR OTHER METABOSS CONTRIBUTORS ARE ADVISED OF THE
12: // POSSIBILITY OF SUCH DAMAGE.
13: //
14: // Copyright 2000-2005 © Softaris Pty.Ltd. All Rights Reserved.
15: package com.metaboss.sdlctools.types.storagemodel;
16:
17: /** Datatype representing possible types of the storage technology */
18: public final class NameConversionType {
19: /** Constant describing no conversion type */
20: public final static NameConversionType NONE = new NameConversionType(
21: "None");
22: public final static NameConversionType UPPER = new NameConversionType(
23: "Upper");
24: public final static NameConversionType LOWER = new NameConversionType(
25: "Lower");
26: public final static NameConversionType UPPER_UNDERSCORED = new NameConversionType(
27: "UpperUnderscored");
28: public final static NameConversionType LOWER_UNDERSCORED = new NameConversionType(
29: "LowerUnderscored");
30:
31: /* Stereotype name storage */
32: protected String mValue;
33:
34: /* Private constructor. Restricts construction from outside */
35: private NameConversionType(String pValue) {
36: mValue = pValue;
37: }
38:
39: /** Indicates whether some other object is "equal to" this one
40: * @return true if this object is the same as the obj argument; false otherwise. */
41: public boolean equals(Object pOtherObject) {
42: if (pOtherObject == null)
43: return false;
44: if ((pOtherObject instanceof NameConversionType) == false)
45: return false;
46: return ((NameConversionType) pOtherObject).mValue
47: .equals(mValue);
48: }
49:
50: public String toString() {
51: return mValue;
52: }
53: }
|