public class FieldDescription
extends java.lang.Object
FieldHelper
.Constructor and Description |
---|
FieldDescription(Resource rsrc)
Construct a new field description for a field resource.
|
FieldDescription(Resource rsrc,
java.lang.String name)
Construct a new field description for a field resource
and set the name property.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getConstraintMessage()
The error message if the constraint is not met.
|
java.lang.String |
getConstraintType()
Get the constraint type (might be null).
|
Resource |
getFieldResource()
Return the associated field resource
|
java.lang.String |
getName()
Return the name of the field.
|
java.lang.String |
getRequiredMessage()
Return the error message for a required field.
|
boolean |
isMultiValue()
Is this a multi value field?
|
boolean |
isPrivate()
Is this a private field?
|
boolean |
isReadOnly()
Is this field readonly?
|
boolean |
isRequired()
Is this field required?
|
void |
setConstraintMessage(java.lang.String constraintMsg)
Set error message if the constraint is not met.
|
void |
setConstraintType(java.lang.String constraintType)
Set the constraint type (might be null).
|
void |
setMultiValue(boolean flag)
Set if this is a private field.
|
void |
setName(java.lang.String name)
Set the name for the field.
|
void |
setPrivateField(boolean flag)
Set if this is a private field.
|
void |
setReadOnly(boolean readOnly)
Set if this field is readonly.
|
void |
setRequired(boolean required)
Set if this field is required.
|
void |
setRequiredMessage(java.lang.String requiredMsg)
Set the error message for a required field.
|
void |
update(Resource rsrc) |
public FieldDescription(Resource rsrc)
rsrc
- field resourcepublic FieldDescription(Resource rsrc, java.lang.String name)
rsrc
- The resourcename
- The field name.public void update(Resource rsrc)
public Resource getFieldResource()
public java.lang.String getName()
public void setName(java.lang.String name)
name
- field namepublic boolean isRequired()
public void setRequired(boolean required)
required
- indicates whether field is requiredpublic java.lang.String getRequiredMessage()
public void setRequiredMessage(java.lang.String requiredMsg)
requiredMsg
- error message for a required fieldpublic java.lang.String getConstraintType()
public void setConstraintType(java.lang.String constraintType)
constraintType
- constraint typepublic java.lang.String getConstraintMessage()
public void setConstraintMessage(java.lang.String constraintMsg)
constraintMsg
- error message if the constraint is not metpublic boolean isReadOnly()
public void setReadOnly(boolean readOnly)
readOnly
- indicates whether field is read onlypublic boolean isPrivate()
public void setPrivateField(boolean flag)
flag
- indicates whether field is privatepublic boolean isMultiValue()
public void setMultiValue(boolean flag)
flag
- indicates whether field is multi valueCopyright © 2010 - 2020 Adobe. All Rights Reserved