com.izforge.izpack.panels.userinput.field.search
Class SearchFieldReader

java.lang.Object
  extended by com.izforge.izpack.panels.userinput.field.ElementReader
      extended by com.izforge.izpack.panels.userinput.field.FieldReader
          extended by com.izforge.izpack.panels.userinput.field.search.SearchFieldReader
All Implemented Interfaces:
FieldConfig, SearchFieldConfig

public class SearchFieldReader
extends FieldReader
implements SearchFieldConfig

Search field reader.

Author:
Tim Anderson

Field Summary
 
Fields inherited from class com.izforge.izpack.panels.userinput.field.FieldReader
OMIT_FROM_AUTO, SPEC, VARIABLE
 
Constructor Summary
SearchFieldReader(IXMLElement field, Config config, PlatformModelMatcher matcher)
          Constructs a SearchFieldReader.
 
Method Summary
 String getCheckFilename()
          Returns the filename to check the existence of.
 List<String> getChoices()
          Returns the search choices.
 String getFilename()
          Returns the filename to search on.
 ResultType getResultType()
          Returns the result type.
 SearchType getSearchType()
          Returns the search type.
 int getSelectedIndex()
          Returns the index of the selected choice.
 
Methods inherited from class com.izforge.izpack.panels.userinput.field.FieldReader
getCondition, getDefaultValue, getDescription, getDisplayHiddenCondition, getField, getInitialValue, getLabel, getOmitFromAuto, getOsModels, getPacks, getProcessors, getReadonlyCondition, getSize, getSpec, getSpec, getSummaryKey, getText, getTooltip, getValidators, getValidators, getVariable, isDisplayHidden, isReadonly
 
Methods inherited from class com.izforge.izpack.panels.userinput.field.ElementReader
getComplexPanelCondition, getConfig, getOsModels, getPacks, getUnselectedPacks
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.izforge.izpack.panels.userinput.field.FieldConfig
getCondition, getDefaultValue, getDescription, getDisplayHiddenCondition, getInitialValue, getLabel, getOmitFromAuto, getOsModels, getPacks, getProcessors, getReadonlyCondition, getSize, getSummaryKey, getTooltip, getValidators, getValidators, getVariable, isDisplayHidden, isReadonly
 

Constructor Detail

SearchFieldReader

public SearchFieldReader(IXMLElement field,
                         Config config,
                         PlatformModelMatcher matcher)
Constructs a SearchFieldReader.

Parameters:
field - the field element
config - the configuration
Method Detail

getFilename

public String getFilename()
Returns the filename to search on.

Specified by:
getFilename in interface SearchFieldConfig
Returns:
the filename to search on. May be null

getCheckFilename

public String getCheckFilename()
Returns the filename to check the existence of.

Specified by:
getCheckFilename in interface SearchFieldConfig
Returns:
the filename to to check the existence of. May be null

getSearchType

public SearchType getSearchType()
Returns the search type.

Specified by:
getSearchType in interface SearchFieldConfig
Returns:
the search type

getResultType

public ResultType getResultType()
Returns the result type.

Specified by:
getResultType in interface SearchFieldConfig
Returns:
the result type
Throws:
IzPackException - if the attribute is not present or is invalid

getChoices

public List<String> getChoices()
Returns the search choices.

Specified by:
getChoices in interface SearchFieldConfig
Returns:
the search choices

getSelectedIndex

public int getSelectedIndex()
Returns the index of the selected choice.

A choice is selected if the "set" attribute is 'true'.

This is only valid after getChoices() is invoked.

Specified by:
getSelectedIndex in interface SearchFieldConfig
Returns:
the selected index or -1 if no choice is selected


Copyright © 2018. All rights reserved.