|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.intermine.metadata.FieldDescriptor
org.intermine.metadata.AttributeDescriptor
public class AttributeDescriptor
Describes an attribute of a class - i.e. a field that is neither an object reference or a collection.
| Field Summary | |
|---|---|
protected java.lang.String |
type
|
static java.util.Set<java.lang.String> |
VALID_TYPES
This is a list of the valid type strings. |
| Fields inherited from class org.intermine.metadata.FieldDescriptor |
|---|
cld, M_N_RELATION, N_ONE_RELATION, name, NOT_RELATION, ONE_N_RELATION, ONE_ONE_RELATION |
| Constructor Summary | |
|---|---|
AttributeDescriptor(java.lang.String name,
java.lang.String type)
Construct, name and type cannot be null. |
|
| Method Summary | |
|---|---|
boolean |
equals(java.lang.Object obj)
|
java.lang.String |
getType()
Get the type of the attribute - either name of primitive or fully qualified class name. |
int |
hashCode()
|
boolean |
isPrimitive()
Returns true if the type of the attribute is a primitive type (rather than object). |
int |
relationType()
Return an integer describing the type of relationship this field represents, where relationship types are 1:1, 1:N, N:1, M:N and "not a relationship". |
java.lang.String |
toString()
|
| Methods inherited from class org.intermine.metadata.FieldDescriptor |
|---|
getClassDescriptor, getName, isAttribute, isCollection, isReference, setClassDescriptor |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected final java.lang.String type
public static final java.util.Set<java.lang.String> VALID_TYPES
| Constructor Detail |
|---|
public AttributeDescriptor(java.lang.String name,
java.lang.String type)
name - name of field in the classtype - name of primitive or a fully qualified class name
java.lang.IllegalArgumentException - if arguments are null| Method Detail |
|---|
public java.lang.String getType()
public int relationType()
relationType in class FieldDescriptorpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Objectpublic boolean isPrimitive()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||