Java Code Examples for org.mybatis.generator.internal.rules.Rules#generateSelectByExampleWithoutBLOBs()

The following examples show how to use org.mybatis.generator.internal.rules.Rules#generateSelectByExampleWithoutBLOBs() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ExtendedDAOMethodNameCalculator.java    From mybatis-generator-core-fix with Apache License 2.0 6 votes vote down vote up
/**
 * 1. if this will be the only selectByExample, then the result should be
 * selectByExample. 2. Else the method name should be
 * selectByExampleWithBLOBs
 */
public String getSelectByExampleWithBLOBsMethodName(
        IntrospectedTable introspectedTable) {
    StringBuilder sb = new StringBuilder();
    sb.append("select"); //$NON-NLS-1$
    sb.append(introspectedTable.getFullyQualifiedTable()
            .getDomainObjectName());
    sb.append("ByExample"); //$NON-NLS-1$

    Rules rules = introspectedTable.getRules();

    if (rules.generateSelectByExampleWithoutBLOBs()) {
        sb.append("WithBLOBs"); //$NON-NLS-1$
    }

    return sb.toString();
}
 
Example 2
Source File: ExtendedDAOMethodNameCalculator.java    From mybatis-generator-plus with Apache License 2.0 6 votes vote down vote up
/**
 * 1. if this will be the only selectByExample, then the result should be
 * selectByExample. 2. Else the method name should be
 * selectByExampleWithBLOBs
 */
public String getSelectByExampleWithBLOBsMethodName(
        IntrospectedTable introspectedTable) {
    StringBuilder sb = new StringBuilder();
    sb.append("select"); //$NON-NLS-1$
    sb.append(introspectedTable.getFullyQualifiedTable()
            .getDomainObjectName());
    sb.append("ByExample"); //$NON-NLS-1$

    Rules rules = introspectedTable.getRules();

    if (rules.generateSelectByExampleWithoutBLOBs()) {
        sb.append("WithBLOBs"); //$NON-NLS-1$
    }

    return sb.toString();
}
 
Example 3
Source File: DefaultDAOMethodNameCalculator.java    From mybatis-generator-core-fix with Apache License 2.0 5 votes vote down vote up
/**
 * 1. if this will be the only selectByExample, then the result should be
 * selectByExample. 2. Else the method name should be
 * selectByExampleWithBLOBs
 */
public String getSelectByExampleWithBLOBsMethodName(
        IntrospectedTable introspectedTable) {
    Rules rules = introspectedTable.getRules();

    if (!rules.generateSelectByExampleWithoutBLOBs()) {
        return "selectByExample"; //$NON-NLS-1$
    } else {
        return "selectByExampleWithBLOBs"; //$NON-NLS-1$
    }
}
 
Example 4
Source File: DefaultDAOMethodNameCalculator.java    From mybatis-generator-plus with Apache License 2.0 5 votes vote down vote up
/**
 * 1. if this will be the only selectByExample, then the result should be
 * selectByExample. 2. Else the method name should be
 * selectByExampleWithBLOBs
 */
public String getSelectByExampleWithBLOBsMethodName(
        IntrospectedTable introspectedTable) {
    Rules rules = introspectedTable.getRules();

    if (!rules.generateSelectByExampleWithoutBLOBs()) {
        return "selectByExample"; //$NON-NLS-1$
    } else {
        return "selectByExampleWithBLOBs"; //$NON-NLS-1$
    }
}