org.eclipse.mylar.tasks.core
Class RepositoryOperation

java.lang.Object
  extended by org.eclipse.mylar.tasks.core.RepositoryOperation
All Implemented Interfaces:
java.io.Serializable

public class RepositoryOperation
extends java.lang.Object
implements java.io.Serializable

A representation of an operation that can be done to the bug when it is submitted

Author:
Shawn Minto
See Also:
Serialized Form

Field Summary
private  boolean hasOptions
          Flag for if we have any options or not
private  java.lang.String inputName
           
private  java.lang.String inputValue
           
private  boolean isChecked
          Whether this is to be checked or not
private  boolean isInput
           
private  java.lang.String knob_name
          The name of the value for the knob attribute
private  java.lang.String op_name
          The name of the operation (text that we display)
private  java.lang.String op_sel
          The option that is selected
private  java.lang.String optionName
          The name of the option that can be chosen
private  java.util.List<java.lang.String> optionNames
          List of option names
private  java.util.Map<java.lang.String,java.lang.String> options
          Map of options and their names
private static long serialVersionUID
          Comment for serialVersionUID
 
Constructor Summary
RepositoryOperation(java.lang.String knobName, java.lang.String operationName)
          Constructor
 
Method Summary
 void addOption(java.lang.String name, java.lang.String value)
          Add an option value to the operation
 java.lang.String getInputName()
           
 java.lang.String getInputValue()
           
 java.lang.String getKnobName()
          Get the knob name
 java.lang.String getOperationName()
          Get the display name
 java.lang.String getOptionName()
          Get the name for the option attribute
 java.util.List<java.lang.String> getOptionNames()
          Get the list of option names for this operation
 java.lang.String getOptionSelection()
          Get the selected option
 java.lang.String getOptionValue(java.lang.String option)
          Get the value for an option from its name
 boolean hasOptions()
          Check if this has any options
 boolean isChecked()
          Check if this is to be checked or not
 boolean isInput()
           
 void setChecked(boolean b)
          Set whether this option is to be checked or not
 void setInputName(java.lang.String inputName)
           
 void setInputValue(java.lang.String inputValue)
           
 void setOptionSelection(java.lang.String string)
          Set the selected option
 void setUpOptions(java.lang.String optionName)
          Set up this operation to have options
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
Comment for serialVersionUID

See Also:
Constant Field Values

knob_name

private java.lang.String knob_name
The name of the value for the knob attribute


optionName

private java.lang.String optionName
The name of the option that can be chosen


optionNames

private java.util.List<java.lang.String> optionNames
List of option names


options

private java.util.Map<java.lang.String,java.lang.String> options
Map of options and their names


hasOptions

private boolean hasOptions
Flag for if we have any options or not


op_name

private java.lang.String op_name
The name of the operation (text that we display)


op_sel

private java.lang.String op_sel
The option that is selected


isChecked

private boolean isChecked
Whether this is to be checked or not


isInput

private boolean isInput

inputName

private java.lang.String inputName

inputValue

private java.lang.String inputValue
Constructor Detail

RepositoryOperation

public RepositoryOperation(java.lang.String knobName,
                           java.lang.String operationName)
Constructor

Parameters:
knobName - The name of the value for the knob attribute
operationName - The display text for the operation
Method Detail

getKnobName

public java.lang.String getKnobName()
Get the knob name

Returns:
The knob name

getOperationName

public java.lang.String getOperationName()
Get the display name

Returns:
The display name

hasOptions

public boolean hasOptions()
Check if this has any options

Returns:
True if there are option values

setUpOptions

public void setUpOptions(java.lang.String optionName)
Set up this operation to have options

Parameters:
optionName - The name for the option attribute

addOption

public void addOption(java.lang.String name,
                      java.lang.String value)
Add an option value to the operation

Parameters:
name - The name of the option
value - The value of the option

getOptionNames

public java.util.List<java.lang.String> getOptionNames()
Get the list of option names for this operation

Returns:
The list of option names

getOptionSelection

public java.lang.String getOptionSelection()
Get the selected option

Returns:
The selected option name

setOptionSelection

public void setOptionSelection(java.lang.String string)
Set the selected option

Parameters:
string - The name of the selected option

isChecked

public boolean isChecked()
Check if this is to be checked or not

Returns:
True if this is to be checked at the start

setChecked

public void setChecked(boolean b)
Set whether this option is to be checked or not

Parameters:
b - True if it is to be checked

getOptionName

public java.lang.String getOptionName()
Get the name for the option attribute

Returns:
The option name

getOptionValue

public java.lang.String getOptionValue(java.lang.String option)
Get the value for an option from its name

Parameters:
option - The name of the option
Returns:
The value of the option

isInput

public boolean isInput()

getInputName

public java.lang.String getInputName()

setInputName

public void setInputName(java.lang.String inputName)

getInputValue

public java.lang.String getInputValue()

setInputValue

public void setInputValue(java.lang.String inputValue)