org.eclipse.emf.emfstore.internal.server.model.versioning.impl
Class ChangePackageProxyImpl

java.lang.Object
  extended by org.eclipse.emf.common.notify.impl.BasicNotifierImpl
      extended by org.eclipse.emf.ecore.impl.BasicEObjectImpl
          extended by org.eclipse.emf.ecore.impl.EObjectImpl
              extended by org.eclipse.emf.emfstore.internal.server.model.versioning.impl.ChangePackageProxyImpl
All Implemented Interfaces:
org.eclipse.emf.common.notify.Notifier, org.eclipse.emf.ecore.EObject, org.eclipse.emf.ecore.InternalEObject, AbstractChangePackage, ChangePackageProxy

public class ChangePackageProxyImpl
extends org.eclipse.emf.ecore.impl.EObjectImpl
implements ChangePackageProxy

An implementation of the model object 'Change Package Proxy'.

The following features are implemented:


Nested Class Summary
 
Nested classes/interfaces inherited from class org.eclipse.emf.common.notify.impl.BasicNotifierImpl
org.eclipse.emf.common.notify.impl.BasicNotifierImpl.EAdapterList<E extends Object & org.eclipse.emf.common.notify.Adapter>, org.eclipse.emf.common.notify.impl.BasicNotifierImpl.EObservableAdapterList
 
Nested classes/interfaces inherited from interface org.eclipse.emf.ecore.InternalEObject
org.eclipse.emf.ecore.InternalEObject.EStore
 
Field Summary
 
Fields inherited from class org.eclipse.emf.ecore.impl.EObjectImpl
ELAST_EOBJECT_FLAG
 
Fields inherited from interface org.eclipse.emf.ecore.InternalEObject
EOPPOSITE_FEATURE_BASE
 
Method Summary
 void add(AbstractOperation operation)
          Add a single operation to this change package.
 void addAll(List<AbstractOperation> operations)
          Adds all given operations to this change package.
 void apply(Project project)
          Applies this change package to the given project.
 void apply(Project project, boolean forceApplication)
          Apply all operations in the change package to the given project.
 void attachToProjectSpace(ChangePackageContainer changePackageHolder)
          Attaches this change package to the given value.
 LogMessage basicGetLogMessage()
           
 org.eclipse.emf.common.notify.NotificationChain basicSetLogMessage(LogMessage newLogMessage, org.eclipse.emf.common.notify.NotificationChain msgs)
           
 void clear()
          Clears all operations from this change package.
 Object eGet(int featureID, boolean resolve, boolean coreType)
           
 org.eclipse.emf.common.notify.NotificationChain eInverseRemove(org.eclipse.emf.ecore.InternalEObject otherEnd, int featureID, org.eclipse.emf.common.notify.NotificationChain msgs)
           
 boolean eIsSet(int featureID)
           
 void eSet(int featureID, Object newValue)
           
 void eUnset(int featureID)
           
 AbstractOperation get(int index)
          Returns the operation at the given index.
 String getId()
           
 LogMessage getLogMessage()
           
 boolean isEmpty()
          Whether this change package has any operations.
 int leafSize()
          Returns the number of leaf operations that are contained within this change package.
 ESCloseableIterable<AbstractOperation> operations()
          Returns a handle for iterating through operations contained in this change package.
NOTE: Callers must call close on the returned handle.
 List<AbstractOperation> removeAtEnd(int n)
          Removes the given number of operations starting from the end.
 AbstractChangePackage reverse()
          Creates a copy of the change package and reverses it.
 ESCloseableIterable<AbstractOperation> reversedOperations()
          Returns a handle for iterating through operations contained in this change package backwards.
NOTE: Callers must call close on the returned handle.
 void save()
          Save this change package.
 void setId(String newId)
           
 void setLogMessage(LogMessage newLogMessage)
           
 int size()
          Returns the size of this change package, that is, how many operations are contained in it.
 ESChangePackage toAPI()
          Returns the API representation of this change package.
 String toString()
           
 
Methods inherited from class org.eclipse.emf.ecore.impl.EObjectImpl
eAdapters, eClass, eContainerFeatureID, eDeliver, eInternalContainer, eInvoke, eIsProxy, eSetClass, eSetDeliver, eSetProxyURI
 
Methods inherited from class org.eclipse.emf.ecore.impl.BasicEObjectImpl
eAllContents, eBaseStructuralFeatureID, eBasicRemoveFromContainer, eBasicRemoveFromContainerFeature, eBasicSetContainer, eContainer, eContainingFeature, eContainmentFeature, eContains, eContents, eCrossReferences, eDerivedOperationID, eDerivedOperationID, eDerivedStructuralFeatureID, eDerivedStructuralFeatureID, eDirectResource, eDynamicBasicRemoveFromContainer, eDynamicGet, eDynamicGet, eDynamicInverseAdd, eDynamicInverseRemove, eDynamicInvoke, eDynamicIsSet, eDynamicIsSet, eDynamicSet, eDynamicSet, eDynamicUnset, eDynamicUnset, eGet, eGet, eGet, eInternalResource, eInverseAdd, eInverseAdd, eInverseRemove, eInvoke, eIsSet, eObjectForURIFragmentSegment, eOpenGet, eOpenIsSet, eOpenSet, eOpenUnset, eProxyURI, eResolveProxy, eResource, eSet, eSetResource, eSetStore, eSetting, eStore, eUnset, eURIFragmentSegment, eVirtualGet, eVirtualGet, eVirtualIsSet, eVirtualSet, eVirtualUnset
 
Methods inherited from class org.eclipse.emf.common.notify.impl.BasicNotifierImpl
eNotificationRequired, eNotify
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.eclipse.emf.ecore.EObject
eAllContents, eClass, eContainer, eContainingFeature, eContainmentFeature, eContents, eCrossReferences, eGet, eGet, eInvoke, eIsProxy, eIsSet, eResource, eSet, eUnset
 
Methods inherited from interface org.eclipse.emf.common.notify.Notifier
eAdapters, eDeliver, eNotify, eSetDeliver
 
Methods inherited from interface org.eclipse.emf.ecore.InternalEObject
eNotificationRequired
 

Method Detail

getLogMessage

public LogMessage getLogMessage()

Specified by:
getLogMessage in interface AbstractChangePackage
Returns:
the value of the 'Log Message' containment reference.
See Also:
AbstractChangePackage.setLogMessage(LogMessage), VersioningPackage.getAbstractChangePackage_LogMessage()

basicGetLogMessage

public LogMessage basicGetLogMessage()


basicSetLogMessage

public org.eclipse.emf.common.notify.NotificationChain basicSetLogMessage(LogMessage newLogMessage,
                                                                          org.eclipse.emf.common.notify.NotificationChain msgs)


setLogMessage

public void setLogMessage(LogMessage newLogMessage)

Specified by:
setLogMessage in interface AbstractChangePackage
Parameters:
newLogMessage - the new value of the 'Log Message' containment reference.
See Also:
AbstractChangePackage.getLogMessage()

getId

public String getId()

Specified by:
getId in interface ChangePackageProxy
Returns:
the value of the 'Id' attribute.
See Also:
ChangePackageProxy.setId(String), VersioningPackage.getChangePackageProxy_Id()

setId

public void setId(String newId)

Specified by:
setId in interface ChangePackageProxy
Parameters:
newId - the new value of the 'Id' attribute.
See Also:
ChangePackageProxy.getId()

eInverseRemove

public org.eclipse.emf.common.notify.NotificationChain eInverseRemove(org.eclipse.emf.ecore.InternalEObject otherEnd,
                                                                      int featureID,
                                                                      org.eclipse.emf.common.notify.NotificationChain msgs)

Overrides:
eInverseRemove in class org.eclipse.emf.ecore.impl.BasicEObjectImpl

eGet

public Object eGet(int featureID,
                   boolean resolve,
                   boolean coreType)

Specified by:
eGet in interface org.eclipse.emf.ecore.InternalEObject
Overrides:
eGet in class org.eclipse.emf.ecore.impl.BasicEObjectImpl

eSet

public void eSet(int featureID,
                 Object newValue)

Specified by:
eSet in interface org.eclipse.emf.ecore.InternalEObject
Overrides:
eSet in class org.eclipse.emf.ecore.impl.BasicEObjectImpl

eUnset

public void eUnset(int featureID)

Specified by:
eUnset in interface org.eclipse.emf.ecore.InternalEObject
Overrides:
eUnset in class org.eclipse.emf.ecore.impl.BasicEObjectImpl

eIsSet

public boolean eIsSet(int featureID)

Specified by:
eIsSet in interface org.eclipse.emf.ecore.InternalEObject
Overrides:
eIsSet in class org.eclipse.emf.ecore.impl.BasicEObjectImpl

toString

public String toString()

Overrides:
toString in class org.eclipse.emf.ecore.impl.BasicEObjectImpl

add

public void add(AbstractOperation operation)
Add a single operation to this change package.

Specified by:
add in interface AbstractChangePackage
Parameters:
operation - the operation to be added
See Also:
AbstractChangePackage.add(org.eclipse.emf.emfstore.internal.server.model.versioning.operations.AbstractOperation)

addAll

public void addAll(List<AbstractOperation> operations)
Adds all given operations to this change package.

Specified by:
addAll in interface AbstractChangePackage
Parameters:
operations - the operations to be added
See Also:
AbstractChangePackage.addAll(java.util.List)

reverse

public AbstractChangePackage reverse()
Creates a copy of the change package and reverses it.

Specified by:
reverse in interface AbstractChangePackage
Returns:
the reversed change packages
See Also:
AbstractChangePackage.reverse()

size

public int size()
Returns the size of this change package, that is, how many operations are contained in it.

Specified by:
size in interface AbstractChangePackage
Returns:
the number of operations contained in this change package
See Also:
AbstractChangePackage.size()

leafSize

public int leafSize()
Returns the number of leaf operations that are contained within this change package.

Specified by:
leafSize in interface AbstractChangePackage
Returns:
the number of leaf operations contained in this change package
See Also:
AbstractChangePackage.leafSize()

operations

public ESCloseableIterable<AbstractOperation> operations()
Returns a handle for iterating through operations contained in this change package.
NOTE: Callers must call close on the returned handle.

Specified by:
operations in interface AbstractChangePackage
Returns:
a handle that enables iterating through all operations of this change package
See Also:
AbstractChangePackage.operations()

reversedOperations

public ESCloseableIterable<AbstractOperation> reversedOperations()
Returns a handle for iterating through operations contained in this change package backwards.
NOTE: Callers must call close on the returned handle.

Specified by:
reversedOperations in interface AbstractChangePackage
Returns:
a handle that enables iterating through all operations of this change package
See Also:
AbstractChangePackage.reversedOperations()

isEmpty

public boolean isEmpty()
Whether this change package has any operations.

Specified by:
isEmpty in interface AbstractChangePackage
Returns:
true, if this change package is empty, false otherwise
See Also:
AbstractChangePackage.isEmpty()

removeAtEnd

public List<AbstractOperation> removeAtEnd(int n)
Removes the given number of operations starting from the end.

Specified by:
removeAtEnd in interface AbstractChangePackage
Parameters:
n - the number of operations to be removed
Returns:
the removed operations
See Also:
AbstractChangePackage.removeAtEnd(int)

clear

public void clear()
Clears all operations from this change package.

Specified by:
clear in interface AbstractChangePackage
See Also:
AbstractChangePackage.clear()

attachToProjectSpace

public void attachToProjectSpace(ChangePackageContainer changePackageHolder)
Attaches this change package to the given value.

Specified by:
attachToProjectSpace in interface AbstractChangePackage
Parameters:
changePackageHolder - the value to which this change package will be attached to
See Also:
AbstractChangePackage.attachToProjectSpace(org.eclipse.emf.emfstore.internal.server.model.versioning.impl.persistent.ChangePackageContainer)

toAPI

public ESChangePackage toAPI()
Returns the API representation of this change package.

Specified by:
toAPI in interface AbstractChangePackage
Returns:
the API representation of this change package.
See Also:
AbstractChangePackage.toAPI()

apply

public void apply(Project project)
Applies this change package to the given project.

Specified by:
apply in interface AbstractChangePackage
Parameters:
project - the project upon which the change package should be applied
See Also:
AbstractChangePackage.apply(org.eclipse.emf.emfstore.internal.common.model.Project)

apply

public void apply(Project project,
                  boolean forceApplication)
Apply all operations in the change package to the given project. Additional you can force the operations to be applied with illegal operations being ignored.

Specified by:
apply in interface AbstractChangePackage
Parameters:
project - the project
forceApplication - if true, illegal Operations won't stop the other to be applied
See Also:
AbstractChangePackage.apply(org.eclipse.emf.emfstore.internal.common.model.Project, boolean)

save

public void save()
          throws IOException
Save this change package.

Specified by:
save in interface AbstractChangePackage
Throws:
IOException - in case saving fails
See Also:
AbstractChangePackage.save()

get

public AbstractOperation get(int index)
Returns the operation at the given index.

Specified by:
get in interface AbstractChangePackage
Parameters:
index - the requested index
Returns:
the operation corresponding to the given index
See Also:
AbstractChangePackage.get(int)


Copyright © 2016. All Rights Reserved.