com.pyxis.greenhopper.jira.fields
Class AbstractIssueField

java.lang.Object
  extended by com.pyxis.greenhopper.jira.fields.AbstractIssueField
All Implemented Interfaces:
IssueField
Direct Known Subclasses:
AbstractDateField, AbstractMultiSelectField, AbstractSelectField, AbstractTextAreaField, AbstractTextField, NotSupported, Spacer

public abstract class AbstractIssueField
extends java.lang.Object
implements IssueField


Field Summary
static java.lang.String GREENHOPPER_PLUGIN
           
static java.lang.String GROUP_PICKER
           
protected  java.lang.String id
           
protected  java.lang.Long idLong
           
protected  java.lang.String label
           
protected  org.apache.log4j.Logger log
           
static java.lang.String MULTI_GROUP_PICKER
           
static java.lang.String MULTI_SELECT
           
static java.lang.String MULTI_USER_PICKER
           
static java.lang.String NUMBER
           
static java.lang.String SELECT
           
static java.lang.String TEXT
           
static java.lang.String TEXT_AREA
           
static java.lang.String TEXT_FIELD
           
static java.lang.String USER_PICKER
           
 
Constructor Summary
AbstractIssueField(java.lang.String id, java.lang.Long idLong, java.lang.String label)
           
AbstractIssueField(java.lang.String id, java.lang.String label)
           
 
Method Summary
protected abstract  void doValidate(BoardIssue boardIssue, java.lang.String newValue)
           
 boolean equals(java.lang.Object o)
           
 java.lang.String getCssType()
          Temporary hack while transitioning the field VMs to JSON.
 java.lang.String getId()
           
 java.lang.Long getIdAsLong()
           
 java.lang.String getJsonDisplayTemplate()
          Temporary hack while transitioning the field VMs to JSON.
 java.lang.String getLabel()
          This must match the JIRA field name since it's used for JQL resolution!
 java.lang.String getLink(BoardIssue boardIssue, java.lang.String value)
           
 java.lang.String getTransitionTemplate()
           
 java.lang.String getUpdateTemplate()
           
 int hashCode()
           
 boolean isClickable(BoardIssue issue)
           
 boolean isCorner(BoardIssue boardIssue)
           
 boolean isCustomField()
           
 void validate(BoardIssue boardIssue, java.lang.String newValue)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.pyxis.greenhopper.jira.fields.IssueField
canEdit, getCreateTemplate, getDefaultDisplayValue, getDefaultValue, getDisplayTemplate, getDisplayValue, getEditTemplate, getInputType, getTooltipValue, getValue, getValueFromString, lines, updateValue, weight
 

Field Detail

log

protected final org.apache.log4j.Logger log

NUMBER

public static final java.lang.String NUMBER
See Also:
Constant Field Values

TEXT

public static final java.lang.String TEXT
See Also:
Constant Field Values

TEXT_FIELD

public static final java.lang.String TEXT_FIELD
See Also:
Constant Field Values

TEXT_AREA

public static final java.lang.String TEXT_AREA
See Also:
Constant Field Values

SELECT

public static final java.lang.String SELECT
See Also:
Constant Field Values

MULTI_SELECT

public static final java.lang.String MULTI_SELECT
See Also:
Constant Field Values

USER_PICKER

public static final java.lang.String USER_PICKER
See Also:
Constant Field Values

MULTI_USER_PICKER

public static final java.lang.String MULTI_USER_PICKER
See Also:
Constant Field Values

GROUP_PICKER

public static final java.lang.String GROUP_PICKER
See Also:
Constant Field Values

MULTI_GROUP_PICKER

public static final java.lang.String MULTI_GROUP_PICKER
See Also:
Constant Field Values

GREENHOPPER_PLUGIN

public static final java.lang.String GREENHOPPER_PLUGIN
See Also:
Constant Field Values

id

protected java.lang.String id

idLong

protected java.lang.Long idLong

label

protected java.lang.String label
Constructor Detail

AbstractIssueField

public AbstractIssueField(java.lang.String id,
                          java.lang.String label)

AbstractIssueField

public AbstractIssueField(java.lang.String id,
                          java.lang.Long idLong,
                          java.lang.String label)
Method Detail

getLabel

public java.lang.String getLabel()
Description copied from interface: IssueField
This must match the JIRA field name since it's used for JQL resolution!

Specified by:
getLabel in interface IssueField

getId

public java.lang.String getId()
Specified by:
getId in interface IssueField

getIdAsLong

public java.lang.Long getIdAsLong()
Specified by:
getIdAsLong in interface IssueField
Returns:
the Long id of the field, or null if not supported by the field implementation

getCssType

public java.lang.String getCssType()
Temporary hack while transitioning the field VMs to JSON. We need to separate the type and CSS class, once all fields are migrated, this can be deleted.

Specified by:
getCssType in interface IssueField

getJsonDisplayTemplate

public java.lang.String getJsonDisplayTemplate()
Temporary hack while transitioning the field VMs to JSON. Once all fields have JSON templates, this can be deleted.

Specified by:
getJsonDisplayTemplate in interface IssueField

getTransitionTemplate

public java.lang.String getTransitionTemplate()

getUpdateTemplate

public java.lang.String getUpdateTemplate()
Specified by:
getUpdateTemplate in interface IssueField

validate

public void validate(BoardIssue boardIssue,
                     java.lang.String newValue)
              throws GreenHopperException
Specified by:
validate in interface IssueField
Throws:
GreenHopperException

isClickable

public boolean isClickable(BoardIssue issue)
Specified by:
isClickable in interface IssueField

getLink

public java.lang.String getLink(BoardIssue boardIssue,
                                java.lang.String value)
Specified by:
getLink in interface IssueField

isCustomField

public boolean isCustomField()
Specified by:
isCustomField in interface IssueField

isCorner

public boolean isCorner(BoardIssue boardIssue)
Specified by:
isCorner in interface IssueField

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

doValidate

protected abstract void doValidate(BoardIssue boardIssue,
                                   java.lang.String newValue)
                            throws GreenHopperException
Throws:
GreenHopperException


Copyright © 2007-2013 Atlassian. All Rights Reserved.