All Downloads are FREE. Search and download functionalities are using the official Maven repository.

klass.model.meta.domain.MemberReferencePathAbstract Maven / Gradle / Ivy

The newest version!
package klass.model.meta.domain;
import java.math.BigDecimal;
import java.sql.Timestamp;
import java.util.*;
import java.io.*;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import com.gs.fw.common.mithra.*;
import com.gs.fw.common.mithra.attribute.*;
import com.gs.fw.common.mithra.util.*;
import com.gs.fw.common.mithra.notification.*;
import com.gs.fw.common.mithra.notification.listener.*;
import com.gs.fw.common.mithra.list.cursor.Cursor;
import com.gs.fw.common.mithra.bulkloader.*;
import com.gs.fw.common.mithra.*;
import com.gs.fw.common.mithra.behavior.*;
import com.gs.fw.common.mithra.cache.Cache;
import com.gs.fw.common.mithra.extractor.*;
import com.gs.fw.common.mithra.finder.*;
import com.gs.fw.common.mithra.list.*;
import com.gs.fw.common.mithra.behavior.state.PersistenceState;
import com.gs.fw.common.mithra.attribute.update.*;
import com.gs.fw.common.mithra.transaction.MithraObjectPersister;
import java.util.Arrays;
import java.util.HashSet;
/**
* This file was automatically generated using Mithra 18.0.0. Please do not modify it.
* Add custom logic to its subclass instead.
*/
// Generated from templates/transactional/Abstract.jsp
public abstract class MemberReferencePathAbstract extends com.gs.fw.common.mithra.superclassimpl.MithraTransactionalObjectImpl
{
	private static byte MEMORY_STATE = PersistenceState.IN_MEMORY;
	private static byte PERSISTED_STATE = PersistenceState.PERSISTED;
	private static final Logger logger = LoggerFactory.getLogger(MemberReferencePath.class.getName());
	private static final RelationshipHashStrategy forklass = new KlassRhs();
	private static final RelationshipHashStrategy fordataTypeProperty = new DataTypePropertyRhs();
	private static final RelationshipHashStrategy forthisMemberReferencePathSubClass = new ThisMemberReferencePathSubClassRhs();
	private static final RelationshipHashStrategy fortypeMemberReferencePathSubClass = new TypeMemberReferencePathSubClassRhs();
	private static final RelationshipHashStrategy forexpressionValueSuperClass = new ExpressionValueSuperClassRhs();
	private static final class KlassRhs implements RelationshipHashStrategy
	{
		public boolean equalsForRelationship(Object _srcObject, Object _srcData, Object _targetData, Timestamp _asOfDate0, Timestamp _asOfDate1)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			KlassData _castedTargetData = (KlassData) _targetData;
			if (_castedSrcData.getClassName()!= null && _castedSrcData.getClassName().equals(_castedTargetData.getName()))
			{
				return true;
			}

			return false;
		}

