org.outerj.daisy.repository.commonimpl.schema
Class StaticSelectionListImpl

java.lang.Object
  extended by org.outerj.daisy.repository.commonimpl.schema.StaticSelectionListImpl
All Implemented Interfaces:
org.outerj.daisy.repository.schema.SelectionList, org.outerj.daisy.repository.schema.StaticSelectionList

public class StaticSelectionListImpl
extends java.lang.Object
implements org.outerj.daisy.repository.schema.StaticSelectionList

A static selection list, manually created by a daisy administrator for a specific FieldType.


Nested Class Summary
 class StaticSelectionListImpl.IntimateAccess
           
 
Constructor Summary
StaticSelectionListImpl(SchemaStrategy creatingStrategy, org.outerj.daisy.repository.ValueType valueType, FieldTypeImpl owner)
           
 
Method Summary
 void addItem(java.lang.Object value)
          Adds a value to this StaticSelectionListImpl.
 void addToFieldTypeXml(org.outerx.daisy.x10.SelectionListDocument.SelectionList selectionListXml)
           
 void clear()
           
 org.outerj.daisy.repository.schema.StaticListItem createStaticListItem(java.lang.Object value)
           
 StaticSelectionListImpl.IntimateAccess getIntimateAccess(SchemaStrategy strategy)
           
 org.outerj.daisy.repository.schema.ListItem[] getItems()
           
 org.outerj.daisy.repository.schema.ListItem[] getItems(long branchId, long languageId, java.util.Locale locale)
           
 java.lang.String getLabel(java.lang.Object value, java.util.Locale locale)
           
 org.outerx.daisy.x10.StaticSelectionListDocument getXml()
           
 void setAllFromXml(org.outerx.daisy.x10.StaticSelectionListDocument.StaticSelectionList sl)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StaticSelectionListImpl

public StaticSelectionListImpl(SchemaStrategy creatingStrategy,
                               org.outerj.daisy.repository.ValueType valueType,
                               FieldTypeImpl owner)
Method Detail

getItems

public org.outerj.daisy.repository.schema.ListItem[] getItems()
Specified by:
getItems in interface org.outerj.daisy.repository.schema.SelectionList

getItems

public org.outerj.daisy.repository.schema.ListItem[] getItems(long branchId,
                                                              long languageId,
                                                              java.util.Locale locale)
Specified by:
getItems in interface org.outerj.daisy.repository.schema.SelectionList

addItem

public void addItem(java.lang.Object value)
             throws InvalidValueTypeException
Adds a value to this StaticSelectionListImpl.

This value will be wrapped in a ListItem object, i.e. this method is actually a shortcut for the addItem(ListItem listItem) method, relieving the outside world from the task of creating a ListItem object.

Specified by:
addItem in interface org.outerj.daisy.repository.schema.StaticSelectionList
Parameters:
value - the object containing the value to be stored in the StaticSelectionListImpl
Throws:
InvalidValueTypeException

clear

public void clear()
Specified by:
clear in interface org.outerj.daisy.repository.schema.StaticSelectionList

getIntimateAccess

public StaticSelectionListImpl.IntimateAccess getIntimateAccess(SchemaStrategy strategy)

createStaticListItem

public org.outerj.daisy.repository.schema.StaticListItem createStaticListItem(java.lang.Object value)
Specified by:
createStaticListItem in interface org.outerj.daisy.repository.schema.StaticSelectionList

getLabel

public java.lang.String getLabel(java.lang.Object value,
                                 java.util.Locale locale)
Specified by:
getLabel in interface org.outerj.daisy.repository.schema.SelectionList

getXml

public org.outerx.daisy.x10.StaticSelectionListDocument getXml()
Specified by:
getXml in interface org.outerj.daisy.repository.schema.StaticSelectionList

addToFieldTypeXml

public void addToFieldTypeXml(org.outerx.daisy.x10.SelectionListDocument.SelectionList selectionListXml)
Specified by:
addToFieldTypeXml in interface org.outerj.daisy.repository.schema.SelectionList

setAllFromXml

public void setAllFromXml(org.outerx.daisy.x10.StaticSelectionListDocument.StaticSelectionList sl)
Specified by:
setAllFromXml in interface org.outerj.daisy.repository.schema.StaticSelectionList


Copyright © -2012 . All Rights Reserved.