Author: peteroyle
Date: 2010-02-17 06:50:26 -0500 (Wed, 17 Feb 2010)
New Revision: 5860
Modified:
examples/trunk/se/hello-world/src/main/java/org/jboss/weld/environment/se/example/simple/HelloWorld.java
Log:
WELDX-76: Uses error message from validator instead of reproducing one.
Modified:
examples/trunk/se/hello-world/src/main/java/org/jboss/weld/environment/se/example/simple/HelloWorld.java
===================================================================
---
examples/trunk/se/hello-world/src/main/java/org/jboss/weld/environment/se/example/simple/HelloWorld.java 2010-02-17
11:41:28 UTC (rev 5859)
+++
examples/trunk/se/hello-world/src/main/java/org/jboss/weld/environment/se/example/simple/HelloWorld.java 2010-02-17
11:50:26 UTC (rev 5860)
@@ -46,7 +46,9 @@
System.out.println( "Hello " +
argsValidator.getValidParameters().get( 0 ) );
} else
{
- System.out.println( "Please provide just one argument: your first
name" );
+ for (String error : argsValidator.getErrors()) {
+ System.out.println( error );
+ }
}
}
Show replies by date