COSMOS ${releaseVersion} resource-modeling Project
Public API Specification

org.eclipse.cosmos.rm.repository.provisional.operations
Interface ISMLOperation

All Known Subinterfaces:
ISMLExportOperation, ISMLImportOperation, ISMLValidateOperation

public interface ISMLOperation

Represents an operation that can be performed on a repository. ISMLRepository.getSupportedOperations() should be used to retrieve the set of operations that a repository will support.


Method Summary
 void addArgument(java.lang.Object argument)
          Adds an argument to this operation.
 void addProgressListener(IProgressListener listener)
          Adds listener to the list of operation progress listeners that are tracked by this operation
 java.lang.String getId()
          Returns the unique ID of this operation.
 void removeProgressListener(IProgressListener listener)
          Removes listener from the list of progress listener.
 void run()
          Executes this operation.
 void setArguments(java.lang.Object[] arguments)
          Sets the arguments of this operation.
 

Method Detail

getId

java.lang.String getId()
Returns the unique ID of this operation. The ID is expected to be unique amongst the supported operations of a repository

Returns:
The unique ID of this operation

setArguments

void setArguments(java.lang.Object[] arguments)
                  throws java.lang.IllegalArgumentException
Sets the arguments of this operation. The type of the argument is a contract between the implementation of the operation and the consuming client.

Parameters:
arguments - The arguments of this operation
Throws:
java.lang.IllegalArgumentException - If the argument type is not what is expected by the underlying implementation

addArgument

void addArgument(java.lang.Object argument)
                 throws java.lang.IllegalArgumentException
Adds an argument to this operation. The type of the argument is a contract between the implementation of the operation and the consuming client.

Parameters:
argument - The argument to be added
Throws:
java.lang.IllegalArgumentException - If the argument type is not what is expected by the underlying implementation

addProgressListener

void addProgressListener(IProgressListener listener)
Adds listener to the list of operation progress listeners that are tracked by this operation

Parameters:
listener - The listener to be added

removeProgressListener

void removeProgressListener(IProgressListener listener)
Removes listener from the list of progress listener. This method has to effect if listener is not registered with this operation

Parameters:
listener - The listener to be removed

run

void run()
         throws RepositoryOperationException
Executes this operation.

Throws:
RepositoryOperationException - In case of any error

COSMOS ${releaseVersion} resource-modeling Project
Public API Specification