ZMObject
|
+--ZMRule
|
+--ZMDateRule
public class ZMDateRule
extends ZMRule
| Constructor Summary | |
|---|---|
ZMDateRule(string name, string format, string msg) Create new date rule. |
|
| Method Summary | |
|---|---|
| string | Return an appropriate error message. |
| protected void | Get the format string. |
| string | Create JS validation call. |
| boolean | validate(array req) Validate the given request data. |
| Methods inherited from org.zenmagick.validation.ZMRule | |
|---|---|
| getDefaultMsg, getErrorMsg, getJSName, getMsg, getName, toJSString, validate | |
| Methods inherited from org.zenmagick.ZMObject | |
|---|---|
| attachMethod, get, getAttachedMethods, getPropertyNames, set, singleton | |
public ZMDateRule(string name, string format, string msg)
Create new date rule.
null, UI_DATE_FORMAT will be used.public string getErrorMsg()
Return an appropriate error message.
protected void getFormat()
Get the format string. /
public string toJSString()
Create JS validation call.
public boolean validate(array req)
Validate the given request data.
true if the value for $name is valid, false if not.
Date validation rule.