亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? sqlmapdaotemplate.java

?? 本套系統(tǒng)采用了業(yè)界當前最為流行的beanAction組件
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
/*
 *  Copyright 2004 Clinton Begin
 *
 *  Licensed under the Apache License, Version 2.0 (the "License");
 *  you may not use this file except in compliance with the License.
 *  You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 *  Unless required by applicable law or agreed to in writing, software
 *  distributed under the License is distributed on an "AS IS" BASIS,
 *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *  See the License for the specific language governing permissions and
 *  limitations under the License.
 */
package com.ibatis.dao.client.template;

import com.ibatis.common.util.PaginatedList;
import com.ibatis.dao.client.DaoException;
import com.ibatis.dao.client.DaoManager;
import com.ibatis.dao.engine.transaction.sqlmap.SqlMapDaoTransaction;
import com.ibatis.sqlmap.client.SqlMapExecutor;
import com.ibatis.sqlmap.client.SqlMapTransactionManager;
import com.ibatis.sqlmap.client.event.RowHandler;
import com.ibatis.sqlmap.engine.execution.BatchException;

import java.sql.SQLException;
import java.util.List;
import java.util.Map;

/**
 * A DaoTemplate for SQL Map implementations that provides a
 * convenient method to access the SqlMapExecutor.  This class
 * also provides SqlMapExecutor method wrappers that conveniently
 * wrap SQLExceptions with DAO Exceptions.
 *
 * @author Zach Scott
 */
public abstract class SqlMapDaoTemplate extends DaoTemplate implements SqlMapExecutor {

  /**
   * The DaoManager that manages this Dao instance will be passed
   * in as the parameter to this constructor automatically upon
   * instantiation.
   *
   * @param daoManager
   */
  public SqlMapDaoTemplate(DaoManager daoManager) {
    super(daoManager);
  }

  /**
   * Gets the SQL Map Executor associated with the current
   * DaoTransaction that this Dao is working under.  The SqlMapExecutor
   * interface declares a number of methods for executing statements
   * via an SqlMapClient instance.
   *
   * @return A SqlMapExecutor instance.
   */
  protected SqlMapExecutor getSqlMapExecutor() {
    SqlMapDaoTransaction trans = (SqlMapDaoTransaction) daoManager.getTransaction(this);
    return trans.getSqlMap();
  }

  /**
   * Gets the SQL Map Transaction Manager associated with the current
   * DaoTransaction that this Dao is working under.  The SqlMapExecutor
   * interface declares a number of methods for executing statements
   * via an SqlMapClient instance.
   * <p/>
   * NOTE: It is rare to require this in a DAO.  Only very special
   * cases of DAO implementations will require access to the
   * SqlMapTransactionManager.  Messing with transactions at this
   * level might be dangerous to your data integrity (e.g. committing
   * too early).
   *
   * @return A SqlMapTransactionManager instance.
   */
  protected SqlMapTransactionManager getSqlMapTransactionManager() {
    SqlMapDaoTransaction trans = (SqlMapDaoTransaction) daoManager.getTransaction(this);
    return trans.getSqlMap();
  }

  /**
   * Executes a mapped SQL INSERT statement.
   * Insert is a bit different from other update methods, as it
   * provides facilities for returning the primary key of the
   * newly inserted row (rather than the effected rows).  This
   * functionality is of course optional.
   * <p/>
   * The parameter object is generally used to supply the input
   * data for the INSERT values.
   *
   * @param id              The name of the statement to execute.
   * @param parameterObject The parameter object (e.g. JavaBean, Map, XML etc.).
   * @return The primary key of the newly inserted row.  This might be automatically
   *         generated by the RDBMS, or selected from a sequence table or other source.
   */
  public Object insert(String id, Object parameterObject) {
    try {
      return getSqlMapExecutor().insert(id, parameterObject);
    } catch (SQLException e) {
      throw new DaoException("Failed to insert - id ["
          + id + "], parameterObject [" + parameterObject + "]. Cause: " + e, e);
    }
  }

