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

📄 dbservicei.java

📁 DbService数据库接口,测试规范?菘饨涌?测试规范数据库接口,测试规范
💻 JAVA
字号:
package com.rainbow.mas.plugin.dbplugin;import org.apache.log4j.LogManager;import org.apache.log4j.Logger;import MasBox.RunningStatus;import MasBox._ServiceDisp;public class DbServiceI extends _ServiceDisp {	static Logger logger = LogManager.getLogger(DbServiceI.class);		private DbServer _server;		private DbTranslateThread worker = null;		public DbServiceI(DbServer server){		_server = server;	}		public void start(Ice.Current current) {		logger.info("start...");		if ( worker == null){			worker = new DbTranslateThread();			worker.start();		}		_server.status = RunningStatus.Running;	}	public void stop(Ice.Current current) {		logger.info("stop...");		if (worker!=null){			worker.setStop();			worker.interrupt();		}		_server.status = RunningStatus.Stopped;		_server.communicator().shutdown();	}		public void pause(Ice.Current current){		logger.info("pause...");			if (worker!=null){			worker.pause();			worker.interrupt();		}		_server.status = RunningStatus.Paused;	}		public void keepon(Ice.Current current){		logger.info("keepon...");		if (worker!=null){			worker.keepon();			worker.interrupt();		}		_server.status = RunningStatus.Running;	}		public void restart(Ice.Current current){		logger.info("restart...");			worker.setStop();		worker.interrupt();		try {			worker.join();		} catch (InterruptedException e) {		}		if (!worker.isAlive()){			worker=new DbTranslateThread();			worker.start();		}		_server.status = RunningStatus.Running;	}}

⌨️ 快捷键说明

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