Añado los fuentes de java

This commit is contained in:
2025-06-09 13:37:06 +02:00
parent d6c990e5d5
commit a97a6350ee
226 changed files with 57246 additions and 0 deletions
@@ -0,0 +1,47 @@
package com.tarisan.chipcard.tpvvs.webservicetrayicon.accesodatos;
import java.sql.ResultSet;
import es.chipcard.util.*;
/*****
* Clase base de los objetos de acceso a Datos
* @author jjrider
*
*/
public abstract class ClsDBBase {
private static java.util.HashMap hshExistTable=new java.util.HashMap();
public ClsDBBase(){
checkExists();
}
public void checkExists(){
if(!tableExistLocally()){
createLocalTable();
}
}
public abstract String getTableName();
protected abstract int createLocalTable();
public boolean tableExistLocally(){
if(hshExistTable.containsKey(getTableName()))
return true;
boolean blnRetorno=false;
ResultSet rs=LocalDatabaseControl.getInstance().getQuery("SELECT * FROM SYS.SYSTABLES WHERE TABLENAME='"+getTableName()+"'");
if(rs!=null){
try{
if(rs.next()){
blnRetorno=true;
hshExistTable.put(getTableName(),getTableName());
}
}catch(Exception err){
SerClsDebug.aLog(err);
}
}
LocalDatabaseControl.forceClose(rs);
return blnRetorno;
}
}