  /**
   * Executes a mapped SQL INSERT statement.
   * Insert is a bit different from other update methods, as it
   * provides facilities for returning the primary key of the
   * newly inserted row (rather than the effected rows).  This
   * functionality is of course optional.
   * <p/>
   * This overload assumes no parameter is needed.
   *
   * @param id              The name of the statement to execute.
   * @return The primary key of the newly inserted row.  This might be automatically
   *         generated by the RDBMS, or selected from a sequence table or other source.
   */
  public Object insert(String id) {
    try {
      return getSqlMapExecutor().insert(id);
    } catch (SQLException e) {
      throw new DaoException("Failed to insert - id ["
          + id + "]. Cause: " + e, e);
    }
  }
  
  /**
   * Executes a mapped SQL UPDATE statement.
   * Update can also be used for any other update statement type,
   * such as inserts and deletes.  Update returns the number of
   * rows effected.
   * <p/>
   * The parameter object is generally used to supply the input
   * data for the UPDATE values as well as the WHERE clause parameter(s).
   *
   * @param id              The name of the statement to execute.
   * @param parameterObject The parameter object (e.g. JavaBean, Map, XML etc.).
   * @return The number of rows effected.
   */
  public int update(String id, Object parameterObject) {
    try {
      return getSqlMapExecutor().update(id, parameterObject);
    } catch (SQLException e) {
      throw new DaoException("Failed to update - id ["
          + id + "] - parameterObject [" + parameterObject + "].  Cause: " + e, e);
    }
  }

  /**
   * Executes a mapped SQL UPDATE statement.
   * Update can also be used for any other update statement type,
   * such as inserts and deletes.  Update returns the number of
   * rows effected.
   * <p/>
   * This overload assumes no parameter is needed.
   *
   * @param id              The name of the statement to execute.
   * @return The number of rows effected.
   */
  public int update(String id) {
    try {
      return getSqlMapExecutor().update(id);
    } catch (SQLException e) {
      throw new DaoException("Failed to update - id ["
          + id + "].  Cause: " + e, e);
    }
  }

  /**
   * Executes a mapped SQL DELETE statement.
   * Delete returns the number of rows effected.
   * <p/>
   * The parameter object is generally used to supply the input
   * data for the WHERE clause parameter(s) of the DELETE statement.
   *
   * @param id              The name of the statement to execute.
   * @param parameterObject The parameter object (e.g. JavaBean, Map, XML etc.).
   * @return The number of rows effected.
   */
  public int delete(String id, Object parameterObject) {
    try {
      return getSqlMapExecutor().delete(id, parameterObject);
    } catch (SQLException e) {
      throw new DaoException("Failed to delete - id ["
          + id + "] - parameterObject [" + parameterObject + "].  Cause: " + e, e);
    }
  }

  /**
   * Executes a mapped SQL DELETE statement.
   * Delete returns the number of rows effected.
   * <p/>
   * This overload assumes no parameter is needed.
   *
   * @param id              The name of the statement to execute.
   * @return The number of rows effected.
   */
  public int delete(String id) {
    try {
      return getSqlMapExecutor().delete(id);
    } catch (SQLException e) {
      throw new DaoException("Failed to delete - id ["
          + id + "].  Cause: " + e, e);
    }
  }

  /**
   * Executes a mapped SQL SELECT statement that returns data to populate
   * a single object instance.
   * <p/>
   * The parameter object is generally used to supply the input
   * data for the WHERE clause parameter(s) of the SELECT statement.
   *
   * @param id              The name of the statement to execute.
   * @param parameterObject The parameter object (e.g. JavaBean, Map, XML etc.).
   * @return The single result object populated with the result set data.
   */
  public Object queryForObject(String id, Object parameterObject) {
    try {
      return getSqlMapExecutor().queryForObject(id, parameterObject);
    } catch (SQLException e) {
      throw new DaoException("Failed to execute queryForObject - id ["
          + id + "], parameterObject [" + parameterObject + "].  Cause: " + e, e);
    }
  }

