KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jahia > security > license > LimitValue


1 /*
2  * Created on Sep 14, 2003
3  *
4  * To change the template for this generated file go to
5  * Window>Preferences>Java>Code Generation>Code and Comments
6  */

7 package org.jahia.security.license;
8
9 import java.io.Serializable JavaDoc;
10
11 import org.jahia.utils.xml.XmlUtils;
12 import org.jahia.resourcebundle.ResourceMessage;
13
14 /**
15  * @author loom
16  *
17  * To change the template for this generated type comment go to
18  * Window>Preferences>Java>Code Generation>Code and Comments
19  */

20 public class LimitValue implements Serializable JavaDoc {
21
22     private String JavaDoc value;
23
24     /**
25      * @param value
26      */

27     public LimitValue(String JavaDoc value) {
28         this.value = value;
29     }
30     /**
31      * @return
32      */

33     public String JavaDoc getValue() {
34         return value;
35     }
36
37     public String JavaDoc toXMLString() {
38         return XmlUtils.escapeXml(value);
39     }
40
41     public boolean check(Validator validator) {
42         return validator.assertEquals(value);
43     }
44
45     public ResourceMessage getErrorMessage(Validator validator) {
46         return validator.getErrorMessage();
47     }
48
49 }
50
Popular Tags