Refactored out duplicate db interface.
This commit is contained in:
@@ -84,22 +84,6 @@ public abstract class AbstractGameObject {
|
||||
return GameObjectType.values()[ordinal];
|
||||
}
|
||||
|
||||
/**
|
||||
* Generates a {@link PreparedStatementShared} based on the specified query.
|
||||
* <p>
|
||||
* If {@link AbstractGameObject} Database functions will properly release
|
||||
* the PreparedStatementShared upon completion. If these functions are not
|
||||
* used, then {@link PreparedStatementShared#release release()} must be
|
||||
* called when finished with this object.
|
||||
*
|
||||
* @param sql The SQL string used to generate the PreparedStatementShared
|
||||
* @return {@link PreparedStatementShared}
|
||||
* @throws {@link SQLException}
|
||||
**/
|
||||
protected static PreparedStatementShared prepareStatement(String sql) throws SQLException {
|
||||
return new PreparedStatementShared(sql);
|
||||
}
|
||||
|
||||
public static AbstractGameObject getFromTypeAndID(long compositeID) {
|
||||
int objectTypeID = extractTypeOrdinal(compositeID);
|
||||
int tableID = extractTableID(objectTypeID, compositeID);
|
||||
|
||||
Reference in New Issue
Block a user