Package ro.sync.ecss.conditions
Class ProfilingAttributeStylePO
- java.lang.Object
-
- ro.sync.ecss.conditions.ProfilingAttributeStylePO
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Cloneable
,PersistentObject
@API(type=EXTENDABLE, src=PRIVATE) public class ProfilingAttributeStylePO extends java.lang.Object implements PersistentObject
Contains information about a profiling attribute value and associated profiling styles.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ANY_VALUE
Wildcard constant for the attribute value.static java.lang.String
DOUBLE_UNDERLINE
Text decoration double underlinestatic int
NO_COLOR
No color.static java.lang.String
OVERLINE
Text decoration overlinestatic java.lang.String
UNDERLINE
Text decoration underline
-
Constructor Summary
Constructors Constructor Description ProfilingAttributeStylePO()
Constructor.ProfilingAttributeStylePO(java.lang.String framework, java.lang.String attributeName, java.lang.String attributeValue, int foreground, int background, java.lang.String textDecoration, boolean bold, boolean italic)
Constructor.ProfilingAttributeStylePO(java.lang.String framework, java.lang.String attributeName, java.lang.String attributGroupName, java.lang.String attributeValue, int foreground, int background, java.lang.String textDecoration, boolean bold, boolean italic)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
checkValid()
Check if object is valid to be used.java.lang.Object
clone()
Forces all the persistent objects to be cloneable.boolean
equals(java.lang.Object obj)
java.lang.String
getAttributeGroupName()
java.lang.String
getAttributeName()
java.lang.String
getAttributeValue()
int
getBackgroundColor()
java.lang.String
getDisplayedValue()
Get the display value.java.lang.String
getDocumentTypePattern()
int
getForegroundColor()
java.lang.String[]
getNotPersistentFieldNames()
java.lang.String
getTextDecoration()
Get the text decoration to be applied on the content profiled by using this condition value.int
hashCode()
boolean
isBold()
boolean
isEmpty()
boolean
isItalic()
void
setAttributeGroupName(java.lang.String attributeGroupName)
Set the attribute group name.void
setAttributeName(java.lang.String attributeName)
Set the profiling attribute name.void
setAttributeValue(java.lang.String attributeValue)
Set the profiling attribute value.void
setBackgroundColor(int backgroundColor)
Set the background color to be applied on the content profiled by using this condition value.void
setBold(boolean bold)
void
setDocTypePattern(java.lang.String docTypePattern)
Set the document type pattern.void
setForegroundColor(int foregroundColor)
Set the foreground color to be applied on the content profiled by using this condition value.void
setItalic(boolean italic)
void
setTextDecoration(java.lang.String textDecoration)
java.lang.String
toString()
-
-
-
Field Detail
-
UNDERLINE
public static final java.lang.String UNDERLINE
Text decoration underline- See Also:
- Constant Field Values
-
DOUBLE_UNDERLINE
public static final java.lang.String DOUBLE_UNDERLINE
Text decoration double underline- See Also:
- Constant Field Values
-
OVERLINE
public static final java.lang.String OVERLINE
Text decoration overline- See Also:
- Constant Field Values
-
ANY_VALUE
public static final java.lang.String ANY_VALUE
Wildcard constant for the attribute value.- See Also:
- Constant Field Values
-
NO_COLOR
public static final int NO_COLOR
No color.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ProfilingAttributeStylePO
public ProfilingAttributeStylePO()
Constructor.
-
ProfilingAttributeStylePO
public ProfilingAttributeStylePO(java.lang.String framework, java.lang.String attributeName, java.lang.String attributeValue, int foreground, int background, java.lang.String textDecoration, boolean bold, boolean italic)
Constructor.- Parameters:
framework
- The name of the document type.attributeName
- The attribute name.attributeValue
- The attribute value.foreground
- Foreground color to be applied on the content profiled by using this condition value.background
- Background color to be applied on the content profiled by using this condition value.textDecoration
- Text decoration to be applied on the content profiled by using this condition value.bold
-true
if the bold style should be applied on the content profiled by using this condition value.italic
-true
if the italic style should be applied on the content profiled by using this condition value.
-
ProfilingAttributeStylePO
public ProfilingAttributeStylePO(java.lang.String framework, java.lang.String attributeName, java.lang.String attributGroupName, java.lang.String attributeValue, int foreground, int background, java.lang.String textDecoration, boolean bold, boolean italic)
Constructor.- Parameters:
framework
- The name of the document type.attributeName
- The attribute name.attributGroupName
- The attribute group name.attributeValue
- The attribute value.foreground
- Foreground color to be applied on the content profiled by using this condition value.background
- Background color to be applied on the content profiled by using this condition value.textDecoration
- Text decoration to be applied on the content profiled by using this condition value.bold
-true
if the bold style should be applied on the content profiled by using this condition value.italic
-true
if the italic style should be applied on the content profiled by using this condition value.
-
-
Method Detail
-
setDocTypePattern
public void setDocTypePattern(java.lang.String docTypePattern)
Set the document type pattern.- Parameters:
docTypePattern
- The document type pattern.
-
setAttributeName
public void setAttributeName(java.lang.String attributeName)
Set the profiling attribute name.- Parameters:
attributeName
- The profiling attribute name.
-
setAttributeGroupName
public void setAttributeGroupName(java.lang.String attributeGroupName)
Set the attribute group name.- Parameters:
attributeGroupName
- The attributeGroupName to set.
-
setAttributeValue
public void setAttributeValue(java.lang.String attributeValue)
Set the profiling attribute value.- Parameters:
attributeValue
- The profiling attribute value.
-
setForegroundColor
public void setForegroundColor(int foregroundColor)
Set the foreground color to be applied on the content profiled by using this condition value.- Parameters:
foregroundColor
- The foreground color.
-
getForegroundColor
public int getForegroundColor()
- Returns:
- Returns the foreground color to be applied on the content profiled by using this condition value.
-
setBackgroundColor
public void setBackgroundColor(int backgroundColor)
Set the background color to be applied on the content profiled by using this condition value.- Parameters:
backgroundColor
- The background color.
-
getBackgroundColor
public int getBackgroundColor()
- Returns:
- Returns the background color to be applied on the content profiled by using this condition value.
-
checkValid
public void checkValid() throws InvalidPersistentObjException
Description copied from interface:PersistentObject
Check if object is valid to be used. Method is called after it is deserialized from options. If not then throw anInvalidPersistentObjException
exception.- Specified by:
checkValid
in interfacePersistentObject
- Throws:
InvalidPersistentObjException
- Thrown when instance is not valid.- See Also:
PersistentObject.checkValid()
-
getNotPersistentFieldNames
public java.lang.String[] getNotPersistentFieldNames()
- Specified by:
getNotPersistentFieldNames
in interfacePersistentObject
- Returns:
- The names of the field from this object which should not be serialized.
- See Also:
PersistentObject.getNotPersistentFieldNames()
-
clone
public java.lang.Object clone()
Description copied from interface:PersistentObject
Forces all the persistent objects to be cloneable.- Specified by:
clone
in interfacePersistentObject
- Overrides:
clone
in classjava.lang.Object
- Returns:
- A clone of this object. The clone and the original are disjunct. They share only immutable objects, like Strings, Integers, etc.
- See Also:
Object.clone()
-
getDocumentTypePattern
public java.lang.String getDocumentTypePattern()
- Returns:
- The document type pattern
-
getAttributeName
public java.lang.String getAttributeName()
- Returns:
- The attribute name.
-
getAttributeGroupName
public java.lang.String getAttributeGroupName()
- Returns:
- The attribute group name.
-
getAttributeValue
public java.lang.String getAttributeValue()
- Returns:
- The attribute value
-
setTextDecoration
public void setTextDecoration(java.lang.String textDecoration)
- Parameters:
textDecoration
- Text decoration to be applied on the content profiled by using this condition value.
-
getTextDecoration
public java.lang.String getTextDecoration()
Get the text decoration to be applied on the content profiled by using this condition value.
Example values: "underline", "overline", "double_underline".- Returns:
- Returns the text decoration.
-
setBold
public void setBold(boolean bold)
- Parameters:
bold
-true
if the bold style should be applied on the content profiled by using this condition value.
-
isBold
public boolean isBold()
- Returns:
- Returns
true
if the bold style should be applied on the content profiled by using this condition value.
-
setItalic
public void setItalic(boolean italic)
- Parameters:
italic
-true
if the italic style should be applied on the content profiled by using this condition value.
-
isItalic
public boolean isItalic()
- Returns:
- Returns
true
if the italic style should be applied on the content profiled by using this condition value.
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
- See Also:
Object.equals(java.lang.Object)
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
- See Also:
Object.hashCode()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
- See Also:
Object.toString()
-
isEmpty
public boolean isEmpty()
- Returns:
true
if the profiling style is empty, meaning no text style, decoration and colors have been set.
-
getDisplayedValue
public java.lang.String getDisplayedValue()
Get the display value. If the attribute group is defined, will be contains by the displayed value.- Returns:
- The displayed value.
-
-