Java Doc for ConstrainedProperty.java in  » Web-Framework » rife-1.6.1 » com » uwyn » rife » site » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Web Framework » rife 1.6.1 » com.uwyn.rife.site 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.uwyn.rife.site.ConstrainedProperty

ConstrainedProperty
public class ConstrainedProperty implements Cloneable(Code)
A ConstrainedProperty object makes it possible to easily define all constraints for a named property of a bean.

The property name refers to the actual name of the bean property. However, this sometimes doesn't correspond to its conceptual usage. It can be handy to receive constraint violation reports with another conceptual name: the subject name. Notice that this corresponds to the subject that is used in a ValidationError . If no subject name is specified, the property name will be used instead.

It's possible to add constraints to a ConstrainedProperty instance through regular setters, but chainable setters are also available to make it possible to easily define a series of constraints, for example:

ConstrainedProperty constrained = new ConstrainedProperty("password")
 .maxLength(8)
 .notNull(true);

Constrained properties are typically added to a Constrained bean in its constructor. These are the static constraints that will be set for each and every instance of the bean. You'll however most of the time use the MetaData class that provides the MetaData.activateMetaData activateMetaData method which initializes the constraints on a need-to-have basis. This dramatically reduces memory usage since otherwise all constraints will be initialized for every bean instance, even though you don't use them, for example:

public class Credentials extends MetaData
 {
 private String mLogin = null;
 private String mPassword = null;
 private String mLanguage = null;
 public Credentials()
 {
 }
 public activateMetaData()
 {
 addConstraint(new ConstrainedProperty("login").maxLength(6).notNull(true));
 addConstraint(new ConstrainedProperty("password").maxLength(8).notNull(true));
 addConstraint(new ConstrainedProperty("language").notNull(true));
 }
 public void setLogin(String login) { mLogin = login; }
 public String getLogin() { return mLogin; }
 public void setPassword(String password) { mPassword = password; }
 public String getPassword() { return mPassword; }
 public void setLanguage(String language) { mLanguage = language; }
 public String getLanguage() { return mLanguage; }
 }

It's however also possible to add constraints to a single bean instance whenever they can't be determined beforehand. These are then dynamic constraints than can be populated at runtime, for example:

Credentials credentials = new Credentials();
 credentials.addConstraint(new ConstrainedProperty("language").inList(new String[] {"nl", "fr", "en"}));
 

author:
   Geert Bevin (gbevin[remove] at uwyn dot com)
See Also:   Constrained
See Also:   ConstrainedBean
version:
   $Revision: 3732 $
since:
   1.0

Inner Class :public class ManyToOne implements Cloneable
Inner Class :public class ManyToOneAssociation implements Cloneable
Inner Class :public class ManyToMany implements Cloneable
Inner Class :public class ManyToManyAssociation implements Cloneable

Field Summary
final public static  StringAUTO_RETRIEVED
    
final public static  StringCACHED_LOADED_DATA
    
final public static  StringCONTENT_ATTRIBUTES
    
final public static  StringDEFAULT_VALUE
    
final public static  StringDISPLAYED_RAW
    
final public static  StringEDITABLE
    
final public static  StringEMAIL
    
final public static  StringFILE
    
final public static  StringFORMAT
    
final public static  StringFRAGMENT
    
final public static  StringIDENTIFIER
    
final public static  StringIN_LIST
    
final public static  StringLISTED
    
final public static  StringMANY_TO_MANY
    
final public static  StringMANY_TO_MANY_ASSOCIATION
    
final public static  StringMANY_TO_ONE
    
final public static  StringMANY_TO_ONE_ASSOCIATION
    
final public static  StringMAX_DATE
    
final public static  StringMAX_LENGTH
    
final public static  StringMIMETYPE
    
final public static  StringMIN_DATE
    
final public static  StringMIN_LENGTH
    
final public static  StringNAME
    
final public static  StringNOT_EMPTY
    
final public static  StringNOT_EQUAL
    
final public static  StringNOT_NULL
    
final public static  StringORDINAL
    
final public static  StringORDINAL_RESTRICTION
    
final public static  StringPERSISTENT
    
final public static  StringPOSITION
    
final public static  StringRANGE_BEGIN
    
final public static  StringRANGE_END
    
final public static  StringREGEXP
    
final public static  StringREPOSITORY
    
final public static  StringSAME_AS
    
final public static  StringSAVED
    
final public static  StringSCALE
    
final public static  StringSPARSE
    
final public static  StringTRANSFORMER
    
final public static  StringUNIQUE
    
final public static  StringURL
    
protected  Map<String, Object>mConstraints
    
protected  List<ConstrainedPropertyListener>mListeners
    

Constructor Summary
public  ConstrainedProperty(String propertyName)
     Creates a new ConstrainedProperty for the specified property name.

Method Summary
public  voidaddListener(ConstrainedPropertyListener listener)
     Adds a new listener.
public  TautoRetrieved(boolean autoRetrieved)
     Sets whether the content data of this property should be retrieved automatically from the back-end.
public  ConstrainedPropertyclone()
    
public  Tconstraint(String name, Object constraintData)
     Sets the data of a particular constraint in a generic fashion.
public  TcontentAttribute(String name, boolean value)
     Sets a named content attribute for this property that will be converted internally to a String value.
public  TcontentAttribute(String name, char value)
     Sets a named content attribute for this property that will be converted internally to a String value.
public  TcontentAttribute(String name, byte value)
     Sets a named content attribute for this property that will be converted internally to a String value.
public  TcontentAttribute(String name, short value)
     Sets a named content attribute for this property that will be converted internally to a String value.
public  TcontentAttribute(String name, int value)
     Sets a named content attribute for this property that will be converted internally to a String value.
public  TcontentAttribute(String name, long value)
     Sets a named content attribute for this property that will be converted internally to a String value.
public  TcontentAttribute(String name, float value)
     Sets a named content attribute for this property that will be converted internally to a String value.
public  TcontentAttribute(String name, double value)
     Sets a named content attribute for this property that will be converted internally to a String value.
public  TcontentAttribute(String name, String value)
     Sets a named content attribute for this property.
public  TdefaultValue(boolean value)
    
public  TdefaultValue(char value)
    
public  TdefaultValue(byte value)
    
public  TdefaultValue(short value)
    
public  TdefaultValue(int value)
    
public  TdefaultValue(long value)
    
public  TdefaultValue(float value)
    
public  TdefaultValue(double value)
    
public  TdefaultValue(Object value)
    
public  TdisplayedRaw(boolean displayedRaw)
    
public  Teditable(boolean editable)
    
public  Temail(boolean email)
    
public  Tfile(boolean file)
    
public  Tformat(Format format)
    
public  Tfragment(boolean fragment)
     Sets whether the content data of this property is a fragment.

This is only useful when the property also has a mime type constraint.

public  ObjectgetCachedLoadedData()
     Retrieves the cached loaded content data.
public  ObjectgetConstraint(String name)
    
public  Map<String, Object>getConstraints()
     Retrieves the map of all the constraints.
public  Map<String, String>getContentAttributes()
     Retrieves the map of named content attributes for this property.
public  ObjectgetDefaultValue()
    
public  FormatgetFormat()
    
public  String[]getInList()
    
public  ManyToManygetManyToMany()
    
public  ManyToManyAssociationgetManyToManyAssociation()
    
public  ManyToOnegetManyToOne()
    
public  ManyToOneAssociationgetManyToOneAssociation()
    
public  DategetMaxDate()
    
public  intgetMaxLength()
    
public  MimeTypegetMimeType()
     Retrieves the mime type of the property.
public  DategetMinDate()
    
public  intgetMinLength()
    
public  StringgetName()
     Retrieves the name of this property.
public  ObjectgetNotEqual()
     Retrieves the reference object to which the property value can't be equal.
public  StringgetOrdinalRestriction()
     Retrieves the ordinal restriction of this property.
public  intgetPosition()
     Retrieves the position in which the property should be displayed.
public  intgetPrecision()
    
public  StringgetPropertyName()
     Retrieves the property name.
public  ComparablegetRangeBegin()
    
public  ComparablegetRangeEnd()
    
public  StringgetRegexp()
    
public  StringgetRepository()
     Retrieves the repository where the content data of this property will be stored.
public  StringgetSameAs()
    
public  intgetScale()
    
public  StringgetSubjectName()
     Retrieves the subject name.
public  ContentTransformergetTransformer()
     Retrieves the content transformer of this property.
public  booleanhasDefaultValue()
    
public  booleanhasLimitedLength()
    
public  booleanhasManyToMany()
    
public  booleanhasManyToManyAssociation()
    
public  booleanhasManyToOne()
    
public  booleanhasManyToOneAssociation()
    
public  booleanhasMaxLength()
    
public  booleanhasMimeType()
     Indicates whether the property has a mime type.
public  booleanhasMixLength()
    
public  booleanhasName()
     Indicates whether this property has a name.
public  booleanhasOrdinalRestriction()
     Indicates whether this property has an ordinal restricting column.
public  booleanhasPosition()
     Indicates whether the position of the property is set.
public  booleanhasPrecision()
    
public  booleanhasRepository()
     Indicates whether this property will be stored in another repository than the default repository.
public  booleanhasScale()
    
public  booleanhasTransformer()
     Indicates whether this property has a content transformer.
public  Tidentifier(boolean identifier)
     Set whether the property value is an identifier.

Note that this is only applicable to contexts where a collection of the data is stored an that identification can apply against the other entries.

public  TinList(String... inList)
    
public  TinList(int... inList)
    
public  TinList(byte... inList)
    
public  TinList(char... inList)
    
public  TinList(short... inList)
    
public  TinList(long... inList)
    
public  TinList(float... inList)
    
public  TinList(double... inList)
    
public  TinList(Collection inList)
    
public  booleanisAutoRetrieved()
     Indicates whether the content data of this property is automatically retrieved from the back-end.
public  booleanisDisplayedRaw()
    
public  booleanisEditable()
    
public  booleanisEmail()
    
public  booleanisFile()
    
public  booleanisFormatted()
    
public  booleanisFragment()
     Indicates whether the content data of this property is a fragment.
public  booleanisIdentifier()
     Retrieves whether the property is an identifier.
public  booleanisInList()
    
public  booleanisLimitedDate()
    
public  booleanisListed()
     Retrieves whether the property should be included in data lists.
public  booleanisNotEmpty()
     Retrieves whether the property value can be empty.
public  booleanisNotEqual()
     Retrieves whether the property can't be equal to a specific reference value.
public  booleanisNotNull()
     Retrieves whether the property value can be null.
public  booleanisOrdinal()
     Indicates whether this property has to be used as an ordinal.
public  booleanisPersistent()
    
public  booleanisRange()
    
public  booleanisSameAs()
    
public  booleanisSaved()
    
public  booleanisSparse()
    
public  booleanisUnique()
     Retrieves whether the property value has to be unique.
public  booleanisUrl()
    
public  Tlisted(boolean listed)
     Sets whether the property should be included in data lists.
public  TmanyToMany()
    
public  TmanyToMany(Class klass)
    
public  TmanyToMany(CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)
    
public  TmanyToMany(Class klass, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)
    
public  TmanyToManyAssociation()
    
public  TmanyToManyAssociation(String property)
    
public  TmanyToManyAssociation(Class klass, String property)
    
public  TmanyToOne()
    
public  TmanyToOne(Class klass)
    
public  TmanyToOne(Class klass, String columnReference)
    
public  TmanyToOne(String table, String columnReference)
    
public  TmanyToOne(Class klass, String columnReference, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)
    
public  TmanyToOne(String table, String columnReference, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)
    
public  TmanyToOneAssociation()
    
public  TmanyToOneAssociation(String property)
    
public  TmanyToOneAssociation(Class klass, String property)
    
public  booleanmatchesRegexp()
    
public  TmaxDate(Date maxDate)
    
public  TmaxLength(int maxLength)
    
public  TmimeType(MimeType mimeType)
     Sets the mime type of the property.

Setting this constraint will make the com.uwyn.rife.cmf.dam.ContentQueryManager ContentQueryManager automatically store the data in this property in the content management back-end.

public  TminDate(Date minDate)
    
public  TminLength(int minLength)
    
public  Tname(String name)
     Sets the name of the content data of this property.
public  TnotEmpty(boolean notEmpty)
     Set whether the property value can be empty.

Note that this has different meanings for different datatypes

  • for textual types this is an empty string, ie.
public  TnotEqual(boolean reference)
     Set that the property value can't be equal to a specified boolean reference value.
public  TnotEqual(byte reference)
     Set that the property value can't be equal to a specified byte reference value.
public  TnotEqual(char reference)
     Set that the property value can't be equal to a specified char reference value.
public  TnotEqual(short reference)
     Set that the property value can't be equal to a specified short reference value.
public  TnotEqual(int reference)
     Set that the property value can't be equal to a specified int reference value.
public  TnotEqual(long reference)
     Set that the property value can't be equal to a specified long reference value.
public  TnotEqual(float reference)
     Set that the property value can't be equal to a specified float reference value.
public  TnotEqual(double reference)
     Set that the property value can't be equal to a specified double reference value.
public  TnotEqual(Object reference)
     Set that the property value can't be equal to a specified Object reference value.
public  TnotNull(boolean notNull)
     Set whether the property value can be null.

Note that this has different meanings in different contexts:

  • for values in java this is only applicable to object references as primitive values are never null,
  • for values that are stored in a database, it's applicable to every column.

Parameters:
  notNull - true when the value can't benull; or false when the value can benull.
public  Tordinal(boolean ordinal)
     Sets whether this property has to be used as an ordinal.

The value of this property will be handled in the back-end by an com.uwyn.rife.cmf.dam.OrdinalManager OrdinalManager .

public  Tordinal(boolean ordinal, String restriction)
     Sets whether this property has to be used as an ordinal with a restricting column.
public  Tpersistent(boolean persistent)
    
public  Tposition(int position)
     Sets the position in which the property should be displayed.
public  Tprecision(int precision)
    
public  TrangeBegin(byte value)
    
public  TrangeBegin(char value)
    
public  TrangeBegin(short value)
    
public  TrangeBegin(int value)
    
public  TrangeBegin(long value)
    
public  TrangeBegin(float value)
    
public  TrangeBegin(double value)
    
public  TrangeBegin(Comparable value)
    
public  TrangeEnd(char value)
    
public  TrangeEnd(byte value)
    
public  TrangeEnd(double value)
    
public  TrangeEnd(float value)
    
public  TrangeEnd(int value)
    
public  TrangeEnd(long value)
    
public  TrangeEnd(short value)
    
public  TrangeEnd(Comparable value)
    
public  Tregexp(String regexp)
    
public  booleanremoveListener(ConstrainedPropertyListener listener)
     Removes a listener.
public  Trepository(String repository)
     Sets the repository where the content data of this property will be stored.
public  TsameAs(String reference)
    
public  Tsaved(boolean saved)
    
public  Tscale(int scale)
    
public  voidsetAutoRetrieved(boolean autoRetrieved)
     Sets whether the content data of this property should be retrieved automatically from the back-end.
public  voidsetCachedLoadedData(Object data)
     Sets the cached loaded data.
public  voidsetConstraint(String name, Object constraintData)
     Sets the data of a particular constraint in a generic fashion.
public  voidsetDefaultValue(Object value)
    
