public boolean delete() { boolean result = super.delete(); boolean delete_error = false; String errorMsg = "The following relationships were not torn down by the Assign to Member.dispose call: "; Value_c testR609Inst = Value_c.getOneV_VALOnR609(this, false); if (testR609Inst != null) { delete_error = true; errorMsg = errorMsg + "609 "; } Value_c testR689Inst = Value_c.getOneV_VALOnR689(this, false); if (testR689Inst != null) { delete_error = true; errorMsg = errorMsg + "689 "; } Statement_c testR603Inst11 = Statement_c.getOneACT_SMTOnR603(this, false); if (testR603Inst11 != null) { delete_error = true; errorMsg = errorMsg + "603 "; } if (delete_error == true) { if (CorePlugin.getDefault().isDebugging()) { Ooaofooa.log.println(ILogger.DELETE, "Assign to Member", errorMsg); } else { Exception e = new Exception(); e.fillInStackTrace(); CorePlugin.logError(errorMsg, e); } } return result; }
public void relateAcrossR801To(Value_c target, boolean notifyChanges) { if (target == null) return; if (target == IsSupertypeValue) return; // already related if (IsSupertypeValue != target) { Object oldKey = getInstanceKey(); if (IsSupertypeValue != null) { IsSupertypeValue.clearBackPointerR801To(this); if (Boolean.valueOf(System.getenv("PTC_MCC_ENABLED")) == true) { // $NON-NLS-1$ Ooaofooa.log.println( ILogger.CONSISTENCY, "TransientValueReference_c.relateAcrossR801To(Value_c target)", "Relate performed across R801 from Transient Value Reference to Value without unrelate of prior instance."); } } IsSupertypeValue = target; m_value_id = target.getValue_id(); updateInstanceKey(oldKey, getInstanceKey()); target.setBackPointerR801To(this); target.addRef(); } }
public void relateAcrossR689To(Value_c target, boolean notifyChanges) { if (target == null) return; if (target == WritesValue) return; // already related if (WritesValue != target) { Object oldKey = getInstanceKey(); if (WritesValue != null) { WritesValue.clearBackPointerR689To(this); if (Boolean.valueOf(System.getenv("PTC_MCC_ENABLED")) == true) { // $NON-NLS-1$ Ooaofooa.log.println( ILogger.CONSISTENCY, "AssignToMember_c.relateAcrossR689To(Value_c target)", "Relate performed across R689 from Assign to Member to Value without unrelate of prior instance."); } } WritesValue = target; m_l_value_id = target.getValue_id(); updateInstanceKey(oldKey, getInstanceKey()); target.setBackPointerR689To(this); target.addRef(); } }
public boolean delete() { boolean result = super.delete(); boolean delete_error = false; String errorMsg = "The following relationships were not torn down by the Transient Value Reference.dispose call: "; Variable_c testR805Inst = Variable_c.getOneV_VAROnR805(this, false); if (testR805Inst != null) { delete_error = true; errorMsg = errorMsg + "805 "; } Value_c testR801Inst13 = Value_c.getOneV_VALOnR801(this, false); if (testR801Inst13 != null) { delete_error = true; errorMsg = errorMsg + "801 "; } if (delete_error == true) { if (CorePlugin.getDefault().isDebugging()) { Ooaofooa.log.println(ILogger.DELETE, "Transient Value Reference", errorMsg); } else { Exception e = new Exception(); e.fillInStackTrace(); CorePlugin.logError(errorMsg, e); } } return result; }
public static TransientValueReference_c getOneV_TVLOnR801( Value_c target, ClassQueryInterface_c test) { if (target != null) { return getOneV_TVLOnR801(target.getModelRoot(), target, test); } return null; }
public void unrelateAcrossR689From(Value_c target, boolean notifyChanges) { if (target == null) return; if (WritesValue == null) return; // already unrelated if (target != WritesValue) { Exception e = new Exception(); e.fillInStackTrace(); CorePlugin.logError("Tried to unrelate from non-related instance across R689", e); return; } if (target != null) { target.clearBackPointerR689To(this); } if (WritesValue != null) { m_l_value_id = WritesValue.getValue_id(); WritesValue = null; target.removeRef(); } }
// declare transform functions public void Dispose() { Ooaofooa.log.println( ILogger.OPERATION, "Assign to Member", " Operation entered: AssignToMember::Dispose"); final ModelRoot modelRoot = getModelRoot(); Value_c v_value = Value_c.getOneV_VALOnR609(this); if (((v_value != null))) { this.unrelateAcrossR609From(v_value); if (v_value != null) { v_value.Dispose(); } else { Throwable t = new Throwable(); t.fillInStackTrace(); CorePlugin.logError("Attempted to call an operation on a null instance.", t); } } v_value = Value_c.getOneV_VALOnR689(this); if (((v_value != null))) { this.unrelateAcrossR689From(v_value); if (v_value != null) { v_value.Dispose(); } else { Throwable t = new Throwable(); t.fillInStackTrace(); CorePlugin.logError("Attempted to call an operation on a null instance.", t); } } delete(); } // End dispose
public boolean evaluate(Object candidate) { Value_c selected = (Value_c) candidate; boolean retval = false; retval = (selected.getValue_id().equals(m_p40744)); return retval; }
public boolean checkConsistency() { Ooaofooa.log.println( ILogger.OPERATION, "Assign to Member", //$NON-NLS-1$ " Operation entered: Assign to Member::checkConsistency"); //$NON-NLS-1$ if (Boolean.valueOf(System.getenv("PTC_MCC_ENABLED")) == false) { // $NON-NLS-1$ return true; } ModelRoot modelRoot = getModelRoot(); boolean retval = true; class AssignToMember_c_test40732_c implements ClassQueryInterface_c { AssignToMember_c_test40732_c(java.util.UUID p40733) { m_p40733 = p40733; } private java.util.UUID m_p40733; public boolean evaluate(Object candidate) { AssignToMember_c selected = (AssignToMember_c) candidate; boolean retval = false; retval = (selected.getStatement_id().equals(m_p40733)); return retval; } } AssignToMember_c[] objs40731 = AssignToMember_c.AssignToMemberInstances( modelRoot, new AssignToMember_c_test40732_c(getStatement_id())); if (((objs40731.length) == 0)) { if (CorePlugin.getDefault().isDebugging()) { Ooaofooa.log.println( ILogger.CONSISTENCY, "Assign to Member", //$NON-NLS-1$ "Consistency: Object: Assign to Member: Cardinality of an identifier is zero. " //$NON-NLS-1$ + "Actual Value: " + Integer.toString(objs40731.length)); // $NON-NLS-1$ } else { Exception e = new Exception(); CorePlugin.logError( "Consistency: Object: Assign to Member: Cardinality of an identifier is zero. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs40731.length), e); } retval = false; } if (((objs40731.length) > 1)) { if (CorePlugin.getDefault().isDebugging()) { Ooaofooa.log.println( ILogger.CONSISTENCY, "Assign to Member", //$NON-NLS-1$ "Consistency: Object: Assign to Member: Cardinality of an identifier is greater than 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs40731.length) + " Statement_ID: " + "Not Printable"); //$NON-NLS-1$ } else { Exception e = new Exception(); CorePlugin.logError( "Consistency: Object: Assign to Member: Cardinality of an identifier is greater than 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs40731.length) + " Statement_ID: " + "Not Printable", e); //$NON-NLS-1$ } retval = false; } // Assign to Member is a subtype in association: rel.Numb = 603 // The supertype class is: Statement class Statement_c_test40737_c implements ClassQueryInterface_c { Statement_c_test40737_c(java.util.UUID p40738) { m_p40738 = p40738; } private java.util.UUID m_p40738; public boolean evaluate(Object candidate) { Statement_c selected = (Statement_c) candidate; boolean retval = false; retval = (selected.getStatement_id().equals(m_p40738)); return retval; } } Statement_c[] objs40736 = Statement_c.StatementInstances(modelRoot, new Statement_c_test40737_c(getStatement_id())); if (((objs40736.length) != 1)) { if (CorePlugin.getDefault().isDebugging()) { Ooaofooa.log.println( ILogger.CONSISTENCY, "Assign to Member", //$NON-NLS-1$ "Consistency: Object: Assign to Member: Association: 603: Cardinality of a supertype is not equal to 1. " //$NON-NLS-1$ + "Actual Value: " + Integer.toString(objs40736.length)); // $NON-NLS-1$ } else { Exception e = new Exception(); CorePlugin.logError( "Consistency: Object: Assign to Member: Association: 603: Cardinality of a supertype is not equal to 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs40736.length), e); } retval = false; } // Assign to Member is a referring class in association: rel.Numb = 609 // The participating class is: Value class Value_c_test40740_c implements ClassQueryInterface_c { Value_c_test40740_c(java.util.UUID p40741) { m_p40741 = p40741; } private java.util.UUID m_p40741; public boolean evaluate(Object candidate) { Value_c selected = (Value_c) candidate; boolean retval = false; retval = (selected.getValue_id().equals(m_p40741)); return retval; } } Value_c[] objs40739 = Value_c.ValueInstances(modelRoot, new Value_c_test40740_c(getR_value_id())); // The participant is unconditional // The multiplicity of the participant is one if (((objs40739.length) != 1)) { if (CorePlugin.getDefault().isDebugging()) { Ooaofooa.log.println( ILogger.CONSISTENCY, "Assign to Member", //$NON-NLS-1$ "Consistency: Object: Assign to Member: Association: 609: Cardinality of a participant is not equal to 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs40739.length) + " r_Value_ID: " + "Not Printable"); //$NON-NLS-1$ } else { Exception e = new Exception(); CorePlugin.logError( "Consistency: Object: Assign to Member: Association: 609: Cardinality of a participant is not equal to 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs40739.length) + " r_Value_ID: " + "Not Printable", e); //$NON-NLS-1$ } retval = false; } // Assign to Member is a referring class in association: rel.Numb = 689 // The participating class is: Value class Value_c_test40743_c implements ClassQueryInterface_c { Value_c_test40743_c(java.util.UUID p40744) { m_p40744 = p40744; } private java.util.UUID m_p40744; public boolean evaluate(Object candidate) { Value_c selected = (Value_c) candidate; boolean retval = false; retval = (selected.getValue_id().equals(m_p40744)); return retval; } } Value_c[] objs40742 = Value_c.ValueInstances(modelRoot, new Value_c_test40743_c(getL_value_id())); // The participant is unconditional // The multiplicity of the participant is one if (((objs40742.length) != 1)) { if (CorePlugin.getDefault().isDebugging()) { Ooaofooa.log.println( ILogger.CONSISTENCY, "Assign to Member", //$NON-NLS-1$ "Consistency: Object: Assign to Member: Association: 689: Cardinality of a participant is not equal to 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs40742.length) + " l_Value_ID: " + "Not Printable"); //$NON-NLS-1$ } else { Exception e = new Exception(); CorePlugin.logError( "Consistency: Object: Assign to Member: Association: 689: Cardinality of a participant is not equal to 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs40742.length) + " l_Value_ID: " + "Not Printable", e); //$NON-NLS-1$ } retval = false; } return retval; }
public void batchRelate( ModelRoot modelRoot, boolean relateProxies, boolean notifyChanges, boolean searchAllRoots) { InstanceList instances = null; ModelRoot baseRoot = modelRoot; if (ReferencesVariable == null) { // R805 Variable_c relInst37416 = (Variable_c) baseRoot.getInstanceList(Variable_c.class).get(new Object[] {m_var_id}); // if there was no local element, check for any global elements // failing that proceed to check other model roots if (relInst37416 == null) { relInst37416 = (Variable_c) Ooaofooa.getDefaultInstance() .getInstanceList(Variable_c.class) .get(new Object[] {m_var_id}); } if (relInst37416 == null && searchAllRoots && !baseRoot.isCompareRoot()) { Ooaofooa[] roots = Ooaofooa.getInstances(); for (int i = 0; i < roots.length; i++) { if (roots[i].isCompareRoot()) { // never use elements from any compare root continue; } relInst37416 = (Variable_c) roots[i].getInstanceList(Variable_c.class).get(new Object[] {m_var_id}); if (relInst37416 != null) break; } } // synchronized if (relInst37416 != null) { if (relateProxies || !isProxy() || (inSameComponent(this, relInst37416) && !isProxy())) { relInst37416.relateAcrossR805To(this, notifyChanges); } } } // R801 Value_c relInst37417 = (Value_c) baseRoot.getInstanceList(Value_c.class).get(new Object[] {m_value_id}); // if there was no local element, check for any global elements // failing that proceed to check other model roots if (relInst37417 == null) { relInst37417 = (Value_c) Ooaofooa.getDefaultInstance() .getInstanceList(Value_c.class) .get(new Object[] {m_value_id}); } if (relInst37417 == null && searchAllRoots && !baseRoot.isCompareRoot()) { Ooaofooa[] roots = Ooaofooa.getInstances(); for (int i = 0; i < roots.length; i++) { if (roots[i].isCompareRoot()) { // never use elements from any compare root continue; } relInst37417 = (Value_c) roots[i].getInstanceList(Value_c.class).get(new Object[] {m_value_id}); if (relInst37417 != null) break; } } // synchronized if (relInst37417 != null) { if (relateProxies || !isProxy() || (inSameComponent(this, relInst37417) && !isProxy())) { relInst37417.relateAcrossR801To(this, notifyChanges); } } }
public void batchRelate( ModelRoot modelRoot, boolean relateProxies, boolean notifyChanges, boolean searchAllRoots) { InstanceList instances = null; ModelRoot baseRoot = modelRoot; if (ReadsValue == null) { // R609 Value_c relInst40728 = (Value_c) baseRoot.getInstanceList(Value_c.class).get(new Object[] {m_r_value_id}); // if there was no local element, check for any global elements // failing that proceed to check other model roots if (relInst40728 == null) { relInst40728 = (Value_c) Ooaofooa.getDefaultInstance() .getInstanceList(Value_c.class) .get(new Object[] {m_r_value_id}); } if (relInst40728 == null && searchAllRoots && !baseRoot.isCompareRoot()) { Ooaofooa[] roots = Ooaofooa.getInstances(); for (int i = 0; i < roots.length; i++) { if (roots[i].isCompareRoot()) { // never use elements from any compare root continue; } relInst40728 = (Value_c) roots[i].getInstanceList(Value_c.class).get(new Object[] {m_r_value_id}); if (relInst40728 != null) break; } } // synchronized if (relInst40728 != null) { if (relateProxies || !isProxy() || (inSameComponent(this, relInst40728) && !isProxy())) { relInst40728.relateAcrossR609To(this, notifyChanges); } } } if (WritesValue == null) { // R689 Value_c relInst40729 = (Value_c) baseRoot.getInstanceList(Value_c.class).get(new Object[] {m_l_value_id}); // if there was no local element, check for any global elements // failing that proceed to check other model roots if (relInst40729 == null) { relInst40729 = (Value_c) Ooaofooa.getDefaultInstance() .getInstanceList(Value_c.class) .get(new Object[] {m_l_value_id}); } if (relInst40729 == null && searchAllRoots && !baseRoot.isCompareRoot()) { Ooaofooa[] roots = Ooaofooa.getInstances(); for (int i = 0; i < roots.length; i++) { if (roots[i].isCompareRoot()) { // never use elements from any compare root continue; } relInst40729 = (Value_c) roots[i].getInstanceList(Value_c.class).get(new Object[] {m_l_value_id}); if (relInst40729 != null) break; } } // synchronized if (relInst40729 != null) { if (relateProxies || !isProxy() || (inSameComponent(this, relInst40729) && !isProxy())) { relInst40729.relateAcrossR689To(this, notifyChanges); } } } // R603 Statement_c relInst40730 = (Statement_c) baseRoot.getInstanceList(Statement_c.class).get(new Object[] {m_statement_id}); // if there was no local element, check for any global elements // failing that proceed to check other model roots if (relInst40730 == null) { relInst40730 = (Statement_c) Ooaofooa.getDefaultInstance() .getInstanceList(Statement_c.class) .get(new Object[] {m_statement_id}); } if (relInst40730 == null && searchAllRoots && !baseRoot.isCompareRoot()) { Ooaofooa[] roots = Ooaofooa.getInstances(); for (int i = 0; i < roots.length; i++) { if (roots[i].isCompareRoot()) { // never use elements from any compare root continue; } relInst40730 = (Statement_c) roots[i].getInstanceList(Statement_c.class).get(new Object[] {m_statement_id}); if (relInst40730 != null) break; } } // synchronized if (relInst40730 != null) { if (relateProxies || !isProxy() || (inSameComponent(this, relInst40730) && !isProxy())) { relInst40730.relateAcrossR603To(this, notifyChanges); } } }
public java.util.UUID getR_value_id() { if (ReadsValue != null) { return ReadsValue.getValue_id(); } return IdAssigner.NULL_UUID; }
public long getR_value_idLongBased() { if (ReadsValue != null) { return ReadsValue.getValue_idLongBased(); } return 0; }
public boolean checkConsistency() { Ooaofooa.log.println( ILogger.OPERATION, "Transient Value Reference", //$NON-NLS-1$ " Operation entered: Transient Value Reference::checkConsistency"); //$NON-NLS-1$ if (Boolean.valueOf(System.getenv("PTC_MCC_ENABLED")) == false) { // $NON-NLS-1$ return true; } ModelRoot modelRoot = getModelRoot(); boolean retval = true; class TransientValueReference_c_test37419_c implements ClassQueryInterface_c { TransientValueReference_c_test37419_c(java.util.UUID p37420) { m_p37420 = p37420; } private java.util.UUID m_p37420; public boolean evaluate(Object candidate) { TransientValueReference_c selected = (TransientValueReference_c) candidate; boolean retval = false; retval = (selected.getValue_id().equals(m_p37420)); return retval; } } TransientValueReference_c[] objs37418 = TransientValueReference_c.TransientValueReferenceInstances( modelRoot, new TransientValueReference_c_test37419_c(getValue_id())); if (((objs37418.length) == 0)) { if (CorePlugin.getDefault().isDebugging()) { Ooaofooa.log.println( ILogger.CONSISTENCY, "Transient Value Reference", //$NON-NLS-1$ "Consistency: Object: Transient Value Reference: Cardinality of an identifier is zero. " //$NON-NLS-1$ + "Actual Value: " + Integer.toString(objs37418.length)); // $NON-NLS-1$ } else { Exception e = new Exception(); CorePlugin.logError( "Consistency: Object: Transient Value Reference: Cardinality of an identifier is zero. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs37418.length), e); } retval = false; } if (((objs37418.length) > 1)) { if (CorePlugin.getDefault().isDebugging()) { Ooaofooa.log.println( ILogger.CONSISTENCY, "Transient Value Reference", //$NON-NLS-1$ "Consistency: Object: Transient Value Reference: Cardinality of an identifier is greater than 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs37418.length) + " Value_ID: " + "Not Printable"); //$NON-NLS-1$ } else { Exception e = new Exception(); CorePlugin.logError( "Consistency: Object: Transient Value Reference: Cardinality of an identifier is greater than 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs37418.length) + " Value_ID: " + "Not Printable", e); //$NON-NLS-1$ } retval = false; } // Transient Value Reference is a subtype in association: rel.Numb = 801 // The supertype class is: Value class Value_c_test37424_c implements ClassQueryInterface_c { Value_c_test37424_c(java.util.UUID p37425) { m_p37425 = p37425; } private java.util.UUID m_p37425; public boolean evaluate(Object candidate) { Value_c selected = (Value_c) candidate; boolean retval = false; retval = (selected.getValue_id().equals(m_p37425)); return retval; } } Value_c[] objs37423 = Value_c.ValueInstances(modelRoot, new Value_c_test37424_c(getValue_id())); if (((objs37423.length) != 1)) { if (CorePlugin.getDefault().isDebugging()) { Ooaofooa.log.println( ILogger.CONSISTENCY, "Transient Value Reference", //$NON-NLS-1$ "Consistency: Object: Transient Value Reference: Association: 801: Cardinality of a supertype is not equal to 1. " //$NON-NLS-1$ + "Actual Value: " + Integer.toString(objs37423.length)); // $NON-NLS-1$ } else { Exception e = new Exception(); CorePlugin.logError( "Consistency: Object: Transient Value Reference: Association: 801: Cardinality of a supertype is not equal to 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs37423.length), e); } retval = false; } // Transient Value Reference is a referring class in association: rel.Numb = 805 // The participating class is: Variable class Variable_c_test37427_c implements ClassQueryInterface_c { Variable_c_test37427_c(java.util.UUID p37428) { m_p37428 = p37428; } private java.util.UUID m_p37428; public boolean evaluate(Object candidate) { Variable_c selected = (Variable_c) candidate; boolean retval = false; retval = (selected.getVar_id().equals(m_p37428)); return retval; } } Variable_c[] objs37426 = Variable_c.VariableInstances(modelRoot, new Variable_c_test37427_c(getVar_id())); // The participant is unconditional // The multiplicity of the participant is one if (((objs37426.length) != 1)) { if (CorePlugin.getDefault().isDebugging()) { Ooaofooa.log.println( ILogger.CONSISTENCY, "Transient Value Reference", //$NON-NLS-1$ "Consistency: Object: Transient Value Reference: Association: 805: Cardinality of a participant is not equal to 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs37426.length) + " Var_ID: " + "Not Printable"); //$NON-NLS-1$ } else { Exception e = new Exception(); CorePlugin.logError( "Consistency: Object: Transient Value Reference: Association: 805: Cardinality of a participant is not equal to 1. " //$NON-NLS-1$ + "Actual Value: " //$NON-NLS-1$ + Integer.toString(objs37426.length) + " Var_ID: " + "Not Printable", e); //$NON-NLS-1$ } retval = false; } return retval; }
public java.util.UUID getValue_id() { if (IsSupertypeValue != null) { return IsSupertypeValue.getValue_id(); } return IdAssigner.NULL_UUID; }
// declare attribute accessors public long getValue_idLongBased() { if (IsSupertypeValue != null) { return IsSupertypeValue.getValue_idLongBased(); } return 0; }
public static AssignToMember_c getOneACT_AIOnR689(Value_c target, boolean loadComponent) { return getOneACT_AIOnR689(target.getModelRoot(), target, null, loadComponent); }
public static AssignToMember_c getOneACT_AIOnR689(Value_c target, ClassQueryInterface_c test) { if (target != null) { return getOneACT_AIOnR689(target.getModelRoot(), target, test); } return null; }
public static TransientValueReference_c getOneV_TVLOnR801(Value_c target, boolean loadComponent) { return getOneV_TVLOnR801(target.getModelRoot(), target, null, loadComponent); }
public long getL_value_idLongBased() { if (WritesValue != null) { return WritesValue.getValue_idLongBased(); } return 0; }
public java.util.UUID getL_value_id() { if (WritesValue != null) { return WritesValue.getValue_id(); } return IdAssigner.NULL_UUID; }