org.apache.commons.clazz.reflect.common
Class ReflectedPropertyParseResults

java.lang.Object
  extended by org.apache.commons.clazz.reflect.common.ReflectedPropertyParseResults
All Implemented Interfaces:
Comparable
Direct Known Subclasses:
ReflectedListPropertyParseResults, ReflectedMappedPropertyParseResults, ReflectedScalarPropertyParseResults

public abstract class ReflectedPropertyParseResults
extends Object
implements Comparable

Base class for Reflected*PropertyParseResults classes; aggregates parse results for individual accessor methods.

Version:
$Id: ReflectedPropertyParseResults.java 155436 2005-02-26 13:17:48Z dirkv $
Author:
Dmitri Plotnikov

Field Summary
protected  List extraneousAccessors
           
protected  AccessorMethodParseResults readMethodParseResults
           
protected  AccessorMethodParseResults writeMethodParseResults
           
 
Constructor Summary
ReflectedPropertyParseResults(ReflectedClazz clazz, String propertyName)
           
 
Method Summary
 void addAlias(String alias)
           
protected  void appendDescription(StringBuffer buffer)
           
protected  boolean appendInconsistencyDescriptions(StringBuffer buffer)
           
protected  void appendMethodDescriptions(StringBuffer buffer)
           
 boolean checkConsistency()
           
protected  void checkForExtraneousAccessor(AccessorMethodParseResults currentValue, AccessorMethodParseResults newValue)
          Checks if there is an existing parse result recorded and if so saves it into the extraneousAccessors for error reporting.
 int compareTo(Object object)
           
 String[] getAliases()
           
 ReflectedClazz getClazz()
           
protected abstract  String getPropertyCategory()
           
 String getPropertyName()
          Returns the propertyName.
 Class getPropertyType()
           
 Method getReadMethod()
           
 Method getWriteMethod()
           
 void merge(ReflectedPropertyParseResults other)
           
 void setReadMethodParseResults(AccessorMethodParseResults readMethodParseResults)
          Sets the readMethodParseResults.
 void setWriteMethodParseResults(AccessorMethodParseResults writeMethodParseResults)
          Sets the writeMethodParseResults.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

readMethodParseResults

protected AccessorMethodParseResults readMethodParseResults

writeMethodParseResults

protected AccessorMethodParseResults writeMethodParseResults

extraneousAccessors

protected List extraneousAccessors
Constructor Detail

ReflectedPropertyParseResults

public ReflectedPropertyParseResults(ReflectedClazz clazz,
                                     String propertyName)
Method Detail

getClazz

public ReflectedClazz getClazz()

getPropertyName

public String getPropertyName()
Returns the propertyName.

Returns:
String

compareTo

public int compareTo(Object object)
Specified by:
compareTo in interface Comparable

getAliases

public String[] getAliases()

addAlias

public void addAlias(String alias)

getPropertyCategory

protected abstract String getPropertyCategory()

merge

public void merge(ReflectedPropertyParseResults other)

getPropertyType

public Class getPropertyType()

getReadMethod

public Method getReadMethod()

getWriteMethod

public Method getWriteMethod()

setReadMethodParseResults

public void setReadMethodParseResults(AccessorMethodParseResults readMethodParseResults)
Sets the readMethodParseResults.

Parameters:
readMethodParseResults - The readMethodParseResults to set

setWriteMethodParseResults

public void setWriteMethodParseResults(AccessorMethodParseResults writeMethodParseResults)
Sets the writeMethodParseResults.

Parameters:
writeMethodParseResults - The writeMethodParseResults to set

checkForExtraneousAccessor

protected void checkForExtraneousAccessor(AccessorMethodParseResults currentValue,
                                          AccessorMethodParseResults newValue)
Checks if there is an existing parse result recorded and if so saves it into the extraneousAccessors for error reporting.


checkConsistency

public boolean checkConsistency()

toString

public String toString()
Overrides:
toString in class Object

appendDescription

protected void appendDescription(StringBuffer buffer)

appendMethodDescriptions

protected void appendMethodDescriptions(StringBuffer buffer)

appendInconsistencyDescriptions

protected boolean appendInconsistencyDescriptions(StringBuffer buffer)


Copyright © 2001-2010 The Apache Software Foundation. All Rights Reserved.