|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jminor.framework.client.model.DefaultEntityLookupModel
public class DefaultEntityLookupModel
A default EntityLookupModel implementation
Constructor Summary | |
---|---|
DefaultEntityLookupModel(String entityID,
EntityConnectionProvider connectionProvider,
List<Property.ColumnProperty> lookupProperties)
Instantiates a new EntityLookupModel |
Method Summary | |
---|---|
void |
addSearchStringListener(ActionListener listener)
|
void |
addSelectedEntitiesListener(ActionListener listener)
|
EntityConnectionProvider |
getConnectionProvider()
|
String |
getDescription()
|
String |
getEntityID()
|
List<Property.ColumnProperty> |
getLookupProperties()
|
String |
getMultipleValueSeparator()
|
String |
getSearchString()
|
List<Entity> |
getSelectedEntities()
|
String |
getWildcard()
|
boolean |
isCaseSensitive()
|
boolean |
isMultipleSelectionAllowed()
|
boolean |
isWildcardPostfix()
|
boolean |
isWildcardPrefix()
|
List<Entity> |
performQuery()
Performs a query based on the select criteria |
void |
refreshSearchText()
Refreshes the search text so that is represents the selected entities |
void |
removeSearchStringListener(ActionListener listener)
|
void |
removeSelectedEntitiesListener(ActionListener listener)
|
EventObserver |
searchStringObserver()
|
boolean |
searchStringRepresentsSelected()
|
EntityLookupModel |
setAdditionalLookupCriteria(Criteria additionalLookupCriteria)
Sets the additional lookup criteria to use when performing the lookup. |
EntityLookupModel |
setCaseSensitive(boolean caseSensitive)
Specifies whether or not this lookup model should be case sensitive |
void |
setDescription(String description)
|
void |
setMultipleSelectionAllowed(boolean multipleSelectionAllowed)
Specifies whether or not this lookup model should allow selection of multiple entities |
EntityLookupModel |
setMultipleValueSeparator(String multipleValueSeparator)
Sets the string to use to separate multiple values when shown as a string |
void |
setSearchString(String searchString)
Sets the search string to use when performing the next lookup |
void |
setSelectedEntities(List<Entity> entities)
Sets the selected entities |
void |
setSelectedEntity(Entity entity)
Sets the given entity as the selected entity |
EntityLookupModel |
setWildcard(String wildcard)
Sets the wildcard to use |
EntityLookupModel |
setWildcardPostfix(boolean wildcardPostfix)
Specifies whether or not to automatically append a wildcard to the search string |
EntityLookupModel |
setWildcardPrefix(boolean wildcardPrefix)
Specifies whether or not to automatically prefix the search string with a wildcard |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DefaultEntityLookupModel(String entityID, EntityConnectionProvider connectionProvider, List<Property.ColumnProperty> lookupProperties)
entityID
- the ID of the entity to lookupconnectionProvider
- the EntityConnectionProvider to use when performing the lookuplookupProperties
- the properties to search by, these must be string basedMethod Detail |
---|
public final String getEntityID()
getEntityID
in interface EntityDataProvider
public final EntityConnectionProvider getConnectionProvider()
getConnectionProvider
in interface EntityDataProvider
public final List<Property.ColumnProperty> getLookupProperties()
getLookupProperties
in interface EntityLookupModel
public final boolean isMultipleSelectionAllowed()
isMultipleSelectionAllowed
in interface EntityLookupModel
public final void setMultipleSelectionAllowed(boolean multipleSelectionAllowed)
setMultipleSelectionAllowed
in interface EntityLookupModel
multipleSelectionAllowed
- if true then selection of multiple entities is allowedpublic final String getDescription()
getDescription
in interface EntityLookupModel
public final void setDescription(String description)
setDescription
in interface EntityLookupModel
description
- a string describing this lookup modelpublic final void setSelectedEntity(Entity entity)
setSelectedEntity
in interface EntityLookupModel
entity
- the entity to set as the selected entitypublic final void setSelectedEntities(List<Entity> entities)
setSelectedEntities
in interface EntityLookupModel
entities
- the entities to set as selectedpublic final List<Entity> getSelectedEntities()
getSelectedEntities
in interface EntityLookupModel
public final boolean isCaseSensitive()
isCaseSensitive
in interface EntityLookupModel
public final EntityLookupModel setCaseSensitive(boolean caseSensitive)
setCaseSensitive
in interface EntityLookupModel
caseSensitive
- if true then this lookup model is case sensitive
public final boolean isWildcardPostfix()
isWildcardPostfix
in interface EntityLookupModel
public final EntityLookupModel setWildcardPostfix(boolean wildcardPostfix)
setWildcardPostfix
in interface EntityLookupModel
wildcardPostfix
- if true then a wildcard is automatically appended to the search string
public final boolean isWildcardPrefix()
isWildcardPrefix
in interface EntityLookupModel
public final EntityLookupModel setWildcardPrefix(boolean wildcardPrefix)
setWildcardPrefix
in interface EntityLookupModel
wildcardPrefix
- if true then a wildcard is automatically prefixed to the search string
public final String getWildcard()
getWildcard
in interface EntityLookupModel
public final EntityLookupModel setWildcard(String wildcard)
setWildcard
in interface EntityLookupModel
wildcard
- the wildcard
public final String getMultipleValueSeparator()
getMultipleValueSeparator
in interface EntityLookupModel
public final EntityLookupModel setMultipleValueSeparator(String multipleValueSeparator)
setMultipleValueSeparator
in interface EntityLookupModel
multipleValueSeparator
- the separator string
public final EntityLookupModel setAdditionalLookupCriteria(Criteria additionalLookupCriteria)
setAdditionalLookupCriteria
in interface EntityLookupModel
additionalLookupCriteria
- the additional lookup criteria
public final void refreshSearchText()
refreshSearchText
in interface EntityLookupModel
public final void setSearchString(String searchString)
setSearchString
in interface EntityLookupModel
searchString
- the search stringpublic final String getSearchString()
getSearchString
in interface EntityLookupModel
public final boolean searchStringRepresentsSelected()
searchStringRepresentsSelected
in interface EntityLookupModel
public final List<Entity> performQuery()
performQuery
in interface EntityLookupModel
public final EventObserver searchStringObserver()
searchStringObserver
in interface EntityLookupModel
public final void addSearchStringListener(ActionListener listener)
addSearchStringListener
in interface EntityLookupModel
listener
- a listener to be notified each time the search string changespublic final void addSelectedEntitiesListener(ActionListener listener)
addSelectedEntitiesListener
in interface EntityLookupModel
listener
- a listener to be notified each time the selected entities are changedpublic final void removeSearchStringListener(ActionListener listener)
removeSearchStringListener
in interface EntityLookupModel
listener
- the listener to removepublic final void removeSelectedEntitiesListener(ActionListener listener)
removeSelectedEntitiesListener
in interface EntityLookupModel
listener
- the listener to remove
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |