org.eclipse.emf.emfstore.internal.server.model.versioning
Interface AbstractChangePackage

All Superinterfaces:
org.eclipse.emf.ecore.EObject, org.eclipse.emf.common.notify.Notifier
All Known Subinterfaces:
ChangePackage, ChangePackageProxy, FileBasedChangePackage
All Known Implementing Classes:
ChangePackageImpl, ChangePackageProxyImpl, FileBasedChangePackageImpl

public interface AbstractChangePackage
extends org.eclipse.emf.ecore.EObject

A representation of the model object 'Abstract Change Package'.

The following features are supported:

See Also:
VersioningPackage.getAbstractChangePackage()

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.
 void clear()
          Clears all operations from this change package.
 AbstractOperation get(int index)
          Returns the operation at the given index.
 LogMessage getLogMessage()
          Returns the value of the 'Log Message' containment reference.
 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 setLogMessage(LogMessage value)
          Sets the value of the ' Log Message' containment reference.
 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.
 
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
 

Method Detail

getLogMessage

LogMessage getLogMessage()
Returns the value of the 'Log Message' containment reference.

If the meaning of the 'Log Message' containment reference isn't clear, there really should be more of a description here...

Returns:
the value of the 'Log Message' containment reference.
See Also:
setLogMessage(LogMessage), VersioningPackage.getAbstractChangePackage_LogMessage()

setLogMessage

void setLogMessage(LogMessage value)
Sets the value of the ' Log Message' containment reference.

Parameters:
value - the new value of the 'Log Message' containment reference.
See Also:
getLogMessage()

add

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

Parameters:
operation - the operation to be added

addAll

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

Parameters:
operations - the operations to be added

reverse

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

Returns:
the reversed change packages

size

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

Returns:
the number of operations contained in this change package

leafSize

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

Returns:
the number of leaf operations contained in this change package

operations

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

Returns:
a handle that enables iterating through all operations of this change package

reversedOperations

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.

Returns:
a handle that enables iterating through all operations of this change package

isEmpty

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

Returns:
true, if this change package is empty, false otherwise

removeAtEnd

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

Parameters:
n - the number of operations to be removed
Returns:
the removed operations

clear

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


attachToProjectSpace

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

Parameters:
changePackageHolder - the value to which this change package will be attached to

toAPI

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

Returns:
the API representation of this change package.

apply

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

Parameters:
project - the project upon which the change package should be applied

apply

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.

Parameters:
project - the project
forceApplication - if true, illegal Operations won't stop the other to be applied

save

void save()
          throws IOException
Save this change package.

Throws:
IOException - in case saving fails

get

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

Parameters:
index - the requested index
Returns:
the operation corresponding to the given index


Copyright © 2016. All Rights Reserved.