Java Doc for PropertyValidationSupport.java in  » Swing-Library » jgoodies-validation » com » jgoodies » validation » util » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Swing Library » jgoodies validation » com.jgoodies.validation.util 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.jgoodies.validation.util.PropertyValidationSupport

PropertyValidationSupport
final public class PropertyValidationSupport (Code)
A utility class that minimizes the effort to create instances of PropertyValidationMessage in validation code. You can use an instance of this class as a member field of your validator implementation and delegate the message creation to it.
author:
   Karsten Lentzsch
version:
   $Revision: 1.5 $
See Also:   com.jgoodies.validation.message.PropertyValidationMessage



Constructor Summary
public  PropertyValidationSupport(Object target, String role)
     Constructs a PropertyValidationSupport instance for the given validation target and its validation role.
public  PropertyValidationSupport(Severity defaultSeverity, Object target, String role)
     Constructs a PropertyValidationSupport instance for the given validation target and its validation role.
public  PropertyValidationSupport(ValidationResult defaultResult, Severity defaultSeverity, Object target, String role)
     Constructs a PropertyValidationSupport instance for the given default result, default severity, validation target and the given validation role.

Method Summary
public  voidadd(String property, String text)
     Adds a PropertyValidationMessage to this object's default ValidationResult.
public  voidadd(Severity severity, String property, String text)
     Adds a PropertyValidationMessage to this object's default ValidationResult.
public  voidadd(ValidationResult result, String property, String text)
     Adds a PropertyValidationMessage to the specified ValidationResult.
public  voidadd(ValidationResult result, Severity severity, String property, String text)
     Adds a PropertyValidationMessage to the specified ValidationResult.
public  voidaddError(String property, String text)
     Adds an error PropertyValidationMessage to this object's default ValidationResult.
public  voidaddError(ValidationResult result, String property, String text)
     Adds an error PropertyValidationMessage to the specified ValidationResult.
public  voidaddWarning(String property, String text)
     Adds a warning PropertyValidationMessage to this object's default ValidationResult.
public  voidaddWarning(ValidationResult result, String property, String text)
     Adds a warning PropertyValidationMessage to the specified ValidationResult.
public  voidclearResult()
     Sets an empty ValidationResult as default result.
public  PropertyValidationMessagecreate(String property, String text)
     Creates and returns a PropertyValidationMessage for the given property and message text using the default severity.
public  PropertyValidationMessagecreate(Severity severity, String property, String text)
     Creates and returns an error PropertyValidationMessage for the given property and message text using the specified severity.
public  PropertyValidationMessagecreateError(String property, String text)
     Creates and returns an error PropertyValidationMessage for the given property and message text.
public  PropertyValidationMessagecreateWarning(String property, String text)
     Creates and returns a warning PropertyValidationMessage for the given property and message text.
public  ValidationResultgetResult()
     Returns the default ValidationResult .


Constructor Detail
PropertyValidationSupport
public PropertyValidationSupport(Object target, String role)(Code)
Constructs a PropertyValidationSupport instance for the given validation target and its validation role. The default severity is set to Severity.WARNING.
Parameters:
  target - the object to be validated
Parameters:
  role - the validation target's role in the outer context
throws:
  NullPointerException - if the target or role is null



PropertyValidationSupport
public PropertyValidationSupport(Severity defaultSeverity, Object target, String role)(Code)
Constructs a PropertyValidationSupport instance for the given validation target and its validation role.
Parameters:
  defaultSeverity - the optional Severity used formessage creation when no severity is specified
Parameters:
  target - the object to be validated
Parameters:
  role - the validation target's role in the outer context
throws:
  NullPointerException - if the target or role is null
throws:
  IllegalArgumentException - if defaultSeverity is Severity.OK



PropertyValidationSupport
public PropertyValidationSupport(ValidationResult defaultResult, Severity defaultSeverity, Object target, String role)(Code)
Constructs a PropertyValidationSupport instance for the given default result, default severity, validation target and the given validation role.
Parameters:
  defaultResult - the optional ValidationResultthat is used to add ValidationMessages to
