Class ConfigSectionImpl
java.lang.Object
com.biglybt.ui.config.ConfigSectionImpl
- All Implemented Interfaces:
BaseConfigSection
- Direct Known Subclasses:
BasicPluginConfigImpl, ConfigSectionBackupRestore, ConfigSectionConnection, ConfigSectionConnectionAdvanced, ConfigSectionConnectionDNS, ConfigSectionConnectionEncryption, ConfigSectionConnectionProxy, ConfigSectionFile, ConfigSectionFileMove, ConfigSectionFilePerformance, ConfigSectionFileTorrents, ConfigSectionFileTorrentsDecoding, ConfigSectionHolder, ConfigSectionInterfaceAlertsSWT, ConfigSectionInterfaceColorSWT, ConfigSectionInterfaceDisplaySWT, ConfigSectionInterfaceLanguage, ConfigSectionInterfaceLegacySWT, ConfigSectionInterfacePasswordSWT, ConfigSectionInterfaceStartSWT, ConfigSectionInterfaceSWT, ConfigSectionInterfaceTablesSWT, ConfigSectionInterfaceTags, ConfigSectionIPFilter, ConfigSectionLogging, ConfigSectionMode, ConfigSectionPlugins, ConfigSectionSecurity, ConfigSectionSharing, ConfigSectionStartShutdown, ConfigSectionStats, ConfigSectionTracker, ConfigSectionTrackerClient, ConfigSectionTrackerServer, ConfigSectionTransfer, ConfigSectionTransferAutoSpeedClassic, ConfigSectionTransferAutoSpeedSelect, ConfigSectionTransferAutoSpeedV2, ConfigSectionTransferLAN
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate intprivate String[]private booleanstatic final Stringprotected final Map<String, ParameterImpl> private final intprivate final Stringprivate ConfigSectionRebuildRunnerprivate final String -
Constructor Summary
ConstructorsConstructorDescriptionConfigSectionImpl(WeakReference<BasicPluginConfigModel> model_ref) ConfigSectionImpl(String sectionID, String parentSectionID) ConfigSectionImpl(String sectionID, String parentSectionID, int minUserMode) -
Method Summary
Modifier and TypeMethodDescriptionprotected final <T extends ParameterImpl>
Tprotected final <T extends ParameterImpl>
Tprotected final <T extends ParameterImpl>
Tprotected final <T extends ParameterImpl>
TvoidConfig view is closingfinal StringfindPluginParamKey(Parameter param) final StringIn order for the plugin to display its section correctly, a key in the Plugin language file will need to contain ConfigView.section.<getConfigSectionID() result>=The Section name.final intIndicate if additional options are available to display a hint to the usersfinal intReturns the minimum user mode needed for this section to be displayed.final Parameter[]final StringReturns section you want your configuration panel to be under.final ParameterImplgetPluginParam(String key) static StringgetSectionNameKey(String sectionID) protected StringguessParamName(Parameter param, boolean warnExists) final booleanisBuilt()final voidvoidRequest the UI to rebuild this config section.voidUser selected Save.final voidsetDefaultUITypesForAdd(String... defaultUITypes) Any Parameters added after this call will be auto-assigned these UI Typesfinal voidsetDefaultUserModeForAdd(int defaultMode) Any Parameters added after this call will be auto-assigned this user modevoidsetRebuildRunner(ConfigSectionRebuildRunner rebuildRunner) Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface BaseConfigSection
build
-
Field Details
-
L10N_SECTION_PREFIX
- See Also:
-
sectionID
-
parentSectionID
-
minUserMode
private final int minUserMode -
defaultMode
private int defaultMode -
isBuilt
private boolean isBuilt -
defaultUITypes
-
rebuildRunner
-
mapPluginParams
-
-
Constructor Details
-
ConfigSectionImpl
-
ConfigSectionImpl
-
ConfigSectionImpl
-
-
Method Details
-
getConfigSectionID
Description copied from interface:BaseConfigSectionIn order for the plugin to display its section correctly, a key in the Plugin language file will need to contain ConfigView.section.<getConfigSectionID() result>=The Section name.- Specified by:
getConfigSectionIDin interfaceBaseConfigSection- Returns:
- The name of the configuration section
-
getParentSectionID
Description copied from interface:BaseConfigSectionReturns section you want your configuration panel to be under. See BasicPluginConfigModel.SECTION_* constants. To add a subsection to your own ConfigSection, return the getConfigSectionID result of your parent.- Specified by:
getParentSectionIDin interfaceBaseConfigSection
-
postBuild
public final void postBuild()- Specified by:
postBuildin interfaceBaseConfigSection
-
isBuilt
public final boolean isBuilt()- Specified by:
isBuiltin interfaceBaseConfigSection
-
setDefaultUserModeForAdd
public final void setDefaultUserModeForAdd(int defaultMode) Any Parameters added after this call will be auto-assigned this user mode -
setDefaultUITypesForAdd
Any Parameters added after this call will be auto-assigned these UI Types- Parameters:
defaultUITypes-UIInstance.UIT_SWT, UIInstance.UIT_CONSOLE, etc
-
add
@SafeVarargs protected final <T extends ParameterImpl> T add(T param, List<Parameter>... otherLists) -
add
@SafeVarargs protected final <T extends ParameterImpl> T add(T param, int minMode, List<Parameter>... otherLists) -
add
@SafeVarargs protected final <T extends ParameterImpl> T add(String key, T param, List<Parameter>... otherLists) -
add
@SafeVarargs protected final <T extends ParameterImpl> T add(String key, T param, int minMode, List<Parameter>... otherLists) -
guessParamName
-
getParamArray
- Specified by:
getParamArrayin interfaceBaseConfigSection
-
getPluginParam
- Specified by:
getPluginParamin interfaceBaseConfigSection
-
findPluginParamKey
-
saveConfigSection
public void saveConfigSection()Description copied from interface:BaseConfigSectionUser selected Save. All saving of non-plugin tabs have been completed, as well as saving of plugins that implement com.biglybt.pif.ui.config parameters.- Specified by:
saveConfigSectionin interfaceBaseConfigSection
-
deleteConfigSection
public void deleteConfigSection()Description copied from interface:BaseConfigSectionConfig view is closing- Specified by:
deleteConfigSectionin interfaceBaseConfigSection
-
getMinUserMode
public final int getMinUserMode()Description copied from interface:BaseConfigSectionReturns the minimum user mode needed for this section to be displayed. Note: Section may be visually displayed, but with a notification that modification is unavailable at current user mode.- Specified by:
getMinUserModein interfaceBaseConfigSection- See Also:
-
setRebuildRunner
- Specified by:
setRebuildRunnerin interfaceBaseConfigSection
-
requestRebuild
public void requestRebuild()Description copied from interface:BaseConfigSectionRequest the UI to rebuild this config section. For SWT, all SWT objects will be disposed and recreated.- Specified by:
requestRebuildin interfaceBaseConfigSection
-
getMaxUserMode
public final int getMaxUserMode()Description copied from interface:BaseConfigSectionIndicate if additional options are available to display a hint to the users- Specified by:
getMaxUserModein interfaceBaseConfigSection- Returns:
- the highest user mode that reveals additional options (0 = Beginner, 1 = Intermediate, 2 = Advanced)
-
getSectionNameKey
- Specified by:
getSectionNameKeyin interfaceBaseConfigSection
-
getSectionNameKey
-
search
- Specified by:
searchin interfaceBaseConfigSection
-