org.intermine.api.results
Class ResultElement

java.lang.Object
  extended by org.intermine.api.results.ResultElement
All Implemented Interfaces:
java.io.Serializable

public class ResultElement
extends java.lang.Object
implements java.io.Serializable

Cell of results table containing information for the parent Object

See Also:
Serialized Form

Field Summary
protected  java.lang.Object field
           
protected  java.lang.String htmlId
           
protected  FastPathObject imObj
           
 
Constructor Summary
ResultElement(FastPathObject imObj, Path path, boolean isKeyField)
          Constructs a new ResultCell object
ResultElement(java.lang.Object fieldValue)
          Create a ResultElement that displays a single raw value.
 
Method Summary
 boolean equals(java.lang.Object obj)
          
 java.lang.Object getField()
          Get the field value
 java.lang.Integer getId()
          Get the Id.
 FastPathObject getObject()
          Return the Object contained in this result element.
 Path getPath()
           
 java.lang.String getType()
          Get the type
 int hashCode()
          
 boolean isKeyField()
          Return true if this object represents a field that is an identifying field (according to ClassKeyHelper.isKeyField())
 void setField(java.lang.Object field)
          Set the field value
 java.lang.String toString()
          Returns a String representation of the ResultElement.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

field

protected java.lang.Object field

imObj

protected FastPathObject imObj

htmlId

protected java.lang.String htmlId
Constructor Detail

ResultElement

public ResultElement(FastPathObject imObj,
                     Path path,
                     boolean isKeyField)
Constructs a new ResultCell object

Parameters:
imObj - the InterMineObject or SimpleObject to wrap
path - the Path
isKeyField - should be true if this is an identifying field

ResultElement

public ResultElement(java.lang.Object fieldValue)
Create a ResultElement that displays a single raw value.

Parameters:
fieldValue - the value to hold in this object
Method Detail

getField

public java.lang.Object getField()
Get the field value

Returns:
the value

setField

public void setField(java.lang.Object field)
Set the field value

Parameters:
field - the field

getType

public java.lang.String getType()
Get the type

Returns:
the type

isKeyField

public boolean isKeyField()
Return true if this object represents a field that is an identifying field (according to ClassKeyHelper.isKeyField())

Returns:
true if this is a key field

getId

public java.lang.Integer getId()
Get the Id.

Returns:
the id

getPath

public Path getPath()
Returns:
the path

getObject

public FastPathObject getObject()
Return the Object contained in this result element.

Returns:
the InterMineObject

toString

public java.lang.String toString()
Returns a String representation of the ResultElement.

Overrides:
toString in class java.lang.Object
Returns:
a String

equals

public boolean equals(java.lang.Object obj)

Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()

Overrides:
hashCode in class java.lang.Object