Parameters:
  defaultSeverity - the optional Severity used formessage creation when no severity is specified
Parameters:
  target - the object to be validated
Parameters:
  role - the validation target's role in the outer context
throws:
  NullPointerException - if the target or role is null
throws:
  IllegalArgumentException - if defaultSeverity is Severity.OK




Method Detail
add
public void add(String property, String text)(Code)
Adds a PropertyValidationMessage to this object's default ValidationResult. Uses the default severity and the given property and message text.
Parameters:
  property - describes the validated property
Parameters:
  text - the message text



add
public void add(Severity severity, String property, String text)(Code)
Adds a PropertyValidationMessage to this object's default ValidationResult. Uses the specified Severity and given property and message text.
Parameters:
  severity - the Severity to be used
Parameters:
  property - describes the validated property
Parameters:
  text - the message text



add
public void add(ValidationResult result, String property, String text)(Code)
Adds a PropertyValidationMessage to the specified ValidationResult. Uses this object's default severity and the given property and message text.
Parameters:
  result - the result the message will be added to
Parameters:
  property - describes the validated property
Parameters:
  text - the message text



add
public void add(ValidationResult result, Severity severity, String property, String text)(Code)
Adds a PropertyValidationMessage to the specified ValidationResult. Uses the specified severity and the given property and message text.
Parameters:
  result - the result the message will be added to
Parameters:
  severity - the severity used for the created message
Parameters:
  property - describes the validated property
Parameters:
  text - the message text
throws:
  IllegalArgumentException - if severity is Severity.OK



addError
public void addError(String property, String text)(Code)
Adds an error PropertyValidationMessage to this object's default ValidationResult. Uses the given property and message text.
Parameters:
  property - describes the validated property
Parameters:
  text - the message text



addError
public void addError(ValidationResult result, String property, String text)(Code)
Adds an error PropertyValidationMessage to the specified ValidationResult. Uses the given property and message text.
Parameters:
  result - the result the message will be added to
Parameters:
  property - describes the validated property
Parameters:
  text - the message text



addWarning
public void addWarning(String property, String text)(Code)
Adds a warning PropertyValidationMessage to this object's default ValidationResult. Uses the given property and message text.
Parameters:
  property - describes the validated property
Parameters:
  text - the message text



addWarning
public void addWarning(ValidationResult result, String property, String text)(Code)
Adds a warning PropertyValidationMessage to the specified ValidationResult. Uses the given property and message text.
Parameters:
  result - the result the message will be added to
Parameters:
  property - describes the validated property
Parameters:
  text - the message text



clearResult
public void clearResult()(Code)
Sets an empty ValidationResult as default result. Useful at the begin of a validation sequence.



create
public PropertyValidationMessage create(String property, String text)(Code)
Creates and returns a PropertyValidationMessage for the given property and message text using the default severity.
Parameters:
  property - describes the validated property
Parameters:
  text - the message text a PropertyValidationMessage with default severityfor the given property and text



create
public PropertyValidationMessage create(Severity severity, String property, String text)(Code)
Creates and returns an error PropertyValidationMessage for the given property and message text using the specified severity.
Parameters:
  severity - the Severity to be used
Parameters:
  property - describes the validated property
Parameters:
  text - the message text a PropertyValidationMessage with the specified severityfor the given property and text



createError
public PropertyValidationMessage createError(String property, String text)(Code)
Creates and returns an error PropertyValidationMessage for the given property and message text.
Parameters:
  property - describes the validated property
Parameters:
  text - the message text a PropertyValidationMessage with error severityfor the given property and text



createWarning
public PropertyValidationMessage createWarning(String property, String text)(Code)
Creates and returns a warning PropertyValidationMessage for the given property and message text.
Parameters:
  property - describes the validated property
Parameters:
  text - the message text a PropertyValidationMessage with warning severityfor the given property and text



getResult
public ValidationResult getResult()(Code)
Returns the default ValidationResult . the default validation result



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.