Java Doc for PropertyAccessor.java in  » J2EE » spring-framework-2.0.6 » org » springframework » beans » 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 » J2EE » spring framework 2.0.6 » org.springframework.beans 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.springframework.beans.PropertyAccessor

PropertyAccessor
public interface PropertyAccessor (Code)
Common interface for classes that can access named properties (such as bean properties of an object or fields in an object) Serves as base interface for BeanWrapper .
author:
   Juergen Hoeller
since:
   1.1
See Also:   BeanWrapper


Field Summary
 StringNESTED_PROPERTY_SEPARATOR
     Path separator for nested properties.
 charNESTED_PROPERTY_SEPARATOR_CHAR
    
 StringPROPERTY_KEY_PREFIX
     Marker that indicates the start of a property key for an indexed or mapped property like "person.addresses[0]".
 charPROPERTY_KEY_PREFIX_CHAR
    
 StringPROPERTY_KEY_SUFFIX
     Marker that indicates the end of a property key for an indexed or mapped property like "person.addresses[0]".
 charPROPERTY_KEY_SUFFIX_CHAR
    


Method Summary
 ClassgetPropertyType(String propertyName)
     Determine the property type for the specified property, either checking the property descriptor or checking the value in case of an indexed or mapped element.
 ObjectgetPropertyValue(String propertyName)
     Get the current value of the specified property.
 booleanisReadableProperty(String propertyName)
     Determine whether the specified property is readable.
 booleanisWritableProperty(String propertyName)
     Determine whether the specified property is writable.
 voidsetPropertyValue(String propertyName, Object value)
     Set the specified value as current property value.
 voidsetPropertyValue(PropertyValue pv)
     Set the specified value as current property value.
 voidsetPropertyValues(Map map)
     Perform a batch update from a Map.

Bulk updates from PropertyValues are more powerful: This method is provided for convenience.

 voidsetPropertyValues(PropertyValues pvs)
     The preferred way to perform a batch update.

Note that performing a batch update differs from performing a single update, in that an implementation of this class will continue to update properties if a recoverable error (such as a type mismatch, but not an invalid field name or the like) is encountered, throwing a PropertyBatchUpdateException containing all the individual errors. This exception can be examined later to see all binding errors. Properties that were successfully updated remain changed.

Does not allow unknown fields or invalid fields.
Parameters:
  pvs - PropertyValues to set on the target object
throws:
  InvalidPropertyException - if there is no such property orif the property isn't writable
throws:
  PropertyBatchUpdateException - if one or more PropertyAccessExceptionsoccured for specific properties during the batch update.

 voidsetPropertyValues(PropertyValues pvs, boolean ignoreUnknown)
     Perform a batch update with more control over behavior.

Note that performing a batch update differs from performing a single update, in that an implementation of this class will continue to update properties if a recoverable error (such as a type mismatch, but not an invalid field name or the like) is encountered, throwing a PropertyBatchUpdateException containing all the individual errors. This exception can be examined later to see all binding errors. Properties that were successfully updated remain changed.
Parameters:
  pvs - PropertyValues to set on the target object
Parameters:
  ignoreUnknown - should we ignore unknown properties (not found in the bean)
throws:
  InvalidPropertyException - if there is no such property orif the property isn't writable
throws:
  PropertyBatchUpdateException - if one or more PropertyAccessExceptionsoccured for specific properties during the batch update.

 voidsetPropertyValues(PropertyValues pvs, boolean ignoreUnknown, boolean ignoreInvalid)
     Perform a batch update with full control over behavior.

Note that performing a batch update differs from performing a single update, in that an implementation of this class will continue to update properties if a recoverable error (such as a type mismatch, but not an invalid field name or the like) is encountered, throwing a PropertyBatchUpdateException containing all the individual errors. This exception can be examined later to see all binding errors. Properties that were successfully updated remain changed.
Parameters:
  pvs - PropertyValues to set on the target object
Parameters:
  ignoreUnknown - should we ignore unknown properties (not found in the bean)
Parameters:
  ignoreInvalid - should we ignore invalid properties (found but not accessible)
throws:
  InvalidPropertyException - if there is no such property orif the property isn't writable
throws:
  PropertyBatchUpdateException - if one or more PropertyAccessExceptionsoccured for specific properties during the batch update.


Field Detail
NESTED_PROPERTY_SEPARATOR
String NESTED_PROPERTY_SEPARATOR(Code)
Path separator for nested properties. Follows normal Java conventions: getFoo().getBar() would be "foo.bar".



NESTED_PROPERTY_SEPARATOR_CHAR
char NESTED_PROPERTY_SEPARATOR_CHAR(Code)



PROPERTY_KEY_PREFIX
String PROPERTY_KEY_PREFIX(Code)
Marker that indicates the start of a property key for an indexed or mapped property like "person.addresses[0]".



PROPERTY_KEY_PREFIX_CHAR
char PROPERTY_KEY_PREFIX_CHAR(Code)



PROPERTY_KEY_SUFFIX
String PROPERTY_KEY_SUFFIX(Code)
Marker that indicates the end of a property key for an indexed or mapped property like "person.addresses[0]".



PROPERTY_KEY_SUFFIX_CHAR
char PROPERTY_KEY_SUFFIX_CHAR(Code)





Method Detail
getPropertyType
Class getPropertyType(String propertyName) throws BeansException(Code)
Determine the property type for the specified property, either checking the property descriptor or checking the value in case of an indexed or mapped element.
Parameters:
  propertyName - the property to check(may be a nested path and/or an indexed/mapped property) the property type for the particular property,or null if not determinable
