nl.knowlogy.validation.metadata
Interface PropertyMetadata

All Known Implementing Classes:
PropertyMetadataImpl

public interface PropertyMetadata

PropertyMetadata is a interface for retrieving metadata from a property.

Author:
Robert
See Also:
nl.knowlogy.validation.metadata.StringMetadata, nl.knowlogy.validation.metadata.IntegerMetadata

Field Summary
static String ALLOWED_VALUES
           
static String MAX_LENGTH
           
static String MAX_SIZE
           
static String MIN_LENGTH
           
static String MIN_SIZE
           
static String PATTERN
           
static String REQUIRED
           
 
Method Summary
 String getAllowedValues()
          Returns a string with the allowed values.
 Long getMaxLength()
           
 Long getMaxSize()
          Return a maxsize of a number value
 Map getMetadata()
          Retuns a map with metadata.
 Long getMinLength()
           
 Long getMinSize()
          Returns a minsize of a number value.
 String getPattern()
           
 String getPropertyName()
          Returns the propertyName from the property to which this propertyMetadata belongs.
 Boolean isRequired()
          Return true if a value for this property is required.
 void setAllowedValues(String value)
           
 void setMaxLength(Long value)
           
 void setMaxSize(Long value)
           
 void setMinLength(Long value)
           
 void setMinSize(Long value)
           
 void setPattern(String pattern)
           
 void setRequired(Boolean value)
           
 

Field Detail

MAX_SIZE

static final String MAX_SIZE
See Also:
Constant Field Values

MIN_SIZE

static final String MIN_SIZE
See Also:
Constant Field Values

REQUIRED

static final String REQUIRED
See Also:
Constant Field Values

MIN_LENGTH

static final String MIN_LENGTH
See Also:
Constant Field Values

MAX_LENGTH

static final String MAX_LENGTH
See Also:
Constant Field Values

PATTERN

static final String PATTERN
See Also:
Constant Field Values

ALLOWED_VALUES

static final String ALLOWED_VALUES
See Also:
Constant Field Values
Method Detail

getPropertyName

String getPropertyName()
Returns the propertyName from the property to which this propertyMetadata belongs.

Returns:
the propertyName from the property to which this propertyMetadata belongs.

isRequired

Boolean isRequired()
Return true if a value for this property is required.

Returns:
Returns the isRequired.

setRequired

void setRequired(Boolean value)
Parameters:
value -

getMaxSize

Long getMaxSize()
Return a maxsize of a number value

Returns:

setMaxSize

void setMaxSize(Long value)

getMinSize

Long getMinSize()
Returns a minsize of a number value.

Returns:
minsize of a number value

setMinSize

void setMinSize(Long value)

getPattern

String getPattern()
Returns:
Returns the regEx.

setPattern

void setPattern(String pattern)

getAllowedValues

String getAllowedValues()
Returns a string with the allowed values. Values a separeted with ','

Returns:

setAllowedValues

void setAllowedValues(String value)

setMaxLength

void setMaxLength(Long value)

getMaxLength

Long getMaxLength()
Returns:
Returns the maxLength.

setMinLength

void setMinLength(Long value)

getMinLength

Long getMinLength()
Returns:
Returns the minLength.

getMetadata

Map getMetadata()
Retuns a map with metadata. Standard keys ared maxSize, minSize, required,minlength, maxlenght, pattern

Returns:
a map with metadata. Standard keys ared maxSize, minSize, required,minlength, maxlenght, pattern .


Copyright © 2007. All Rights Reserved.