cmu.survey.editor.data.sql
Class AuxillaryQuestionPartSetSQL
java.lang.Object
org.browsecode.helpers.reorderablelistpanel.ReorderableListModelWithOrderIndexStub<AuxillaryQuestionPart>
cmu.survey.editor.data.table.AuxillaryQuestionPartSetTable
cmu.survey.editor.data.sql.AuxillaryQuestionPartSetSQL
- All Implemented Interfaces:
- AuxillaryQuestionPartSet, ReorderableListModel<AuxillaryQuestionPart>
public class AuxillaryQuestionPartSetSQL
- extends AuxillaryQuestionPartSetTable
Methods inherited from class org.browsecode.helpers.reorderablelistpanel.ReorderableListModelWithOrderIndexStub |
addReorderableChangeListener, addUndoableEditListener, canItemBeMovedElsewhere, deleteItem, deleteItemProtected, fireUndoableEdit, getHasBeenChanged, getItemCount, getNewItem, getVectorOfReorderableItems, insertNewItemAt, insertNewItemAtProtected, iterator, moveItemElsewhere, moveItemElsewhereProtected, moveItemToIndex, moveItemToIndexProtected, removeReorderableChangeListener, removeUndoableEditListener, resetHasBeenChanged, setCachedReorderableItems, undeleteItem |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AuxillaryQuestionPartSetSQL
public AuxillaryQuestionPartSetSQL(QuestionDataBitSetSQL question,
java.util.Vector<AuxillaryOptionDataBitTable> auxillaryOptionsParts)
- Parameters:
question
-
getParts
public java.util.Vector<AuxillaryQuestionPart> getParts()
- Description copied from interface:
AuxillaryQuestionPartSet
- DO NOT modify the Vector after you get it! All modifications should be done through calls to AuxillaryQuestionPartSet, not to the Vector.
Changes made to the Vector will not affect this class.
- Returns:
- Vector of AuxillaryQuestionPart
getPartsSize
public int getPartsSize()
- Description copied from interface:
AuxillaryQuestionPartSet
- The size of the vector of parts returned by getParts(). This may be slightly more efficient than calling getParts().size(), since it may not need to generate a vector for it.
- Returns:
hasBeenModified
public boolean hasBeenModified()
hasError
public boolean hasError(StringDataBit answersTable)
getErrorDescription
public java.lang.String getErrorDescription(StringDataBit answersTable)
getItemsName
protected java.lang.String getItemsName()
- Description copied from class:
ReorderableListModelWithOrderIndexStub
- For undos and presentation names -- so we can say what we're moving/deleting/inserting
- Overrides:
getItemsName
in class ReorderableListModelWithOrderIndexStub<AuxillaryQuestionPart>
getItemsVector
protected java.util.Vector<ReorderableListModelWithOrderIndexStub.ReorderableObject<AuxillaryQuestionPart>> getItemsVector()
- Description copied from class:
ReorderableListModelWithOrderIndexStub
- Should return a non-cloned version of the list of items -- the vector
will be changed to reflect the order, etc.
- Overrides:
getItemsVector
in class ReorderableListModelWithOrderIndexStub<AuxillaryQuestionPart>
- Returns:
- Vector
deleteItem
protected void deleteItem(ReorderableListModelWithOrderIndexStub.ReorderableObject<AuxillaryQuestionPart> justDeleted)
- Description copied from class:
ReorderableListModelWithOrderIndexStub
- If an object is deleted from the list, this method is fired and should be
used to keep track of which items should not be saved anymore and deleted
when this set is saved.
- Overrides:
deleteItem
in class ReorderableListModelWithOrderIndexStub<AuxillaryQuestionPart>
undeleteItem
protected boolean undeleteItem(java.lang.Object justUndeleted)
getNewItem
public AuxillaryQuestionPart getNewItem()
- Description copied from class:
ReorderableListModelWithOrderIndexStub
- Creates a new item for the list, but does not insert it into the list.
Required for getNewItem(int), which does the job correctly if you implement this.;
- Overrides:
getNewItem
in class ReorderableListModelWithOrderIndexStub<AuxillaryQuestionPart>
- Returns:
save
public boolean save()
- Specified by:
save
in class AuxillaryQuestionPartSetTable
copyTo
public AuxillaryQuestionPartSetSQL copyTo(QuestionDataBitSetSQL newParent)
getReorderableObjectFor
protected ReorderableListModelWithOrderIndexStub.ReorderableObject<AuxillaryQuestionPart> getReorderableObjectFor(AuxillaryQuestionPart reorderableItem)
- Overrides:
getReorderableObjectFor
in class ReorderableListModelWithOrderIndexStub<AuxillaryQuestionPart>
shouldFireUndoableEdits
public boolean shouldFireUndoableEdits()
- Description copied from class:
ReorderableListModelWithOrderIndexStub
- Also public for other classes that want to use the same list of undoableEditListeners.
- Overrides:
shouldFireUndoableEdits
in class ReorderableListModelWithOrderIndexStub<AuxillaryQuestionPart>
fireUndoableEdit
protected void fireUndoableEdit(javax.swing.undo.UndoableEdit edit)
- Overrides:
fireUndoableEdit
in class ReorderableListModelWithOrderIndexStub<AuxillaryQuestionPart>