Package com.inet.pdfc.config
Class DefaultSetting
java.lang.Object
com.inet.pdfc.config.DefaultSetting
- All Implemented Interfaces:
Settings
,ColorProvider
,Serializable
This is the Defaultsetting with the default values. This setting will be used for the first installation. All setting
for
DiffGroup.GroupType
and Settings.EXPORT
are enabled Setting for
Settings.OPTION
are disabled Differencemarker color (Settings.METAOPTION
) are blue AddAndRemoved
Elements are red Modified content are orange Modified styles are red Meta Data changed are light blue- Since:
- 4.1
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.inet.pdfc.config.Settings
Settings.EXPORT, Settings.FILTER, Settings.METAOPTION, Settings.OPTION
-
Field Summary
Fields inherited from interface com.inet.pdfc.config.Settings
IMAGE_SCALE_FACTOR, MAX_ERRORS_PER_FILE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription@Nonnull Settings
copy()
Create a copy of the current settingList<ObjectSetting<?>>
Returns all registered additional settings.getColor
(@Nonnull com.inet.pdfc.config.ColorSetting colorSetting) Get the color for a setting@Nonnull Color
getMarkerColor
(DiffGroup.GroupType content) Returns the color of the marker for a difference group of the given type@Nonnull Color
getOutlineColor
(DiffGroup.GroupType content) Returns the color to mark the difference elements inside a difference group of the given type@Nullable Object
getSetting
(String setting) Return the value for this settingboolean
isEnabled
(VisibilitySetting content) Get the visibility for this settingvoid
Set the color for this setting.void
setEnabled
(boolean isVisible, @Nonnull VisibilitySetting... visibles) Set the visibility for this settingvoid
setMarkerColor
(@Nonnull Color color, DiffGroup.GroupType content) Set the color for the marker.void
setSetting
(@Nullable Object value, String setting) Set the specific setting with the value
-
Constructor Details
-
DefaultSetting
public DefaultSetting()The Defaultsetting with the default values- Since:
- 4.1
-
-
Method Details
-
getAllObjectSettingNames
Returns all registered additional settings. To query the current value of the setting passVisibilitySetting.name()
to theSettings.getSetting(String)
method.- Specified by:
getAllObjectSettingNames
in interfaceSettings
- Returns:
- all additional settings, not
null
-
setMarkerColor
Set the color for the marker. Overrides the default provided by {linkColorProvider.getMarkerColor(DiffGroup.GroupType)
. (For visible set the alpha to 0)- Specified by:
setMarkerColor
in interfaceSettings
- Parameters:
color
- the marker colorcontent
- the group type tp set the marker color for
-
setColor
Set the color for this setting. If the key is aDiffGroup.GroupType
, it overrides the default provided byColorProvider.getOutlineColor(DiffGroup.GroupType)
).
Note: Colors forDiffGroup.GroupType
s should be semi-transparent.- Specified by:
setColor
in interfaceSettings
- Parameters:
color
- the color to be used to the markupsetting
- the setting key. e.G. aDiffGroup.GroupType
or theSettings.METAOPTION.ALLOUTLINEMARKER
- See Also:
-
setEnabled
Set the visibility for this setting- Specified by:
setEnabled
in interfaceSettings
- Parameters:
isVisible
- true for visible otherwise falsevisibles
- the visibility setting key(s) to update the vsibility for- See Also:
-
isEnabled
Get the visibility for this setting -
getMarkerColor
Returns the color of the marker for a difference group of the given type- Specified by:
getMarkerColor
in interfaceColorProvider
- Parameters:
content
- the type of the difference group- Returns:
- the color of the marker for a difference group, should not be null
-
getColor
Get the color for a setting -
getSetting
Return the value for this setting- Specified by:
getSetting
in interfaceSettings
- Parameters:
setting
- the setting name- Returns:
- value for this setting or null if no setting be set.
-
setSetting
Set the specific setting with the value- Specified by:
setSetting
in interfaceSettings
- Parameters:
value
- value for the setting or null for remove the settingsetting
- the setting name, usuallyVisibilitySetting.name()
-
copy
Create a copy of the current setting -
getOutlineColor
Returns the color to mark the difference elements inside a difference group of the given type- Specified by:
getOutlineColor
in interfaceColorProvider
- Parameters:
content
- the type of the difference group- Returns:
- the color to mark the difference elements, should not be null
-