public  voidsetDisplayedRaw(boolean displayedRaw)
    
public  voidsetEditable(boolean editable)
    
public  voidsetEmail(boolean email)
    
public  voidsetFile(boolean file)
    
public  voidsetFormat(Format format)
    
public  voidsetFragment(boolean fragment)
     Sets whether the content data of this property is a fragment.
public  voidsetIdentifier(boolean identifier)
     Set whether the property value is an identifier.
public  voidsetInList(String... inList)
    
public  voidsetInList(int... inList)
    
public  voidsetInList(byte... inList)
    
public  voidsetInList(char... inList)
    
public  voidsetInList(short... inList)
    
public  voidsetInList(long... inList)
    
public  voidsetInList(float... inList)
    
public  voidsetInList(double... inList)
    
public  voidsetInList(Collection inList)
    
public  voidsetListed(boolean listed)
     Sets whether the property should be included in data lists.
public  voidsetManyToMany()
    
public  voidsetManyToMany(Class klass)
    
public  voidsetManyToMany(CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)
    
public  voidsetManyToMany(Class klass, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)
    
public  voidsetManyToManyAssociation()
    
public  voidsetManyToManyAssociation(String property)
    
public  voidsetManyToManyAssociation(Class klass, String property)
    
public  voidsetManyToOne()
    
public  voidsetManyToOne(Class klass)
    
public  voidsetManyToOne(Class klass, String columnReference)
    
public  voidsetManyToOne(String table, String columnReference)
    
public  voidsetManyToOne(Class klass, String columnReference, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)
    
public  voidsetManyToOne(String table, String columnReference, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)
    
public  voidsetManyToOneAssociation()
    
public  voidsetManyToOneAssociation(String property)
    
public  voidsetManyToOneAssociation(Class klass, String property)
    
public  voidsetMaxDate(Date maxDate)
    
public  voidsetMaxLength(int maxLength)
    
public  voidsetMimeType(MimeType mimeType)
     Sets the mime type of the property.
public  voidsetMinDate(Date minDate)
    
public  voidsetMinLength(int minLength)
    
public  voidsetName(String name)
     Sets the name of the content data of this property.
public  voidsetNotEmpty(boolean notEmpty)
     Set whether the property value can be empty.
public  voidsetNotEqual(boolean reference)
     Set that the property value can't be equal to a specified boolean reference value.
public  voidsetNotEqual(byte reference)
     Set that the property value can't be equal to a specified byte reference value.
public  voidsetNotEqual(char reference)
     Set that the property value can't be equal to a specified char reference value.
public  voidsetNotEqual(short reference)
     Set that the property value can't be equal to a specified short reference value.
public  voidsetNotEqual(int reference)
     Set that the property value can't be equal to a specified int reference value.
public  voidsetNotEqual(long reference)
     Set that the property value can't be equal to a specified long reference value.
public  voidsetNotEqual(float reference)
     Set that the property value can't be equal to a specified float reference value.
public  voidsetNotEqual(double reference)
     Set that the property value can't be equal to a specified double reference value.
public  voidsetNotEqual(Object reference)
     Set that the property value can't be equal to a specified Object reference value.
public  voidsetNotNull(boolean notNull)
     Set whether the property value can be null.
public  voidsetOrdinal(boolean ordinal)
     Sets whether this property has to be used as an ordinal.
public  voidsetOrdinal(boolean ordinal, String restriction)
     Sets whether this property has to be used as an ordinal with a restricting column.
public  voidsetPersistent(boolean persistent)
    
public  voidsetPosition(int position)
     Sets the position in which the property should be displayed.
public  voidsetPrecision(int precision)
    
public  voidsetRangeBegin(byte value)
    
public  voidsetRangeBegin(char value)
    
public  voidsetRangeBegin(short value)
    
public  voidsetRangeBegin(int value)
    
public  voidsetRangeBegin(long value)
    
public  voidsetRangeBegin(float value)
    
public  voidsetRangeBegin(double value)
    
public  voidsetRangeBegin(Comparable rangeBegin)
    
public  voidsetRangeEnd(byte value)
    
public  voidsetRangeEnd(char value)
    
public  voidsetRangeEnd(short value)
    
public  voidsetRangeEnd(int value)
    
public  voidsetRangeEnd(long value)
    
public  voidsetRangeEnd(float value)
    
public  voidsetRangeEnd(double value)
    
public  voidsetRangeEnd(Comparable rangeEnd)
    
public  voidsetRegexp(String regexp)
    
public  voidsetRepository(String repository)
     Sets the repository where the content data of this property will be stored.
public  voidsetSameAs(String reference)
    
public  voidsetSaved(boolean saved)
    
public  voidsetScale(int scale)
    
public  voidsetSparse(boolean sparse)
    
public  voidsetSubjectName(String name)
     Sets the subject name.
public  voidsetTransformer(ContentTransformer transformer)
     Sets a content transformer for this property.
public  voidsetUnique(boolean unique)
     Set whether the property value has to be unique.
public  voidsetUrl(boolean url)
    
public  Tsparse(boolean sparse)
    
public  TsubjectName(String name)
     Sets the subject name.
public  Ttransformer(ContentTransformer transformer)
     Sets a content transformer for this property.
public  Tunique(boolean unique)
     Set whether the property value has to be unique.

Note that this is only applicable to contexts where a collection of the data is stored an that uniqueness can apply against the other entries.

public  Turl(boolean url)
    

Field Detail
AUTO_RETRIEVED
final public static String AUTO_RETRIEVED(Code)



CACHED_LOADED_DATA
final public static String CACHED_LOADED_DATA(Code)



CONTENT_ATTRIBUTES
final public static String CONTENT_ATTRIBUTES(Code)



DEFAULT_VALUE
final public static String DEFAULT_VALUE(Code)



DISPLAYED_RAW
final public static String DISPLAYED_RAW(Code)



EDITABLE
final public static String EDITABLE(Code)



EMAIL
final public static String EMAIL(Code)



FILE
final public static String FILE(Code)



FORMAT
final public static String FORMAT(Code)



FRAGMENT
final public static String FRAGMENT(Code)



IDENTIFIER
final public static String IDENTIFIER(Code)



IN_LIST
final public static String IN_LIST(Code)



LISTED
final public static String LISTED(Code)



MANY_TO_MANY
final public static String MANY_TO_MANY(Code)



MANY_TO_MANY_ASSOCIATION
final public static String MANY_TO_MANY_ASSOCIATION(Code)



MANY_TO_ONE
final public static String MANY_TO_ONE(Code)



MANY_TO_ONE_ASSOCIATION
final public static String MANY_TO_ONE_ASSOCIATION(Code)



MAX_DATE
final public static String MAX_DATE(Code)



MAX_LENGTH
final public static String MAX_LENGTH(Code)



MIMETYPE
final public static String MIMETYPE(Code)



MIN_DATE
final public static String MIN_DATE(Code)



MIN_LENGTH
final public static String MIN_LENGTH(Code)



NAME
final public static String NAME(Code)



NOT_EMPTY
final public static String NOT_EMPTY(Code)



NOT_EQUAL
final public static String NOT_EQUAL(Code)



NOT_NULL
final public static String NOT_NULL(Code)



ORDINAL
final public static String ORDINAL(Code)



ORDINAL_RESTRICTION
final public static String ORDINAL_RESTRICTION(Code)



PERSISTENT
final public static String PERSISTENT(Code)



POSITION
final public static String POSITION(Code)



RANGE_BEGIN
final public static String RANGE_BEGIN(Code)



RANGE_END
final public static String RANGE_END(Code)



REGEXP
final public static String REGEXP(Code)



REPOSITORY
final public static String REPOSITORY(Code)



SAME_AS
final public static String SAME_AS(Code)



