| java.lang.Object org.apache.beehive.controls.system.jdbc.parser.SqlFragment org.apache.beehive.controls.system.jdbc.parser.ReflectionFragment
ReflectionFragment | final public class ReflectionFragment extends SqlFragment (Code) | | Represents a method parameter substitution into the SQL annotation's statement member. Delimited by '{' and '}'.
Method parameter names must exactly match the name used in the SQL statement in order for the substitution to occur.
SQL(statement="SELECT * FROM {tableName}")
public void getAll(String tableName) throws SQLException;
|
Constructor Summary | |
protected | ReflectionFragment(String parameterName) Create a new ReflectionFragment with the specifed method parameter name. | protected | ReflectionFragment(String parameterName, String sqlDataType) Create a new ReflectionFragment with the specified method parameter name and SQL type. |
ReflectionFragment | protected ReflectionFragment(String parameterName)(Code) | | Create a new ReflectionFragment with the specifed method parameter name.
Parameters: parameterName - The name of the parameter whose value should be substituted at this location. |
ReflectionFragment | protected ReflectionFragment(String parameterName, String sqlDataType)(Code) | | Create a new ReflectionFragment with the specified method parameter name and SQL type.
Parameters: parameterName - The name of the parameter whose value should be substituted at this location. Parameters: sqlDataType - A String specifing the SQL data type for this parameter. |
getParamSqlDataType | protected int getParamSqlDataType()(Code) | | Get the SQL data type of this param.
The SQL data type for this param. |
getParameterName | protected String getParameterName()(Code) | | Get the parameter name (as specified in the SQL statement).
The parameter name. |
getParameterNameQualifiers | protected String[] getParameterNameQualifiers()(Code) | | Get a copy of the array of parameter name qualifiers.
An array of parameter name qualifiers. |
getParameterValues | protected Object[] getParameterValues(ControlBeanContext context, Method method, Object[] args)(Code) | | Get the value of this parameter.
Parameters: context - ControlBeanContext instance to evaluate the parameter's value against. Parameters: method - Method instance to evaluate against. Parameters: args - Method argument values All parameter object values contained within this fragment |
getPreparedStatementText | protected String getPreparedStatementText(ControlBeanContext context, Method m, Object[] args)(Code) | | Return text generated by this fragment for a PreparedStatement
Parameters: context - A ControlBeanContext instance. Parameters: m - The annotated method. Parameters: args - The method's parameters Always returns a PREPARED_STATEMENT_SUB_MARK |
hasComplexValue | protected boolean hasComplexValue(ControlBeanContext context, Method m, Object[] args)(Code) | | A reflection fragment may evaluate to an JdbcControl.ComplexSqlFragment type,
which requires additional steps to evaluate after reflection.
Parameters: context - Control bean context. Parameters: m - Method. Parameters: args - Method args. true or false. |
hasParamValue | protected boolean hasParamValue()(Code) | | Always true for ReflectionFragment.
true |
toString | public String toString()(Code) | | For JUnit testing.
The String value of this fragment. |
|
|