public class MetaProperty extends Meta implements Cloneable, Features.Property
Validation
,
MetaBean
,
Serialized FormparentMetaBean
DEFAULT_VALUE, DENIED, ENUM, HIDDEN, JAVASCRIPT_VALIDATION_FUNCTIONS, MANDATORY, MAX_LENGTH, MAX_VALUE, MIN_LENGTH, MIN_VALUE, PREFERRED, READONLY, REF_BEAN_ID, REF_BEAN_TYPE, REF_CASCADE, REG_EXP, TIME_LAG, UNIQUE_KEY
Constructor and Description |
---|
MetaProperty()
Create a new MetaProperty instance.
|
Modifier and Type | Method and Description |
---|---|
MetaProperty |
clone() |
String[] |
getJavaScriptValidations()
Deprecated.
|
MetaBean |
getMetaBean()
Get the metabean of the target bean (mainly for relationships).
|
String |
getName()
Get the name of this property.
|
Type |
getType()
Get the type of this property.
|
Class<?> |
getTypeClass()
Resolve the type of this property to a class.
|
boolean |
isMandatory()
Learn whether this property is considered mandatory.
|
boolean |
isRelationship()
Learn whether this property is considered a relationship.
|
void |
setMandatory(boolean mandatory)
Set this property as being mandatory (or not).
|
void |
setMetaBean(MetaBean metaBean)
Set the MetaBean of this
MetaProperty . |
void |
setName(String name)
Set the name of this property.
|
void |
setType(Type type)
Set the type of this property.
|
String |
toString() |
getParentMetaBean
addValidation, copy, copyInto, createFeaturesMap, getFeature, getFeature, getFeatures, getValidations, hasValidation, initFeature, putFeature, setValidations
public MetaBean getMetaBean()
public void setMetaBean(MetaBean metaBean)
MetaProperty
.metaBean
- to setpublic boolean isRelationship()
true
if it has a MetaBean of its ownpublic void setType(Type type)
type
- to setpublic Type getType()
public Class<?> getTypeClass()
null
if cannot be determinedpublic String getName()
public boolean isMandatory()
true
if the MANDATORY
feature is set to true
.Features.Property#MANDATORY}
public void setMandatory(boolean mandatory)
mandatory
- Features.Property#MANDATORY}
@Deprecated public String[] getJavaScriptValidations()
public void setName(String name)
name
- to setpublic MetaProperty clone() throws CloneNotSupportedException
clone
in class Object
CloneNotSupportedException
Copyright © 2010–2022 The Apache Software Foundation. All rights reserved.