Mobile Tools for Java
Release 1.0

org.eclipse.mtj.core.nature
Class BuildSpecManipulator

java.lang.Object
  extended by org.eclipse.mtj.core.nature.BuildSpecManipulator

public class BuildSpecManipulator
extends Object

Handles changes to the project builder command list.


Constructor Summary
BuildSpecManipulator(IProject project)
          Construct a new command handler
 
Method Summary
 void addBuilderAfter(String relativeBuilder, String builder, Map<?,?> arguments)
          Add a new builder after the specified build.
 void addBuilderBefore(String relativeBuilder, String builder, Map<?,?> arguments)
          Add a new builder before the specified build.
 void commitChanges(IProgressMonitor monitor)
          Commit any changes made to the list of commands in the build specification.
 boolean hasArguments(String builder)
          Return a boolean indicating whether the specified builder has arguments.
 boolean hasBuilder(String builder)
          Return a boolean indicating whether the command list contains the specified builder.
 int indexOf(String builder)
          Find the specified builder in the list of builders and return the index.
 void removeBuilder(String builder)
          Remove the builder with the specified identifier.
 void replaceBuilder(String builder, Map<?,?> arguments)
          Replaces the specified builder with a new command and the specified arguments.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BuildSpecManipulator

public BuildSpecManipulator(IProject project)
                     throws CoreException
Construct a new command handler

Throws:
CoreException
Method Detail

addBuilderAfter

public void addBuilderAfter(String relativeBuilder,
                            String builder,
                            Map<?,?> arguments)
                     throws CoreException
Add a new builder after the specified build.

Parameters:
relativeBuilder -
builder -
arguments -
Throws:
CoreException

addBuilderBefore

public void addBuilderBefore(String relativeBuilder,
                             String builder,
                             Map<?,?> arguments)
                      throws CoreException
Add a new builder before the specified build.

Parameters:
relativeBuilder -
builder -
arguments -
Throws:
CoreException

commitChanges

public void commitChanges(IProgressMonitor monitor)
                   throws CoreException
Commit any changes made to the list of commands in the build specification.

Parameters:
monitor -
Throws:
CoreException

hasArguments

public boolean hasArguments(String builder)
                     throws CoreException
Return a boolean indicating whether the specified builder has arguments.

Parameters:
builder -
Returns:
Throws:
CoreException

hasBuilder

public boolean hasBuilder(String builder)
                   throws CoreException
Return a boolean indicating whether the command list contains the specified builder.

Parameters:
builder -
Returns:
Throws:
CoreException

indexOf

public int indexOf(String builder)
            throws CoreException
Find the specified builder in the list of builders and return the index. Return -1 if not found.

Parameters:
builder -
Returns:
Throws:
CoreException

replaceBuilder

public void replaceBuilder(String builder,
                           Map<?,?> arguments)
                    throws CoreException
Replaces the specified builder with a new command and the specified arguments. Does nothing if the specified builder could not be found.

Parameters:
builder -
arguments -
Throws:
CoreException

removeBuilder

public void removeBuilder(String builder)
                   throws CoreException
Remove the builder with the specified identifier. Does nothing if the builder is not in the list.

Parameters:
builder -
Throws:
CoreException

Mobile Tools for Java
Release 1.0