throws:
  InvalidPropertyException - if there is no such property orif the property isn't readable
throws:
  PropertyAccessException - if the property was valid but theaccessor method failed



getPropertyValue
Object getPropertyValue(String propertyName) throws BeansException(Code)
Get the current value of the specified property.
Parameters:
  propertyName - the name of the property to get the value of(may be a nested path and/or an indexed/mapped property) the value of the property
throws:
  InvalidPropertyException - if there is no such property orif the property isn't readable
throws:
  PropertyAccessException - if the property was valid but theaccessor method failed



isReadableProperty
boolean isReadableProperty(String propertyName)(Code)
Determine whether the specified property is readable.

Returns false if the property doesn't exist.
Parameters:
  propertyName - the property to check(may be a nested path and/or an indexed/mapped property) whether the property is readable




isWritableProperty
boolean isWritableProperty(String propertyName)(Code)
Determine whether the specified property is writable.

Returns false if the property doesn't exist.
Parameters:
  propertyName - the property to check(may be a nested path and/or an indexed/mapped property) whether the property is writable




setPropertyValue
void setPropertyValue(String propertyName, Object value) throws BeansException(Code)
Set the specified value as current property value.
Parameters:
  propertyName - the name of the property to set the value of(may be a nested path and/or an indexed/mapped property)
Parameters:
  value - the new value
throws:
  InvalidPropertyException - if there is no such property orif the property isn't writable
throws:
  PropertyAccessException - if the property was valid but theaccessor method failed or a type mismatch occured



setPropertyValue
void setPropertyValue(PropertyValue pv) throws BeansException(Code)
Set the specified value as current property value.
Parameters:
  pv - an object containing the new property value
throws:
  InvalidPropertyException - if there is no such property orif the property isn't writable
throws:
  PropertyAccessException - if the property was valid but theaccessor method failed or a type mismatch occured



setPropertyValues
void setPropertyValues(Map map) throws BeansException(Code)
Perform a batch update from a Map.

Bulk updates from PropertyValues are more powerful: This method is provided for convenience. Behavior will be identical to that of the PropertyAccessor.setPropertyValues(PropertyValues) method.
Parameters:
  map - Map to take properties from. Contains property value objects,keyed by property name
throws:
  InvalidPropertyException - if there is no such property orif the property isn't writable
throws:
  PropertyBatchUpdateException - if one or more PropertyAccessExceptionsoccured for specific properties during the batch update. This exception bundlesall individual PropertyAccessExceptions. All other properties will have beensuccessfully updated.




setPropertyValues
void setPropertyValues(PropertyValues pvs) throws BeansException(Code)
The preferred way to perform a batch update.

Note that performing a batch update differs from performing a single update, in that an implementation of this class will continue to update properties if a recoverable error (such as a type mismatch, but not an invalid field name or the like) is encountered, throwing a PropertyBatchUpdateException containing all the individual errors. This exception can be examined later to see all binding errors. Properties that were successfully updated remain changed.

Does not allow unknown fields or invalid fields.
Parameters:
  pvs - PropertyValues to set on the target object
throws:
  InvalidPropertyException - if there is no such property orif the property isn't writable
throws:
  PropertyBatchUpdateException - if one or more PropertyAccessExceptionsoccured for specific properties during the batch update. This exception bundlesall individual PropertyAccessExceptions. All other properties will have beensuccessfully updated.
See Also:   PropertyAccessor.setPropertyValues(PropertyValues,boolean,boolean)




setPropertyValues
void setPropertyValues(PropertyValues pvs, boolean ignoreUnknown) throws BeansException(Code)
Perform a batch update with more control over behavior.

Note that performing a batch update differs from performing a single update, in that an implementation of this class will continue to update properties if a recoverable error (such as a type mismatch, but not an invalid field name or the like) is encountered, throwing a PropertyBatchUpdateException containing all the individual errors. This exception can be examined later to see all binding errors. Properties that were successfully updated remain changed.
Parameters:
  pvs - PropertyValues to set on the target object
Parameters:
  ignoreUnknown - should we ignore unknown properties (not found in the bean)
throws:
  InvalidPropertyException - if there is no such property orif the property isn't writable
throws:
  PropertyBatchUpdateException - if one or more PropertyAccessExceptionsoccured for specific properties during the batch update. This exception bundlesall individual PropertyAccessExceptions. All other properties will have beensuccessfully updated.
See Also:   PropertyAccessor.setPropertyValues(PropertyValues,boolean,boolean)




setPropertyValues
void setPropertyValues(PropertyValues pvs, boolean ignoreUnknown, boolean ignoreInvalid) throws BeansException(Code)
Perform a batch update with full control over behavior.

Note that performing a batch update differs from performing a single update, in that an implementation of this class will continue to update properties if a recoverable error (such as a type mismatch, but not an invalid field name or the like) is encountered, throwing a PropertyBatchUpdateException containing all the individual errors. This exception can be examined later to see all binding errors. Properties that were successfully updated remain changed.
Parameters:
  pvs - PropertyValues to set on the target object
Parameters:
  ignoreUnknown - should we ignore unknown properties (not found in the bean)
Parameters:
  ignoreInvalid - should we ignore invalid properties (found but not accessible)
throws:
  InvalidPropertyException - if there is no such property orif the property isn't writable
throws:
  PropertyBatchUpdateException - if one or more PropertyAccessExceptionsoccured for specific properties during the batch update. This exception bundlesall individual PropertyAccessExceptions. All other properties will have beensuccessfully updated.




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