org.kohsuke.jnt
Class JNIssue.Activity

java.lang.Object
  extended by org.kohsuke.jnt.JNIssue.Item<JNIssue.Activity>
      extended by org.kohsuke.jnt.JNIssue.Activity
All Implemented Interfaces:
Comparable<JNIssue.Item<JNIssue.Activity>>
Direct Known Subclasses:
JNIssue.CreationActivity, JNIssue.UpdateActivity
Enclosing class:
JNIssue

public abstract class JNIssue.Activity
extends JNIssue.Item<JNIssue.Activity>


Constructor Summary
JNIssue.Activity()
           
 
Method Summary
abstract  JNUser getAuthor()
          Gets the user who performed this activity.
 IssueStatus getCurrentStatus()
          Gets the status of the issue right after this activity.
abstract  IssueField getField()
          Gets the field that has changed.
abstract  String getNewValue()
          New value after the change.
abstract  String getOldValue()
          Old value before the change.
abstract  Calendar getTimestamp()
          Gets the timestamp when this item was created.
 boolean isUpdate()
          Returns true if this activity is an update activity and not the creation activity.
 
Methods inherited from class org.kohsuke.jnt.JNIssue.Item
compareTo, getAge, getNext, getParent, getPrev
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JNIssue.Activity

public JNIssue.Activity()
Method Detail

getAuthor

public abstract JNUser getAuthor()
Gets the user who performed this activity.

Specified by:
getAuthor in class JNIssue.Item<JNIssue.Activity>

getTimestamp

public abstract Calendar getTimestamp()
Description copied from class: JNIssue.Item
Gets the timestamp when this item was created.

Specified by:
getTimestamp in class JNIssue.Item<JNIssue.Activity>

getField

public abstract IssueField getField()
Gets the field that has changed.

Returns:
Null if this is the creation activity.

getOldValue

public abstract String getOldValue()
Old value before the change.

Returns:
Can be empty string but never null for update activity. For creation activity, null.

getNewValue

public abstract String getNewValue()
New value after the change. Value can be parsed with methods like IssueStatus.valueOf(String), IssueResolution.valueOf(String), IssueType.valueOf(String), and Priority.valueOf(String).

Returns:
Can be empty string but never null for update activity. For creation activity, null.

isUpdate

public boolean isUpdate()
Returns true if this activity is an update activity and not the creation activity.


getCurrentStatus

public IssueStatus getCurrentStatus()
Gets the status of the issue right after this activity.

That is, if this activity updates the status, this method returns that value, and otherwise it returns the status of the issue when the activity happened.



Copyright © 2003-2008 Kohsuke Kawaguchi. All Rights Reserved.