List of usage examples for java.util SortedMap remove
V remove(Object key);
From source file:net.sourceforge.msscodefactory.v1_10.MSSBamRam.MSSBamRamTableInt16Table.java
public void deleteTableInt16(MSSBamAuthorization Authorization, MSSBamTableInt16Buff Buff) { final String S_ProcName = "MSSBamRamTableInt16Table.deleteTableInt16() "; MSSBamAnyObjPKey pkey = schema.getFactoryAnyObj().newPKey(); pkey.setRequiredId(schema.nextAnyObjIdGen()); MSSBamTableInt16Buff existing = dictByPKey.get(pkey); if (existing == null) { throw CFLib.getDefaultExceptionFactory().newStaleCacheDetectedException(getClass(), "deleteTableInt16", "Existing record not found", "TableInt16", pkey); }//www. j a va 2s.com if (existing.getRequiredRevision() != Buff.getRequiredRevision()) { throw CFLib.getDefaultExceptionFactory().newCollisionDetectedException(getClass(), "deleteTableInt16", pkey); } MSSBamTableInt16ByContainerIdxKey keyContainerIdx = schema.getFactoryTableInt16().newContainerIdxKey(); keyContainerIdx.setRequiredContainerId(existing.getRequiredContainerId()); // Validate reverse foreign keys // Delete is valid SortedMap<MSSBamAnyObjPKey, MSSBamTableInt16Buff> subdict; dictByPKey.remove(pkey); subdict = dictByContainerIdx.get(keyContainerIdx); subdict.remove(pkey); }
From source file:net.sourceforge.msscodefactory.v1_10.MSSBamRam.MSSBamRamTableInt32Table.java
public void updateTableInt32(MSSBamAuthorization Authorization, MSSBamTableInt32Buff Buff) { MSSBamAnyObjPKey pkey = schema.getFactoryAnyObj().newPKey(); pkey.setRequiredId(Buff.getRequiredId()); MSSBamTableInt32Buff existing = dictByPKey.get(pkey); if (existing == null) { throw CFLib.getDefaultExceptionFactory().newStaleCacheDetectedException(getClass(), "updateTableInt32", "Existing record not found", "TableInt32", pkey); }/*from w w w. j av a 2 s. com*/ MSSBamTableInt32ByContainerIdxKey existingKeyContainerIdx = schema.getFactoryTableInt32() .newContainerIdxKey(); existingKeyContainerIdx.setRequiredContainerId(existing.getRequiredContainerId()); MSSBamTableInt32ByContainerIdxKey newKeyContainerIdx = schema.getFactoryTableInt32().newContainerIdxKey(); newKeyContainerIdx.setRequiredContainerId(Buff.getRequiredContainerId()); // Check unique indexes // Validate foreign keys { boolean allNull = true; if (allNull) { if (null == schema.getTableInt32Def().readDerivedByIdIdx(Authorization, Buff.getRequiredId())) { throw CFLib.getDefaultExceptionFactory().newUnresolvedRelationException(getClass(), "updateTableInt32", "Superclass", "SuperClass", "Int32Def", null); } } } { boolean allNull = true; if (allNull) { if (null == schema.getTableTable().readDerivedByIdIdx(Authorization, Buff.getRequiredContainerId())) { throw CFLib.getDefaultExceptionFactory().newUnresolvedRelationException(getClass(), "updateTableInt32", "Container", "CTable", "Table", null); } } } // Update is valid SortedMap<MSSBamAnyObjPKey, MSSBamTableInt32Buff> subdict; dictByPKey.remove(pkey); dictByPKey.put(pkey, Buff); subdict = dictByContainerIdx.get(existingKeyContainerIdx); if (subdict != null) { subdict.remove(pkey); } if (dictByContainerIdx.containsKey(newKeyContainerIdx)) { subdict = dictByContainerIdx.get(newKeyContainerIdx); } else { subdict = new TreeMap<MSSBamAnyObjPKey, MSSBamTableInt32Buff>(); dictByContainerIdx.put(newKeyContainerIdx, subdict); } subdict.put(pkey, Buff); }
From source file:net.sourceforge.msscodefactory.v1_10.MSSBamRam.MSSBamRamTableInt32Table.java
public void deleteTableInt32(MSSBamAuthorization Authorization, MSSBamTableInt32Buff Buff) { final String S_ProcName = "MSSBamRamTableInt32Table.deleteTableInt32() "; MSSBamAnyObjPKey pkey = schema.getFactoryAnyObj().newPKey(); pkey.setRequiredId(schema.nextAnyObjIdGen()); MSSBamTableInt32Buff existing = dictByPKey.get(pkey); if (existing == null) { throw CFLib.getDefaultExceptionFactory().newStaleCacheDetectedException(getClass(), "deleteTableInt32", "Existing record not found", "TableInt32", pkey); }//from w ww . jav a2 s.c om if (existing.getRequiredRevision() != Buff.getRequiredRevision()) { throw CFLib.getDefaultExceptionFactory().newCollisionDetectedException(getClass(), "deleteTableInt32", pkey); } MSSBamTableInt32ByContainerIdxKey keyContainerIdx = schema.getFactoryTableInt32().newContainerIdxKey(); keyContainerIdx.setRequiredContainerId(existing.getRequiredContainerId()); // Validate reverse foreign keys // Delete is valid SortedMap<MSSBamAnyObjPKey, MSSBamTableInt32Buff> subdict; dictByPKey.remove(pkey); subdict = dictByContainerIdx.get(keyContainerIdx); subdict.remove(pkey); }
From source file:net.sourceforge.msscodefactory.v1_10.MSSBamRam.MSSBamRamTableInt64Table.java
public void updateTableInt64(MSSBamAuthorization Authorization, MSSBamTableInt64Buff Buff) { MSSBamAnyObjPKey pkey = schema.getFactoryAnyObj().newPKey(); pkey.setRequiredId(Buff.getRequiredId()); MSSBamTableInt64Buff existing = dictByPKey.get(pkey); if (existing == null) { throw CFLib.getDefaultExceptionFactory().newStaleCacheDetectedException(getClass(), "updateTableInt64", "Existing record not found", "TableInt64", pkey); }// www . j av a 2 s . c o m MSSBamTableInt64ByContainerIdxKey existingKeyContainerIdx = schema.getFactoryTableInt64() .newContainerIdxKey(); existingKeyContainerIdx.setRequiredContainerId(existing.getRequiredContainerId()); MSSBamTableInt64ByContainerIdxKey newKeyContainerIdx = schema.getFactoryTableInt64().newContainerIdxKey(); newKeyContainerIdx.setRequiredContainerId(Buff.getRequiredContainerId()); // Check unique indexes // Validate foreign keys { boolean allNull = true; if (allNull) { if (null == schema.getTableInt64Def().readDerivedByIdIdx(Authorization, Buff.getRequiredId())) { throw CFLib.getDefaultExceptionFactory().newUnresolvedRelationException(getClass(), "updateTableInt64", "Superclass", "SuperClass", "Int64Def", null); } } } { boolean allNull = true; if (allNull) { if (null == schema.getTableTable().readDerivedByIdIdx(Authorization, Buff.getRequiredContainerId())) { throw CFLib.getDefaultExceptionFactory().newUnresolvedRelationException(getClass(), "updateTableInt64", "Container", "CTable", "Table", null); } } } // Update is valid SortedMap<MSSBamAnyObjPKey, MSSBamTableInt64Buff> subdict; dictByPKey.remove(pkey); dictByPKey.put(pkey, Buff); subdict = dictByContainerIdx.get(existingKeyContainerIdx); if (subdict != null) { subdict.remove(pkey); } if (dictByContainerIdx.containsKey(newKeyContainerIdx)) { subdict = dictByContainerIdx.get(newKeyContainerIdx); } else { subdict = new TreeMap<MSSBamAnyObjPKey, MSSBamTableInt64Buff>(); dictByContainerIdx.put(newKeyContainerIdx, subdict); } subdict.put(pkey, Buff); }
From source file:net.sourceforge.msscodefactory.v1_10.MSSBamRam.MSSBamRamTableInt64Table.java
public void deleteTableInt64(MSSBamAuthorization Authorization, MSSBamTableInt64Buff Buff) { final String S_ProcName = "MSSBamRamTableInt64Table.deleteTableInt64() "; MSSBamAnyObjPKey pkey = schema.getFactoryAnyObj().newPKey(); pkey.setRequiredId(schema.nextAnyObjIdGen()); MSSBamTableInt64Buff existing = dictByPKey.get(pkey); if (existing == null) { throw CFLib.getDefaultExceptionFactory().newStaleCacheDetectedException(getClass(), "deleteTableInt64", "Existing record not found", "TableInt64", pkey); }/*from w w w. j a va 2s. c o m*/ if (existing.getRequiredRevision() != Buff.getRequiredRevision()) { throw CFLib.getDefaultExceptionFactory().newCollisionDetectedException(getClass(), "deleteTableInt64", pkey); } MSSBamTableInt64ByContainerIdxKey keyContainerIdx = schema.getFactoryTableInt64().newContainerIdxKey(); keyContainerIdx.setRequiredContainerId(existing.getRequiredContainerId()); // Validate reverse foreign keys // Delete is valid SortedMap<MSSBamAnyObjPKey, MSSBamTableInt64Buff> subdict; dictByPKey.remove(pkey); subdict = dictByContainerIdx.get(keyContainerIdx); subdict.remove(pkey); }
From source file:net.sourceforge.msscodefactory.v1_10.MSSBamRam.MSSBamRamTableNmTokensTable.java
public void updateTableNmTokens(MSSBamAuthorization Authorization, MSSBamTableNmTokensBuff Buff) { MSSBamAnyObjPKey pkey = schema.getFactoryAnyObj().newPKey(); pkey.setRequiredId(Buff.getRequiredId()); MSSBamTableNmTokensBuff existing = dictByPKey.get(pkey); if (existing == null) { throw CFLib.getDefaultExceptionFactory().newStaleCacheDetectedException(getClass(), "updateTableNmTokens", "Existing record not found", "TableNmTokens", pkey); }//from www . ja v a 2 s .co m MSSBamTableNmTokensByContainerIdxKey existingKeyContainerIdx = schema.getFactoryTableNmTokens() .newContainerIdxKey(); existingKeyContainerIdx.setRequiredContainerId(existing.getRequiredContainerId()); MSSBamTableNmTokensByContainerIdxKey newKeyContainerIdx = schema.getFactoryTableNmTokens() .newContainerIdxKey(); newKeyContainerIdx.setRequiredContainerId(Buff.getRequiredContainerId()); // Check unique indexes // Validate foreign keys { boolean allNull = true; if (allNull) { if (null == schema.getTableNmTokensDef().readDerivedByIdIdx(Authorization, Buff.getRequiredId())) { throw CFLib.getDefaultExceptionFactory().newUnresolvedRelationException(getClass(), "updateTableNmTokens", "Superclass", "SuperClass", "NmTokensDef", null); } } } { boolean allNull = true; if (allNull) { if (null == schema.getTableTable().readDerivedByIdIdx(Authorization, Buff.getRequiredContainerId())) { throw CFLib.getDefaultExceptionFactory().newUnresolvedRelationException(getClass(), "updateTableNmTokens", "Container", "CTable", "Table", null); } } } // Update is valid SortedMap<MSSBamAnyObjPKey, MSSBamTableNmTokensBuff> subdict; dictByPKey.remove(pkey); dictByPKey.put(pkey, Buff); subdict = dictByContainerIdx.get(existingKeyContainerIdx); if (subdict != null) { subdict.remove(pkey); } if (dictByContainerIdx.containsKey(newKeyContainerIdx)) { subdict = dictByContainerIdx.get(newKeyContainerIdx); } else { subdict = new TreeMap<MSSBamAnyObjPKey, MSSBamTableNmTokensBuff>(); dictByContainerIdx.put(newKeyContainerIdx, subdict); } subdict.put(pkey, Buff); }
From source file:net.sourceforge.msscodefactory.v1_10.MSSBamRam.MSSBamRamTableNmTokensTable.java
public void deleteTableNmTokens(MSSBamAuthorization Authorization, MSSBamTableNmTokensBuff Buff) { final String S_ProcName = "MSSBamRamTableNmTokensTable.deleteTableNmTokens() "; MSSBamAnyObjPKey pkey = schema.getFactoryAnyObj().newPKey(); pkey.setRequiredId(schema.nextAnyObjIdGen()); MSSBamTableNmTokensBuff existing = dictByPKey.get(pkey); if (existing == null) { throw CFLib.getDefaultExceptionFactory().newStaleCacheDetectedException(getClass(), "deleteTableNmTokens", "Existing record not found", "TableNmTokens", pkey); }/*from w ww .j a va 2 s . c o m*/ if (existing.getRequiredRevision() != Buff.getRequiredRevision()) { throw CFLib.getDefaultExceptionFactory().newCollisionDetectedException(getClass(), "deleteTableNmTokens", pkey); } MSSBamTableNmTokensByContainerIdxKey keyContainerIdx = schema.getFactoryTableNmTokens() .newContainerIdxKey(); keyContainerIdx.setRequiredContainerId(existing.getRequiredContainerId()); // Validate reverse foreign keys // Delete is valid SortedMap<MSSBamAnyObjPKey, MSSBamTableNmTokensBuff> subdict; dictByPKey.remove(pkey); subdict = dictByContainerIdx.get(keyContainerIdx); subdict.remove(pkey); }
From source file:net.sourceforge.msscodefactory.v1_10.MSSBamRam.MSSBamRamTableNmTokenTable.java
public void updateTableNmToken(MSSBamAuthorization Authorization, MSSBamTableNmTokenBuff Buff) { MSSBamAnyObjPKey pkey = schema.getFactoryAnyObj().newPKey(); pkey.setRequiredId(Buff.getRequiredId()); MSSBamTableNmTokenBuff existing = dictByPKey.get(pkey); if (existing == null) { throw CFLib.getDefaultExceptionFactory().newStaleCacheDetectedException(getClass(), "updateTableNmToken", "Existing record not found", "TableNmToken", pkey); }/* ww w. j a va2 s .co m*/ MSSBamTableNmTokenByContainerIdxKey existingKeyContainerIdx = schema.getFactoryTableNmToken() .newContainerIdxKey(); existingKeyContainerIdx.setRequiredContainerId(existing.getRequiredContainerId()); MSSBamTableNmTokenByContainerIdxKey newKeyContainerIdx = schema.getFactoryTableNmToken() .newContainerIdxKey(); newKeyContainerIdx.setRequiredContainerId(Buff.getRequiredContainerId()); // Check unique indexes // Validate foreign keys { boolean allNull = true; if (allNull) { if (null == schema.getTableNmTokenDef().readDerivedByIdIdx(Authorization, Buff.getRequiredId())) { throw CFLib.getDefaultExceptionFactory().newUnresolvedRelationException(getClass(), "updateTableNmToken", "Superclass", "SuperClass", "NmTokenDef", null); } } } { boolean allNull = true; if (allNull) { if (null == schema.getTableTable().readDerivedByIdIdx(Authorization, Buff.getRequiredContainerId())) { throw CFLib.getDefaultExceptionFactory().newUnresolvedRelationException(getClass(), "updateTableNmToken", "Container", "CTable", "Table", null); } } } // Update is valid SortedMap<MSSBamAnyObjPKey, MSSBamTableNmTokenBuff> subdict; dictByPKey.remove(pkey); dictByPKey.put(pkey, Buff); subdict = dictByContainerIdx.get(existingKeyContainerIdx); if (subdict != null) { subdict.remove(pkey); } if (dictByContainerIdx.containsKey(newKeyContainerIdx)) { subdict = dictByContainerIdx.get(newKeyContainerIdx); } else { subdict = new TreeMap<MSSBamAnyObjPKey, MSSBamTableNmTokenBuff>(); dictByContainerIdx.put(newKeyContainerIdx, subdict); } subdict.put(pkey, Buff); }
From source file:net.sourceforge.msscodefactory.v1_10.MSSBamRam.MSSBamRamTableNmTokenTable.java
public void deleteTableNmToken(MSSBamAuthorization Authorization, MSSBamTableNmTokenBuff Buff) { final String S_ProcName = "MSSBamRamTableNmTokenTable.deleteTableNmToken() "; MSSBamAnyObjPKey pkey = schema.getFactoryAnyObj().newPKey(); pkey.setRequiredId(schema.nextAnyObjIdGen()); MSSBamTableNmTokenBuff existing = dictByPKey.get(pkey); if (existing == null) { throw CFLib.getDefaultExceptionFactory().newStaleCacheDetectedException(getClass(), "deleteTableNmToken", "Existing record not found", "TableNmToken", pkey); }/*from w ww . j av a2s.c o m*/ if (existing.getRequiredRevision() != Buff.getRequiredRevision()) { throw CFLib.getDefaultExceptionFactory().newCollisionDetectedException(getClass(), "deleteTableNmToken", pkey); } MSSBamTableNmTokenByContainerIdxKey keyContainerIdx = schema.getFactoryTableNmToken().newContainerIdxKey(); keyContainerIdx.setRequiredContainerId(existing.getRequiredContainerId()); // Validate reverse foreign keys // Delete is valid SortedMap<MSSBamAnyObjPKey, MSSBamTableNmTokenBuff> subdict; dictByPKey.remove(pkey); subdict = dictByContainerIdx.get(keyContainerIdx); subdict.remove(pkey); }
From source file:net.sourceforge.msscodefactory.v1_10.MSSBamRam.MSSBamRamTableNumberTable.java
public void updateTableNumber(MSSBamAuthorization Authorization, MSSBamTableNumberBuff Buff) { MSSBamAnyObjPKey pkey = schema.getFactoryAnyObj().newPKey(); pkey.setRequiredId(Buff.getRequiredId()); MSSBamTableNumberBuff existing = dictByPKey.get(pkey); if (existing == null) { throw CFLib.getDefaultExceptionFactory().newStaleCacheDetectedException(getClass(), "updateTableNumber", "Existing record not found", "TableNumber", pkey); }//from w w w . j av a 2s. c om MSSBamTableNumberByContainerIdxKey existingKeyContainerIdx = schema.getFactoryTableNumber() .newContainerIdxKey(); existingKeyContainerIdx.setRequiredContainerId(existing.getRequiredContainerId()); MSSBamTableNumberByContainerIdxKey newKeyContainerIdx = schema.getFactoryTableNumber().newContainerIdxKey(); newKeyContainerIdx.setRequiredContainerId(Buff.getRequiredContainerId()); // Check unique indexes // Validate foreign keys { boolean allNull = true; if (allNull) { if (null == schema.getTableNumberDef().readDerivedByIdIdx(Authorization, Buff.getRequiredId())) { throw CFLib.getDefaultExceptionFactory().newUnresolvedRelationException(getClass(), "updateTableNumber", "Superclass", "SuperClass", "NumberDef", null); } } } { boolean allNull = true; if (allNull) { if (null == schema.getTableTable().readDerivedByIdIdx(Authorization, Buff.getRequiredContainerId())) { throw CFLib.getDefaultExceptionFactory().newUnresolvedRelationException(getClass(), "updateTableNumber", "Container", "Table", "Table", null); } } } // Update is valid SortedMap<MSSBamAnyObjPKey, MSSBamTableNumberBuff> subdict; dictByPKey.remove(pkey); dictByPKey.put(pkey, Buff); subdict = dictByContainerIdx.get(existingKeyContainerIdx); if (subdict != null) { subdict.remove(pkey); } if (dictByContainerIdx.containsKey(newKeyContainerIdx)) { subdict = dictByContainerIdx.get(newKeyContainerIdx); } else { subdict = new TreeMap<MSSBamAnyObjPKey, MSSBamTableNumberBuff>(); dictByContainerIdx.put(newKeyContainerIdx, subdict); } subdict.put(pkey, Buff); }