		public int computeHashCodeFromRelated(Object _srcObject, Object _srcData)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			return HashUtil.hash(_castedSrcData.getClassName());
		}

		public int computeOffHeapHashCodeFromRelated(Object _srcObject, Object _srcData)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			return HashUtil.offHeapHash(_castedSrcData.getClassName());
		}
	}

	private static final class DataTypePropertyRhs implements RelationshipHashStrategy
	{
		public boolean equalsForRelationship(Object _srcObject, Object _srcData, Object _targetData, Timestamp _asOfDate0, Timestamp _asOfDate1)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			DataTypePropertyData _castedTargetData = (DataTypePropertyData) _targetData;
			if (_castedSrcData.getPropertyClassName()!= null && _castedSrcData.getPropertyClassName().equals(_castedTargetData.getClassifierName()) && _castedSrcData.getPropertyName()!= null && _castedSrcData.getPropertyName().equals(_castedTargetData.getName()))
			{
				return true;
			}

			return false;
		}

		public int computeHashCodeFromRelated(Object _srcObject, Object _srcData)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			return HashUtil.combineHashes(HashUtil.hash(_castedSrcData.getPropertyClassName()),HashUtil.hash(_castedSrcData.getPropertyName()));
		}

		public int computeOffHeapHashCodeFromRelated(Object _srcObject, Object _srcData)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			return HashUtil.combineHashes(HashUtil.offHeapHash(_castedSrcData.getPropertyClassName()),HashUtil.offHeapHash(_castedSrcData.getPropertyName()));
		}
	}

	private static final class ThisMemberReferencePathSubClassRhs implements RelationshipHashStrategy
	{
		public boolean equalsForRelationship(Object _srcObject, Object _srcData, Object _targetData, Timestamp _asOfDate0, Timestamp _asOfDate1)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			ThisMemberReferencePathData _castedTargetData = (ThisMemberReferencePathData) _targetData;
			if (_castedSrcData.getId() == _castedTargetData.getId())
			{
				return true;
			}

			return false;
		}

		public int computeHashCodeFromRelated(Object _srcObject, Object _srcData)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			return HashUtil.hash(_castedSrcData.getId());
		}

		public int computeOffHeapHashCodeFromRelated(Object _srcObject, Object _srcData)
		{
			return computeHashCodeFromRelated(_srcObject, _srcData);
		}
	}

	private static final class TypeMemberReferencePathSubClassRhs implements RelationshipHashStrategy
	{
		public boolean equalsForRelationship(Object _srcObject, Object _srcData, Object _targetData, Timestamp _asOfDate0, Timestamp _asOfDate1)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			TypeMemberReferencePathData _castedTargetData = (TypeMemberReferencePathData) _targetData;
			if (_castedSrcData.getId() == _castedTargetData.getId())
			{
				return true;
			}

			return false;
		}

		public int computeHashCodeFromRelated(Object _srcObject, Object _srcData)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			return HashUtil.hash(_castedSrcData.getId());
		}

		public int computeOffHeapHashCodeFromRelated(Object _srcObject, Object _srcData)
		{
			return computeHashCodeFromRelated(_srcObject, _srcData);
		}
	}

	private static final class ExpressionValueSuperClassRhs implements RelationshipHashStrategy
	{
		public boolean equalsForRelationship(Object _srcObject, Object _srcData, Object _targetData, Timestamp _asOfDate0, Timestamp _asOfDate1)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			ExpressionValueData _castedTargetData = (ExpressionValueData) _targetData;
			if (_castedSrcData.getId() == _castedTargetData.getId())
			{
				return true;
			}

			return false;
		}

		public int computeHashCodeFromRelated(Object _srcObject, Object _srcData)
		{
			MemberReferencePathData _castedSrcData = (MemberReferencePathData) _srcData;
			return HashUtil.hash(_castedSrcData.getId());
		}

		public int computeOffHeapHashCodeFromRelated(Object _srcObject, Object _srcData)
		{
			return computeHashCodeFromRelated(_srcObject, _srcData);
		}
	}

	public MemberReferencePathAbstract()
	{
		this.persistenceState = MEMORY_STATE;
	}

	public MemberReferencePath getDetachedCopy() throws MithraBusinessException
	{
		return (MemberReferencePath) super.getDetachedCopy();
	}

	public MemberReferencePath getNonPersistentCopy() throws MithraBusinessException
	{
		MemberReferencePath result = (MemberReferencePath) super.getNonPersistentCopy();
		result.persistenceState = MEMORY_STATE;
		return result;
	}

	public MemberReferencePath copyDetachedValuesToOriginalOrInsertIfNew()
	{
		return (MemberReferencePath) this.zCopyDetachedValuesToOriginalOrInsertIfNew();
	}

	public MemberReferencePath zFindOriginal()
	{
		MemberReferencePathData data = (MemberReferencePathData) this.currentData;
		Operation op;
		op = MemberReferencePathFinder.id().eq(data.getId());
		return MemberReferencePathFinder.findOne(op);
	}

	public boolean isModifiedSinceDetachmentByDependentRelationships()
	{
		if(this.isModifiedSinceDetachment()) return true;
		if(isAssociationEndsModifiedSinceDetachment()) return true;
		if(isThisMemberReferencePathSubClassModifiedSinceDetachment()) return true;
		if(isTypeMemberReferencePathSubClassModifiedSinceDetachment()) return true;
		return false;
	}

	private Logger getLogger()
	{
		return logger;
	}

	public MithraDataObject zAllocateData()
	{
		return new MemberReferencePathData();
	}

	protected void zSetFromMemberReferencePathData( MemberReferencePathData data )
	{
		super.zSetData(data);
		this.persistenceState = PERSISTED_STATE;
	}

	public void setFromMemberReferencePathData( MemberReferencePathData data )
	{
		super.zSetData(data);
	}

	public void zWriteDataClassName(ObjectOutput out) throws IOException
	{
	}

	public boolean isClassNameNull()
	{
		return ((MemberReferencePathData) this.zSynchronizedGetData()).isClassNameNull();
	}

	public String getClassName()
	{
		MemberReferencePathData data = (MemberReferencePathData) this.zSynchronizedGetData();
		return data.getClassName();
	}

	public void setClassName(String newValue)
	{
		if (newValue != null && newValue.length() > 256)
		throw new MithraBusinessException("Attribute 'className' cannot exceed maximum length of 256: " + newValue);
		zSetString(MemberReferencePathFinder.className(), newValue, false, false );
	}

	public final boolean isIdNull()
	{
		return ((MemberReferencePathData) this.zSynchronizedGetData()).isIdNull();
	}

	public final long getId()
	{
		MemberReferencePathData data = (MemberReferencePathData) this.zSynchronizedGetData();
		return data.getId();
	}

	public void setId(long newValue)
	{
		MithraDataObject d = zSetLong(MemberReferencePathFinder.id(), newValue, true, false ,false);
		if (d == null) return;
		MemberReferencePathData data = (MemberReferencePathData) d;
		TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary();
		if (!_behavior.isPersisted())
		{
			MemberReferencePathAssociationEndMappingList associationEnds =
			(MemberReferencePathAssociationEndMappingList ) data.getAssociationEnds();
			if (associationEnds != null)
			{
				associationEnds.setMemberReferencePathId(newValue);
			}

			ThisMemberReferencePath thisMemberReferencePathSubClass =
			(ThisMemberReferencePath ) data.getThisMemberReferencePathSubClass();
			if (thisMemberReferencePathSubClass != null)
			{
				thisMemberReferencePathSubClass.setId(newValue);
			}

			TypeMemberReferencePath typeMemberReferencePathSubClass =
			(TypeMemberReferencePath ) data.getTypeMemberReferencePathSubClass();
			if (typeMemberReferencePathSubClass != null)
			{
				typeMemberReferencePathSubClass.setId(newValue);
			}
		}
	}

	public boolean isPropertyClassNameNull()
	{
		return ((MemberReferencePathData) this.zSynchronizedGetData()).isPropertyClassNameNull();
	}

	public String getPropertyClassName()
	{
		MemberReferencePathData data = (MemberReferencePathData) this.zSynchronizedGetData();
		return data.getPropertyClassName();
	}

	public void setPropertyClassName(String newValue)
	{
		if (newValue != null && newValue.length() > 256)
		throw new MithraBusinessException("Attribute 'propertyClassName' cannot exceed maximum length of 256: " + newValue);
		zSetString(MemberReferencePathFinder.propertyClassName(), newValue, false, false );
	}

	public boolean isPropertyNameNull()
	{
		return ((MemberReferencePathData) this.zSynchronizedGetData()).isPropertyNameNull();
	}

	public String getPropertyName()
	{
		MemberReferencePathData data = (MemberReferencePathData) this.zSynchronizedGetData();
		return data.getPropertyName();
	}

	public void setPropertyName(String newValue)
	{
		if (newValue != null && newValue.length() > 256)
		throw new MithraBusinessException("Attribute 'propertyName' cannot exceed maximum length of 256: " + newValue);
		zSetString(MemberReferencePathFinder.propertyName(), newValue, false, false );
	}

	protected void issuePrimitiveNullSetters(TransactionalBehavior behavior, MithraDataObject data)
	{
	}

	public void zPersistDetachedRelationships(MithraDataObject _data)
	{
		MemberReferencePathData _newData = (MemberReferencePathData) _data;
		{
			MemberReferencePathAssociationEndMappingList associationEnds =
			(MemberReferencePathAssociationEndMappingList) _newData.getAssociationEnds();
			if (associationEnds != null)
			{
				associationEnds.copyDetachedValuesToOriginalOrInsertIfNewOrDeleteIfRemoved();
			}
		}

		if (_newData.getThisMemberReferencePathSubClass() instanceof NulledRelation)
		{
			ThisMemberReferencePath thisMemberReferencePathSubClass =
			this.getThisMemberReferencePathSubClass();
			if (thisMemberReferencePathSubClass != null)
			{
				thisMemberReferencePathSubClass.cascadeDelete();
			}
		}
		else
		{
			ThisMemberReferencePath thisMemberReferencePathSubClass =
			(ThisMemberReferencePath) _newData.getThisMemberReferencePathSubClass();
			if (thisMemberReferencePathSubClass != null)
			{
				ThisMemberReferencePath _existing =
				this.getThisMemberReferencePathSubClass();
				if (_existing == null)
				{
					thisMemberReferencePathSubClass.copyDetachedValuesToOriginalOrInsertIfNew();
				}
				else
				{
					_existing.zCopyAttributesFrom(thisMemberReferencePathSubClass.zGetTxDataForRead());
					_existing.zPersistDetachedRelationships(thisMemberReferencePathSubClass.zGetTxDataForRead());
				}
			}
		}

		if (_newData.getTypeMemberReferencePathSubClass() instanceof NulledRelation)
		{
			TypeMemberReferencePath typeMemberReferencePathSubClass =
			this.getTypeMemberReferencePathSubClass();
			if (typeMemberReferencePathSubClass != null)
			{
				typeMemberReferencePathSubClass.cascadeDelete();
			}
		}
		else
		{
			TypeMemberReferencePath typeMemberReferencePathSubClass =
			(TypeMemberReferencePath) _newData.getTypeMemberReferencePathSubClass();
			if (typeMemberReferencePathSubClass != null)
			{
				TypeMemberReferencePath _existing =
				this.getTypeMemberReferencePathSubClass();
				if (_existing == null)
				{
					typeMemberReferencePathSubClass.copyDetachedValuesToOriginalOrInsertIfNew();
				}
				else
				{
					_existing.zCopyAttributesFrom(typeMemberReferencePathSubClass.zGetTxDataForRead());
					_existing.zPersistDetachedRelationships(typeMemberReferencePathSubClass.zGetTxDataForRead());
				}
			}
		}
	}

	public void zSetTxDetachedDeleted()
	{
		TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary();
		if (_behavior.isDetached() && _behavior.isDeleted()) return;
		MemberReferencePathData _newData = (MemberReferencePathData) _behavior.getCurrentDataForRead(this);
		if (_newData.getAssociationEnds() != null && !(_newData.getAssociationEnds() instanceof NulledRelation))
		{
			((MemberReferencePathAssociationEndMappingList)_newData.getAssociationEnds()).zSetTxDetachedDeleted();
		}

		if (_newData.getThisMemberReferencePathSubClass() != null && !(_newData.getThisMemberReferencePathSubClass() instanceof NulledRelation))
		{
			((ThisMemberReferencePath)_newData.getThisMemberReferencePathSubClass()).zSetTxDetachedDeleted();
		}

		if (_newData.getTypeMemberReferencePathSubClass() != null && !(_newData.getTypeMemberReferencePathSubClass() instanceof NulledRelation))
		{
			((TypeMemberReferencePath)_newData.getTypeMemberReferencePathSubClass()).zSetTxDetachedDeleted();
		}

		this.zSetTxPersistenceState(PersistenceState.DETACHED_DELETED);
	}

	public void zSetNonTxDetachedDeleted()
	{
		TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary();
		MemberReferencePathData _newData = (MemberReferencePathData) _behavior.getCurrentDataForRead(this);
		if (_newData.getAssociationEnds() != null && !(_newData.getAssociationEnds() instanceof NulledRelation))
		{
			((MemberReferencePathAssociationEndMappingList)_newData.getAssociationEnds()).zSetNonTxDetachedDeleted();
		}

		if (_newData.getThisMemberReferencePathSubClass() != null && !(_newData.getThisMemberReferencePathSubClass() instanceof NulledRelation))
		{
			((ThisMemberReferencePath)_newData.getThisMemberReferencePathSubClass()).zSetNonTxDetachedDeleted();
		}

		if (_newData.getTypeMemberReferencePathSubClass() != null && !(_newData.getTypeMemberReferencePathSubClass() instanceof NulledRelation))
		{
			((TypeMemberReferencePath)_newData.getTypeMemberReferencePathSubClass()).zSetNonTxDetachedDeleted();
		}

		this.zSetNonTxPersistenceState(PersistenceState.DETACHED_DELETED);
	}

	/**
	* Relationship Expression:
	this.className = Klass.name
* @see Klass#getMemberReferencePaths() reverse relationship Klass.getMemberReferencePaths() * @return The klass */ public Klass getKlass() { Klass _result = null; Operation _op = null; TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForRead(this); MithraObjectPortal _portal = null; if (_behavior.isPersisted()) { { _portal = KlassFinder.getMithraObjectPortal(); Object _related = _portal.getAsOneFromCache(this, _data, forklass, null, null); if (!(_related instanceof NulledRelation)) _result = (Klass) _related; if (_related == null) { _op = KlassFinder.name().eq(_data.getClassName()); } } } else if (_behavior.isDetached()) { { { Operation detachedOp = KlassFinder.name().eq(_data.getClassName()); _result = KlassFinder.zFindOneForRelationship(detachedOp); } } } else if (_behavior.isInMemory()) { _result = (Klass) _data.getKlass(); if (_result == null) { { _op = KlassFinder.name().eq(_data.getClassName()); } } } if (_op != null) { _result = KlassFinder.zFindOneForRelationship(_op); } return _result; } public void setKlass(Klass klass) { Klass _klass = (Klass) klass; TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); if (_behavior.isInMemory()) { _data.setKlass(_klass); if (_klass == null) { this.setClassName(null); } else { this.setClassName(_klass.getName()); } } else if (_behavior.isPersisted()) { _behavior.clearTempTransaction(this); if (_klass == null) { this.setClassName(null); } else { this.setClassName( _klass.getName()); } } else throw new RuntimeException("not implemented"); } /** * Relationship Expression:
	this.id = MemberReferencePathAssociationEndMapping.memberReferencePathId
* Order By: ordinal asc. * @see MemberReferencePathAssociationEndMapping#getMemberReferencePath() reverse relationship MemberReferencePathAssociationEndMapping.getMemberReferencePath() * @return association ends */ public MemberReferencePathAssociationEndMappingList getAssociationEnds() { MemberReferencePathAssociationEndMappingList _result = null; Operation _op = null; TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForRead(this); if (_behavior.isPersisted()) { { { _op = MemberReferencePathAssociationEndMappingFinder.memberReferencePathId().eq(_data.getId()); } } } else if (_behavior.isDetached()) { _result = (MemberReferencePathAssociationEndMappingList) _data.getAssociationEnds(); if (_result == null) { { Operation detachedOp = MemberReferencePathAssociationEndMappingFinder.memberReferencePathId().eq(_data.getId()); _result = new MemberReferencePathAssociationEndMappingList(detachedOp); _result.zSetForRelationship(); if(_result != null) { _result = _result.getDetachedCopy(); } _result.zSetAddHandler(new AssociationEndsAddHandlerInMemory()); } _result.setOrderBy(MemberReferencePathAssociationEndMappingFinder.ordinal().ascendingOrderBy()); _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); _data.setAssociationEnds(_result); if (_result != null) _result.zSetParentContainermemberReferencePath(this); } } else if (_behavior.isInMemory()) { _result = (MemberReferencePathAssociationEndMappingList) _data.getAssociationEnds(); if (_result == null) { _result = new MemberReferencePathAssociationEndMappingList(); _result.zSetAddHandler(new AssociationEndsAddHandlerInMemory()); _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); _data.setAssociationEnds(_result); } } if (_op != null) { _result = new MemberReferencePathAssociationEndMappingList(_op); _result.zSetForRelationship(); _result.zSetRemoveHandler(DeleteOnRemoveHandler.getInstance()); _result.zSetAddHandler(new AssociationEndsAddHandlerPersisted()); _result.setOrderBy(MemberReferencePathAssociationEndMappingFinder.ordinal().ascendingOrderBy()); } return _result; } public void setAssociationEnds(MemberReferencePathAssociationEndMappingList associationEnds) { MemberReferencePathAssociationEndMappingList _associationEnds = (MemberReferencePathAssociationEndMappingList) associationEnds; TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); if (_behavior.isInMemory()) { if (_behavior.isDetached() && _associationEnds != null) { _associationEnds.zMakeDetached(MemberReferencePathAssociationEndMappingFinder.memberReferencePathId().eq(_data.getId()), _data.getAssociationEnds()); } _data.setAssociationEnds(_associationEnds); if (_associationEnds != null) { _associationEnds.setMemberReferencePathId(_data.getId()); _associationEnds.zSetParentContainermemberReferencePath(this); _associationEnds.zSetAddHandler(new AssociationEndsAddHandlerInMemory()); } else if (_behavior.isDetached()) { throw new MithraBusinessException("to-many relationships cannot be set to null. Use the clear() method on the list instead."); } } else if (_behavior.isPersisted()) { _behavior.clearTempTransaction(this); _associationEnds.zSetAddHandler(new AssociationEndsAddHandlerPersisted()); MemberReferencePathAssociationEndMappingList associationEndsToDelete = new MemberReferencePathAssociationEndMappingList(); associationEndsToDelete.addAll(this.getAssociationEnds()); for(int i=0;i < _associationEnds.size(); i++) { MemberReferencePathAssociationEndMapping item = _associationEnds.getMemberReferencePathAssociationEndMappingAt(i); if (!associationEndsToDelete.remove(item)) { item.setMemberReferencePathId(_data.getId()); item.cascadeInsert(); } } associationEndsToDelete.cascadeDeleteAll(); } else throw new RuntimeException("not implemented"); } public boolean isAssociationEndsModifiedSinceDetachment() { TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForRead(this); MemberReferencePathAssociationEndMappingList associationEnds = (MemberReferencePathAssociationEndMappingList) _data.getAssociationEnds(); if( associationEnds != null) { return associationEnds.isModifiedSinceDetachment(); } return false; } /** * Relationship Expression:
	this.propertyClassName = DataTypeProperty.classifierName and this.propertyName = DataTypeProperty.name
* @see DataTypeProperty#getMemberReferencePaths() reverse relationship DataTypeProperty.getMemberReferencePaths() * @return The data type property */ public DataTypeProperty getDataTypeProperty() { DataTypeProperty _result = null; Operation _op = null; TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForRead(this); MithraObjectPortal _portal = null; if (_behavior.isPersisted()) { { _portal = DataTypePropertyFinder.getMithraObjectPortal(); Object _related = _portal.getAsOneFromCache(this, _data, fordataTypeProperty, null, null); if (!(_related instanceof NulledRelation)) _result = (DataTypeProperty) _related; if (_related == null) { _op = new RelationshipMultiEqualityOperation(MemberReferencePathFinder.dataTypeProperty().zGetRelationshipMultiExtractor(), this); } } } else if (_behavior.isDetached()) { { { Operation detachedOp = new RelationshipMultiEqualityOperation(MemberReferencePathFinder.dataTypeProperty().zGetRelationshipMultiExtractor(), this); _result = DataTypePropertyFinder.zFindOneForRelationship(detachedOp); } } } else if (_behavior.isInMemory()) { _result = (DataTypeProperty) _data.getDataTypeProperty(); if (_result == null) { { _op = new RelationshipMultiEqualityOperation(MemberReferencePathFinder.dataTypeProperty().zGetRelationshipMultiExtractor(), this); } } } if (_op != null) { _result = DataTypePropertyFinder.zFindOneForRelationship(_op); } return _result; } public void setDataTypeProperty(DataTypeProperty dataTypeProperty) { DataTypeProperty _dataTypeProperty = (DataTypeProperty) dataTypeProperty; TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); if (_behavior.isInMemory()) { _data.setDataTypeProperty(_dataTypeProperty); if (_dataTypeProperty == null) { this.setPropertyClassName(null); this.setPropertyName(null); } else { this.setPropertyClassName(_dataTypeProperty.getClassifierName()); this.setPropertyName(_dataTypeProperty.getName()); } } else if (_behavior.isPersisted()) { _behavior.clearTempTransaction(this); if (_dataTypeProperty == null) { this.setPropertyClassName(null); this.setPropertyName(null); } else { this.setPropertyClassName( _dataTypeProperty.getClassifierName()); this.setPropertyName( _dataTypeProperty.getName()); } } else throw new RuntimeException("not implemented"); } /** * Relationship Expression:
	this.id = ThisMemberReferencePath.id
* @see ThisMemberReferencePath#getMemberReferencePathSuperClass() reverse relationship ThisMemberReferencePath.getMemberReferencePathSuperClass() * @return The this member reference path sub class */ public ThisMemberReferencePath getThisMemberReferencePathSubClass() { ThisMemberReferencePath _result = null; Operation _op = null; TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForRead(this); MithraObjectPortal _portal = null; if (_behavior.isPersisted()) { { _portal = ThisMemberReferencePathFinder.getMithraObjectPortal(); Object _related = _portal.getAsOneFromCache(this, _data, forthisMemberReferencePathSubClass, null, null); if (!(_related instanceof NulledRelation)) _result = (ThisMemberReferencePath) _related; if (_related == null) { _op = ThisMemberReferencePathFinder.id().eq(_data.getId()); } } } else if (_behavior.isDetached()) { if (_data.getThisMemberReferencePathSubClass() instanceof NulledRelation) { return null; } _result = (ThisMemberReferencePath) _data.getThisMemberReferencePathSubClass(); if (_result == null) { { Operation detachedOp = ThisMemberReferencePathFinder.id().eq(_data.getId()); _result = ThisMemberReferencePathFinder.zFindOneForRelationship(detachedOp); if(_result != null) { _result = _result.getDetachedCopy(); } } _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); _data.setThisMemberReferencePathSubClass(_result); if (_result != null) _result.zSetParentContainermemberReferencePathSuperClass(this); } } else if (_behavior.isInMemory()) { _result = (ThisMemberReferencePath) _data.getThisMemberReferencePathSubClass(); } if (_op != null) { _result = ThisMemberReferencePathFinder.zFindOneForRelationship(_op); } return _result; } public void setThisMemberReferencePathSubClass(ThisMemberReferencePath thisMemberReferencePathSubClass) { ThisMemberReferencePath _thisMemberReferencePathSubClass = (ThisMemberReferencePath) thisMemberReferencePathSubClass; TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); if (_behavior.isInMemory()) { Object _prev = _data.getThisMemberReferencePathSubClass(); _data.setThisMemberReferencePathSubClass(_thisMemberReferencePathSubClass); if (_thisMemberReferencePathSubClass != null) { _thisMemberReferencePathSubClass.setId(_data.getId()); _thisMemberReferencePathSubClass.zSetParentContainermemberReferencePathSuperClass(this); } else if (_behavior.isDetached()) { _data.setThisMemberReferencePathSubClass(NulledRelation.create(_prev)); if (_prev != null && !(_prev instanceof NulledRelation) && (!((MithraTransactionalObject)_prev).isInMemoryAndNotInserted() || ((MithraTransactionalObject)_prev).zIsDetached())) { ((MithraTransactionalObject)_prev).delete(); } } } else if (_behavior.isPersisted()) { _behavior.clearTempTransaction(this); ThisMemberReferencePath _existing = this.getThisMemberReferencePathSubClass(); if (_thisMemberReferencePathSubClass != _existing) { if (_existing != null) { _existing.cascadeDelete(); } if (_thisMemberReferencePathSubClass != null) { _thisMemberReferencePathSubClass.setId(_data.getId()); _thisMemberReferencePathSubClass.cascadeInsert(); } } } else throw new RuntimeException("not implemented"); } public boolean isThisMemberReferencePathSubClassModifiedSinceDetachment() { TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForRead(this); if (_data.getThisMemberReferencePathSubClass() instanceof NulledRelation) { ThisMemberReferencePath _existing = this.getOriginalPersistentObject().getThisMemberReferencePathSubClass(); return _existing != null; } ThisMemberReferencePath thisMemberReferencePathSubClass = (ThisMemberReferencePath) _data.getThisMemberReferencePathSubClass(); if( thisMemberReferencePathSubClass != null) { return thisMemberReferencePathSubClass.isModifiedSinceDetachment(); } return false; } /** * Relationship Expression:
	this.id = TypeMemberReferencePath.id
* @see TypeMemberReferencePath#getMemberReferencePathSuperClass() reverse relationship TypeMemberReferencePath.getMemberReferencePathSuperClass() * @return The type member reference path sub class */ public TypeMemberReferencePath getTypeMemberReferencePathSubClass() { TypeMemberReferencePath _result = null; Operation _op = null; TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForRead(this); MithraObjectPortal _portal = null; if (_behavior.isPersisted()) { { _portal = TypeMemberReferencePathFinder.getMithraObjectPortal(); Object _related = _portal.getAsOneFromCache(this, _data, fortypeMemberReferencePathSubClass, null, null); if (!(_related instanceof NulledRelation)) _result = (TypeMemberReferencePath) _related; if (_related == null) { _op = TypeMemberReferencePathFinder.id().eq(_data.getId()); } } } else if (_behavior.isDetached()) { if (_data.getTypeMemberReferencePathSubClass() instanceof NulledRelation) { return null; } _result = (TypeMemberReferencePath) _data.getTypeMemberReferencePathSubClass(); if (_result == null) { { Operation detachedOp = TypeMemberReferencePathFinder.id().eq(_data.getId()); _result = TypeMemberReferencePathFinder.zFindOneForRelationship(detachedOp); if(_result != null) { _result = _result.getDetachedCopy(); } } _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); _data.setTypeMemberReferencePathSubClass(_result); if (_result != null) _result.zSetParentContainermemberReferencePathSuperClass(this); } } else if (_behavior.isInMemory()) { _result = (TypeMemberReferencePath) _data.getTypeMemberReferencePathSubClass(); } if (_op != null) { _result = TypeMemberReferencePathFinder.zFindOneForRelationship(_op); } return _result; } public void setTypeMemberReferencePathSubClass(TypeMemberReferencePath typeMemberReferencePathSubClass) { TypeMemberReferencePath _typeMemberReferencePathSubClass = (TypeMemberReferencePath) typeMemberReferencePathSubClass; TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); if (_behavior.isInMemory()) { Object _prev = _data.getTypeMemberReferencePathSubClass(); _data.setTypeMemberReferencePathSubClass(_typeMemberReferencePathSubClass); if (_typeMemberReferencePathSubClass != null) { _typeMemberReferencePathSubClass.setId(_data.getId()); _typeMemberReferencePathSubClass.zSetParentContainermemberReferencePathSuperClass(this); } else if (_behavior.isDetached()) { _data.setTypeMemberReferencePathSubClass(NulledRelation.create(_prev)); if (_prev != null && !(_prev instanceof NulledRelation) && (!((MithraTransactionalObject)_prev).isInMemoryAndNotInserted() || ((MithraTransactionalObject)_prev).zIsDetached())) { ((MithraTransactionalObject)_prev).delete(); } } } else if (_behavior.isPersisted()) { _behavior.clearTempTransaction(this); TypeMemberReferencePath _existing = this.getTypeMemberReferencePathSubClass(); if (_typeMemberReferencePathSubClass != _existing) { if (_existing != null) { _existing.cascadeDelete(); } if (_typeMemberReferencePathSubClass != null) { _typeMemberReferencePathSubClass.setId(_data.getId()); _typeMemberReferencePathSubClass.cascadeInsert(); } } } else throw new RuntimeException("not implemented"); } public boolean isTypeMemberReferencePathSubClassModifiedSinceDetachment() { TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForRead(this); if (_data.getTypeMemberReferencePathSubClass() instanceof NulledRelation) { TypeMemberReferencePath _existing = this.getOriginalPersistentObject().getTypeMemberReferencePathSubClass(); return _existing != null; } TypeMemberReferencePath typeMemberReferencePathSubClass = (TypeMemberReferencePath) _data.getTypeMemberReferencePathSubClass(); if( typeMemberReferencePathSubClass != null) { return typeMemberReferencePathSubClass.isModifiedSinceDetachment(); } return false; } /** * Relationship Expression:
	EdgePointCriteria.memberReferencePathId = this.id
* @see EdgePointCriteria#getMemberReferencePath() reverse relationship EdgePointCriteria.getMemberReferencePath() * @return The edge point criteria */ public EdgePointCriteria getEdgePointCriteria() { EdgePointCriteria _result = null; Operation _op = null; TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForRead(this); if (_behavior.isPersisted()) { { { _op = EdgePointCriteriaFinder.memberReferencePathId().eq(_data.getId()); } } } else if (_behavior.isDetached()) { { { Operation detachedOp = EdgePointCriteriaFinder.memberReferencePathId().eq(_data.getId()); _result = EdgePointCriteriaFinder.zFindOneForRelationship(detachedOp); } } } else if (_behavior.isInMemory()) { _result = (EdgePointCriteria) _data.getEdgePointCriteria(); if (_result == null) { { _op = EdgePointCriteriaFinder.memberReferencePathId().eq(_data.getId()); } } } if (_op != null) { _result = EdgePointCriteriaFinder.zFindOneForRelationship(_op); } return _result; } public void setEdgePointCriteria(EdgePointCriteria edgePointCriteria) { EdgePointCriteria _edgePointCriteria = (EdgePointCriteria) edgePointCriteria; TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); if (_behavior.isInMemory()) { _data.setEdgePointCriteria(_edgePointCriteria); if (_edgePointCriteria == null) { this.setId(0); } else { this.setId(_edgePointCriteria.getMemberReferencePathId()); } } else if (_behavior.isPersisted()) { _behavior.clearTempTransaction(this); if (_edgePointCriteria == null) { this.setId(0); } else { this.setId( _edgePointCriteria.getMemberReferencePathId()); } } else throw new RuntimeException("not implemented"); } /** * Relationship Expression:
	ExpressionValue.id = this.id
* @see ExpressionValue#getMemberReferencePathSubClass() reverse relationship ExpressionValue.getMemberReferencePathSubClass() * @return The expression value super class */ public ExpressionValue getExpressionValueSuperClass() { ExpressionValue _result = null; Operation _op = null; TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForRead(this); MithraObjectPortal _portal = null; if (_behavior.isPersisted()) { { _portal = ExpressionValueFinder.getMithraObjectPortal(); Object _related = _portal.getAsOneFromCache(this, _data, forexpressionValueSuperClass, null, null); if (!(_related instanceof NulledRelation)) _result = (ExpressionValue) _related; if (_related == null) { _op = ExpressionValueFinder.id().eq(_data.getId()); } } } else if (_behavior.isDetached()) { if (_data.getExpressionValueSuperClass() instanceof NulledRelation) { return null; } _result = (ExpressionValue) _data.getExpressionValueSuperClass(); if (_result == null) { { Operation detachedOp = ExpressionValueFinder.id().eq(_data.getId()); _result = ExpressionValueFinder.zFindOneForRelationship(detachedOp); if(_result != null) { _result = _result.getDetachedCopy(); } } _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); _data.setExpressionValueSuperClass(_result); } } else if (_behavior.isInMemory()) { _result = (ExpressionValue) _data.getExpressionValueSuperClass(); if (_result == null) { { _op = ExpressionValueFinder.id().eq(_data.getId()); } } } if (_op != null) { _result = ExpressionValueFinder.zFindOneForRelationship(_op); } return _result; } public void setExpressionValueSuperClass(ExpressionValue expressionValueSuperClass) { ((ExpressionValue)expressionValueSuperClass).setMemberReferencePathSubClass((MemberReferencePath)this); } public void zSetParentContainerexpressionValueSuperClass(ExpressionValueAbstract parent) { TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); _behavior.clearTempTransaction(this); if (_behavior.isInMemory()) { _data.setExpressionValueSuperClass(parent); } } protected void cascadeInsertImpl() throws MithraBusinessException { TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); MemberReferencePathAssociationEndMappingList associationEnds = (MemberReferencePathAssociationEndMappingList) _data.getAssociationEnds(); ThisMemberReferencePath thisMemberReferencePathSubClass = (ThisMemberReferencePath) _data.getThisMemberReferencePathSubClass(); TypeMemberReferencePath typeMemberReferencePathSubClass = (TypeMemberReferencePath) _data.getTypeMemberReferencePathSubClass(); _behavior.insert(this); if (associationEnds != null) { associationEnds.cascadeInsertAll(); } if (thisMemberReferencePathSubClass != null) { thisMemberReferencePathSubClass.cascadeInsert(); } if (typeMemberReferencePathSubClass != null) { typeMemberReferencePathSubClass.cascadeInsert(); } } @Override public Map< RelatedFinder, StatisticCounter > zAddNavigatedRelationshipsStats(RelatedFinder finder, Map< RelatedFinder, StatisticCounter > navigationStats) { TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); _behavior.addNavigatedRelationshipsStats(this, finder, navigationStats); return navigationStats; } @Override public Map< RelatedFinder, StatisticCounter > zAddNavigatedRelationshipsStatsForUpdate(RelatedFinder parentFinderGeneric, Map< RelatedFinder, StatisticCounter > navigationStats) { MemberReferencePathFinder.MemberReferencePathRelatedFinder parentFinder = (MemberReferencePathFinder.MemberReferencePathRelatedFinder) parentFinderGeneric; TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); MemberReferencePathData _newData = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); { MemberReferencePathAssociationEndMappingList associationEnds = (MemberReferencePathAssociationEndMappingList) _newData.getAssociationEnds(); RelatedFinder dependentFinder = parentFinder.associationEnds(); DeepRelationshipUtility.zAddToNavigationStats(dependentFinder, associationEnds != null, navigationStats); if (associationEnds != null) { associationEnds.zCascadeAddNavigatedRelationshipsStats(dependentFinder, navigationStats); } } if (_newData.getThisMemberReferencePathSubClass() instanceof NulledRelation) { RelatedFinder dependentFinder = parentFinder.thisMemberReferencePathSubClass(); DeepRelationshipUtility.zAddToNavigationStats(dependentFinder, true, navigationStats); DeepRelationshipUtility.zAddAllDependentNavigationsStatsForDelete(dependentFinder, navigationStats); } else { ThisMemberReferencePath thisMemberReferencePathSubClass = (ThisMemberReferencePath) _newData.getThisMemberReferencePathSubClass(); RelatedFinder dependentFinder = parentFinder.thisMemberReferencePathSubClass(); DeepRelationshipUtility.zAddToNavigationStats(dependentFinder, thisMemberReferencePathSubClass != null, navigationStats); if (thisMemberReferencePathSubClass != null) { _behavior.addNavigatedRelationshipsStats(thisMemberReferencePathSubClass, dependentFinder, navigationStats); } } if (_newData.getTypeMemberReferencePathSubClass() instanceof NulledRelation) { RelatedFinder dependentFinder = parentFinder.typeMemberReferencePathSubClass(); DeepRelationshipUtility.zAddToNavigationStats(dependentFinder, true, navigationStats); DeepRelationshipUtility.zAddAllDependentNavigationsStatsForDelete(dependentFinder, navigationStats); } else { TypeMemberReferencePath typeMemberReferencePathSubClass = (TypeMemberReferencePath) _newData.getTypeMemberReferencePathSubClass(); RelatedFinder dependentFinder = parentFinder.typeMemberReferencePathSubClass(); DeepRelationshipUtility.zAddToNavigationStats(dependentFinder, typeMemberReferencePathSubClass != null, navigationStats); if (typeMemberReferencePathSubClass != null) { _behavior.addNavigatedRelationshipsStats(typeMemberReferencePathSubClass, dependentFinder, navigationStats); } } return navigationStats; } @Override public Map< RelatedFinder, StatisticCounter > zAddNavigatedRelationshipsStatsForDelete(RelatedFinder parentFinder, Map< RelatedFinder, StatisticCounter > navigationStats) { DeepRelationshipUtility.zAddAllDependentNavigationsStatsForDelete(parentFinder, navigationStats); return navigationStats; } @Override public MemberReferencePath zCascadeCopyThenInsert() throws MithraBusinessException { TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); MemberReferencePathData _data = (MemberReferencePathData) _behavior.getCurrentDataForWrite(this); MemberReferencePathAssociationEndMappingList associationEnds = (MemberReferencePathAssociationEndMappingList) _data.getAssociationEnds(); ThisMemberReferencePath thisMemberReferencePathSubClass = (ThisMemberReferencePath) _data.getThisMemberReferencePathSubClass(); TypeMemberReferencePath typeMemberReferencePathSubClass = (TypeMemberReferencePath) _data.getTypeMemberReferencePathSubClass(); MemberReferencePath original = (MemberReferencePath) _behavior.copyThenInsert(this); if (associationEnds != null) { associationEnds.zCascadeCopyThenInsertAll(); } if (thisMemberReferencePathSubClass != null) { thisMemberReferencePathSubClass.zCascadeCopyThenInsert(); } if (typeMemberReferencePathSubClass != null) { typeMemberReferencePathSubClass.zCascadeCopyThenInsert(); } return original; } protected void cascadeDeleteImpl() throws MithraBusinessException { this.getAssociationEnds().cascadeDeleteAll(); { ThisMemberReferencePath related = this.getThisMemberReferencePathSubClass(); if (related != null) related.cascadeDelete(); } { TypeMemberReferencePath related = this.getTypeMemberReferencePathSubClass(); if (related != null) related.cascadeDelete(); } this.delete(); } public Cache zGetCache() { return MemberReferencePathFinder.getMithraObjectPortal().getCache(); } public MithraObjectPortal zGetPortal() { return MemberReferencePathFinder.getMithraObjectPortal(); } public MemberReferencePath getOriginalPersistentObject() { return this.zFindOriginal(); } protected boolean issueUpdatesForNonPrimaryKeys(TransactionalBehavior behavior, MithraDataObject data, MithraDataObject newData) { boolean changed = false; changed |= zUpdateString(behavior, data, newData, MemberReferencePathFinder.className(), false); changed |= zUpdateString(behavior, data, newData, MemberReferencePathFinder.propertyClassName(), false); changed |= zUpdateString(behavior, data, newData, MemberReferencePathFinder.propertyName(), false); return changed; } protected boolean issueUpdatesForPrimaryKeys(TransactionalBehavior behavior, MithraDataObject data, MithraDataObject newData) { boolean changed = false; changed |= zUpdateLong(behavior, data, newData, MemberReferencePathFinder.id(), false); return changed; } public Object readResolve() throws ObjectStreamException { MemberReferencePathAbstract result = (MemberReferencePathAbstract) super.readResolve(); if (result.persistenceState == PersistenceState.PERSISTED) { result.persistenceState = PERSISTED_STATE; } else if (result.persistenceState == PersistenceState.IN_MEMORY) { result.persistenceState = MEMORY_STATE; } return result; } protected static void zConfigNonTx() { MEMORY_STATE = PersistenceState.IN_MEMORY_NON_TRANSACTIONAL; PERSISTED_STATE = PersistenceState.PERSISTED_NON_TRANSACTIONAL; } protected static void zConfigFullTx() { MEMORY_STATE = PersistenceState.IN_MEMORY; PERSISTED_STATE = PersistenceState.PERSISTED; } protected class AssociationEndsAddHandlerInMemory implements DependentRelationshipAddHandler { public void addRelatedObject(MithraTransactionalObject relatedObject) { MemberReferencePathAssociationEndMapping item = (MemberReferencePathAssociationEndMapping) relatedObject; item.setMemberReferencePathId(getId()); item.zSetParentContainermemberReferencePath(MemberReferencePathAbstract.this); } } protected class AssociationEndsAddHandlerPersisted implements DependentRelationshipAddHandler { public void addRelatedObject(MithraTransactionalObject relatedObject) { MemberReferencePathAssociationEndMapping item = (MemberReferencePathAssociationEndMapping) relatedObject; item.setMemberReferencePathId(getId()); item.cascadeInsert(); } } protected class ThisMemberReferencePathSubClassAddHandlerInMemory implements DependentRelationshipAddHandler { public void addRelatedObject(MithraTransactionalObject relatedObject) { ThisMemberReferencePath item = (ThisMemberReferencePath) relatedObject; item.setId(getId()); item.zSetParentContainermemberReferencePathSuperClass(MemberReferencePathAbstract.this); } } protected class ThisMemberReferencePathSubClassAddHandlerPersisted implements DependentRelationshipAddHandler { public void addRelatedObject(MithraTransactionalObject relatedObject) { ThisMemberReferencePath item = (ThisMemberReferencePath) relatedObject; item.setId(getId()); item.cascadeInsert(); } } protected class TypeMemberReferencePathSubClassAddHandlerInMemory implements DependentRelationshipAddHandler { public void addRelatedObject(MithraTransactionalObject relatedObject) { TypeMemberReferencePath item = (TypeMemberReferencePath) relatedObject; item.setId(getId()); item.zSetParentContainermemberReferencePathSuperClass(MemberReferencePathAbstract.this); } } protected class TypeMemberReferencePathSubClassAddHandlerPersisted implements DependentRelationshipAddHandler { public void addRelatedObject(MithraTransactionalObject relatedObject) { TypeMemberReferencePath item = (TypeMemberReferencePath) relatedObject; item.setId(getId()); item.cascadeInsert(); } } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy