org.gusdb.wdk.model
Class RecordClass

java.lang.Object
  extended by org.gusdb.wdk.model.RecordClass

public class RecordClass
extends java.lang.Object


Field Summary
static java.lang.String PRIMARY_KEY_MACRO
           
static java.lang.String PRIMARY_KEY_NAME
           
static java.lang.String PROJECT_ID_MACRO
           
static java.lang.String PROJECT_ID_NAME
           
 
Constructor Summary
RecordClass()
           
 
Method Summary
 void addAttributesQueryRef(Reference attributesQueryRef)
           
 void addLinkAttribute(LinkAttributeField linkAttributeField)
           
 void addNestedRecordListQuestion(Question q)
           
 void addNestedRecordListQuestionRef(NestedRecordList nrl)
           
 void addNestedRecordQuestion(Question q)
           
 void addNestedRecordQuestionRef(NestedRecord nr)
           
 void addQuestion(Question q)
           
 void addTableQueryRef(Reference tableQueryRef)
           
 void addTextAttribute(TextAttributeField textAttributeField)
           
 java.util.Map getAttributeFields()
           
 java.lang.String getDelimiter()
          Added by Jerric
 FieldI getField(java.lang.String fieldName)
           
 java.util.Map getFields()
           
 java.lang.String getFullName()
           
 java.lang.String getIdPrefix()
           
 java.lang.String getName()
           
 Question[] getNestedRecordListQuestions()
           
 Question[] getNestedRecordQuestions()
           
 PrimaryKeyField getPrimaryKeyField()
          Added by Jerric
 Question[] getQuestions()
           
 Reference getReference()
           
 java.util.List getSummaryColumnNames()
           
 java.util.Map getTableFields()
           
 java.lang.String getType()
           
 void initNestedRecords()
          Called when the RecordClass is asked for a NestedRecordQuestion or NestedRecordQuestionList.
 RecordInstance makeRecordInstance()
           
 void setAttributeOrdering(java.lang.String attOrder)
           
 void setDelimiter(java.lang.String delimiter)
          Added by Jerric
 void setIdPrefix(java.lang.String idPrefix)
           
 void setName(java.lang.String name)
           
 void setProjectParamRef(Reference projectParamRef)
          Added by Jerric
 void setType(java.lang.String type)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

PRIMARY_KEY_NAME

public static final java.lang.String PRIMARY_KEY_NAME
See Also:
Constant Field Values

PROJECT_ID_NAME

public static final java.lang.String PROJECT_ID_NAME
See Also:
Constant Field Values

PRIMARY_KEY_MACRO

public static final java.lang.String PRIMARY_KEY_MACRO
See Also:
Constant Field Values

PROJECT_ID_MACRO

public static final java.lang.String PROJECT_ID_MACRO
See Also:
Constant Field Values
Constructor Detail

RecordClass

public RecordClass()
Method Detail

setName

public void setName(java.lang.String name)

setIdPrefix

public void setIdPrefix(java.lang.String idPrefix)

setType

public void setType(java.lang.String type)

setDelimiter

public void setDelimiter(java.lang.String delimiter)
Added by Jerric

Parameters:
delimiter -

setProjectParamRef

public void setProjectParamRef(Reference projectParamRef)
Added by Jerric

Parameters:
projectParamRef -

setAttributeOrdering

public void setAttributeOrdering(java.lang.String attOrder)
Parameters:
attList - comma separated list of attributes in a summary containing this recordClass.

addAttributesQueryRef

public void addAttributesQueryRef(Reference attributesQueryRef)
Parameters:
attributesQueryRef - two part query name (set.name)

addTableQueryRef

public void addTableQueryRef(Reference tableQueryRef)
Parameters:
tableQueryRef - two part query name (set.name)

addTextAttribute

public void addTextAttribute(TextAttributeField textAttributeField)
                      throws WdkModelException
Throws:
WdkModelException

addLinkAttribute

public void addLinkAttribute(LinkAttributeField linkAttributeField)
                      throws WdkModelException
Throws:
WdkModelException

addQuestion

public void addQuestion(Question q)

addNestedRecordQuestion

public void addNestedRecordQuestion(Question q)

addNestedRecordListQuestion

public void addNestedRecordListQuestion(Question q)

addNestedRecordQuestionRef

public void addNestedRecordQuestionRef(NestedRecord nr)

addNestedRecordListQuestionRef

public void addNestedRecordListQuestionRef(NestedRecordList nrl)

getName

public java.lang.String getName()

getFullName

public java.lang.String getFullName()

getIdPrefix

public java.lang.String getIdPrefix()

getType

public java.lang.String getType()

getTableFields

public java.util.Map getTableFields()

getAttributeFields

public java.util.Map getAttributeFields()

getFields

public java.util.Map getFields()

getField

public FieldI getField(java.lang.String fieldName)

getNestedRecordQuestions

public Question[] getNestedRecordQuestions()

getNestedRecordListQuestions

public Question[] getNestedRecordListQuestions()

getQuestions

public Question[] getQuestions()
Returns:
all Questions in the current model that are using this record class as their return type.

getSummaryColumnNames

public java.util.List getSummaryColumnNames()
Returns:

getReference

public Reference getReference()
                       throws WdkModelException
Throws:
WdkModelException

getDelimiter

public java.lang.String getDelimiter()
Added by Jerric

Returns:
returns the delimiter for separating projectID & primaryKey

getPrimaryKeyField

public PrimaryKeyField getPrimaryKeyField()
Added by Jerric

Returns:

makeRecordInstance

public RecordInstance makeRecordInstance()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

initNestedRecords

public void initNestedRecords()
Called when the RecordClass is asked for a NestedRecordQuestion or NestedRecordQuestionList. Cannot be done upon RecordClass initialization because the Questions are not guaranteed to have their resources set, which throws a NullPointerException when the Question is asked for the name of its QuestionSet.