Package megamek.common.options
Class AbstractOptionsInfo
java.lang.Object
megamek.common.options.AbstractOptionsInfo
- All Implemented Interfaces:
IOptionsInfo
Abstract base class for Singletons representing Options' static information such as displayable name, description
etc. The derived classes must implement the Singleton pattern
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected StringgetGroupDisplayableName(String groupName) Returns the user-friendly NLS dependent name suitable for displaying in the options editor dialogs etc.Returns theEnumerationof theIBasicOptionGroupgetOptionInfo(String name) Returns theIOptionInfofor the specified option
-
Field Details
-
GROUP_SUFFIX
- See Also:
-
OPTION_SUFFIX
- See Also:
-
DISPLAYABLE_NAME_SUFFIX
- See Also:
-
DESCRIPTION_SUFFIX
- See Also:
-
-
Constructor Details
-
AbstractOptionsInfo
Protected constructor. It is called only by descendants. The name must be unique because it's used to query the NLS dependent information from the resource bundle.- Parameters:
name- options info name
-
-
Method Details
-
getOptionInfo
Description copied from interface:IOptionsInfoReturns theIOptionInfofor the specified option- Specified by:
getOptionInfoin interfaceIOptionsInfo- Parameters:
name- option name- Returns:
- the
IOptionInfofor the specified option - See Also:
-
getGroups
Description copied from interface:IOptionsInfoReturns theEnumerationof theIBasicOptionGroup- Specified by:
getGroupsin interfaceIOptionsInfo- Returns:
- the
Enumerationof theIBasicOptionGroup
-
getGroupDisplayableName
Returns the user-friendly NLS dependent name suitable for displaying in the options editor dialogs etc.- Parameters:
groupName- the group name which we want the display format- Returns:
- group displayable name
-