Package net.paoding.rose.jade.annotation

Examples of net.paoding.rose.jade.annotation.SQLType


    private SQLType sqlType;

    public SQLType getSQLType() {
        if (sqlType == null) {
            SQL sql = method.getAnnotation(SQL.class);
            SQLType sqlType = sql.type();
            if (sqlType == SQLType.AUTO_DETECT) {
                for (int i = 0; i < SELECT_PATTERNS.length; i++) {
                    // 用正则表达式匹配  SELECT 语句
                    if (SELECT_PATTERNS[i].matcher(getSQL()).find()) {
                        sqlType = SQLType.READ;
View Full Code Here


        if (statement == null) {
            synchronized (method) {
                statement = statements.get(method);
                if (statement == null) {
                    StatementMetaData smd = new StatementMetaData(daoMetaData, method);
                    SQLType sqlType = smd.getSQLType();
                    Querier querier;
                    if (sqlType == SQLType.READ) {
                        RowMapper rowMapper = rowMapperFactory.getRowMapper(smd);
                        querier = new SelectQuerier(dataAccessFactory, smd, rowMapper);
                    } else {
View Full Code Here

        if (statement == null) {
            synchronized (method) {
                statement = statements.get(method);
                if (statement == null) {
                    StatementMetaData smd = new StatementMetaData(daoMetaData, method);
                    SQLType sqlType = smd.getSQLType();
                    Querier querier;
                    if (sqlType == SQLType.READ) {
                        RowMapper<?> rowMapper = rowMapperFactory.getRowMapper(smd);
                        querier = new SelectQuerier(dataAccessFactory, smd, rowMapper);
                    } else {
View Full Code Here

    private SQLType sqlType;

    public SQLType getSQLType() {
        if (sqlType == null) {
            SQL sql = method.getAnnotation(SQL.class);
            SQLType sqlType = sql.type();
            if (sqlType == SQLType.AUTO_DETECT) {
                for (int i = 0; i < SELECT_PATTERNS.length; i++) {
                    // 用正则表达式匹配  SELECT 语句
                    if (SELECT_PATTERNS[i].matcher(getSQL()).find()) {
                        sqlType = SQLType.READ;
View Full Code Here

     */
    public CachedStatement(CacheProvider cacheProvider, Statement realStatement) {
        this.realStatement = realStatement;
        this.cacheProvider = cacheProvider;
        StatementMetaData metaData = realStatement.getMetaData();
        SQLType sqlType = metaData.getSQLType();
        cacheDeleteAnnotation = metaData.getMethod().getAnnotation(CacheDelete.class);
        Cache cacheAnnotation = metaData.getMethod().getAnnotation(Cache.class);
        if (sqlType == SQLType.READ) {
            this.cacheAnnotation = cacheAnnotation;
        } else {
View Full Code Here

TOP

Related Classes of net.paoding.rose.jade.annotation.SQLType

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.