first commit

This commit is contained in:
2025-07-28 13:56:49 +05:30
commit e9eb805edb
3438 changed files with 520990 additions and 0 deletions

View File

@@ -0,0 +1,38 @@
package WEB-INF.classes.wenrgise.ejb.common.helper;
import java.io.Serializable;
import wenrgise.ejb.common.helper.InputDBObject;
public class DBObject extends InputDBObject implements Serializable {
private int iInputOutput;
public static final int IN = 1;
public static final int OUT = 2;
public static final int INOUT = 3;
public DBObject() {}
public DBObject(int iPosition, int iDataType) {
this.iPosition = iPosition;
this.iDataType = iDataType;
}
public DBObject(int iPosition, int iInputOutput, int iDataType) {
this.iPosition = iPosition;
this.iInputOutput = iInputOutput;
this.iDataType = iDataType;
}
public DBObject(int iPosition, int iInputOutput, int iDataType, Object oValue) {
this.iPosition = iPosition;
this.iInputOutput = iInputOutput;
this.iDataType = iDataType;
this.oValue = oValue;
}
public int getDirection() {
return this.iInputOutput;
}
}

View File

@@ -0,0 +1,43 @@
package WEB-INF.classes.wenrgise.ejb.common.helper;
import java.io.Serializable;
public class InputDBObject implements Serializable {
protected int iPosition;
protected int iDataType;
protected Object oValue;
public InputDBObject() {}
public InputDBObject(int iPosition, int iDataType, Object oValue) {
this.iPosition = iPosition;
this.iDataType = iDataType;
this.oValue = oValue;
}
public int getDataType() {
return this.iDataType;
}
public void setDataType(int newIDataType) {
this.iDataType = newIDataType;
}
public int getPosition() {
return this.iPosition;
}
public void setPosition(int newIPosition) {
this.iPosition = newIPosition;
}
public Object getObject() {
return this.oValue;
}
public void setObject(Object newOValue) {
this.oValue = newOValue;
}
}

View File

@@ -0,0 +1,27 @@
package WEB-INF.classes.wenrgise.ejb.common.helper;
import java.io.Serializable;
import java.util.HashMap;
import wenrgise.ejb.common.helper.QueryValue;
public class QueryRow implements Serializable {
private HashMap row = null;
public QueryRow(int iCapacity) {
this.row = new HashMap(iCapacity);
}
public HashMap getRow() {
return this.row;
}
public void setRow(HashMap newRow) {
this.row = newRow;
}
public QueryValue get(String sColumnName) {
if (this.row != null)
return (QueryValue)this.row.get(sColumnName.toUpperCase());
return null;
}
}

View File

@@ -0,0 +1,166 @@
package WEB-INF.classes.wenrgise.ejb.common.helper;
import java.io.Serializable;
import java.math.BigDecimal;
import java.sql.Blob;
import java.sql.Clob;
import java.sql.Date;
import java.sql.Time;
import java.sql.Timestamp;
import java.util.Date;
public class QueryValue implements Serializable {
private String stringValue = null;
private BigDecimal bigDecimalValue = BigDecimal.valueOf(0L);
private short shortValue = 0;
private int intValue = 0;
private long longValue = 0L;
private float floatValue = 0.0F;
private double doubleValue = 0.0D;
private Date dateValue = null;
private Blob blobValue = null;
private Clob clobValue = null;
public void setString(String value) {
this.stringValue = value;
}
public String getString() {
return this.stringValue;
}
public void setBigDecimal(BigDecimal value) {
this.bigDecimalValue = value;
this.stringValue = (null != value) ? value.toString() : null;
}
public BigDecimal getBigDecimal() {
return this.bigDecimalValue;
}
public void setShort(short value) {
this.shortValue = value;
Short shrt = new Short(value);
this.stringValue = (null != shrt) ? shrt.toString() : null;
}
public short getShort() {
return this.shortValue;
}
public void setInt(int value) {
this.intValue = value;
Integer iValue = new Integer(value);
this.stringValue = (null != iValue) ? iValue.toString() : null;
}
public int getInt() {
return this.intValue;
}
public void setLong(long value) {
this.longValue = value;
Long lValue = new Long(value);
this.stringValue = (null != lValue) ? lValue.toString() : null;
}
public long getLong() {
return this.longValue;
}
public void setFloat(float value) {
this.floatValue = value;
Float fValue = new Float(value);
this.stringValue = (null != fValue) ? fValue.toString() : null;
}
public float getFloat() {
return this.floatValue;
}
public void setDouble(double value) {
this.doubleValue = value;
Double dValue = new Double(value);
this.stringValue = (null != dValue) ? dValue.toString() : null;
}
public double getDouble() {
return this.doubleValue;
}
public void setDate(Date value) {
this.dateValue = value;
this.stringValue = (null != value) ? value.toString() : null;
}
public void setDate(Date value) {
if (null == value) {
this.stringValue = null;
this.dateValue = null;
return;
}
this.dateValue = new Date(value.getTime());
this.stringValue = this.dateValue.toString();
}
public Date getDate() {
return this.dateValue;
}
public void setTime(Date value) {
setDate(value);
}
public void setTime(Time value) {
if (null == value) {
this.stringValue = null;
this.dateValue = null;
return;
}
this.dateValue = new Date(value.getTime());
this.stringValue = this.dateValue.toString();
}
public Date getTime() {
return this.dateValue;
}
public void setTimestamp(Timestamp value) {
if (null == value) {
this.stringValue = null;
this.dateValue = null;
return;
}
this.dateValue = new Date(value.getTime() + (value.getNanos() / 1000000));
this.stringValue = this.dateValue.toString();
}
public Date getTimestamp() {
return this.dateValue;
}
public void setBlob(Blob value) {
this.blobValue = value;
}
public Blob getBlob() {
return this.blobValue;
}
public void setClob(Clob value) {
this.clobValue = value;
}
public Clob getClob() {
return this.clobValue;
}
}