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

klass.model.meta.domain.UrlAbstract 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 UrlAbstract extends com.gs.fw.common.mithra.superclassimpl.MithraTransactionalObjectImpl
implements
Element
{
	private static byte MEMORY_STATE = PersistenceState.IN_MEMORY;
	private static byte PERSISTED_STATE = PersistenceState.PERSISTED;
	private static final Logger logger = LoggerFactory.getLogger(Url.class.getName());
	private static final RelationshipHashStrategy forserviceGroup = new ServiceGroupRhs();
	private static final class ServiceGroupRhs implements RelationshipHashStrategy
	{
		public boolean equalsForRelationship(Object _srcObject, Object _srcData, Object _targetData, Timestamp _asOfDate0, Timestamp _asOfDate1)
		{
			UrlData _castedSrcData = (UrlData) _srcData;
			ServiceGroupData _castedTargetData = (ServiceGroupData) _targetData;
			if (_castedSrcData.getServiceGroupName()!= null && _castedSrcData.getServiceGroupName().equals(_castedTargetData.getName()))
			{
				return true;
			}

			return false;
		}

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

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

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

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

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

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

	public Url zFindOriginal()
	{
		UrlData data = (UrlData) this.currentData;
		Operation op;
		op = UrlFinder.serviceGroupName().eq(data.getServiceGroupName());
		op = op.and(UrlFinder.url().eq(data.getUrl()));
		return UrlFinder.findOne(op);
	}

	public boolean isModifiedSinceDetachmentByDependentRelationships()
	{
		if(this.isModifiedSinceDetachment()) return true;
		if(isParametersModifiedSinceDetachment()) return true;
		if(isServicesModifiedSinceDetachment()) return true;
		return false;
	}

	private Logger getLogger()
	{
		return logger;
	}

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

	protected void zSetFromUrlData( UrlData data )
	{
		super.zSetData(data);
		this.persistenceState = PERSISTED_STATE;
	}

	public void setFromUrlData( UrlData data )
	{
		super.zSetData(data);
	}

	public void zWriteDataClassName(ObjectOutput out) throws IOException
	{
	}

	public boolean isOrdinalNull()
	{
		return ((UrlData) this.zSynchronizedGetData()).isOrdinalNull();
	}

	public int getOrdinal()
	{
		UrlData data = (UrlData) this.zSynchronizedGetData();
		return data.getOrdinal();
	}

	public void setOrdinal(int newValue)
	{
		zSetInteger(UrlFinder.ordinal(), newValue, false, false ,false);
	}

	public final boolean isServiceGroupNameNull()
	{
		return ((UrlData) this.zSynchronizedGetData()).isServiceGroupNameNull();
	}

	public final String getServiceGroupName()
	{
		UrlData data = (UrlData) this.zSynchronizedGetData();
		return data.getServiceGroupName();
	}

	public void setServiceGroupName(String newValue)
	{
		if (newValue != null && newValue.length() > 256)
		throw new MithraBusinessException("Attribute 'serviceGroupName' cannot exceed maximum length of 256: " + newValue);
		MithraDataObject d = zSetString(UrlFinder.serviceGroupName(), newValue, true, false );
		if (d == null) return;
		UrlData data = (UrlData) d;
		TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary();
		if (!_behavior.isPersisted())
		{
			UrlParameterList parameters =
			(UrlParameterList ) data.getParameters();
			if (parameters != null)
			{
				parameters.setServiceGroupName(newValue);
			}

			ServiceList services =
			(ServiceList ) data.getServices();
			if (services != null)
			{
				services.setServiceGroupName(newValue);
			}
		}
	}

	public final boolean isUrlNull()
	{
		return ((UrlData) this.zSynchronizedGetData()).isUrlNull();
	}

	public final String getUrl()
	{
		UrlData data = (UrlData) this.zSynchronizedGetData();
		return data.getUrl();
	}

	public void setUrl(String newValue)
	{
		if (newValue != null && newValue.length() > 8192)
		throw new MithraBusinessException("Attribute 'url' cannot exceed maximum length of 8192: " + newValue);
		MithraDataObject d = zSetString(UrlFinder.url(), newValue, true, false );
		if (d == null) return;
		UrlData data = (UrlData) d;
		TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary();
		if (!_behavior.isPersisted())
		{
			UrlParameterList parameters =
			(UrlParameterList ) data.getParameters();
			if (parameters != null)
			{
				parameters.setUrlString(newValue);
			}

			ServiceList services =
			(ServiceList ) data.getServices();
			if (services != null)
			{
				services.setUrlString(newValue);
			}
		}
	}

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

	public void zPersistDetachedRelationships(MithraDataObject _data)
	{
		UrlData _newData = (UrlData) _data;
		{
			UrlParameterList parameters =
			(UrlParameterList) _newData.getParameters();
			if (parameters != null)
			{
				parameters.copyDetachedValuesToOriginalOrInsertIfNewOrDeleteIfRemoved();
			}
		}

		{
			ServiceList services =
			(ServiceList) _newData.getServices();
			if (services != null)
			{
				services.copyDetachedValuesToOriginalOrInsertIfNewOrDeleteIfRemoved();
			}
		}
	}

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

		if (_newData.getServices() != null && !(_newData.getServices() instanceof NulledRelation))
		{
			((ServiceList)_newData.getServices()).zSetTxDetachedDeleted();
		}

		this.zSetTxPersistenceState(PersistenceState.DETACHED_DELETED);
	}

	public void zSetNonTxDetachedDeleted()
	{
		TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary();
		UrlData _newData = (UrlData) _behavior.getCurrentDataForRead(this);
		if (_newData.getParameters() != null && !(_newData.getParameters() instanceof NulledRelation))
		{
			((UrlParameterList)_newData.getParameters()).zSetNonTxDetachedDeleted();
		}

		if (_newData.getServices() != null && !(_newData.getServices() instanceof NulledRelation))
		{
			((ServiceList)_newData.getServices()).zSetNonTxDetachedDeleted();
		}

		this.zSetNonTxPersistenceState(PersistenceState.DETACHED_DELETED);
	}

	/**
	* Relationship Expression:
	this.serviceGroupName = UrlParameter.serviceGroupName and this.url = UrlParameter.urlString
* Order By: ordinal asc. * @see UrlParameter#getUrl() reverse relationship UrlParameter.getUrl() * @return parameters */ public UrlParameterList getParameters() { UrlParameterList _result = null; Operation _op = null; TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); UrlData _data = (UrlData) _behavior.getCurrentDataForRead(this); if (_behavior.isPersisted()) { { { _op = new RelationshipMultiEqualityOperation(UrlFinder.parameters().zGetRelationshipMultiExtractor(), this); } } } else if (_behavior.isDetached()) { _result = (UrlParameterList) _data.getParameters(); if (_result == null) { { Operation detachedOp = new RelationshipMultiEqualityOperation(UrlFinder.parameters().zGetRelationshipMultiExtractor(), this); _result = new UrlParameterList(detachedOp); _result.zSetForRelationship(); if(_result != null) { _result = _result.getDetachedCopy(); } _result.zSetAddHandler(new ParametersAddHandlerInMemory()); } _result.setOrderBy(UrlParameterFinder.ordinal().ascendingOrderBy()); _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); _data = (UrlData) _behavior.getCurrentDataForWrite(this); _data.setParameters(_result); if (_result != null) _result.zSetParentContainerurl(this); } } else if (_behavior.isInMemory()) { _result = (UrlParameterList) _data.getParameters(); if (_result == null) { _result = new UrlParameterList(); _result.zSetAddHandler(new ParametersAddHandlerInMemory()); _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); _data = (UrlData) _behavior.getCurrentDataForWrite(this); _data.setParameters(_result); } } if (_op != null) { _result = new UrlParameterList(_op); _result.zSetForRelationship(); _result.zSetRemoveHandler(DeleteOnRemoveHandler.getInstance()); _result.zSetAddHandler(new ParametersAddHandlerPersisted()); _result.setOrderBy(UrlParameterFinder.ordinal().ascendingOrderBy()); } return _result; } public void setParameters(UrlParameterList parameters) { UrlParameterList _parameters = (UrlParameterList) parameters; TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); UrlData _data = (UrlData) _behavior.getCurrentDataForWrite(this); if (_behavior.isInMemory()) { if (_behavior.isDetached() && _parameters != null) { _parameters.zMakeDetached(new RelationshipMultiEqualityOperation(UrlFinder.parameters().zGetRelationshipMultiExtractor(), this), _data.getParameters()); } _data.setParameters(_parameters); if (_parameters != null) { _parameters.setServiceGroupName(_data.getServiceGroupName()); _parameters.setUrlString(_data.getUrl()); _parameters.zSetParentContainerurl(this); _parameters.zSetAddHandler(new ParametersAddHandlerInMemory()); } 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); _parameters.zSetAddHandler(new ParametersAddHandlerPersisted()); UrlParameterList parametersToDelete = new UrlParameterList(); parametersToDelete.addAll(this.getParameters()); for(int i=0;i < _parameters.size(); i++) { UrlParameter item = _parameters.getUrlParameterAt(i); if (!parametersToDelete.remove(item)) { item.setServiceGroupName(_data.getServiceGroupName()); item.setUrlString(_data.getUrl()); item.cascadeInsert(); } } parametersToDelete.cascadeDeleteAll(); } else throw new RuntimeException("not implemented"); } public boolean isParametersModifiedSinceDetachment() { TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); UrlData _data = (UrlData) _behavior.getCurrentDataForRead(this); UrlParameterList parameters = (UrlParameterList) _data.getParameters(); if( parameters != null) { return parameters.isModifiedSinceDetachment(); } return false; } /** * Relationship Expression:
	this.serviceGroupName = Service.serviceGroupName and this.url = Service.urlString
* Order By: ordinal asc. * @see Service#getUrl() reverse relationship Service.getUrl() * @return services */ public ServiceList getServices() { ServiceList _result = null; Operation _op = null; TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); UrlData _data = (UrlData) _behavior.getCurrentDataForRead(this); if (_behavior.isPersisted()) { { { _op = new RelationshipMultiEqualityOperation(UrlFinder.services().zGetRelationshipMultiExtractor(), this); } } } else if (_behavior.isDetached()) { _result = (ServiceList) _data.getServices(); if (_result == null) { { Operation detachedOp = new RelationshipMultiEqualityOperation(UrlFinder.services().zGetRelationshipMultiExtractor(), this); _result = new ServiceList(detachedOp); _result.zSetForRelationship(); if(_result != null) { _result = _result.getDetachedCopy(); } _result.zSetAddHandler(new ServicesAddHandlerInMemory()); } _result.setOrderBy(ServiceFinder.ordinal().ascendingOrderBy()); _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); _data = (UrlData) _behavior.getCurrentDataForWrite(this); _data.setServices(_result); if (_result != null) _result.zSetParentContainerurl(this); } } else if (_behavior.isInMemory()) { _result = (ServiceList) _data.getServices(); if (_result == null) { _result = new ServiceList(); _result.zSetAddHandler(new ServicesAddHandlerInMemory()); _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); _data = (UrlData) _behavior.getCurrentDataForWrite(this); _data.setServices(_result); } } if (_op != null) { _result = new ServiceList(_op); _result.zSetForRelationship(); _result.zSetRemoveHandler(DeleteOnRemoveHandler.getInstance()); _result.zSetAddHandler(new ServicesAddHandlerPersisted()); _result.setOrderBy(ServiceFinder.ordinal().ascendingOrderBy()); } return _result; } public void setServices(ServiceList services) { ServiceList _services = (ServiceList) services; TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); UrlData _data = (UrlData) _behavior.getCurrentDataForWrite(this); if (_behavior.isInMemory()) { if (_behavior.isDetached() && _services != null) { _services.zMakeDetached(new RelationshipMultiEqualityOperation(UrlFinder.services().zGetRelationshipMultiExtractor(), this), _data.getServices()); } _data.setServices(_services); if (_services != null) { _services.setServiceGroupName(_data.getServiceGroupName()); _services.setUrlString(_data.getUrl()); _services.zSetParentContainerurl(this); _services.zSetAddHandler(new ServicesAddHandlerInMemory()); } 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); _services.zSetAddHandler(new ServicesAddHandlerPersisted()); ServiceList servicesToDelete = new ServiceList(); servicesToDelete.addAll(this.getServices()); for(int i=0;i < _services.size(); i++) { Service item = _services.getServiceAt(i); if (!servicesToDelete.remove(item)) { item.setServiceGroupName(_data.getServiceGroupName()); item.setUrlString(_data.getUrl()); item.cascadeInsert(); } } servicesToDelete.cascadeDeleteAll(); } else throw new RuntimeException("not implemented"); } public boolean isServicesModifiedSinceDetachment() { TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); UrlData _data = (UrlData) _behavior.getCurrentDataForRead(this); ServiceList services = (ServiceList) _data.getServices(); if( services != null) { return services.isModifiedSinceDetachment(); } return false; } /** * Relationship Expression:
	ServiceGroup.name = this.serviceGroupName
* @see ServiceGroup#getUrls() reverse relationship ServiceGroup.getUrls() * @return The service group */ public ServiceGroup getServiceGroup() { ServiceGroup _result = null; Operation _op = null; TransactionalBehavior _behavior = zGetTransactionalBehaviorForReadWithWaitIfNecessary(); UrlData _data = (UrlData) _behavior.getCurrentDataForRead(this); MithraObjectPortal _portal = null; if (_behavior.isPersisted()) { { _portal = ServiceGroupFinder.getMithraObjectPortal(); Object _related = _portal.getAsOneFromCache(this, _data, forserviceGroup, null, null); if (!(_related instanceof NulledRelation)) _result = (ServiceGroup) _related; if (_related == null) { _op = ServiceGroupFinder.name().eq(_data.getServiceGroupName()); } } } else if (_behavior.isDetached()) { if (_data.getServiceGroup() instanceof NulledRelation) { return null; } _result = (ServiceGroup) _data.getServiceGroup(); if (_result == null) { { Operation detachedOp = ServiceGroupFinder.name().eq(_data.getServiceGroupName()); _result = ServiceGroupFinder.zFindOneForRelationship(detachedOp); if(_result != null) { _result = _result.getDetachedCopy(); } } _data = (UrlData) _behavior.getCurrentDataForWrite(this); _data.setServiceGroup(_result); } } else if (_behavior.isInMemory()) { _result = (ServiceGroup) _data.getServiceGroup(); if (_result == null) { { _op = ServiceGroupFinder.name().eq(_data.getServiceGroupName()); } } } if (_op != null) { _result = ServiceGroupFinder.zFindOneForRelationship(_op); } return _result; } public void setServiceGroup(ServiceGroup serviceGroup) { ServiceGroup _serviceGroup = (ServiceGroup) serviceGroup; TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); UrlData _data = (UrlData) _behavior.getCurrentDataForWrite(this); if (_behavior.isInMemory()) { Object _prev = _data.getServiceGroup(); if (_behavior.isDetached() && _prev != null) { ((DelegatingList)((ServiceGroup)_prev).getUrls()).zMarkMoved( (Url) this); } _data.setServiceGroup(_serviceGroup); _serviceGroup.getUrls().add( (Url) this); } else if (_behavior.isPersisted()) { _behavior.clearTempTransaction(this); if (_serviceGroup == null) { this.setServiceGroupName(null); } else { this.setServiceGroupName( _serviceGroup.getName()); } } else throw new RuntimeException("not implemented"); } public void zSetParentContainerserviceGroup(ServiceGroupAbstract parent) { TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); UrlData _data = (UrlData) _behavior.getCurrentDataForWrite(this); _behavior.clearTempTransaction(this); if (_behavior.isInMemory()) { _data.setServiceGroup(parent); } } protected void cascadeInsertImpl() throws MithraBusinessException { TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); UrlData _data = (UrlData) _behavior.getCurrentDataForWrite(this); UrlParameterList parameters = (UrlParameterList) _data.getParameters(); ServiceList services = (ServiceList) _data.getServices(); _behavior.insert(this); if (parameters != null) { parameters.cascadeInsertAll(); } if (services != null) { services.cascadeInsertAll(); } } @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) { UrlFinder.UrlRelatedFinder parentFinder = (UrlFinder.UrlRelatedFinder) parentFinderGeneric; TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); UrlData _newData = (UrlData) _behavior.getCurrentDataForWrite(this); { UrlParameterList parameters = (UrlParameterList) _newData.getParameters(); RelatedFinder dependentFinder = parentFinder.parameters(); DeepRelationshipUtility.zAddToNavigationStats(dependentFinder, parameters != null, navigationStats); if (parameters != null) { parameters.zCascadeAddNavigatedRelationshipsStats(dependentFinder, navigationStats); } } { ServiceList services = (ServiceList) _newData.getServices(); RelatedFinder dependentFinder = parentFinder.services(); DeepRelationshipUtility.zAddToNavigationStats(dependentFinder, services != null, navigationStats); if (services != null) { services.zCascadeAddNavigatedRelationshipsStats(dependentFinder, navigationStats); } } return navigationStats; } @Override public Map< RelatedFinder, StatisticCounter > zAddNavigatedRelationshipsStatsForDelete(RelatedFinder parentFinder, Map< RelatedFinder, StatisticCounter > navigationStats) { DeepRelationshipUtility.zAddAllDependentNavigationsStatsForDelete(parentFinder, navigationStats); return navigationStats; } @Override public Url zCascadeCopyThenInsert() throws MithraBusinessException { TransactionalBehavior _behavior = zGetTransactionalBehaviorForWriteWithWaitIfNecessary(); UrlData _data = (UrlData) _behavior.getCurrentDataForWrite(this); UrlParameterList parameters = (UrlParameterList) _data.getParameters(); ServiceList services = (ServiceList) _data.getServices(); Url original = (Url) _behavior.copyThenInsert(this); if (parameters != null) { parameters.zCascadeCopyThenInsertAll(); } if (services != null) { services.zCascadeCopyThenInsertAll(); } return original; } protected void cascadeDeleteImpl() throws MithraBusinessException { this.getParameters().cascadeDeleteAll(); this.getServices().cascadeDeleteAll(); this.delete(); } public Cache zGetCache() { return UrlFinder.getMithraObjectPortal().getCache(); } public MithraObjectPortal zGetPortal() { return UrlFinder.getMithraObjectPortal(); } public Url getOriginalPersistentObject() { return this.zFindOriginal(); } protected boolean issueUpdatesForNonPrimaryKeys(TransactionalBehavior behavior, MithraDataObject data, MithraDataObject newData) { boolean changed = false; changed |= zUpdateInteger(behavior, data, newData, UrlFinder.ordinal(), false); return changed; } protected boolean issueUpdatesForPrimaryKeys(TransactionalBehavior behavior, MithraDataObject data, MithraDataObject newData) { boolean changed = false; changed |= zUpdateString(behavior, data, newData, UrlFinder.serviceGroupName(), false); changed |= zUpdateString(behavior, data, newData, UrlFinder.url(), false); return changed; } public Object readResolve() throws ObjectStreamException { UrlAbstract result = (UrlAbstract) 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 ParametersAddHandlerInMemory implements DependentRelationshipAddHandler { public void addRelatedObject(MithraTransactionalObject relatedObject) { UrlParameter item = (UrlParameter) relatedObject; item.setServiceGroupName(getServiceGroupName()); item.setUrlString(getUrl()); item.zSetParentContainerurl(UrlAbstract.this); } } protected class ParametersAddHandlerPersisted implements DependentRelationshipAddHandler { public void addRelatedObject(MithraTransactionalObject relatedObject) { UrlParameter item = (UrlParameter) relatedObject; item.setServiceGroupName(getServiceGroupName()); item.setUrlString(getUrl()); item.cascadeInsert(); } } protected class ServicesAddHandlerInMemory implements DependentRelationshipAddHandler { public void addRelatedObject(MithraTransactionalObject relatedObject) { Service item = (Service) relatedObject; item.setServiceGroupName(getServiceGroupName()); item.setUrlString(getUrl()); item.zSetParentContainerurl(UrlAbstract.this); } } protected class ServicesAddHandlerPersisted implements DependentRelationshipAddHandler { public void addRelatedObject(MithraTransactionalObject relatedObject) { Service item = (Service) relatedObject; item.setServiceGroupName(getServiceGroupName()); item.setUrlString(getUrl()); item.cascadeInsert(); } } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy