Methods Summary |
---|
private int | getParamNumber(java.lang.String ejbqlParamDecl)Internal method to extract the number from a parameter application
in EJBQL.
int paramNum = 0;
try {
paramNum = Integer.parseInt(ejbqlParamDecl.substring(1));
} catch(Exception ex) {
ErrorMsg.error(I18NHelper.getMessage(
msgs, "EXC_InvalidParameterIndex", //NOI18N
ejbqlParamDecl, String.valueOf(parameterTypes.length)));
}
if (paramNum < 1 || paramNum > parameterTypes.length) {
ErrorMsg.error(I18NHelper.getMessage(
msgs, "EXC_InvalidParameterIndex", //NOI18N
ejbqlParamDecl, String.valueOf(parameterTypes.length)));
}
return paramNum;
|
public int | getParameterCount()Returns the number of parameters.
return parameterTypes.length;
|
public java.lang.String | getParameterEjbName(java.lang.String ejbqlParamDecl)Get EJB name corresponding to the EJBQL parameter by input
parameter declaration string.
return getParameterEjbName(getParamNumber(ejbqlParamDecl));
|
public java.lang.String | getParameterEjbName(int paramNumber)Get EJB name corresponding to the EJBQL parameter number.
return parameterEjbNames[paramNumber - 1];
|
public java.lang.String[] | getParameterEjbNames()Get all EJB names corresponding to the EJBQL parameters.
return parameterEjbNames;
|
public java.lang.String | getParameterName(java.lang.String ejbqlParamDecl)Returns the name of the corresponding JDO parameter.
The specified string denotes a parameter application in EJBQL.
It has the form "?" where is the parameter number
starting with 1.
return getParameterName(getParamNumber(ejbqlParamDecl));
|
public java.lang.String | getParameterName(int paramNumber)Returns the name of the corresponding JDO parameter by parameter number.
return "_jdoParam" + String.valueOf(paramNumber);
|
public java.lang.Class | getParameterType(java.lang.String ejbqlParamDecl)Returns type of the EJBQL parameter by input parameter declaration
string. The specified string denotes a parameter application in EJBQL.
It has the form "?" where is the parameter number
starting with 1.
return getParameterType(getParamNumber(ejbqlParamDecl));
|
public java.lang.Class | getParameterType(int paramNumber)Returns the type of the EJBQL parameter by number.
Note, the numbering of EJBQL parameters starts with 1,
so the method expects 1 as the number of the first parameter.
// InputParams are numbered starting at 1, so adjust for
// array indexing.
return parameterTypes[paramNumber - 1];
|
public void | setParameterEjbName(java.lang.String ejbqlParamDecl, java.lang.String ejbName)Set EJB name corresponding to the EJBQL parameter by input
parameter declaration string.
parameterEjbNames[getParamNumber(ejbqlParamDecl) - 1] = ejbName;
|