  /**
   * Executes a mapped SQL SELECT statement that returns data to populate
   * a single object instance.
   * <p/>
   * This overload assumes no parameter is needed.
   *
   * @param id              The name of the statement to execute.
   * @return The single result object populated with the result set data.
   */
  public Object queryForObject(String id) {
    try {
      return getSqlMapExecutor().queryForObject(id);
    } catch (SQLException e) {
      throw new DaoException("Failed to execute queryForObject - id ["
          + id + "].  Cause: " + e, e);
    }
  }

  /**
   * Executes a mapped SQL SELECT statement that returns data to populate
   * the supplied result object.
   * <p/>
   * The parameter object is generally used to supply the input
   * data for the WHERE clause parameter(s) of the SELECT statement.
   *
   * @param id              The name of the statement to execute.
   * @param parameterObject The parameter object (e.g. JavaBean, Map, XML etc.).
   * @param resultObject    The result object instance that should be populated with result data.
   * @return The single result object as supplied by the resultObject parameter, populated with the result set data.
   */
  public Object queryForObject(String id, Object parameterObject, Object resultObject) {
    try {
      return getSqlMapExecutor().queryForObject(id, parameterObject, resultObject);

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美最猛性xxxxx直播| 欧美日韩成人在线一区| 久久精品免视看| 国产一级精品在线| 国产三级精品三级| 91国内精品野花午夜精品| 日韩av一级片| 国产欧美一区二区三区鸳鸯浴| 精品盗摄一区二区三区| va亚洲va日韩不卡在线观看| 亚洲摸摸操操av| 精品免费日韩av| 色综合天天综合网天天看片| 亚洲成人在线免费| 久久久久久久av麻豆果冻| 欧美日韩一二区| 99精品欧美一区| 国产一区激情在线| 国产成人精品亚洲777人妖 | 一区二区三区日韩欧美精品| 欧美一区二区不卡视频| fc2成人免费人成在线观看播放| www.亚洲在线| 日本大香伊一区二区三区| 欧美三级在线看| 日韩视频在线你懂得| 欧美少妇一区二区| 日本道免费精品一区二区三区| 欧美日韩一区 二区 三区 久久精品| 欧美日韩国产天堂| 欧美电影免费观看高清完整版在线| 欧亚洲嫩模精品一区三区| 欧美日韩国产大片| ww久久中文字幕| 91麻豆精品国产| 欧美性生活久久| 日韩免费看网站| 国产精品久线观看视频| 欧美大片免费久久精品三p| 国产日韩精品久久久| 亚洲视频一区在线观看| 国产精品国产三级国产普通话99| 夜夜爽夜夜爽精品视频| 日本一不卡视频| 99久久久无码国产精品| 欧美电影一区二区| 欧美日本一区二区三区| 精品国产亚洲一区二区三区在线观看| 国产精品乱码妇女bbbb| 久久综合成人精品亚洲另类欧美| 国产精品麻豆99久久久久久| 欧美aa在线视频| 日本美女视频一区二区| av成人动漫在线观看| 欧美日本一道本在线视频| 国产午夜精品久久久久久久 | 国产精品一品二品| 国产老女人精品毛片久久| 色婷婷久久综合| 欧美三级资源在线| 欧美国产精品v| 中文字幕一区二区三区精华液| 国产精品全国免费观看高清| 水野朝阳av一区二区三区| 日韩黄色一级片| www.欧美精品一二区| 欧美va天堂va视频va在线| 一区二区视频在线| 一区二区三区久久久| 国产一区二区导航在线播放| 欧美精品久久久久久久多人混战| 中文欧美字幕免费| 国内精品写真在线观看| 国产一区视频导航| 欧美猛男男办公室激情| 亚洲欧洲综合另类在线| 国产精品自拍在线| 日韩色在线观看| 首页欧美精品中文字幕| 99国产精品久久久久久久久久| 久久亚洲精华国产精华液| 日日骚欧美日韩| 欧洲一区二区三区在线| 国产精品久久一级| 成人免费毛片片v| 色综合视频一区二区三区高清| 久久一夜天堂av一区二区三区| 日韩成人av影视| 欧美日韩精品一区二区| 一区二区三区四区中文字幕| 成人h动漫精品一区二区| 欧美日韩中字一区| 亚洲激情一二三区| 色综合欧美在线视频区| 亚洲欧美视频在线观看视频| 成人激情动漫在线观看| 久久精品水蜜桃av综合天堂| 国产在线看一区| 精品裸体舞一区二区三区| 另类小说色综合网站| www.亚洲在线| 自拍偷拍国产亚洲| 91亚洲精品久久久蜜桃网站 | 亚洲特级片在线| 成人国产亚洲欧美成人综合网| 欧美韩国日本不卡| 成人动漫一区二区在线| 综合中文字幕亚洲| 91福利视频在线| 亚洲va天堂va国产va久| 欧美精品久久一区| 久久成人免费日本黄色| 精品国一区二区三区| 国产一区二区三区精品欧美日韩一区二区三区| 日韩女优视频免费观看| 精品亚洲国产成人av制服丝袜| 色噜噜夜夜夜综合网| 亚洲精品国产精品乱码不99| 欧美主播一区二区三区美女| 日韩 欧美一区二区三区| 日韩视频中午一区| 国产99久久久精品| 欧美一级二级三级蜜桃| 久久66热偷产精品| 国产精品午夜春色av| 色诱亚洲精品久久久久久| 亚洲第一激情av| 精品久久一区二区| 成人一区二区在线观看| 亚洲伦在线观看| 欧美日本精品一区二区三区| 久久福利资源站| 中文字幕日韩精品一区| 欧美日韩免费不卡视频一区二区三区| 日韩中文字幕不卡| 久久久蜜桃精品| 一本色道久久综合狠狠躁的推荐| 亚洲va中文字幕| 久久久国产一区二区三区四区小说| 成人激情av网| 丝袜诱惑亚洲看片| 久久久精品蜜桃| 欧美综合久久久| 国产麻豆一精品一av一免费| 中文字幕亚洲精品在线观看| 欧美日韩激情在线| 国产999精品久久| 亚洲r级在线视频| 国产三级精品三级在线专区| 欧洲一区在线电影| 国产成人在线免费观看| 亚洲一区二区三区四区在线观看| av影院午夜一区| 日韩中文字幕91| 国产精品乱人伦| 欧美不卡一区二区三区四区| 不卡的av在线播放| 美女网站色91| 精品久久久网站| 日本韩国欧美一区| 国产一区二区三区香蕉| 夜夜精品视频一区二区| 国产亚洲精品中文字幕| 在线综合视频播放| 色乱码一区二区三区88| 国产精品中文有码| 日日夜夜免费精品| 亚洲激情图片小说视频| 久久亚洲一区二区三区四区| 欧美亚洲禁片免费| 99久久精品国产精品久久| 老司机精品视频导航| 香蕉加勒比综合久久| 国产精品天天摸av网| 久久一留热品黄| 日韩一区二区电影| 欧美日韩视频在线第一区 | 99精品欧美一区| 国产精品一区专区| 日本人妖一区二区| 亚洲福利视频导航| 91精品国产91久久久久久最新毛片| fc2成人免费人成在线观看播放| 国产伦精品一区二区三区在线观看| 日韩 欧美一区二区三区| 亚洲国产欧美在线| 亚洲品质自拍视频| 国产精品久久久久三级| 国产亚洲午夜高清国产拍精品 | 一级中文字幕一区二区| 国产精品久久久久国产精品日日| 2019国产精品| 337p粉嫩大胆色噜噜噜噜亚洲| 7777精品伊人久久久大香线蕉超级流畅 | 91精品婷婷国产综合久久性色| 在线精品视频一区二区三四| 91蝌蚪porny九色| 91一区二区在线观看| 91片在线免费观看| 91蜜桃免费观看视频|