SAVED
final public static String SAVED(Code)



SCALE
final public static String SCALE(Code)



SPARSE
final public static String SPARSE(Code)



TRANSFORMER
final public static String TRANSFORMER(Code)



UNIQUE
final public static String UNIQUE(Code)



URL
final public static String URL(Code)



mConstraints
protected Map<String, Object> mConstraints(Code)



mListeners
protected List<ConstrainedPropertyListener> mListeners(Code)




Constructor Detail
ConstrainedProperty
public ConstrainedProperty(String propertyName)(Code)
Creates a new ConstrainedProperty for the specified property name.
Parameters:
  propertyName - the name of the property that has to beconstrained
since:
   1.0




Method Detail
addListener
public void addListener(ConstrainedPropertyListener listener)(Code)
Adds a new listener.

Listeners will be notified when events occur that are specified in the ConstrainedPropertyListener interface.
Parameters:
  listener - the listener instance that will be added
since:
   1.6




autoRetrieved
public T autoRetrieved(boolean autoRetrieved)(Code)
Sets whether the content data of this property should be retrieved automatically from the back-end.

This is only useful when the property also has a mime type constraint.

It's not recommended to enable this constraint for large data since everything will be stored in memory, only use this for text snippets or something relatively small.
Parameters:
  autoRetrieved - true if the data should beautomatically retrieved; or

false otherwise the current ConstrainedProperty instance
See Also:   ConstrainedProperty.mimeType(MimeType)
See Also:   ConstrainedProperty.setAutoRetrieved(boolean)
See Also:   ConstrainedProperty.isAutoRetrieved()
since:
   1.0




clone
public ConstrainedProperty clone()(Code)



constraint
public T constraint(String name, Object constraintData)(Code)
Sets the data of a particular constraint in a generic fashion.

Note that it's not recommended to use this to set any of the standard constraints since none of the additional logic and checks are executed. the current Content instance
See Also:   ConstrainedProperty.setConstraint
See Also:   ConstrainedProperty.getConstraint
See Also:   ConstrainedProperty.getConstraints
since:
   1.4




contentAttribute
public T contentAttribute(String name, boolean value)(Code)
Sets a named content attribute for this property that will be converted internally to a String value.
Parameters:
  name - the name of the attribute
Parameters:
  value - the value of the attribute the current Content instance
See Also:   ConstrainedProperty.contentAttribute(String,String)
See Also:   ConstrainedProperty.getContentAttributes()
since:
   1.0



contentAttribute
public T contentAttribute(String name, char value)(Code)
Sets a named content attribute for this property that will be converted internally to a String value.
Parameters:
  name - the name of the attribute
Parameters:
  value - the value of the attribute the current Content instance
See Also:   ConstrainedProperty.contentAttribute(String,String)
See Also:   ConstrainedProperty.getContentAttributes()
since:
   1.0



contentAttribute
public T contentAttribute(String name, byte value)(Code)
Sets a named content attribute for this property that will be converted internally to a String value.
Parameters:
  name - the name of the attribute
Parameters:
  value - the value of the attribute the current Content instance
See Also:   ConstrainedProperty.contentAttribute(String,String)
See Also:   ConstrainedProperty.getContentAttributes()
since:
   1.0



contentAttribute
public T contentAttribute(String name, short value)(Code)
Sets a named content attribute for this property that will be converted internally to a String value.
Parameters:
  name - the name of the attribute
Parameters:
  value - the value of the attribute the current Content instance
See Also:   ConstrainedProperty.contentAttribute(String,String)
See Also:   ConstrainedProperty.getContentAttributes()
since:
   1.0



contentAttribute
public T contentAttribute(String name, int value)(Code)
Sets a named content attribute for this property that will be converted internally to a String value.
Parameters:
  name - the name of the attribute
Parameters:
  value - the value of the attribute the current Content instance
See Also:   ConstrainedProperty.contentAttribute(String,String)
See Also:   ConstrainedProperty.getContentAttributes()
since:
   1.0



contentAttribute
public T contentAttribute(String name, long value)(Code)
Sets a named content attribute for this property that will be converted internally to a String value.
Parameters:
  name - the name of the attribute
Parameters:
  value - the value of the attribute the current Content instance
See Also:   ConstrainedProperty.contentAttribute(String,String)
See Also:   ConstrainedProperty.getContentAttributes()
since:
   1.0



contentAttribute
public T contentAttribute(String name, float value)(Code)
Sets a named content attribute for this property that will be converted internally to a String value.
Parameters:
  name - the name of the attribute
Parameters:
  value - the value of the attribute the current Content instance
See Also:   ConstrainedProperty.contentAttribute(String,String)
See Also:   ConstrainedProperty.getContentAttributes()
since:
   1.0



contentAttribute
public T contentAttribute(String name, double value)(Code)
Sets a named content attribute for this property that will be converted internally to a String value.
Parameters:
  name - the name of the attribute
Parameters:
  value - the value of the attribute the current Content instance
See Also:   ConstrainedProperty.contentAttribute(String,String)
See Also:   ConstrainedProperty.getContentAttributes()
since:
   1.0



contentAttribute
public T contentAttribute(String name, String value)(Code)
Sets a named content attribute for this property.

This is only useful when the property also has a mime type constraint.

A content attribute provides additional meta data about how you want to store the content data after loading, this can for example be image dimensions.
Parameters:
  name - the name of the attribute
Parameters:
  value - the value of the attribute the current Content instance
See Also:   ConstrainedProperty.mimeType(MimeType)
See Also:   ConstrainedProperty.getContentAttributes()
since:
   1.0




defaultValue
public T defaultValue(boolean value)(Code)



defaultValue
public T defaultValue(char value)(Code)



defaultValue
public T defaultValue(byte value)(Code)



defaultValue
public T defaultValue(short value)(Code)



defaultValue
public T defaultValue(int value)(Code)



defaultValue
public T defaultValue(long value)(Code)



defaultValue
public T defaultValue(float value)(Code)



defaultValue
public T defaultValue(double value)(Code)



defaultValue
public T defaultValue(Object value)(Code)



displayedRaw
public T displayedRaw(boolean displayedRaw)(Code)



editable
public T editable(boolean editable)(Code)



email
public T email(boolean email)(Code)



file
public T file(boolean file)(Code)



format
public T format(Format format)(Code)



fragment
public T fragment(boolean fragment)(Code)
Sets whether the content data of this property is a fragment.

This is only useful when the property also has a mime type constraint. A fragment means that it's not a complete document or a file, but rather a small part that is intended to be used within a larger document. For example a HTML snippet. This information is for example important when validating the data.
Parameters:
  fragment - true if the content is a fragment; or

false otherwise the current ConstrainedProperty instance
See Also:   ConstrainedProperty.mimeType(MimeType)
See Also:   ConstrainedProperty.setFragment(boolean)
See Also:   ConstrainedProperty.isFragment()
since:
   1.0




getCachedLoadedData
public Object getCachedLoadedData()(Code)
Retrieves the cached loaded content data. the cached loaded content data; or

null if no loaded content data has been cached
See Also:   ConstrainedProperty.setCachedLoadedData(Object)
since:
   1.0




getConstraint
public Object getConstraint(String name)(Code)
Retrieves the value of a particular constraint in a generic fashion the data of a particular constraint; or

null if nothing has been registered forthat constraint
See Also:   ConstrainedProperty.setConstraint
See Also:   ConstrainedProperty.constraint
See Also:   ConstrainedProperty.getConstraints
since:
   1.4




getConstraints
public Map<String, Object> getConstraints()(Code)
Retrieves the map of all the constraints. the map with all the registered constraints
See Also:   ConstrainedProperty.setConstraint
See Also:   ConstrainedProperty.constraint
See Also:   ConstrainedProperty.getConstraint
since:
   1.4



