⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 transactionexample.java

📁 jdo开发实例,一个功能全面的oa系统
💻 JAVA
字号:
//Source file: c:\\test\\cc\\realmap\\lib\\transactionExample.java

package com.gzrealmap.oa.db;

//import java.util.Hashtable;

/**
每个交易对应一个继承自abstractTransaction的子类,虚方法performAction()必须重载,
也可以直接利用SQL语句,,也可以利用fullControl封装表格进行操作
 */
public class transactionExample extends abstractTransaction
{

   /**
   @roseuid 3DD5CF2A019C
    */
   public transactionExample()  throws Exception
   {

   }

   /**
   @roseuid 3DD5D0C400F1
    */
   public void performAction() throws Exception
   {
   	//简单例子
   	this.beginTran();
   	this.performAction("delete from userlog");
   	this.commitTran();
   	//需要值的例子(需要在接受请求的的JSP/Servlet中进行设定——transaction.setParameter(hash))
   	this.beginTran();
   	this.performAction("delete from userlog where id='"+getString("参数1")+"'");
   	this.commitTran();
		return;
   }

}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -