DatabaseUtils
- public class DatabaseUtils
Methods
bytes2UTF8
deriveStage1Inserts
- public static int deriveStage1Inserts(List<Property> stage1Inserts, EntityInterface e)
deriveStage2Inserts
parseEntityResultSet
- public static SparseEntity parseEntityResultSet(ResultSet rs)
Helper function for parsing MySQL results.
This function creates SparseEntities and parses all fields which belong to a SparseEntity: id, name, role, acl, description, datatype, and the file properties.
Never returns null.
parseFromProtoProperties
- public static ArrayList<Property> parseFromProtoProperties(EntityInterface entity, List<ProtoProperty> protos)
parseNameRoleACL
- public static SparseEntity parseNameRoleACL(ResultSet rs)
Helper function for parsing MySQL results.
This function creates SparseEntities and parses only the name, the role and the acl of an entity.
Never returns null.
parseOverrides
- public static void parseOverrides(List<ProtoProperty> properties, ResultSet rs)
parseParentResultSet
- public static LinkedList<VerySparseEntity> parseParentResultSet(ResultSet rs)
parsePropertyResultset
- public static List<ProtoProperty> parsePropertyResultset(ResultSet rs)
transformToDeepPropertyTree
- public static LinkedList<ProtoProperty> transformToDeepPropertyTree(List<ProtoProperty> properties, boolean isHead)