getContentAttributes
public Map<String, String> getContentAttributes()(Code)
Retrieves the map of named content attributes for this property. the map of named content attributes; or

null if no attributes are present
See Also:   ConstrainedProperty.contentAttribute(String,String)
since:
   1.0




getDefaultValue
public Object getDefaultValue()(Code)



getFormat
public Format getFormat()(Code)



getInList
public String[] getInList()(Code)



getManyToMany
public ManyToMany getManyToMany()(Code)



getManyToManyAssociation
public ManyToManyAssociation getManyToManyAssociation()(Code)



getManyToOne
public ManyToOne getManyToOne()(Code)



getManyToOneAssociation
public ManyToOneAssociation getManyToOneAssociation()(Code)



getMaxDate
public Date getMaxDate()(Code)



getMaxLength
public int getMaxLength()(Code)



getMimeType
public MimeType getMimeType()(Code)
Retrieves the mime type of the property. the mime type of the property; or

null if the property has no mime type
See Also:   ConstrainedProperty.mimeType(MimeType)
See Also:   ConstrainedProperty.setMimeType(MimeType)
See Also:   ConstrainedProperty.hasMimeType()
since:
   1.0




getMinDate
public Date getMinDate()(Code)



getMinLength
public int getMinLength()(Code)



getName
public String getName()(Code)
Retrieves the name of this property. null if the content data has no name; or

the name of the content
See Also:   ConstrainedProperty.name(String)
See Also:   ConstrainedProperty.setName(String)
See Also:   ConstrainedProperty.hasName()
since:
   1.0




getNotEqual
public Object getNotEqual()(Code)
Retrieves the reference object to which the property value can't be equal. the requested reference object instance; or

null when the property has no notEqual constraint.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0




getOrdinalRestriction
public String getOrdinalRestriction()(Code)
Retrieves the ordinal restriction of this property. the name of the ordinal restricting column; or

null if no ordinal restricting column has been defined
See Also:   ConstrainedProperty.ordinal(boolean,String)
See Also:   ConstrainedProperty.setOrdinal(boolean,String)
See Also:   ConstrainedProperty.hasOrdinalRestriction()
since:
   1.0




getPosition
public int getPosition()(Code)
Retrieves the position in which the property should be displayed. an integer value with the position; or

-1 if the property shouldn't be positioned
See Also:   ConstrainedProperty.position(int)
See Also:   ConstrainedProperty.setPosition(int)
See Also:   ConstrainedProperty.hasPosition()
since:
   1.0




getPrecision
public int getPrecision()(Code)



getPropertyName
public String getPropertyName()(Code)
Retrieves the property name. the property name
since:
   1.0



getRangeBegin
public Comparable getRangeBegin()(Code)



getRangeEnd
public Comparable getRangeEnd()(Code)



getRegexp
public String getRegexp()(Code)



getRepository
public String getRepository()(Code)
Retrieves the repository where the content data of this property will be stored. null if no repository has been specified; or

the name of the repository
See Also:   ConstrainedProperty.repository(String)
See Also:   ConstrainedProperty.setRepository(String)
See Also:   ConstrainedProperty.hasRepository()
since:
   1.0




getSameAs
public String getSameAs()(Code)



getScale
public int getScale()(Code)



getSubjectName
public String getSubjectName()(Code)
Retrieves the subject name. the subject name; or

the property name if no subject was specified.
since:
   1.0




getTransformer
public ContentTransformer getTransformer()(Code)
Retrieves the content transformer of this property. the requested content transformer; or

null if no content transformer has been defined
See Also:   ConstrainedProperty.transformer(ContentTransformer)
See Also:   ConstrainedProperty.setTransformer(ContentTransformer)
See Also:   ConstrainedProperty.hasTransformer()
since:
   1.0




hasDefaultValue
public boolean hasDefaultValue()(Code)



hasLimitedLength
public boolean hasLimitedLength()(Code)



hasManyToMany
public boolean hasManyToMany()(Code)



hasManyToManyAssociation
public boolean hasManyToManyAssociation()(Code)



hasManyToOne
public boolean hasManyToOne()(Code)



hasManyToOneAssociation
public boolean hasManyToOneAssociation()(Code)



hasMaxLength
public boolean hasMaxLength()(Code)



hasMimeType
public boolean hasMimeType()(Code)
Indicates whether the property has a mime type. true if the property has a mime type; or

false if it hasn't
See Also:   ConstrainedProperty.mimeType(MimeType)
See Also:   ConstrainedProperty.setMimeType(MimeType)
See Also:   ConstrainedProperty.getMimeType()
since:
   1.0




hasMixLength
public boolean hasMixLength()(Code)



hasName
public boolean hasName()(Code)
Indicates whether this property has a name. true if the property has a name; or

false otherwise
See Also:   ConstrainedProperty.name(String)
See Also:   ConstrainedProperty.setName(String)
See Also:   ConstrainedProperty.getName()
since:
   1.0




hasOrdinalRestriction
public boolean hasOrdinalRestriction()(Code)
Indicates whether this property has an ordinal restricting column. true if this property has an ordinal restrictingcolumn; or

false otherwise
See Also:   ConstrainedProperty.ordinal(boolean,String)
See Also:   ConstrainedProperty.setOrdinal(boolean,String)
See Also:   ConstrainedProperty.getOrdinalRestriction()
since:
   1.0




hasPosition
public boolean hasPosition()(Code)
Indicates whether the position of the property is set. true if the property has a position; or

false if it hasn't
See Also:   ConstrainedProperty.position(int)
See Also:   ConstrainedProperty.setPosition(int)
See Also:   ConstrainedProperty.getPosition()
since:
   1.0




hasPrecision
public boolean hasPrecision()(Code)



hasRepository
public boolean hasRepository()(Code)
Indicates whether this property will be stored in another repository than the default repository. true if the property will be stored in anotherrepository; or

false otherwise
See Also:   ConstrainedProperty.repository(String)
See Also:   ConstrainedProperty.setRepository(String)
See Also:   ConstrainedProperty.getRepository()
since:
   1.0




hasScale
public boolean hasScale()(Code)



hasTransformer
public boolean hasTransformer()(Code)
Indicates whether this property has a content transformer. true if this property has a content transformer;or

false otherwise
See Also:   ConstrainedProperty.transformer(ContentTransformer)
See Also:   ConstrainedProperty.setTransformer(ContentTransformer)
See Also:   ConstrainedProperty.getTransformer()
since:
   1.0




identifier
public T identifier(boolean identifier)(Code)
Set whether the property value is an identifier.

Note that this is only applicable to contexts where a collection of the data is stored an that identification can apply against the other entries. In a singular context, identification is meaningless.
Parameters:
  identifier - true when the value is anidentifier; or false when it isn't. this ConstrainedProperty
See Also:   ConstrainedProperty.isIdentifier()
since:
   1.0




inList
public T inList(String... inList)(Code)



inList
public T inList(int... inList)(Code)



inList
public T inList(byte... inList)(Code)



inList
public T inList(char... inList)(Code)



inList
public T inList(short... inList)(Code)



inList
public T inList(long... inList)(Code)



inList
public T inList(float... inList)(Code)



inList
public T inList(double... inList)(Code)



inList
public T inList(Collection inList)(Code)



isAutoRetrieved
public boolean isAutoRetrieved()(Code)
Indicates whether the content data of this property is automatically retrieved from the back-end. true if the data should be automaticallyretrieved; or

false otherwise
See Also:   ConstrainedProperty.autoRetrieved(boolean)
See Also:   ConstrainedProperty.setAutoRetrieved(boolean)
since:
   1.0




isDisplayedRaw
public boolean isDisplayedRaw()(Code)



isEditable
public boolean isEditable()(Code)



isEmail
public boolean isEmail()(Code)



isFile
public boolean isFile()(Code)



isFormatted
public boolean isFormatted()(Code)



isFragment
public boolean isFragment()(Code)
Indicates whether the content data of this property is a fragment. true if the content is a fragment; or

false otherwise
See Also:   ConstrainedProperty.fragment(boolean)
See Also:   ConstrainedProperty.setFragment(boolean)
since:
   1.0




isIdentifier
public boolean isIdentifier()(Code)
Retrieves whether the property is an identifier. true when the property is an identifier; or

false it isn't.
See Also:   ConstrainedProperty.identifier(boolean)
since:
   1.0




isInList
public boolean isInList()(Code)



isLimitedDate
public boolean isLimitedDate()(Code)



isListed
public boolean isListed()(Code)
Retrieves whether the property should be included in data lists. true if the property should be listed; or

false if it shouldn't
See Also:   ConstrainedProperty.listed(boolean)
See Also:   ConstrainedProperty.setListed(boolean)
since:
   1.0




isNotEmpty
public boolean isNotEmpty()(Code)
Retrieves whether the property value can be empty. true when the value can't be empty; or

false when the value can be empty.
See Also:   ConstrainedProperty.notEmpty(boolean)
since:
   1.0




isNotEqual
public boolean isNotEqual()(Code)
Retrieves whether the property can't be equal to a specific reference value. true when the value can't be equal; or

false when the value can be equal.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0




isNotNull
public boolean isNotNull()(Code)
Retrieves whether the property value can be null. true when the value can't be null;or

false when the value can be null.
See Also:   ConstrainedProperty.notNull(boolean)
since:
   1.0




isOrdinal
public boolean isOrdinal()(Code)
Indicates whether this property has to be used as an ordinal. true if this property is an ordinal; or

false otherwise
See Also:   ConstrainedProperty.ordinal(boolean)
See Also:   ConstrainedProperty.ordinal(boolean,String)
See Also:   ConstrainedProperty.setOrdinal(boolean)
See Also:   ConstrainedProperty.setOrdinal(boolean,String)
since:
   1.0




isPersistent
public boolean isPersistent()(Code)



isRange
public boolean isRange()(Code)



isSameAs
public boolean isSameAs()(Code)



isSaved
public boolean isSaved()(Code)



isSparse
public boolean isSparse()(Code)



isUnique
public boolean isUnique()(Code)
Retrieves whether the property value has to be unique. true when the value has to be unique; or

false it doesn't have to be.
See Also:   ConstrainedProperty.unique(boolean)
since:
   1.0




isUrl
public boolean isUrl()(Code)



listed
public T listed(boolean listed)(Code)
Sets whether the property should be included in data lists.

This is not actually used by the CMF itself, but is very useful when integrating with automatic user interface generation libraries.
Parameters:
  listed - true if the property should be listed; or

false if it shouldn't the current ConstrainedProperty instance
See Also:   ConstrainedProperty.setListed(boolean)
See Also:   ConstrainedProperty.isListed()
since:
   1.0




manyToMany
public T manyToMany()(Code)



manyToMany
public T manyToMany(Class klass)(Code)



manyToMany
public T manyToMany(CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)(Code)



manyToMany
public T manyToMany(Class klass, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)(Code)



manyToManyAssociation
public T manyToManyAssociation()(Code)



manyToManyAssociation
public T manyToManyAssociation(String property)(Code)



manyToManyAssociation
public T manyToManyAssociation(Class klass, String property)(Code)



manyToOne
public T manyToOne()(Code)



manyToOne
public T manyToOne(Class klass)(Code)



manyToOne
public T manyToOne(Class klass, String columnReference)(Code)



manyToOne
public T manyToOne(String table, String columnReference)(Code)



manyToOne
public T manyToOne(Class klass, String columnReference, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)(Code)



manyToOne
public T manyToOne(String table, String columnReference, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)(Code)



manyToOneAssociation
public T manyToOneAssociation()(Code)



manyToOneAssociation
public T manyToOneAssociation(String property)(Code)



manyToOneAssociation
public T manyToOneAssociation(Class klass, String property)(Code)



matchesRegexp
public boolean matchesRegexp()(Code)



maxDate
public T maxDate(Date maxDate)(Code)



maxLength
public T maxLength(int maxLength)(Code)



mimeType
public T mimeType(MimeType mimeType)(Code)
Sets the mime type of the property.

Setting this constraint will make the com.uwyn.rife.cmf.dam.ContentQueryManager ContentQueryManager automatically store the data in this property in the content management back-end. This column will not be stored in a regular database table. All this is handled transparently and automatically.
Parameters:
  mimeType - the MimeType of the property the current ConstrainedProperty instance
See Also:   ConstrainedProperty.setMimeType(MimeType)
See Also:   ConstrainedProperty.hasMimeType()
See Also:   ConstrainedProperty.getMimeType()
since:
   1.0




minDate
public T minDate(Date minDate)(Code)



minLength
public T minLength(int minLength)(Code)



name
public T name(String name)(Code)
Sets the name of the content data of this property.

This is only useful when the property also has a mime type constraint.
Parameters:
  name - the name the current ConstrainedProperty instance
See Also:   ConstrainedProperty.mimeType(MimeType)
See Also:   ConstrainedProperty.setName(String)
See Also:   ConstrainedProperty.getName()
See Also:   ConstrainedProperty.hasName()
since:
   1.0




notEmpty
public T notEmpty(boolean notEmpty)(Code)
Set whether the property value can be empty.

Note that this has different meanings for different datatypes

  • for textual types this is an empty string, ie. "",
  • for numeric types this is 0 (zero).

Parameters:
  notEmpty - true when the value can't be empty; orfalse when the value can be empty. this ConstrainedProperty
See Also:   ConstrainedProperty.isNotEmpty()
since:
   1.0



notEqual
public T notEqual(boolean reference)(Code)
Set that the property value can't be equal to a specified boolean reference value.
Parameters:
  reference - the reference value it will be checked against this ConstrainedProperty
See Also:   ConstrainedProperty.isNotEqual()
since:
   1.0



notEqual
public T notEqual(byte reference)(Code)
Set that the property value can't be equal to a specified byte reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



notEqual
public T notEqual(char reference)(Code)
Set that the property value can't be equal to a specified char reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



notEqual
public T notEqual(short reference)(Code)
Set that the property value can't be equal to a specified short reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



notEqual
public T notEqual(int reference)(Code)
Set that the property value can't be equal to a specified int reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



notEqual
public T notEqual(long reference)(Code)
Set that the property value can't be equal to a specified long reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



notEqual
public T notEqual(float reference)(Code)
Set that the property value can't be equal to a specified float reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



notEqual
public T notEqual(double reference)(Code)
Set that the property value can't be equal to a specified double reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



notEqual
public T notEqual(Object reference)(Code)
Set that the property value can't be equal to a specified Object reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



notNull
public T notNull(boolean notNull)(Code)
Set whether the property value can be null.

Note that this has different meanings in different contexts:

  • for values in java this is only applicable to object references as primitive values are never null,
  • for values that are stored in a database, it's applicable to every column.

Parameters:
  notNull - true when the value can't benull; or false when the value can benull. this ConstrainedProperty
See Also:   ConstrainedProperty.isNotNull()
since:
   1.0



ordinal
public T ordinal(boolean ordinal)(Code)
Sets whether this property has to be used as an ordinal.

