com.atlassian.jira.issue.util
Class IssueObjectIssuesIterable

java.lang.Object
  extended by com.atlassian.jira.issue.util.IssueObjectIssuesIterable
All Implemented Interfaces:
IssuesIterable, EnclosedIterable<Issue>, Sized

public class IssueObjectIssuesIterable
extends Object
implements IssuesIterable


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.atlassian.jira.util.collect.EnclosedIterable
EnclosedIterable.Functions, EnclosedIterable.ListResolver<T>
 
Constructor Summary
IssueObjectIssuesIterable(Collection<? extends Issue> issueObjects)
           
 
Method Summary
 void foreach(Consumer<Issue> sink)
          Apply the sink to all elements in the Collection.
 boolean isEmpty()
           
 int size()
           
 String toString()
          Return a user friendly message that identifies which issues this iterable holds.
protected  Issue transform(Object o)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IssueObjectIssuesIterable

public IssueObjectIssuesIterable(Collection<? extends Issue> issueObjects)
Method Detail

transform

protected Issue transform(Object o)

foreach

public final void foreach(Consumer<Issue> sink)
Description copied from interface: EnclosedIterable
Apply the sink to all elements in the Collection.

Specified by:
foreach in interface EnclosedIterable<Issue>

size

public int size()
Specified by:
size in interface EnclosedIterable<Issue>
Specified by:
size in interface Sized
Returns:
the likely size of the objects passed into the sink in EnclosedIterable.foreach(Consumer). Be careful depending on this size being exact, as in many cases its best efforts value or may be unstable due to concurrent changes.

isEmpty

public boolean isEmpty()
Specified by:
isEmpty in interface EnclosedIterable<Issue>
Specified by:
isEmpty in interface Sized
Returns:
true if the there is no data behind it.

toString

public String toString()
Description copied from interface: IssuesIterable
Return a user friendly message that identifies which issues this iterable holds. If there is a problem, this method is used to log what issues are affected.

For example, if there is a problem locking the Lucene index this method is used to log which issues could not be reindexed.

Hence, it is important to provide a useful implementation for this method.

Specified by:
toString in interface IssuesIterable
Overrides:
toString in class Object


Copyright © 2002-2014 Atlassian. All Rights Reserved.