You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by Steve Hill <sh...@futurelogix.co.uk> on 2022/04/19 21:30:30 UTC
Mybatis Generator upgrade to 1.4.1
Hi All:
We are attempting to migrate to the mybatis generator 1.4.1. In doing
we are having to rewrite a number of plugin's as things are somewhat
different now; however we have stumbled into a problem and can't find
the answer. Wondering if someone knows?
We have overridden
public boolean clientGenerated(Interface interfaze,
IntrospectedTable introspectedTable) {
And have the following code in it so that in the mapper interface it
will have references to the new XML sql blocks we have added to the
generated XML mappers.
Method newMethod = new Method(LOGICAL_DELETE_METHOD_NAME);
context.getCommentGenerator().addGeneralMethodComment(newMethod,
introspectedTable);
FullyQualifiedJavaType recordParam = new
FullyQualifiedJavaType(introspectedTable.getBaseRecordType());
newMethod.addParameter(new Parameter(recordParam, "record"));
newMethod.setReturnType(new FullyQualifiedJavaType("int"));
interfaze.addMethod(newMethod);
In the prior version of the generator we ended up with the following
int logicalDelete(User record);
But now it is added the following to the interface which doe not compile
as it is an interface.
int logicalDelete(User record) {
}
Any help would be appreciated.
Thanks!
Steve.
Re: Mybatis Generator upgrade to 1.4.1
Posted by "Tetreault, Lucas" <te...@amazon.com.INVALID>.
Steve,
Was this meant for the ActiveMQ mailing list?
- Lucas
On 2022-04-19, 3:12 PM, "Steve Hill" <sh...@futurelogix.co.uk> wrote:
CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you can confirm the sender and know the content is safe.
Hi All:
We are attempting to migrate to the mybatis generator 1.4.1. In doing
we are having to rewrite a number of plugin's as things are somewhat
different now; however we have stumbled into a problem and can't find
the answer. Wondering if someone knows?
We have overridden
public boolean clientGenerated(Interface interfaze,
IntrospectedTable introspectedTable) {
And have the following code in it so that in the mapper interface it
will have references to the new XML sql blocks we have added to the
generated XML mappers.
Method newMethod = new Method(LOGICAL_DELETE_METHOD_NAME);
context.getCommentGenerator().addGeneralMethodComment(newMethod,
introspectedTable);
FullyQualifiedJavaType recordParam = new
FullyQualifiedJavaType(introspectedTable.getBaseRecordType());
newMethod.addParameter(new Parameter(recordParam, "record"));
newMethod.setReturnType(new FullyQualifiedJavaType("int"));
interfaze.addMethod(newMethod);
In the prior version of the generator we ended up with the following
int logicalDelete(User record);
But now it is added the following to the interface which doe not compile
as it is an interface.
int logicalDelete(User record) {
}
Any help would be appreciated.
Thanks!
Steve.