The value of this property will be handled in the back-end by an com.uwyn.rife.cmf.dam.OrdinalManager OrdinalManager . It will also enable the com.uwyn.rife.cmf.dam.ContentQueryManager.move(ConstrainedStringcom.uwyn.rife.cmf.dam.OrdinalManager.Direction)move , com.uwyn.rife.cmf.dam.ContentQueryManager.up(ConstrainedString) up and com.uwyn.rife.cmf.dam.ContentQueryManager.down(ConstrainedString)down methods in the com.uwyn.rife.cmf.dam.ContentQueryManagerContentQueryManager to easily reorder data rows in the back-end.
Parameters:
  ordinal - true if this property is an ordinal; or

false otherwise the current ConstrainedProperty instance
See Also:   ConstrainedProperty.ordinal(boolean,String)
See Also:   ConstrainedProperty.setOrdinal(boolean)
See Also:   ConstrainedProperty.setOrdinal(boolean,String)
See Also:   ConstrainedProperty.isOrdinal()
since:
   1.0




ordinal
public T ordinal(boolean ordinal, String restriction)(Code)
Sets whether this property has to be used as an ordinal with a restricting column.
Parameters:
  ordinal - true if this property is an ordinal; or

false otherwise
Parameters:
  restriction - the name of the restricting column the current ConstrainedProperty instance
See Also:   ConstrainedProperty.ordinal(boolean)
See Also:   ConstrainedProperty.setOrdinal(boolean)
See Also:   ConstrainedProperty.setOrdinal(boolean,String)
See Also:   ConstrainedProperty.isOrdinal()
See Also:   ConstrainedProperty.hasOrdinalRestriction()
See Also:   ConstrainedProperty.getOrdinalRestriction()
since:
   1.0




persistent
public T persistent(boolean persistent)(Code)



position
public T position(int position)(Code)
Sets the position in which the property should be displayed.

This is not actually used by the CMF itself, but is very useful when integrating with automatic user interface generation libraries.
Parameters:
  position - an integer value with the position; or

-1 if the property shouldn't be positioned the current ConstrainedProperty instance
See Also:   ConstrainedProperty.setPosition(int)
See Also:   ConstrainedProperty.hasPosition()
See Also:   ConstrainedProperty.getPosition()
since:
   1.0




precision
public T precision(int precision)(Code)



rangeBegin
public T rangeBegin(byte value)(Code)



rangeBegin
public T rangeBegin(char value)(Code)



rangeBegin
public T rangeBegin(short value)(Code)



rangeBegin
public T rangeBegin(int value)(Code)



rangeBegin
public T rangeBegin(long value)(Code)



rangeBegin
public T rangeBegin(float value)(Code)



rangeBegin
public T rangeBegin(double value)(Code)



rangeBegin
public T rangeBegin(Comparable value)(Code)



rangeEnd
public T rangeEnd(char value)(Code)



rangeEnd
public T rangeEnd(byte value)(Code)



rangeEnd
public T rangeEnd(double value)(Code)



rangeEnd
public T rangeEnd(float value)(Code)



rangeEnd
public T rangeEnd(int value)(Code)



rangeEnd
public T rangeEnd(long value)(Code)



rangeEnd
public T rangeEnd(short value)(Code)



rangeEnd
public T rangeEnd(Comparable value)(Code)



regexp
public T regexp(String regexp)(Code)



removeListener
public boolean removeListener(ConstrainedPropertyListener listener)(Code)
Removes a listener.

Once the listener has been removed, it will not receive any events anymore.
Parameters:
  listener - the listener instance that will be removed true when the listener could be found and has been removed; or

false when the listener wasn't registered before
since:
   1.6




repository
public T repository(String repository)(Code)
Sets the repository where the content data of this property will be stored.

This is only useful when the property also has a mime type constraint.
Parameters:
  repository - the repository the current CmrProperty instance
See Also:   ConstrainedProperty.mimeType(MimeType)
See Also:   ConstrainedProperty.setRepository(String)
See Also:   ConstrainedProperty.getRepository()
See Also:   ConstrainedProperty.hasRepository()
since:
   1.0




sameAs
public T sameAs(String reference)(Code)



saved
public T saved(boolean saved)(Code)



scale
public T scale(int scale)(Code)



setAutoRetrieved
public void setAutoRetrieved(boolean autoRetrieved)(Code)
Sets whether the content data of this property should be retrieved automatically from the back-end.
Parameters:
  autoRetrieved - true if the data should beautomatically retrieved; or

false otherwise
See Also:   ConstrainedProperty.autoRetrieved(boolean)
See Also:   ConstrainedProperty.isAutoRetrieved()
since:
   1.0




setCachedLoadedData
public void setCachedLoadedData(Object data)(Code)
Sets the cached loaded data.

This is used internally and should never be used explicitly by a developer, see com.uwyn.rife.cmf.Content.cachedLoadedData(Object)Content.cachedLoadedData(Object) for more information.
Parameters:
  data - the loaded data
See Also:   ConstrainedProperty.getCachedLoadedData()
since:
   1.0




setConstraint
public void setConstraint(String name, Object constraintData)(Code)
Sets the data of a particular constraint in a generic fashion.

Note that it's not recommended to use this to set any of the standard constraints since none of the additional logic and checks are executed.
See Also:   ConstrainedProperty.constraint
See Also:   ConstrainedProperty.getConstraint
See Also:   ConstrainedProperty.getConstraints
since:
   1.4




setDefaultValue
public void setDefaultValue(Object value)(Code)



setDisplayedRaw
public void setDisplayedRaw(boolean displayedRaw)(Code)



setEditable
public void setEditable(boolean editable)(Code)



setEmail
public void setEmail(boolean email)(Code)



setFile
public void setFile(boolean file)(Code)



setFormat
public void setFormat(Format format)(Code)



setFragment
public void setFragment(boolean fragment)(Code)
Sets whether the content data of this property is a fragment.
Parameters:
  fragment - true if the content is a fragment; or

false otherwise
See Also:   ConstrainedProperty.fragment(boolean)
See Also:   ConstrainedProperty.isFragment()
since:
   1.0




setIdentifier
public void setIdentifier(boolean identifier)(Code)
Set whether the property value is an identifier.
See Also:   ConstrainedProperty.identifier(boolean)
since:
   1.0



setInList
public void setInList(String... inList)(Code)



setInList
public void setInList(int... inList)(Code)



setInList
public void setInList(byte... inList)(Code)



setInList
public void setInList(char... inList)(Code)



setInList
public void setInList(short... inList)(Code)



setInList
public void setInList(long... inList)(Code)



setInList
public void setInList(float... inList)(Code)



setInList
public void setInList(double... inList)(Code)



setInList
public void setInList(Collection inList)(Code)



setListed
public void setListed(boolean listed)(Code)
Sets whether the property should be included in data lists.
Parameters:
  listed - true if the property should be listed; or

false if it shouldn't
See Also:   ConstrainedProperty.listed(boolean)
See Also:   ConstrainedProperty.isListed()
since:
   1.0




setManyToMany
public void setManyToMany()(Code)



setManyToMany
public void setManyToMany(Class klass)(Code)



setManyToMany
public void setManyToMany(CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)(Code)



setManyToMany
public void setManyToMany(Class klass, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)(Code)



setManyToManyAssociation
public void setManyToManyAssociation()(Code)



setManyToManyAssociation
public void setManyToManyAssociation(String property)(Code)



setManyToManyAssociation
public void setManyToManyAssociation(Class klass, String property)(Code)



setManyToOne
public void setManyToOne()(Code)



setManyToOne
public void setManyToOne(Class klass)(Code)



setManyToOne
public void setManyToOne(Class klass, String columnReference)(Code)



setManyToOne
public void setManyToOne(String table, String columnReference)(Code)



setManyToOne
public void setManyToOne(Class klass, String columnReference, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)(Code)



setManyToOne
public void setManyToOne(String table, String columnReference, CreateTable.ViolationAction onUpdate, CreateTable.ViolationAction onDelete)(Code)



setManyToOneAssociation
public void setManyToOneAssociation()(Code)



