java.lang.Object | |
↳ | org.mybatis.generator.api.IntrospectedTable |
![]() |
![]() |
Base class for all code generator implementations. This class provides many of the housekeeping methods needed to implement a code generator, with only the actual code generation methods left unimplemented.
Nested Classes | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
IntrospectedTable.InternalAttribute | |||||||||||
IntrospectedTable.TargetRuntime |
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
attributes | Attributes may be used by plugins to capture table related state between the different plugin calls. | ||||||||||
baseColumns | |||||||||||
blobColumns | |||||||||||
context | |||||||||||
fullyQualifiedTable | |||||||||||
internalAttributes | Internal attributes are used to store commonly accessed items by all code generators | ||||||||||
primaryKeyColumns | |||||||||||
rules | |||||||||||
tableConfiguration | |||||||||||
targetRuntime |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Attributes may be used by plugins to capture table related state between the different plugin calls.
Internal attributes are used to store commonly accessed items by all code generators
This method can be used to initialize the generators before they will be called. This method is called after all the setX methods, but before getNumberOfSubtasks(), getGeneratedJavaFiles, and getGeneratedXmlFiles.
Returns all columns in the table (for use by the select by primary key and select by example with BLOBs methods)
This method should return a list of generated Java files related to this table. This list could include various types of model classes, as well as DAO classes.
This method should return a list of generated XML files related to this table. Most implementations will only return one file - the generated SqlMap file.
This method should return the number of progress messages that will be send during the generation phase.
Calculates an SQL Map file name for the table. Typically the name is "XXXX_SqlMap.xml" where XXXX is the fully qualified table name (delimited with underscores).
Calculates the package for the current table.
Returns all columns except BLOBs (for use by the select by example without BLOBs method)
Returns the columns in the primary key. If the generatePrimaryKeyClass() method returns false, then these columns will be iterated as the parameters of the selectByPrimaryKay and deleteByPrimaryKey methods
Returns true if any of the columns in the table are JDBC Dates (as opposed to timestamps).
Returns true if any of the columns in the table are JDBC Times (as opposed to timestamps).
Denotes whether generated code is targeted for Java version 5.0 or higher.
Should return true if an XML generator is required for this table. This method will be called during validation of the configuration, so it should not rely on database introspection. This method simply tells the validator if an XML configuration is normally required for this implementation.
This method exists to give plugins the opportunity to replace the calculated rules if necessary.