|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.ibatis.ibator.generator.ibatis2.dao.templates.AbstractDAOTemplate
public abstract class AbstractDAOTemplate
Base class for DAO templates. Subclasses should override any of the configureXXX methods to specify the unique properties of the desired DAO objects.
Constructor Summary | |
---|---|
AbstractDAOTemplate()
|
Method Summary | |
---|---|
protected void |
addCheckedException(FullyQualifiedJavaType type)
|
protected void |
addField(Field field)
|
protected void |
addImplementationImport(FullyQualifiedJavaType type)
|
protected void |
addInterfaceImport(FullyQualifiedJavaType type)
|
protected void |
addMethod(Method method)
|
protected void |
configureCheckedExceptions()
Override this method to add checked exceptions to the throws clause of any generated DAO method. |
protected abstract void |
configureConstructorTemplate()
Override this method to configure a constructor for generated DAO implementation classes. |
protected abstract void |
configureDeleteMethodTemplate()
Override this method to configure a delete method template. |
protected void |
configureFields()
Override this method to add fields to any generated DAO implementation class. |
protected void |
configureImplementationImports()
Override this method to add imports to generated DAO implementation classes. |
protected abstract void |
configureInsertMethodTemplate()
Override this method to configure an insert method template. |
protected void |
configureInterfaceImports()
Override this method to add imports to generated DAO interface classes. |
protected void |
configureMethods()
Override this method to add methods to generated DAO implementation classes. |
protected abstract void |
configureQueryForListMethodTemplate()
Override this method to configure a queryForList method template. |
protected abstract void |
configureQueryForObjectMethodTemplate()
Override this method to configure a queryForObject method template. |
protected void |
configureSuperClass()
Override this method to set the superclass for any generated DAO implementation class. |
protected abstract void |
configureUpdateMethodTemplate()
Override this method to configure an update method template. |
java.util.List<FullyQualifiedJavaType> |
getCheckedExceptions()
|
Method |
getConstructorClone(CommentGenerator commentGenerator,
FullyQualifiedJavaType type,
FullyQualifiedTable table)
|
java.lang.String |
getDeleteMethod(java.lang.String sqlMapNamespace,
java.lang.String statementId,
java.lang.String parameter)
|
java.util.List<Field> |
getFieldClones(CommentGenerator commentGenerator,
FullyQualifiedTable table)
|
java.util.List<FullyQualifiedJavaType> |
getImplementationImports()
|
java.lang.String |
getInsertMethod(java.lang.String sqlMapNamespace,
java.lang.String statementId,
java.lang.String parameter)
|
java.util.List<FullyQualifiedJavaType> |
getInterfaceImports()
|
java.util.List<Method> |
getMethodClones(CommentGenerator commentGenerator,
FullyQualifiedTable table)
|
java.lang.String |
getQueryForListMethod(java.lang.String sqlMapNamespace,
java.lang.String statementId,
java.lang.String parameter)
|
java.lang.String |
getQueryForObjectMethod(java.lang.String sqlMapNamespace,
java.lang.String statementId,
java.lang.String parameter)
|
FullyQualifiedJavaType |
getSuperClass()
|
java.lang.String |
getUpdateMethod(java.lang.String sqlMapNamespace,
java.lang.String statementId,
java.lang.String parameter)
|
protected void |
setConstructorTemplate(Method constructorTemplate)
|
protected void |
setDeleteMethodTemplate(java.lang.String deleteMethodTemplate)
|
protected void |
setInsertMethodTemplate(java.lang.String insertMethodTemplate)
|
protected void |
setQueryForListMethodTemplate(java.lang.String queryForListMethodTemplate)
|
protected void |
setQueryForObjectMethodTemplate(java.lang.String queryForObjectMethodTemplate)
|
protected void |
setSuperClass(FullyQualifiedJavaType superClass)
|
protected void |
setUpdateMethodTemplate(java.lang.String updateMethodTemplate)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AbstractDAOTemplate()
Method Detail |
---|
public final Method getConstructorClone(CommentGenerator commentGenerator, FullyQualifiedJavaType type, FullyQualifiedTable table)
public final java.lang.String getDeleteMethod(java.lang.String sqlMapNamespace, java.lang.String statementId, java.lang.String parameter)
public final java.util.List<FullyQualifiedJavaType> getInterfaceImports()
public final java.util.List<FullyQualifiedJavaType> getImplementationImports()
public final java.lang.String getInsertMethod(java.lang.String sqlMapNamespace, java.lang.String statementId, java.lang.String parameter)
public final java.lang.String getQueryForListMethod(java.lang.String sqlMapNamespace, java.lang.String statementId, java.lang.String parameter)
public final java.lang.String getQueryForObjectMethod(java.lang.String sqlMapNamespace, java.lang.String statementId, java.lang.String parameter)
public final FullyQualifiedJavaType getSuperClass()
public final java.lang.String getUpdateMethod(java.lang.String sqlMapNamespace, java.lang.String statementId, java.lang.String parameter)
public final java.util.List<FullyQualifiedJavaType> getCheckedExceptions()
public final java.util.List<Field> getFieldClones(CommentGenerator commentGenerator, FullyQualifiedTable table)
public final java.util.List<Method> getMethodClones(CommentGenerator commentGenerator, FullyQualifiedTable table)
protected void setConstructorTemplate(Method constructorTemplate)
protected void setDeleteMethodTemplate(java.lang.String deleteMethodTemplate)
protected void addField(Field field)
protected void setInsertMethodTemplate(java.lang.String insertMethodTemplate)
protected void addMethod(Method method)
protected void setQueryForListMethodTemplate(java.lang.String queryForListMethodTemplate)
protected void setQueryForObjectMethodTemplate(java.lang.String queryForObjectMethodTemplate)
protected void setSuperClass(FullyQualifiedJavaType superClass)
protected void setUpdateMethodTemplate(java.lang.String updateMethodTemplate)
protected void addInterfaceImport(FullyQualifiedJavaType type)
protected void addImplementationImport(FullyQualifiedJavaType type)
protected void addCheckedException(FullyQualifiedJavaType type)
protected void configureCheckedExceptions()
addCheckedException(FullyQualifiedJavaType)
one or more times to add checked exception(s) to all generated
DAO methods.
protected void configureFields()
addField(Field)
one
or more times to add field(s) to the generated
DAO implementation class.
protected void configureImplementationImports()
addImplementationImport(FullyQualifiedJavaType)
one
or more times to add import(s) to generated
DAO implementation classes.
protected void configureInterfaceImports()
addInterfaceImport(FullyQualifiedJavaType)
one
or more times to add import(s) to generated
DAO interface classes.
protected void configureMethods()
addMethod(Method)
one
or more times to add method(s) to generated
DAO implementation classes.
protected void configureSuperClass()
setSuperClass(FullyQualifiedJavaType)
to set the superclass for generated DAO implementation classes.
protected abstract void configureConstructorTemplate()
setConstructorTemplate(Method)
to
set the constructor template.
protected abstract void configureInsertMethodTemplate()
setInsertMethodTemplate(String)
protected abstract void configureQueryForListMethodTemplate()
setQueryForListMethodTemplate(String)
protected abstract void configureQueryForObjectMethodTemplate()
setQueryForObjectMethodTemplate(String)
protected abstract void configureUpdateMethodTemplate()
setUpdateMethodTemplate(String)
protected abstract void configureDeleteMethodTemplate()
setDeleteMethodTemplate(String)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |