org.zkoss.bind
Interface ValidationContext

All Known Implementing Classes:
ValidationContextImpl

public interface ValidationContext

The context for validation

Since:
6.0.0
Author:
dennis

Method Summary
 BindContext getBindContext()
           
 java.lang.String getCommand()
          get the command that trigger the validation
 java.util.Map<java.lang.String,Property[]> getProperties()
          get collected properties that need to be validated.
 Property[] getProperties(java.lang.String name)
          get collected properties that need to be validated by a property name.
 Property getProperty()
          get the main property that need to be validated.
 boolean isValid()
          is valid
 void setInvalid()
          set invalid
 

Method Detail

isValid

boolean isValid()
is valid

Returns:
true of result is valid, Note, default is true if no Validator called setInvalid()

setInvalid

void setInvalid()
set invalid


getCommand

java.lang.String getCommand()
get the command that trigger the validation

Returns:
the command, null if a prompt-save-binding

getProperties

java.util.Map<java.lang.String,Property[]> getProperties()
get collected properties that need to be validated. you usually use this method to get value of other properties to do complex validation or a form validation

Returns:
the properties map.

getProperties

Property[] getProperties(java.lang.String name)
get collected properties that need to be validated by a property name. you usually use this method to get a value of other properties to do complex validation or a form validation

Parameters:
name - the property name
Returns:
the properties array

getProperty

Property getProperty()
get the main property that need to be validated.

Returns:
the main property.

getBindContext

BindContext getBindContext()
Returns:
current bind context


Copyright © 2005-2011 Potix Corporation. All Rights Reserved. SourceForge.net Logo