org.intermine.api.results
Class Column

java.lang.Object
  extended by org.intermine.api.results.Column

public class Column
extends java.lang.Object

Configuration information for a column in a table


Field Summary
protected  java.lang.String columnId
           
protected  int index
           
protected  java.lang.String name
           
protected  boolean selectable
           
protected  java.lang.Class type
           
protected  boolean visible
           
 
Constructor Summary
Column(Path path, int index, java.lang.Class type)
          Constructor that takes a Path object.
Column(Path path, java.lang.String name, int index, java.lang.Class type)
          Constructor that takes a Path object.
Column(java.lang.String name, int index, java.lang.Class type)
          Constructor that takes a String name.
 
Method Summary
 boolean equals(java.lang.Object other)
          
 java.lang.String getColumnId()
           
 int getIndex()
          Gets the value of index
 java.lang.String getName()
          Get the name (title) of the column.
 Path getPath()
          Get the Path set by setPath().
 java.lang.Class getType()
          Return the type of this Column
 java.lang.String getTypeClsString()
          Get the column type unqualified as a String
 int hashCode()
          
 boolean isSelectable()
          Gets the value of selectable
 boolean isVisible()
          Gets the value of visible
 void setColumnId(java.lang.String columnId)
           
 void setIndex(int index)
          Sets the value of index
 void setSelectable(boolean selectable)
          Sets the value of selectable
 void setVisible(boolean visible)
          Sets the value of visible
 java.lang.String toString()
          
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

visible

protected boolean visible

index

protected int index

type

protected java.lang.Class type

selectable

protected boolean selectable

name

protected java.lang.String name

columnId

protected java.lang.String columnId
Constructor Detail

Column

public Column(Path path,
              java.lang.String name,
              int index,
              java.lang.Class type)
Constructor that takes a Path object.

Parameters:
path - a Path object
name - an optional, more human readable description of the Column that will be returned by getName() - can be null in which case the column name (given by path.toStringNoConstraints()) will be used
index - the number of the column
type - the type of the column (ClassDescriptor or Class)

Column

public Column(Path path,
              int index,
              java.lang.Class type)
Constructor that takes a Path object. The human readable name for getName() will be generated from the path.

Parameters:
path - a Path object
index - the number of the column
type - the type of the column (ClassDescriptor or Class)

Column

public Column(java.lang.String name,
              int index,
              java.lang.Class type)
Constructor that takes a String name.

Parameters:
name - a column name
index - the number of the column
type - the type of the column (ClassDescriptor or Class)
Method Detail

getColumnId

public java.lang.String getColumnId()
Returns:
the columnId

setColumnId

public void setColumnId(java.lang.String columnId)
Parameters:
columnId - the columnId to set

isSelectable

public boolean isSelectable()
Gets the value of selectable

Returns:
a boolean

setSelectable

public void setSelectable(boolean selectable)
Sets the value of selectable

Parameters:
selectable - value to assign to selectable

isVisible

public boolean isVisible()
Gets the value of visible

Returns:
the value of visible

setVisible

public void setVisible(boolean visible)
Sets the value of visible

Parameters:
visible - value to assign to visible

getIndex

public int getIndex()
Gets the value of index

Returns:
the value of index

setIndex

public void setIndex(int index)
Sets the value of index

Parameters:
index - value to assign to index

getType

public java.lang.Class getType()
Return the type of this Column

Returns:
a Class or a FieldDescriptor

getTypeClsString

public java.lang.String getTypeClsString()
Get the column type unqualified as a String

Returns:
the column type

equals

public boolean equals(java.lang.Object other)

Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()

Overrides:
hashCode in class java.lang.Object

toString

public java.lang.String toString()

Overrides:
toString in class java.lang.Object

getPath

public Path getPath()
Get the Path set by setPath().

Returns:
the Path

getName

public java.lang.String getName()
Get the name (title) of the column.

Returns:
the name