setManyToOneAssociation
public void setManyToOneAssociation(String property)(Code)



setManyToOneAssociation
public void setManyToOneAssociation(Class klass, String property)(Code)



setMaxDate
public void setMaxDate(Date maxDate)(Code)



setMaxLength
public void setMaxLength(int maxLength)(Code)



setMimeType
public void setMimeType(MimeType mimeType)(Code)
Sets the mime type of the property.
Parameters:
  mimeType - the MimeType of the property
See Also:   ConstrainedProperty.mimeType(MimeType)
See Also:   ConstrainedProperty.hasMimeType()
See Also:   ConstrainedProperty.getMimeType()
since:
   1.0



setMinDate
public void setMinDate(Date minDate)(Code)



setMinLength
public void setMinLength(int minLength)(Code)



setName
public void setName(String name)(Code)
Sets the name of the content data of this property.
Parameters:
  name - the name
See Also:   ConstrainedProperty.name(String)
See Also:   ConstrainedProperty.getName()
See Also:   ConstrainedProperty.hasName()
since:
   1.0



setNotEmpty
public void setNotEmpty(boolean notEmpty)(Code)
Set whether the property value can be empty.
See Also:   ConstrainedProperty.notEmpty(boolean)
since:
   1.0



setNotEqual
public void setNotEqual(boolean reference)(Code)
Set that the property value can't be equal to a specified boolean reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



setNotEqual
public void setNotEqual(byte reference)(Code)
Set that the property value can't be equal to a specified byte reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



setNotEqual
public void setNotEqual(char reference)(Code)
Set that the property value can't be equal to a specified char reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



setNotEqual
public void setNotEqual(short reference)(Code)
Set that the property value can't be equal to a specified short reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



setNotEqual
public void setNotEqual(int reference)(Code)
Set that the property value can't be equal to a specified int reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



setNotEqual
public void setNotEqual(long reference)(Code)
Set that the property value can't be equal to a specified long reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



setNotEqual
public void setNotEqual(float reference)(Code)
Set that the property value can't be equal to a specified float reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



setNotEqual
public void setNotEqual(double reference)(Code)
Set that the property value can't be equal to a specified double reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



setNotEqual
public void setNotEqual(Object reference)(Code)
Set that the property value can't be equal to a specified Object reference value.
See Also:   ConstrainedProperty.notEqual(boolean)
since:
   1.0



setNotNull
public void setNotNull(boolean notNull)(Code)
Set whether the property value can be null.
See Also:   ConstrainedProperty.notNull(boolean)
since:
   1.0



setOrdinal
public void setOrdinal(boolean ordinal)(Code)
Sets whether this property has to be used as an ordinal.
Parameters:
  ordinal - true if this property is an ordinal; or

false otherwise
See Also:   ConstrainedProperty.ordinal(boolean)
See Also:   ConstrainedProperty.ordinal(boolean,String)
See Also:   ConstrainedProperty.setOrdinal(boolean,String)
See Also:   ConstrainedProperty.isOrdinal()
since:
   1.0




setOrdinal
public void setOrdinal(boolean ordinal, String restriction)(Code)
Sets whether this property has to be used as an ordinal with a restricting column.
Parameters:
  ordinal - true if this property is an ordinal; or

false otherwise
Parameters:
  restriction - the name of the restricting column
See Also:   ConstrainedProperty.ordinal(boolean)
See Also:   ConstrainedProperty.ordinal(boolean,String)
See Also:   ConstrainedProperty.setOrdinal(boolean)
See Also:   ConstrainedProperty.isOrdinal()
See Also:   ConstrainedProperty.hasOrdinalRestriction()
See Also:   ConstrainedProperty.getOrdinalRestriction()
since:
   1.0




setPersistent
public void setPersistent(boolean persistent)(Code)



setPosition
public void setPosition(int position)(Code)
Sets the position in which the property should be displayed.
Parameters:
  position - an integer value with the position; or

-1 if the property shouldn't be positioned
See Also:   ConstrainedProperty.position(int)
See Also:   ConstrainedProperty.hasPosition()
See Also:   ConstrainedProperty.getPosition()
since:
   1.0




setPrecision
public void setPrecision(int precision)(Code)



setRangeBegin
public void setRangeBegin(byte value)(Code)



setRangeBegin
public void setRangeBegin(char value)(Code)



setRangeBegin
public void setRangeBegin(short value)(Code)



setRangeBegin
public void setRangeBegin(int value)(Code)



setRangeBegin
public void setRangeBegin(long value)(Code)



setRangeBegin
public void setRangeBegin(float value)(Code)



setRangeBegin
public void setRangeBegin(double value)(Code)



setRangeBegin
public void setRangeBegin(Comparable rangeBegin)(Code)



setRangeEnd
public void setRangeEnd(byte value)(Code)



setRangeEnd
public void setRangeEnd(char value)(Code)



setRangeEnd
public void setRangeEnd(short value)(Code)



setRangeEnd
public void setRangeEnd(int value)(Code)



setRangeEnd
public void setRangeEnd(long value)(Code)



setRangeEnd
public void setRangeEnd(float value)(Code)



setRangeEnd
public void setRangeEnd(double value)(Code)



setRangeEnd
public void setRangeEnd(Comparable rangeEnd)(Code)



setRegexp
public void setRegexp(String regexp)(Code)



setRepository
public void setRepository(String repository)(Code)
Sets the repository where the content data of this property will be stored.
Parameters:
  repository - the repository
See Also:   ConstrainedProperty.repository(String)
See Also:   ConstrainedProperty.getRepository()
See Also:   ConstrainedProperty.hasRepository()
since:
   1.0



setSameAs
public void setSameAs(String reference)(Code)



setSaved
public void setSaved(boolean saved)(Code)



setScale
public void setScale(int scale)(Code)



setSparse
public void setSparse(boolean sparse)(Code)



setSubjectName
public void setSubjectName(String name)(Code)
Sets the subject name.
Parameters:
  name - the subject name
since:
   1.0



setTransformer
public void setTransformer(ContentTransformer transformer)(Code)
Sets a content transformer for this property.
Parameters:
  transformer - the content transformer
See Also:   ConstrainedProperty.mimeType(MimeType)
See Also:   ConstrainedProperty.transformer(ContentTransformer)
See Also:   ConstrainedProperty.hasTransformer()
See Also:   ConstrainedProperty.getTransformer()
since:
   1.0



setUnique
public void setUnique(boolean unique)(Code)
Set whether the property value has to be unique.
See Also:   ConstrainedProperty.unique(boolean)
since:
   1.0



setUrl
public void setUrl(boolean url)(Code)



sparse
public T sparse(boolean sparse)(Code)



subjectName
public T subjectName(String name)(Code)
Sets the subject name.
Parameters:
  name - the subject name this ConstrainedProperty
since:
   1.0



transformer
public T transformer(ContentTransformer transformer)(Code)
Sets a content transformer for this property.

This is only useful when the property also has a mime type constraint.
Parameters:
  transformer - the content transformer the current Content instance
See Also:   ConstrainedProperty.mimeType(MimeType)
See Also:   ConstrainedProperty.setTransformer(ContentTransformer)
See Also:   ConstrainedProperty.hasTransformer()
See Also:   ConstrainedProperty.getTransformer()
since:
   1.0




unique
public T unique(boolean unique)(Code)
Set whether the property value has to be unique.

Note that this is only applicable to contexts where a collection of the data is stored an that uniqueness can apply against the other entries. In a singular context, uniqueness is always guaranteed.
Parameters:
  unique - true when the value has to be unique; orfalse when it doesn't have to be. this ConstrainedProperty
See Also:   ConstrainedProperty.isUnique()
since:
   1.0




url
public T url(boolean url)(Code)



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.