Class QuestionRecord
- java.lang.Object
-
- org.silverpeas.processmanager.record.QuestionRecord
-
- All Implemented Interfaces:
Serializable,org.silverpeas.core.contribution.content.form.DataRecord
public class QuestionRecord extends Object implements org.silverpeas.core.contribution.content.form.DataRecord
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description QuestionRecord(String content)A QuestionRecord is built from a Question
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.silverpeas.core.contribution.content.form.FieldgetField(int fieldIndex)Returns the field at the index position in the record.org.silverpeas.core.contribution.content.form.FieldgetField(String fieldName)Returns the named field.org.silverpeas.core.contribution.content.form.FieldgetField(String fieldName, int occurrence)String[]getFieldNames()org.silverpeas.core.contribution.content.form.Field[]getFields()Returns all the fieldsStringgetId()Returns the data record id.StringgetLanguage()org.silverpeas.core.ResourceReferencegetResourceReference()Map<String,String>getValues(String language)booleanisNew()Return true if this record has not been inserted in a RecordSet.voidsetId(String id)Gives an id to the record.voidsetLanguage(String language)intsize()
-
-
-
Constructor Detail
-
QuestionRecord
public QuestionRecord(String content)
A QuestionRecord is built from a Question
-
-
Method Detail
-
getId
public String getId()
Returns the data record id. The record is known by its external id.- Specified by:
getIdin interfaceorg.silverpeas.core.contribution.content.form.DataRecord
-
setId
public void setId(String id)
Gives an id to the record. Caution ! the record is known by its external id.- Specified by:
setIdin interfaceorg.silverpeas.core.contribution.content.form.DataRecord
-
getFields
public org.silverpeas.core.contribution.content.form.Field[] getFields()
Returns all the fields
-
getField
public org.silverpeas.core.contribution.content.form.Field getField(String fieldName) throws org.silverpeas.core.contribution.content.form.FormException
Returns the named field.- Specified by:
getFieldin interfaceorg.silverpeas.core.contribution.content.form.DataRecord- Throws:
org.silverpeas.core.contribution.content.form.FormException- when the fieldName is unknown.
-
getField
public org.silverpeas.core.contribution.content.form.Field getField(String fieldName, int occurrence)
- Specified by:
getFieldin interfaceorg.silverpeas.core.contribution.content.form.DataRecord
-
getField
public org.silverpeas.core.contribution.content.form.Field getField(int fieldIndex) throws org.silverpeas.core.contribution.content.form.FormExceptionReturns the field at the index position in the record.- Specified by:
getFieldin interfaceorg.silverpeas.core.contribution.content.form.DataRecord- Throws:
org.silverpeas.core.contribution.content.form.FormException- when the fieldIndex is unknown.
-
size
public int size()
- Specified by:
sizein interfaceorg.silverpeas.core.contribution.content.form.DataRecord
-
getFieldNames
public String[] getFieldNames()
- Specified by:
getFieldNamesin interfaceorg.silverpeas.core.contribution.content.form.DataRecord
-
isNew
public boolean isNew()
Return true if this record has not been inserted in a RecordSet.- Specified by:
isNewin interfaceorg.silverpeas.core.contribution.content.form.DataRecord
-
getLanguage
public String getLanguage()
- Specified by:
getLanguagein interfaceorg.silverpeas.core.contribution.content.form.DataRecord
-
setLanguage
public void setLanguage(String language)
- Specified by:
setLanguagein interfaceorg.silverpeas.core.contribution.content.form.DataRecord
-
getValues
public Map<String,String> getValues(String language)
- Specified by:
getValuesin interfaceorg.silverpeas.core.contribution.content.form.DataRecord
-
getResourceReference
public org.silverpeas.core.ResourceReference getResourceReference()
- Specified by:
getResourceReferencein interfaceorg.silverpeas.core.contribution.content.form.DataRecord
-
-