Author: alexsmirnov
Date: 2008-07-03 20:34:36 -0400 (Thu, 03 Jul 2008)
New Revision: 9416
Added:
trunk/sandbox/samples/beanValidatorSample/.metadata/
trunk/sandbox/samples/beanValidatorSample/.metadata/src/
trunk/sandbox/samples/beanValidatorSample/.metadata/src/main/
trunk/sandbox/samples/beanValidatorSample/.metadata/src/main/webapp/
trunk/sandbox/samples/beanValidatorSample/.metadata/src/main/webapp/WEB-INF/
trunk/sandbox/samples/beanValidatorSample/.metadata/src/main/webapp/WEB-INF/faces-config.pageflow
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/DataBean.java
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/LengthBean.java
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MaxBean.java
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MinBean.java
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MinMaxBean.java
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/NotEmptyBean.java
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/NotNullBean.java
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/Validable.java
trunk/sandbox/samples/beanValidatorSample/src/main/webapp/META-INF/
trunk/sandbox/samples/beanValidatorSample/src/main/webapp/META-INF/MANIFEST.MF
trunk/sandbox/samples/beanValidatorSample/src/main/webapp/WEB-INF/lib/
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/BeanValidator.java
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/ELContextWrapper.java
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/FacesBeanValidator.java
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/BeanValidatorTest.java
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/UnValidableBean.java
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/ValidableBean.java
Removed:
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/BeanValidator.java
Modified:
trunk/sandbox/samples/beanValidatorSample/pom.xml
trunk/sandbox/samples/beanValidatorSample/src/main/webapp/WEB-INF/faces-config.xml
trunk/sandbox/samples/beanValidatorSample/src/main/webapp/WEB-INF/web.xml
trunk/sandbox/samples/beanValidatorSample/src/main/webapp/pages/index.jsp
trunk/sandbox/ui/beanValidator/pom.xml
trunk/sandbox/ui/beanValidator/src/main/config/component/beanValidator.xml
Log:
Validator sample start working
Added:
trunk/sandbox/samples/beanValidatorSample/.metadata/src/main/webapp/WEB-INF/faces-config.pageflow
===================================================================
---
trunk/sandbox/samples/beanValidatorSample/.metadata/src/main/webapp/WEB-INF/faces-config.pageflow
(rev 0)
+++
trunk/sandbox/samples/beanValidatorSample/.metadata/src/main/webapp/WEB-INF/faces-config.pageflow 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<pageflow:Pageflow
xmlns:pageflow="http://www.sybase.com/suade/pageflow"
id="pf12151265924800"
configfile="/beanValidatorSample/src/main/webapp/WEB-INF/faces-config.xml"/>
Modified: trunk/sandbox/samples/beanValidatorSample/pom.xml
===================================================================
--- trunk/sandbox/samples/beanValidatorSample/pom.xml 2008-07-03 19:26:19 UTC (rev 9415)
+++ trunk/sandbox/samples/beanValidatorSample/pom.xml 2008-07-04 00:34:36 UTC (rev 9416)
@@ -1,38 +1,49 @@
-<?xml version="1.0"?><project>
- <parent>
- <artifactId>samples</artifactId>
- <groupId>org.richfaces.sandbox</groupId>
- <version>3.2.2-SNAPSHOT</version>
- </parent>
- <modelVersion>4.0.0</modelVersion>
- <groupId>org.richfaces.samples</groupId>
- <artifactId>beanValidatorSample</artifactId>
- <packaging>war</packaging>
- <name>beanValidatorSample Maven Webapp</name>
- <version>3.2.2-SNAPSHOT</version>
- <build>
- <finalName>beanValidatorSample</finalName>
- <plugins>
- <plugin>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
- </plugins>
- </build>
- <dependencies>
- <dependency>
- <groupId>junit</groupId>
- <artifactId>junit</artifactId>
- <version>3.8.1</version>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.richfaces.ui</groupId>
- <artifactId>richfaces-ui</artifactId>
- <version>3.2.2-SNAPSHOT</version>
- </dependency>
- </dependencies>
+<?xml version="1.0"?>
+<project>
+ <parent>
+ <artifactId>samples</artifactId>
+ <groupId>org.richfaces.sandbox</groupId>
+ <version>3.2.2-SNAPSHOT</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.richfaces.samples</groupId>
+ <artifactId>beanValidatorSample</artifactId>
+ <packaging>war</packaging>
+ <name>beanValidatorSample Maven Webapp</name>
+ <version>3.2.2-SNAPSHOT</version>
+ <build>
+ <finalName>beanValidatorSample</finalName>
+ <plugins>
+ <plugin>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ <dependencies>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>3.8.1</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.richfaces.ui</groupId>
+ <artifactId>beanValidator</artifactId>
+ <version>3.2.2-SNAPSHOT</version>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-jcl</artifactId>
+ <version>1.4.2</version>
+ </dependency>
+ <dependency>
+ <groupId>org.richfaces.ui</groupId>
+ <artifactId>richfaces-ui</artifactId>
+ <version>3.2.2-SNAPSHOT</version>
+ </dependency>
+ </dependencies>
</project>
\ No newline at end of file
Added:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/DataBean.java
===================================================================
--- trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/DataBean.java
(rev 0)
+++
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/DataBean.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,186 @@
+/**
+ *
+ */
+package org.richfaces;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.List;
+import java.util.ListIterator;
+
+/**
+ * @author asmirnov
+ *
+ */
+public class DataBean implements List<Validable> {
+
+ private final List<Validable> backend;
+
+ public DataBean() {
+ backend = new ArrayList<Validable>(6);
+ backend.add(new NotNullBean());
+ backend.add(new NotEmptyBean());
+ backend.add(new LengthBean());
+ backend.add(new MinBean());
+ backend.add(new MaxBean());
+ backend.add(new MinMaxBean());
+ }
+
+ /**
+ * @param o
+ * @return
+ * @see java.util.List#contains(java.lang.Object)
+ */
+ public boolean contains(Object o) {
+ return backend.contains(o);
+ }
+
+ /**
+ * @param c
+ * @return
+ * @see java.util.List#containsAll(java.util.Collection)
+ */
+ public boolean containsAll(Collection<?> c) {
+ return backend.containsAll(c);
+ }
+
+ /**
+ * @param index
+ * @return
+ * @see java.util.List#get(int)
+ */
+ public Validable get(int index) {
+ return backend.get(index);
+ }
+
+ /**
+ * @param o
+ * @return
+ * @see java.util.List#indexOf(java.lang.Object)
+ */
+ public int indexOf(Object o) {
+ return backend.indexOf(o);
+ }
+
+ /**
+ * @return
+ * @see java.util.List#isEmpty()
+ */
+ public boolean isEmpty() {
+ return backend.isEmpty();
+ }
+
+ /**
+ * @return
+ * @see java.util.List#iterator()
+ */
+ public Iterator<Validable> iterator() {
+ return backend.iterator();
+ }
+
+ /**
+ * @param o
+ * @return
+ * @see java.util.List#lastIndexOf(java.lang.Object)
+ */
+ public int lastIndexOf(Object o) {
+ return backend.lastIndexOf(o);
+ }
+
+ /**
+ * @return
+ * @see java.util.List#listIterator()
+ */
+ public ListIterator<Validable> listIterator() {
+ return backend.listIterator();
+ }
+
+ /**
+ * @param index
+ * @return
+ * @see java.util.List#listIterator(int)
+ */
+ public ListIterator<Validable> listIterator(int index) {
+ return backend.listIterator(index);
+ }
+
+ /**
+ * @return
+ * @see java.util.List#size()
+ */
+ public int size() {
+ return backend.size();
+ }
+
+ /**
+ * @param fromIndex
+ * @param toIndex
+ * @return
+ * @see java.util.List#subList(int, int)
+ */
+ public List<Validable> subList(int fromIndex, int toIndex) {
+ return backend.subList(fromIndex, toIndex);
+ }
+
+ /**
+ * @return
+ * @see java.util.List#toArray()
+ */
+ public Object[] toArray() {
+ return backend.toArray();
+ }
+
+ /**
+ * @param <T>
+ * @param a
+ * @return
+ * @see java.util.List#toArray(T[])
+ */
+ public <T> T[] toArray(T[] a) {
+ return backend.toArray(a);
+ }
+
+ public boolean add(Validable o) {
+ throw new IllegalAccessError();
+ }
+
+ public void add(int index, Validable element) {
+ throw new IllegalAccessError();
+ }
+
+ public boolean addAll(Collection<? extends Validable> c) {
+ throw new IllegalAccessError();
+ }
+
+ public boolean addAll(int index, Collection<? extends Validable> c) {
+ throw new IllegalAccessError();
+ }
+
+ public void clear() {
+ throw new IllegalAccessError();
+ }
+
+ public boolean remove(Object o) {
+ throw new IllegalAccessError();
+ }
+
+ public Validable remove(int index) {
+ throw new IllegalAccessError();
+ }
+
+ public boolean removeAll(Collection<?> c) {
+ throw new IllegalAccessError();
+ }
+
+ public boolean retainAll(Collection<?> c) {
+ throw new IllegalAccessError();
+ }
+
+ public Validable set(int index, Validable element) {
+ throw new IllegalAccessError();
+ }
+
+
+
+}
Property changes on:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/DataBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/LengthBean.java
===================================================================
--- trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/LengthBean.java
(rev 0)
+++
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/LengthBean.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,53 @@
+/**
+ *
+ */
+package org.richfaces;
+
+import org.hibernate.validator.Length;
+import org.hibernate.validator.NotEmpty;
+import org.hibernate.validator.NotNull;
+
+/**
+ * @author asmirnov
+ *
+ */
+public class LengthBean implements Validable {
+
+ @Length(max=10,min=2,message="incorrect field length")
+ private String text;
+
+ private int intValue;
+
+ /**
+ * @return the text
+ */
+ public String getText() {
+ return text;
+ }
+
+ /**
+ * @param text the text to set
+ */
+ public void setText(String text) {
+ this.text = text;
+ }
+
+ /**
+ * @return the intValue
+ */
+ public int getIntValue() {
+ return intValue;
+ }
+
+ /**
+ * @param intValue the intValue to set
+ */
+ public void setIntValue(int intValue) {
+ this.intValue = intValue;
+ }
+
+ public String getDescription() {
+ return "String Length Validation";
+ }
+
+}
Property changes on:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/LengthBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MaxBean.java
===================================================================
--- trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MaxBean.java
(rev 0)
+++
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MaxBean.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,55 @@
+/**
+ *
+ */
+package org.richfaces;
+
+import org.hibernate.validator.Length;
+import org.hibernate.validator.Max;
+import org.hibernate.validator.Min;
+import org.hibernate.validator.NotEmpty;
+import org.hibernate.validator.NotNull;
+
+/**
+ * @author asmirnov
+ *
+ */
+public class MaxBean implements Validable {
+
+ private String text;
+
+ @Max(10)
+ private int intValue;
+
+ /**
+ * @return the text
+ */
+ public String getText() {
+ return text;
+ }
+
+ /**
+ * @param text the text to set
+ */
+ public void setText(String text) {
+ this.text = text;
+ }
+
+ /**
+ * @return the intValue
+ */
+ public int getIntValue() {
+ return intValue;
+ }
+
+ /**
+ * @param intValue the intValue to set
+ */
+ public void setIntValue(int intValue) {
+ this.intValue = intValue;
+ }
+
+ public String getDescription() {
+ return "Max integer Validation";
+ }
+
+}
Property changes on:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MaxBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MinBean.java
===================================================================
--- trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MinBean.java
(rev 0)
+++
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MinBean.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,54 @@
+/**
+ *
+ */
+package org.richfaces;
+
+import org.hibernate.validator.Length;
+import org.hibernate.validator.Min;
+import org.hibernate.validator.NotEmpty;
+import org.hibernate.validator.NotNull;
+
+/**
+ * @author asmirnov
+ *
+ */
+public class MinBean implements Validable {
+
+ private String text;
+
+ @Min(2)
+ private int intValue;
+
+ /**
+ * @return the text
+ */
+ public String getText() {
+ return text;
+ }
+
+ /**
+ * @param text the text to set
+ */
+ public void setText(String text) {
+ this.text = text;
+ }
+
+ /**
+ * @return the intValue
+ */
+ public int getIntValue() {
+ return intValue;
+ }
+
+ /**
+ * @param intValue the intValue to set
+ */
+ public void setIntValue(int intValue) {
+ this.intValue = intValue;
+ }
+
+ public String getDescription() {
+ return "Min integer Validation";
+ }
+
+}
Property changes on:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MinBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MinMaxBean.java
===================================================================
--- trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MinMaxBean.java
(rev 0)
+++
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MinMaxBean.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,56 @@
+/**
+ *
+ */
+package org.richfaces;
+
+import org.hibernate.validator.Length;
+import org.hibernate.validator.Max;
+import org.hibernate.validator.Min;
+import org.hibernate.validator.NotEmpty;
+import org.hibernate.validator.NotNull;
+
+/**
+ * @author asmirnov
+ *
+ */
+public class MinMaxBean implements Validable {
+
+ private String text;
+
+ @Min(2)
+ @Max(10)
+ private int intValue;
+
+ /**
+ * @return the text
+ */
+ public String getText() {
+ return text;
+ }
+
+ /**
+ * @param text the text to set
+ */
+ public void setText(String text) {
+ this.text = text;
+ }
+
+ /**
+ * @return the intValue
+ */
+ public int getIntValue() {
+ return intValue;
+ }
+
+ /**
+ * @param intValue the intValue to set
+ */
+ public void setIntValue(int intValue) {
+ this.intValue = intValue;
+ }
+
+ public String getDescription() {
+ return "Min and Max integer Validation";
+ }
+
+}
Property changes on:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/MinMaxBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/NotEmptyBean.java
===================================================================
---
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/NotEmptyBean.java
(rev 0)
+++
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/NotEmptyBean.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,52 @@
+/**
+ *
+ */
+package org.richfaces;
+
+import org.hibernate.validator.NotEmpty;
+import org.hibernate.validator.NotNull;
+
+/**
+ * @author asmirnov
+ *
+ */
+public class NotEmptyBean implements Validable {
+
+ @NotEmpty
+ private String text;
+
+ private int intValue;
+
+ /**
+ * @return the text
+ */
+ public String getText() {
+ return text;
+ }
+
+ /**
+ * @param text the text to set
+ */
+ public void setText(String text) {
+ this.text = text;
+ }
+
+ /**
+ * @return the intValue
+ */
+ public int getIntValue() {
+ return intValue;
+ }
+
+ /**
+ * @param intValue the intValue to set
+ */
+ public void setIntValue(int intValue) {
+ this.intValue = intValue;
+ }
+
+ public String getDescription() {
+ return "Not Empty Validation";
+ }
+
+}
Property changes on:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/NotEmptyBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/NotNullBean.java
===================================================================
---
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/NotNullBean.java
(rev 0)
+++
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/NotNullBean.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,51 @@
+/**
+ *
+ */
+package org.richfaces;
+
+import org.hibernate.validator.NotNull;
+
+/**
+ * @author asmirnov
+ *
+ */
+public class NotNullBean implements Validable {
+
+ @NotNull
+ private String text;
+
+ private int intValue;
+
+ /**
+ * @return the text
+ */
+ public String getText() {
+ return text;
+ }
+
+ /**
+ * @param text the text to set
+ */
+ public void setText(String text) {
+ this.text = text;
+ }
+
+ /**
+ * @return the intValue
+ */
+ public int getIntValue() {
+ return intValue;
+ }
+
+ /**
+ * @param intValue the intValue to set
+ */
+ public void setIntValue(int intValue) {
+ this.intValue = intValue;
+ }
+
+ public String getDescription() {
+ return "Not Null Validation";
+ }
+
+}
Property changes on:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/NotNullBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/Validable.java
===================================================================
--- trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/Validable.java
(rev 0)
+++
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/Validable.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,17 @@
+/**
+ *
+ */
+package org.richfaces;
+
+/**
+ * @author asmirnov
+ *
+ */
+public interface Validable {
+
+ public String getText();
+
+ public String getDescription();
+
+ public int getIntValue();
+}
Property changes on:
trunk/sandbox/samples/beanValidatorSample/src/main/java/org/richfaces/Validable.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/sandbox/samples/beanValidatorSample/src/main/webapp/META-INF/MANIFEST.MF
===================================================================
--- trunk/sandbox/samples/beanValidatorSample/src/main/webapp/META-INF/MANIFEST.MF
(rev 0)
+++
trunk/sandbox/samples/beanValidatorSample/src/main/webapp/META-INF/MANIFEST.MF 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+Class-Path:
+
Property changes on:
trunk/sandbox/samples/beanValidatorSample/src/main/webapp/META-INF/MANIFEST.MF
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified:
trunk/sandbox/samples/beanValidatorSample/src/main/webapp/WEB-INF/faces-config.xml
===================================================================
---
trunk/sandbox/samples/beanValidatorSample/src/main/webapp/WEB-INF/faces-config.xml 2008-07-03
19:26:19 UTC (rev 9415)
+++
trunk/sandbox/samples/beanValidatorSample/src/main/webapp/WEB-INF/faces-config.xml 2008-07-04
00:34:36 UTC (rev 9416)
@@ -7,4 +7,9 @@
<managed-bean-class>org.richfaces.Bean</managed-bean-class>
<managed-bean-scope>request</managed-bean-scope>
</managed-bean>
+ <managed-bean>
+ <managed-bean-name>data</managed-bean-name>
+ <managed-bean-class>org.richfaces.DataBean</managed-bean-class>
+ <managed-bean-scope>session</managed-bean-scope>
+ </managed-bean>
</faces-config>
Modified: trunk/sandbox/samples/beanValidatorSample/src/main/webapp/WEB-INF/web.xml
===================================================================
--- trunk/sandbox/samples/beanValidatorSample/src/main/webapp/WEB-INF/web.xml 2008-07-03
19:26:19 UTC (rev 9415)
+++ trunk/sandbox/samples/beanValidatorSample/src/main/webapp/WEB-INF/web.xml 2008-07-04
00:34:36 UTC (rev 9416)
@@ -3,10 +3,6 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
<display-name>Archetype Created Web Application</display-name>
<context-param>
- <param-name>javax.faces.CONFIG_FILES</param-name>
- <param-value>/WEB-INF/faces-config.xml</param-value>
- </context-param>
- <context-param>
<param-name>javax.faces.STATE_SAVING_METHOD</param-name>
<param-value>server</param-value>
</context-param>
Modified: trunk/sandbox/samples/beanValidatorSample/src/main/webapp/pages/index.jsp
===================================================================
--- trunk/sandbox/samples/beanValidatorSample/src/main/webapp/pages/index.jsp 2008-07-03
19:26:19 UTC (rev 9415)
+++ trunk/sandbox/samples/beanValidatorSample/src/main/webapp/pages/index.jsp 2008-07-04
00:34:36 UTC (rev 9416)
@@ -1,12 +1,49 @@
-<%@ taglib
uri="http://java.sun.com/jsf/html" prefix="h" %>
+<%@ taglib
uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib
uri="http://java.sun.com/jsf/core" prefix="f"%>
+<%@ taglib
+
uri="http://labs.jboss.com/jbossrichfaces/ui/ui/beanValidator"
+ prefix="v"%>
+<%@ taglib
uri="http://richfaces.org/rich" prefix="data"%>
+<%@taglib prefix="a4j"
uri="http://richfaces.org/a4j"%>
<html>
- <head>
- <title></title>
- </head>
- <body>
- <f:view>
-
- </f:view>
- </body>
-</html>
+<head>
+<title>Hibernate validator test</title>
+</head>
+<body>
+<f:view>
+ <h:form id="form">
+ <h:dataTable value="#{data}" var="bean" id="table">
+ <h:column>
+ <f:facet name="header">
+ <h:outputText value="text field" />
+ </f:facet>
+ <h:outputLabel for="text" value="Text input:" />
+ <h:inputText id="text" value="#{bean.text}">
+ <a4j:support event="onblur" reRender="table"/>
+ <v:beanValidator/>
+ </h:inputText>
+ <h:message for="text"/>
+ </h:column>
+ <h:column>
+ <f:facet name="header">
+ <h:outputText value="integer field" />
+ </f:facet>
+ <h:outputLabel for="intValue" value="Number input:" />
+ <h:inputText id="intValue" value="#{bean.intValue}">
+ <a4j:support event="onblur" reRender="table"/>
+ <v:beanValidator/>
+ </h:inputText>
+ <h:message for="intValue"/>
+ </h:column>
+ <h:column>
+ <f:facet name="header">
+ <h:outputText value="description" />
+ </f:facet>
+ <h:outputText value="#{bean.description}"></h:outputText>
+ </h:column>
+ </h:dataTable>
+</h:form>
+ <data:messages></data:messages>
+</f:view>
+</body>
+</html>
Modified: trunk/sandbox/ui/beanValidator/pom.xml
===================================================================
--- trunk/sandbox/ui/beanValidator/pom.xml 2008-07-03 19:26:19 UTC (rev 9415)
+++ trunk/sandbox/ui/beanValidator/pom.xml 2008-07-04 00:34:36 UTC (rev 9416)
@@ -52,15 +52,19 @@
<artifactId>hibernate-validator</artifactId>
<version>3.1.0.CR1</version>
<exclusions>
- <exclusion>
- <artifactId>hibernate-core</artifactId>
- <groupId>org.hibernate</groupId>
- </exclusion>
- <exclusion>
- <artifactId>slf4j-api</artifactId>
- <groupId>org.slf4j</groupId>
- </exclusion>
+ <!--
+ <exclusion> <artifactId>hibernate-core</artifactId>
+ <groupId>org.hibernate</groupId> </exclusion> <exclusion>
+ <artifactId>slf4j-api</artifactId>
<groupId>org.slf4j</groupId>
+ </exclusion>
+ -->
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-simple</artifactId>
+ <version>1.4.2</version>
+ <scope>test</scope>
+ </dependency>
</dependencies>
</project>
\ No newline at end of file
Modified: trunk/sandbox/ui/beanValidator/src/main/config/component/beanValidator.xml
===================================================================
--- trunk/sandbox/ui/beanValidator/src/main/config/component/beanValidator.xml 2008-07-03
19:26:19 UTC (rev 9415)
+++ trunk/sandbox/ui/beanValidator/src/main/config/component/beanValidator.xml 2008-07-04
00:34:36 UTC (rev 9416)
@@ -40,7 +40,7 @@
</component>
<validator generate="false">
<id>org.richfaces.BeanValidator</id>
- <classname>org.richfaces.validator.BeanValidator</classname>
+ <classname>org.richfaces.validator.FacesBeanValidator</classname>
<description>
<![CDATA[Validate Input by the Bean/Hibernate validator annotations]]>
</description>
Deleted:
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/BeanValidator.java
===================================================================
---
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/BeanValidator.java 2008-07-03
19:26:19 UTC (rev 9415)
+++
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/BeanValidator.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -1,26 +0,0 @@
-/**
- *
- */
-package org.richfaces.validator;
-
-import javax.faces.component.UIComponent;
-import javax.faces.context.FacesContext;
-import javax.faces.validator.Validator;
-import javax.faces.validator.ValidatorException;
-
-/**
- * @author asmirnov
- *
- */
-public class BeanValidator implements Validator {
-
- /* (non-Javadoc)
- * @see javax.faces.validator.Validator#validate(javax.faces.context.FacesContext,
javax.faces.component.UIComponent, java.lang.Object)
- */
- public void validate(FacesContext context, UIComponent component, Object
convertedValue)
- throws ValidatorException {
- // TODO Auto-generated method stub
-
- }
-
-}
Added:
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/BeanValidator.java
===================================================================
---
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/BeanValidator.java
(rev 0)
+++
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/BeanValidator.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,257 @@
+/**
+ *
+ */
+package org.richfaces.validator;
+
+import java.beans.FeatureDescriptor;
+import java.util.Iterator;
+import java.util.Locale;
+import java.util.Map;
+
+import javax.el.ELContext;
+import javax.el.ELResolver;
+import javax.el.ValueExpression;
+import javax.faces.context.ExternalContext;
+import javax.faces.context.FacesContext;
+
+import org.hibernate.validator.ClassValidator;
+import org.hibernate.validator.InvalidValue;
+
+/**
+ * Perform validation by Hibernate Validator annotations
+ * @author asmirnov
+ *
+ */
+public class BeanValidator {
+
+ public static final String VALIDATOR_PARAM = BeanValidator.class.getName();
+
+ private BeanValidator(){
+ // This is a "singleton"-like class. Only factory methods allowed.
+ }
+
+ /**
+ * Create BeanValidator instance. For a Junit tests only.
+ * @return
+ */
+ static BeanValidator createInstance(){
+ // TODO - get instance class name from a "META-INF/service"
+ return new BeanValidator();
+ }
+
+ /**
+ * Return BeanValidator object from a ServletContext attribute.
+ * Create new instance if noone is defined.
+ * @param context
+ * @return
+ */
+ public static BeanValidator getInstance(FacesContext context) {
+ ExternalContext externalContext = context.getExternalContext();
+ externalContext.getContext();
+ BeanValidator instance;
+ // TODO - use properly synchronization mutex ?
+ synchronized (context) {
+ Map<String, Object> applicationMap = externalContext.getApplicationMap();
+ instance = (BeanValidator) applicationMap.get(VALIDATOR_PARAM);
+ if(null == instance){
+ // Vaildator not initialized - create and store new instance.
+ instance = createInstance();
+ applicationMap.put(VALIDATOR_PARAM, instance);
+ }
+ }
+ return instance;
+ }
+
+ /**
+ * Perform Validation for a new value.
+ * @param context current faces context.
+ * @param target {@link ValueExpression} for a value assigement.
+ * @param value new value for validation
+ * @return null if no validation errors. Array of the validation messages othervise.
+ */
+ public String[] validate(FacesContext context, ValueExpression target, Object value) {
+ // TODO -check null parameters.
+ ELContext elContext = context.getELContext();
+ ValidationResolver validationResolver = new
ValidationResolver(elContext.getELResolver());
+ ELContextWrapper wrappedElContext = new
ELContextWrapper(elContext,validationResolver);
+ // TODO - check null viewRoot and null Locale.
+ wrappedElContext.setLocale(context.getViewRoot().getLocale());
+ // TODO - handle ELExceptions ?
+ target.setValue(wrappedElContext, value);
+ if(validationResolver.isValid()){
+ return null;
+ } else {
+ return validationResolver.getValidationMessages();
+ }
+ }
+
+ /**
+ * Validate bean property for a new value.
+ * TODO - localisation ?
+ * @param base - bean
+ * @param property - bean property name.
+ * @param value new value.
+ * @return null for a valid value, array of the validation messages othervise.
+ */
+ public String[] validate(Object base, String property, Object value, Locale locale) {
+ InvalidValue[] invalidValues = validateBean(base, property, value, locale);
+ if(null == invalidValues){
+ return null;
+ } else {
+ String[] result = new String[invalidValues.length];
+ for (int i = 0; i < invalidValues.length; i++) {
+ InvalidValue invalidValue = invalidValues[i];
+ result[i] = invalidValue.getMessage();
+ }
+ return result;
+ }
+ }
+
+ /**
+ * Validate bean property of the base object aganist new value
+ * @param base
+ * @param property
+ * @param value
+ * @return
+ */
+ protected InvalidValue[] validateBean(Object base, String property,
+ Object value, Locale locale) {
+ Class<? extends Object> beanClass = base.getClass();
+ InvalidValue[] invalidValues = validateClass(beanClass, property, value, locale);
+ return invalidValues;
+ }
+
+ /**
+ * Validate bean property in the base class aganist new value.
+ * @param beanClass
+ * @param property
+ * @param value
+ * @return
+ */
+ protected InvalidValue[] validateClass(Class<? extends Object> beanClass,
+ String property, Object value, Locale locale) {
+ ClassValidator<? extends Object> classValidator = getValidator(beanClass,
locale);
+ InvalidValue[] invalidValues = classValidator.getPotentialInvalidValues( property,
value );
+ return invalidValues;
+ }
+
+ /**
+ * Get ( or create ) {@link ClassValidator} for a given bean class.
+ * @param beanClass
+ * @return
+ */
+ @SuppressWarnings("unchecked")
+ protected ClassValidator<? extends Object> getValidator(Class<? extends
Object> beanClass, Locale locale) {
+ // TODO - cache validator instances.
+ // TODO - localization support.
+ return new ClassValidator(beanClass);
+ }
+
+ /**
+ * Wrapper class for a {@link ELResolver}. For a setValue method, perform validation
instead of real assigement.
+ * @author asmirnov
+ *
+ */
+ final class ValidationResolver extends ELResolver {
+
+ /**
+ * Original resolver.
+ */
+ private final ELResolver parent;
+
+ private boolean valid = true;
+
+ private String[] validationMessages = null;
+
+ /**
+ * @param parent
+ */
+ public ValidationResolver(ELResolver parent) {
+ this.parent = parent;
+ }
+
+ public boolean isValid() {
+ // TODO Auto-generated method stub
+ return valid;
+ }
+
+ /**
+ * @param context
+ * @param base
+ * @return
+ * @see javax.el.ELResolver#getCommonPropertyType(javax.el.ELContext,
java.lang.Object)
+ */
+ public Class<?> getCommonPropertyType(ELContext context, Object base) {
+ return parent.getCommonPropertyType(context, base);
+ }
+
+ /**
+ * @param context
+ * @param base
+ * @return
+ * @see javax.el.ELResolver#getFeatureDescriptors(javax.el.ELContext,
java.lang.Object)
+ */
+ public Iterator<FeatureDescriptor> getFeatureDescriptors(
+ ELContext context, Object base) {
+ return parent.getFeatureDescriptors(context, base);
+ }
+
+ /**
+ * @param context
+ * @param base
+ * @param property
+ * @return
+ * @see javax.el.ELResolver#getType(javax.el.ELContext, java.lang.Object,
java.lang.Object)
+ */
+ public Class<?> getType(ELContext context, Object base, Object property) {
+ return parent.getType(context, base, property);
+ }
+
+ /**
+ * @param context
+ * @param base
+ * @param property
+ * @return
+ * @see javax.el.ELResolver#getValue(javax.el.ELContext, java.lang.Object,
java.lang.Object)
+ */
+ public Object getValue(ELContext context, Object base, Object property) {
+ return parent.getValue(context, base, property);
+ }
+
+ /**
+ * @param context
+ * @param base
+ * @param property
+ * @return
+ * @see javax.el.ELResolver#isReadOnly(javax.el.ELContext, java.lang.Object,
java.lang.Object)
+ */
+ public boolean isReadOnly(ELContext context, Object base,
+ Object property) {
+ return parent.isReadOnly(context, base, property);
+ }
+
+ /**
+ * @param context
+ * @param base
+ * @param property
+ * @param value
+ * @see javax.el.ELResolver#setValue(javax.el.ELContext, java.lang.Object,
java.lang.Object, java.lang.Object)
+ */
+ public void setValue(ELContext context, Object base, Object property,
+ Object value) {
+ if(null != base && null != property){
+ context.setPropertyResolved(true);
+ validationMessages = validate(base,property.toString(),value,
context.getLocale());
+ valid = null == validationMessages || 0 == validationMessages.length;
+ }
+ }
+
+ /**
+ * @return the validationMessages
+ */
+ public String[] getValidationMessages() {
+ return validationMessages;
+ }
+
+ }
+}
Added:
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/ELContextWrapper.java
===================================================================
---
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/ELContextWrapper.java
(rev 0)
+++
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/ELContextWrapper.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,72 @@
+/**
+ *
+ */
+package org.richfaces.validator;
+
+import javax.el.ELContext;
+import javax.el.ELResolver;
+import javax.el.FunctionMapper;
+import javax.el.VariableMapper;
+
+/**
+ * @author asmirnov
+ *
+ */
+public class ELContextWrapper extends ELContext {
+
+ private final ELContext parent;
+
+ private final ELResolver resolver;
+
+ /**
+ * @param parent
+ */
+ public ELContextWrapper(ELContext parent,ELResolver resolver) {
+ super();
+ this.resolver = resolver;
+ this.parent = parent;
+ }
+
+ /* (non-Javadoc)
+ * @see javax.el.ELContext#getELResolver()
+ */
+ @Override
+ public ELResolver getELResolver() {
+ return resolver;
+ }
+
+ /**
+ * @return
+ * @see javax.el.ELContext#getFunctionMapper()
+ */
+ public FunctionMapper getFunctionMapper() {
+ return parent.getFunctionMapper();
+ }
+
+ /**
+ * @return
+ * @see javax.el.ELContext#getVariableMapper()
+ */
+ public VariableMapper getVariableMapper() {
+ return parent.getVariableMapper();
+ }
+
+ /**
+ * @param key
+ * @return
+ * @see javax.el.ELContext#getContext(java.lang.Class)
+ */
+ public Object getContext(Class key) {
+ return parent.getContext(key);
+ }
+
+ /**
+ * @param key
+ * @param contextObject
+ * @see javax.el.ELContext#putContext(java.lang.Class, java.lang.Object)
+ */
+ public void putContext(Class key, Object contextObject) {
+ parent.putContext(key, contextObject);
+ }
+
+}
Property changes on:
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/ELContextWrapper.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied:
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/FacesBeanValidator.java
(from rev 9413,
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/BeanValidator.java)
===================================================================
---
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/FacesBeanValidator.java
(rev 0)
+++
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/FacesBeanValidator.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,43 @@
+/**
+ *
+ */
+package org.richfaces.validator;
+
+import javax.el.ValueExpression;
+import javax.faces.application.FacesMessage;
+import javax.faces.component.UIComponent;
+import javax.faces.component.UIInput;
+import javax.faces.context.FacesContext;
+import javax.faces.validator.Validator;
+import javax.faces.validator.ValidatorException;
+
+/**
+ * Implementation of the JSF validator to use with Bean Validation / Hibernate validator
+ * @author asmirnov
+ *
+ */
+public class FacesBeanValidator implements Validator {
+
+ /* (non-Javadoc)
+ * @see javax.faces.validator.Validator#validate(javax.faces.context.FacesContext,
javax.faces.component.UIComponent, java.lang.Object)
+ */
+ public void validate(FacesContext context, UIComponent component, Object
convertedValue)
+ throws ValidatorException {
+ if (component instanceof UIInput) {
+ // Validate input component
+ UIInput input = (UIInput) component;
+ ValueExpression valueExpression = input.getValueExpression("value");
+ if(null != valueExpression){
+ // TODO - check EL Exceptions ?
+ String[] messages = BeanValidator.getInstance(context).validate(context,
valueExpression, convertedValue);
+ if(null != messages){
+ input.setValid(false);
+ // TODO - send all validation messages.
+ throw new ValidatorException(new
FacesMessage(FacesMessage.SEVERITY_ERROR,messages[0],""));
+ }
+ }
+ }
+
+ }
+
+}
Property changes on:
trunk/sandbox/ui/beanValidator/src/main/java/org/richfaces/validator/FacesBeanValidator.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/BeanValidatorTest.java
===================================================================
---
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/BeanValidatorTest.java
(rev 0)
+++
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/BeanValidatorTest.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,49 @@
+package org.richfaces.validator;
+
+import java.util.Locale;
+
+import org.hibernate.validator.ClassValidator;
+import org.hibernate.validator.InvalidValue;
+
+import junit.framework.TestCase;
+
+public class BeanValidatorTest extends TestCase {
+
+ public void testValidate() {
+
+ }
+
+ public void testGetValidator() throws Exception {
+ BeanValidator beanValidator = BeanValidator.createInstance();
+ ClassValidator<? extends Object> validator =
beanValidator.getValidator(ValidableBean.class,Locale.getDefault());
+ assertNotNull(validator);
+ assertTrue(validator.hasValidationRules());
+ validator = beanValidator.getValidator(String.class,Locale.getDefault());
+ assertNotNull(validator);
+ assertFalse(validator.hasValidationRules());
+ }
+
+ public void testValidateClass() throws Exception {
+ BeanValidator beanValidator = BeanValidator.createInstance();
+ InvalidValue[] invalidValues = beanValidator.validateClass(ValidableBean.class,
"integerProperty", new Integer(3),Locale.getDefault());
+ assertNotNull(invalidValues);
+ assertEquals(0, invalidValues.length);
+ invalidValues = beanValidator.validateClass(ValidableBean.class,
"integerProperty", new Integer(-1),Locale.getDefault());
+ assertNotNull(invalidValues);
+ assertEquals(1, invalidValues.length);
+ invalidValues = beanValidator.validateClass(UnValidableBean.class,
"integerProperty", new Integer(-1),Locale.getDefault());
+ assertNotNull(invalidValues);
+ assertEquals(0, invalidValues.length);
+ invalidValues = beanValidator.validateClass(ValidableBean.class,
"nonExistentProperty", new Integer(-1),Locale.getDefault());
+ assertNotNull(invalidValues);
+ assertEquals(0, invalidValues.length);
+
+ }
+
+ public void testValidateBean() throws Exception {
+ BeanValidator beanValidator = BeanValidator.createInstance();
+ InvalidValue[] invalidValues = beanValidator.validateBean(new ValidableBean(),
"integerProperty", new Integer(-1),Locale.getDefault());
+ assertNotNull(invalidValues);
+ assertEquals(1, invalidValues.length);
+ }
+}
Property changes on:
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/BeanValidatorTest.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/UnValidableBean.java
===================================================================
---
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/UnValidableBean.java
(rev 0)
+++
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/UnValidableBean.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,61 @@
+/**
+ *
+ */
+package org.richfaces.validator;
+
+
+/**
+ * @author asmirnov
+ *
+ */
+public class UnValidableBean {
+
+ private int integerProperty;
+
+ private String text;
+
+ private Object foo;
+
+ /**
+ * @return the integerProperty
+ */
+ public int getIntegerProperty() {
+ return integerProperty;
+ }
+
+ /**
+ * @param integerProperty the integerProperty to set
+ */
+ public void setIntegerProperty(int integerProperty) {
+ this.integerProperty = integerProperty;
+ }
+
+ /**
+ * @return the text
+ */
+ public String getText() {
+ return text;
+ }
+
+ /**
+ * @param text the text to set
+ */
+ public void setText(String text) {
+ this.text = text;
+ }
+
+ /**
+ * @return the foo
+ */
+ public Object getFoo() {
+ return foo;
+ }
+
+ /**
+ * @param foo the foo to set
+ */
+ public void setFoo(Object foo) {
+ this.foo = foo;
+ }
+
+}
Property changes on:
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/UnValidableBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/ValidableBean.java
===================================================================
---
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/ValidableBean.java
(rev 0)
+++
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/ValidableBean.java 2008-07-04
00:34:36 UTC (rev 9416)
@@ -0,0 +1,71 @@
+/**
+ *
+ */
+package org.richfaces.validator;
+
+import org.hibernate.validator.Length;
+import org.hibernate.validator.Max;
+import org.hibernate.validator.Min;
+import org.hibernate.validator.NotNull;
+
+/**
+ * @author asmirnov
+ *
+ */
+public class ValidableBean {
+
+ @Min(2)
+ @Max(5)
+ private int integerProperty;
+
+ private String text;
+
+ private Object foo;
+
+ /**
+ * @return the integerProperty
+ */
+ public int getIntegerProperty() {
+ return integerProperty;
+ }
+
+ /**
+ * @param integerProperty the integerProperty to set
+ */
+ @Min(2)
+ @Max(5)
+ public void setIntegerProperty(int integerProperty) {
+ this.integerProperty = integerProperty;
+ }
+
+ /**
+ * @return the text
+ */
+ public String getText() {
+ return text;
+ }
+
+ /**
+ * @param text the text to set
+ */
+ @Length(max=10,min=1,message="text size")
+ public void setText(String text) {
+ this.text = text;
+ }
+
+ /**
+ * @return the foo
+ */
+ public Object getFoo() {
+ return foo;
+ }
+
+ /**
+ * @param foo the foo to set
+ */
+ @NotNull
+ public void setFoo(Object foo) {
+ this.foo = foo;
+ }
+
+}
Property changes on:
trunk/sandbox/ui/beanValidator/src/test/java/org/richfaces/validator/ValidableBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain