litesoft
Diff Revisions
949
vs
950
for /trunk/Java/KeyHole/src/org/litesoft/aokeyhole/objects/AttributeType.java
|
@@ -1,38 +1,38 @@ |
1 |
|
- |
// This Source Code is in the Public Domain per: http://unlicense.org |
2 |
|
- |
package org.litesoft.aokeyhole.objects; |
3 |
|
- |
|
4 |
|
- |
public abstract class AttributeType { |
5 |
|
- |
private FundamentalAttributeType mFAT; |
6 |
|
- |
|
7 |
|
- |
protected AttributeType( FundamentalAttributeType pFAT ) { |
8 |
|
- |
if ( !getClass().getSimpleName().startsWith( "A_" ) ) { |
9 |
|
- |
throw new Error( "Invalid AttributeType, Class Name did NOT start with 'A_': " + getClass().getSimpleName() ); |
10 |
|
- |
} |
11 |
|
- |
if ( null == (mFAT = pFAT) ) { |
12 |
|
- |
throw new Error( "FundamentalAttributeType was null" ); |
13 |
|
- |
} |
14 |
|
- |
} |
15 |
|
- |
|
16 |
|
- |
public FundamentalAttributeType getFAT() { |
17 |
|
- |
return mFAT; |
18 |
|
- |
} |
19 |
|
- |
|
20 |
|
- |
@Override |
21 |
|
- |
public String toString() { |
22 |
|
- |
return getClass().getSimpleName().substring( 2 ); |
23 |
|
- |
} |
24 |
|
- |
|
25 |
|
- |
@Override |
26 |
|
- |
public boolean equals( Object o ) { |
27 |
|
- |
return (this == o) || ((o != null) && this.getClass().equals( o.getClass() )); |
28 |
|
- |
} |
29 |
|
- |
|
30 |
|
- |
@Override |
31 |
|
- |
public int hashCode() { |
32 |
|
- |
return toString().hashCode(); |
33 |
|
- |
} |
34 |
|
- |
|
35 |
|
- |
public Class getSimpleDataType() { |
36 |
|
- |
return null; |
37 |
|
- |
} |
38 |
|
- |
} |
|
1 |
+ |
// This Source Code is in the Public Domain per: http://unlicense.org |
|
2 |
+ |
package org.litesoft.aokeyhole.objects; |
|
3 |
+ |
|
|
4 |
+ |
public abstract class AttributeType { |
|
5 |
+ |
private FundamentalAttributeType mFAT; |
|
6 |
+ |
|
|
7 |
+ |
protected AttributeType( FundamentalAttributeType pFAT ) { |
|
8 |
+ |
if ( !getClass().getSimpleName().startsWith( "A_" ) ) { |
|
9 |
+ |
throw new Error( "Invalid AttributeType, Class Name did NOT start with 'A_': " + getClass().getSimpleName() ); |
|
10 |
+ |
} |
|
11 |
+ |
if ( null == (mFAT = pFAT) ) { |
|
12 |
+ |
throw new Error( "FundamentalAttributeType was null" ); |
|
13 |
+ |
} |
|
14 |
+ |
} |
|
15 |
+ |
|
|
16 |
+ |
public FundamentalAttributeType getFAT() { |
|
17 |
+ |
return mFAT; |
|
18 |
+ |
} |
|
19 |
+ |
|
|
20 |
+ |
@Override |
|
21 |
+ |
public String toString() { |
|
22 |
+ |
return getClass().getSimpleName().substring( 2 ); |
|
23 |
+ |
} |
|
24 |
+ |
|
|
25 |
+ |
@Override |
|
26 |
+ |
public boolean equals( Object o ) { |
|
27 |
+ |
return (this == o) || ((o != null) && this.getClass().equals( o.getClass() )); |
|
28 |
+ |
} |
|
29 |
+ |
|
|
30 |
+ |
@Override |
|
31 |
+ |
public int hashCode() { |
|
32 |
+ |
return toString().hashCode(); |
|
33 |
+ |
} |
|
34 |
+ |
|
|
35 |
+ |
public Class getSimpleDataType() { |
|
36 |
+ |
return null; |
|
37 |
+ |
} |
|
38 |
+ |
} |