public class PropertyHandler extends java.lang.Object implements RevisionHandler
Constructor and Description |
---|
PropertyHandler()
initializes the handling
|
Modifier and Type | Method and Description |
---|---|
void |
addAllowed(java.lang.Class c,
java.lang.String displayName)
adds the given property (display name) to the list of allowed properties
for the specified class.
|
void |
addIgnored(java.lang.Class c,
java.lang.String displayName)
adds the given class with the display name of a property to the ignore list.
|
void |
addIgnored(java.lang.String displayName)
adds the given display name of a property to the ignore list.
|
java.util.Enumeration |
allowed()
returns an enumeration of the classnames for which only certain properties
(display names) are allowed
|
java.lang.String |
getRevision()
Returns the revision string.
|
java.util.Enumeration |
ignored()
returns an enumeration of the stored display names and classes of
properties to ignore.
NOTE: String and Class Objects are mixed in this enumeration, depending whether it is a global property to ignore or just one for a certain class! |
boolean |
isAllowed(java.lang.Class c,
java.lang.String displayName)
returns whether the given property (display name) is allowed for the
given class.
|
boolean |
isAllowed(java.lang.Object o,
java.lang.String displayName)
returns whether the given property (display name) is allowed for the given
object .
|
boolean |
isIgnored(java.lang.Class c,
java.lang.String displayName)
checks whether the given display name of a certain class is an ignored
property.
|
boolean |
isIgnored(java.lang.Object o,
java.lang.String displayName)
checks whether the given display name of a given object is an ignored
property.
|
boolean |
isIgnored(java.lang.String displayName)
checks whether the given display name is an ignored property
|
boolean |
removeAllowed(java.lang.Class c,
java.lang.String displayName)
removes the given property (display name) for the specified class from
the list of allowed properties.
|
boolean |
removeIgnored(java.lang.Class c,
java.lang.String displayName)
removes the given display name from the ignore list of the class.
|
boolean |
removeIgnored(java.lang.String displayName)
removes the given display name from the ignore list.
|
public java.util.Enumeration ignored()
m_Ignored
public void addIgnored(java.lang.String displayName)
__root__.options
) or only a
property name (e.g. options
). In the latter case it matches
all occurences of this display name.displayName
- the property to ignorem_Ignored
public void addIgnored(java.lang.Class c, java.lang.String displayName)
c
- the class for which a property is to be ignoreddisplayName
- the property to ignorem_Ignored
public boolean removeIgnored(java.lang.String displayName)
displayName
- the property to remove from the ignore listm_Ignored
public boolean removeIgnored(java.lang.Class c, java.lang.String displayName)
c
- the class to remove the property fromdisplayName
- the property to remove from the ignore listm_Ignored
public boolean isIgnored(java.lang.String displayName)
displayName
- the property to check whether it is on the ignore listm_Ignored
public boolean isIgnored(java.lang.Class c, java.lang.String displayName)
isIgnored(Object,String)
.c
- the class to check the property fordisplayName
- the property to check whether it is on the ignore listm_Ignored
,
isIgnored(Object, String)
public boolean isIgnored(java.lang.Object o, java.lang.String displayName)
instanceof
. If the class is not stored then it will default
to false
, since there are no restrictions for this class.o
- the object to check the property fordisplayName
- the property to check whether it is on the ignore listm_Ignored
public java.util.Enumeration allowed()
public void addAllowed(java.lang.Class c, java.lang.String displayName)
c
- the class to add a property fordisplayName
- the property to allow for the classm_Allowed
public boolean removeAllowed(java.lang.Class c, java.lang.String displayName)
c
- the class to remove the property fordisplayName
- the property to removem_Allowed
public boolean isAllowed(java.lang.Class c, java.lang.String displayName)
isAllowed(Object,String)
.c
- the class to check the property fordisplayName
- the property (display name) to checkm_Allowed
,
isAllowed(Object, String)
public boolean isAllowed(java.lang.Object o, java.lang.String displayName)
instanceof
. If the class is not stored then it will default
to true
, since there are no restrictions for this class.o
- the object to check the property fordisplayName
- the property (display name) to checkpublic java.lang.String getRevision()
getRevision
in interface RevisionHandler