Package chemaxon.checkers
Class StructureCheckerDescriptor
- java.lang.Object
-
- chemaxon.checkers.StructureCheckerDescriptor
-
- All Implemented Interfaces:
Cloneable
@PublicAPI public final class StructureCheckerDescriptor extends Object implements Cloneable
Descriptor forStructureChecker
- Since:
- 5.7
-
-
Field Summary
Fields Modifier and Type Field Description static String
ACTIONSTRING_TOKEN
action string token of the checkerstatic String
CUSTOM_NAME
custom name propertystatic String
DESCRIPTION
description of checkerstatic String
EDITOR_CLASS_NAME
editor class name property of checkerstatic String
FIX_MODE
fix mode propertystatic String
FIXER_CLASS_NAME
fixer class name propertystatic String
HELP_TEXT
help text for checkerstatic String
ICON_PATH
icon path of checkerstatic String
LOCAL_MENU_NAME
local menu name property of checkerstatic String
MORE_ERROR_MESSAGE
multiple error message for checkerstatic String
NAME
name property of checkerstatic String
NO_ERROR_MESSAGE
no error message for checkerstatic String
ONE_ERROR_MESSAGE
single error message for checkerstatic String
SEVERITY
severity of checker
-
Constructor Summary
Constructors Constructor Description StructureCheckerDescriptor(Class<? extends StructureChecker> checkerClass)
Constructs a descriptor based on checker class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addPropertyChangeListener(PropertyChangeListener listener)
Add a PropertyChangeListener to the listener list.void
addPropertyChangeListener(String propertyName, PropertyChangeListener listener)
Add a PropertyChangeListener for a specific property.StructureCheckerDescriptor
clone()
boolean
equals(Object obj)
String[]
getActionStringTokens()
Gets the action string token of the checkerString
getCustomName()
Returns the customNameString
getDescription()
Returns the descriptionString
getEditorClassName()
Returns the editorClassNameString
getFixerClassName()
Returns the fixerClassNameFixMode
getFixMode()
Returns the fixModeString
getHelpText()
Returns the help textIcon
getIcon()
Returns theIcon
related to iconPath propertyString
getIconPath()
Returns the icon pathString
getIdentifier()
Returns the checker identifierString
getLocalMenuName()
Returns the local menu nameString
getMoreErrorMessage()
Returns the more error messageString
getName()
Returns the checker nameString
getNoErrorMessage()
Returns the no error message of the concerning checkerString
getOneErrorMessage()
Returns the one error messageCheckerSeverity
getSeverity()
Returns the severityint
hashCode()
void
removePropertyChangeListener(PropertyChangeListener listener)
Remove a PropertyChangeListener from the listener list.void
removePropertyChangeListener(String propertyName, PropertyChangeListener listener)
Remove a PropertyChangeListener for a specific property.void
setActionStringTokens(String[] actionStringTokens)
Sets the action string token of the checkervoid
setCustomName(String customName)
Sets the customNamevoid
setDescription(String description)
Sets the description of the concerning checkervoid
setEditorClassName(String editorClassName)
Sets the editorClassNamevoid
setFixerClassName(String fixerClassName)
Sets the fixerClassNamevoid
setFixMode(FixMode fixMode)
Sets the fixModevoid
setHelpText(String helpText)
Sets the help text of the concerning checkervoid
setIconPath(String iconPath)
Sets the icon pathvoid
setIdentifier(String checkerId)
Sets the checker identifiervoid
setLocalMenuName(String localMenuName)
Sets the local menu name of the concerning checkervoid
setMoreErrorMessage(String moreErrorMessage)
Sets the more error message of the concerning checkervoid
setName(String name)
Sets the checker namevoid
setNoErrorMessage(String noErrorMessage)
Sets the no error message of the concerning checkervoid
setOneErrorMessage(String oneErrorMessage)
Sets the one error message of the concerning checkervoid
setSeverity(CheckerSeverity severity)
Sets the severity of the concerning checkerString
toString()
-
-
-
Field Detail
-
CUSTOM_NAME
public static final String CUSTOM_NAME
custom name property- See Also:
- Constant Field Values
-
FIX_MODE
public static final String FIX_MODE
fix mode property- See Also:
- Constant Field Values
-
FIXER_CLASS_NAME
public static final String FIXER_CLASS_NAME
fixer class name property- See Also:
- Constant Field Values
-
EDITOR_CLASS_NAME
public static final String EDITOR_CLASS_NAME
editor class name property of checker- See Also:
- Constant Field Values
-
NAME
public static final String NAME
name property of checker- See Also:
- Constant Field Values
-
LOCAL_MENU_NAME
public static final String LOCAL_MENU_NAME
local menu name property of checker- See Also:
- Constant Field Values
-
NO_ERROR_MESSAGE
public static final String NO_ERROR_MESSAGE
no error message for checker- See Also:
- Constant Field Values
-
ONE_ERROR_MESSAGE
public static final String ONE_ERROR_MESSAGE
single error message for checker- See Also:
- Constant Field Values
-
MORE_ERROR_MESSAGE
public static final String MORE_ERROR_MESSAGE
multiple error message for checker- See Also:
- Constant Field Values
-
HELP_TEXT
public static final String HELP_TEXT
help text for checker- See Also:
- Constant Field Values
-
DESCRIPTION
public static final String DESCRIPTION
description of checker- See Also:
- Constant Field Values
-
ICON_PATH
public static final String ICON_PATH
icon path of checker- See Also:
- Constant Field Values
-
SEVERITY
public static final String SEVERITY
severity of checker- See Also:
- Constant Field Values
-
ACTIONSTRING_TOKEN
public static final String ACTIONSTRING_TOKEN
action string token of the checker- See Also:
- Constant Field Values
-
-
Constructor Detail
-
StructureCheckerDescriptor
public StructureCheckerDescriptor(Class<? extends StructureChecker> checkerClass) throws IllegalArgumentException
Constructs a descriptor based on checker class.CheckerInfo
of specified class will be used for descriptor generation- Parameters:
checkerClass
- the class used to generate descriptor- Throws:
IllegalArgumentException
- if the checkerClass is null
-
-
Method Detail
-
getIdentifier
public String getIdentifier()
Returns the checker identifier- Returns:
- the checker identifier
-
setIdentifier
public void setIdentifier(String checkerId)
Sets the checker identifier- Parameters:
checkerId
- the checker identifier
-
getName
public String getName()
Returns the checker name- Returns:
- the checker name
-
setName
public void setName(String name)
Sets the checker name- Parameters:
name
- the new name
-
getLocalMenuName
public String getLocalMenuName()
Returns the local menu name- Returns:
- the local menu name
-
setLocalMenuName
public void setLocalMenuName(String localMenuName)
Sets the local menu name of the concerning checker- Parameters:
localMenuName
- is aString
object which represents the local menu name of the concerning checker
-
getNoErrorMessage
public String getNoErrorMessage()
Returns the no error message of the concerning checker- Returns:
- the no error message
-
setNoErrorMessage
public void setNoErrorMessage(String noErrorMessage)
Sets the no error message of the concerning checker- Parameters:
noErrorMessage
- is aString
object which represents the message given by the concerned checker is no error found
-
getOneErrorMessage
public String getOneErrorMessage()
Returns the one error message- Returns:
- the one error message
-
setOneErrorMessage
public void setOneErrorMessage(String oneErrorMessage)
Sets the one error message of the concerning checker- Parameters:
oneErrorMessage
- is aString
object which represents the message given by the concerned checker if one error found
-
getMoreErrorMessage
public String getMoreErrorMessage()
Returns the more error message- Returns:
- the more error message
-
setMoreErrorMessage
public void setMoreErrorMessage(String moreErrorMessage)
Sets the more error message of the concerning checker- Parameters:
moreErrorMessage
- is aString
object which represents the message given by the concerned checker if more than one error found
-
getHelpText
public String getHelpText()
Returns the help text- Returns:
- the help text
-
setHelpText
public void setHelpText(String helpText)
Sets the help text of the concerning checker- Parameters:
helpText
- is aString
object which represents the detailed help text of the concerning checker
-
getDescription
public String getDescription()
Returns the description- Returns:
- the description
-
setDescription
public void setDescription(String description)
Sets the description of the concerning checker- Parameters:
description
- is aString
object which represents the description of the concerning checker
-
getIconPath
public String getIconPath()
Returns the icon path- Returns:
- the icon path
-
setIconPath
public void setIconPath(String iconPath)
Sets the icon path- Parameters:
iconPath
- represents the path of the icon image as aString
object
-
getEditorClassName
public String getEditorClassName()
Returns the editorClassName- Returns:
- the editorClassName
-
setEditorClassName
public void setEditorClassName(String editorClassName)
Sets the editorClassName- Parameters:
editorClassName
- the editorClassName to set
-
getCustomName
public String getCustomName()
Returns the customName- Returns:
- the customName
-
setCustomName
public void setCustomName(String customName)
Sets the customName- Parameters:
customName
- the customName to set
-
getFixMode
public FixMode getFixMode()
Returns the fixMode- Returns:
- the fixMode
-
setFixMode
public void setFixMode(FixMode fixMode)
Sets the fixMode- Parameters:
fixMode
- the fixMode to set
-
getFixerClassName
public String getFixerClassName()
Returns the fixerClassName- Returns:
- the fixerClassName
-
setFixerClassName
public void setFixerClassName(String fixerClassName)
Sets the fixerClassName- Parameters:
fixerClassName
- the fixerClassName to set
-
getSeverity
public CheckerSeverity getSeverity()
Returns the severity- Returns:
- the severity
-
setSeverity
public void setSeverity(CheckerSeverity severity)
Sets the severity of the concerning checker- Parameters:
severity
- is an instance ofCheckerSeverity
which represents the severity of the concerning checker
-
getActionStringTokens
public String[] getActionStringTokens()
Gets the action string token of the checker- Returns:
- the action string token of the checker
-
setActionStringTokens
public void setActionStringTokens(String[] actionStringTokens)
Sets the action string token of the checker- Parameters:
actionStringTokens
- the action string tokens of the checker
-
addPropertyChangeListener
public void addPropertyChangeListener(PropertyChangeListener listener)
Add a PropertyChangeListener to the listener list. The listener is registered for all properties. The same listener object may be added more than once, and will be called as many times as it is added. Iflistener
is null, no exception is thrown and no action is taken.- Parameters:
listener
- The PropertyChangeListener to be added
-
removePropertyChangeListener
public void removePropertyChangeListener(PropertyChangeListener listener)
Remove a PropertyChangeListener from the listener list. This removes a PropertyChangeListener that was registered for all properties. Iflistener
was added more than once to the same event source, it will be notified one less time after being removed. Iflistener
is null, or was never added, no exception is thrown and no action is taken.- Parameters:
listener
- The PropertyChangeListener to be removed
-
addPropertyChangeListener
public void addPropertyChangeListener(String propertyName, PropertyChangeListener listener)
Add a PropertyChangeListener for a specific property. The listener will be invoked only when a call on firePropertyChange names that specific property. The same listener object may be added more than once. For each property, the listener will be invoked the number of times it was added for that property. IfpropertyName
orlistener
is null, no exception is thrown and no action is taken.- Parameters:
propertyName
- The name of the property to listen on.listener
- The PropertyChangeListener to be added
-
removePropertyChangeListener
public void removePropertyChangeListener(String propertyName, PropertyChangeListener listener)
Remove a PropertyChangeListener for a specific property. Iflistener
was added more than once to the same event source for the specified property, it will be notified one less time after being removed. IfpropertyName
is null, no exception is thrown and no action is taken. Iflistener
is null, or was never added for the specified property, no exception is thrown and no action is taken.- Parameters:
propertyName
- The name of the property that was listened on.listener
- The PropertyChangeListener to be removed
-
getIcon
public Icon getIcon()
Returns theIcon
related to iconPath property- Returns:
- the
Icon
related to iconPath property
-
clone
public StructureCheckerDescriptor clone() throws CloneNotSupportedException
- Overrides:
clone
in classObject
- Throws:
CloneNotSupportedException
-
-