org.jboss.dna.common.collection
Class ThreadSafeProblems

java.lang.Object
  extended by org.jboss.dna.common.collection.AbstractProblems
      extended by org.jboss.dna.common.collection.ThreadSafeProblems
All Implemented Interfaces:
Serializable, Iterable<Problem>, Problems

@ThreadSafe
public class ThreadSafeProblems
extends AbstractProblems

A thread-safe Problems collection. The problems will be returned in the order in which they were encountered.

See Also:
Serialized Form

Constructor Summary
ThreadSafeProblems()
           
 
Method Summary
 boolean hasErrors()
          Determine if there is at least one error in this collection.
 boolean hasInfo()
          Determine if there is at least one informational problem in this collection.
 boolean hasProblems()
          Determine if there are problems in this collection.
 boolean hasWarnings()
          Determine if there is at least one warning in this collection.
 boolean isEmpty()
          Determine if this collection is empty.
 int size()
          Get the number of problems that are in this collection
 
Methods inherited from class org.jboss.dna.common.collection.AbstractProblems
addError, addError, addError, addError, addError, addError, addError, addError, addInfo, addInfo, addInfo, addInfo, addInfo, addInfo, addInfo, addInfo, addWarning, addWarning, addWarning, addWarning, addWarning, addWarning, addWarning, addWarning, iterator
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ThreadSafeProblems

public ThreadSafeProblems()
Method Detail

hasErrors

public boolean hasErrors()
Determine if there is at least one error in this collection.

Specified by:
hasErrors in interface Problems
Overrides:
hasErrors in class AbstractProblems
Returns:
true if there is at least one error in this collection, or false if there are no errors
See Also:
AbstractProblems.hasErrors()

hasProblems

public boolean hasProblems()
Determine if there are problems in this collection.

Specified by:
hasProblems in interface Problems
Overrides:
hasProblems in class AbstractProblems
Returns:
true if there is at least one problem, or false if it is empty
See Also:
AbstractProblems.hasProblems()

hasInfo

public boolean hasInfo()
Determine if there is at least one informational problem in this collection.

Specified by:
hasInfo in interface Problems
Overrides:
hasInfo in class AbstractProblems
Returns:
true if there is at least one informational problem in this collection, or false if there are no informational problems
See Also:
AbstractProblems.hasInfo()

hasWarnings

public boolean hasWarnings()
Determine if there is at least one warning in this collection.

Specified by:
hasWarnings in interface Problems
Overrides:
hasWarnings in class AbstractProblems
Returns:
true if there is at least one warning in this collection, or false if there are no warnings
See Also:
AbstractProblems.hasWarnings()

isEmpty

public boolean isEmpty()
Determine if this collection is empty.

Specified by:
isEmpty in interface Problems
Overrides:
isEmpty in class AbstractProblems
Returns:
true if the there are no problems, or false if there is at least one
See Also:
AbstractProblems.isEmpty()

size

public int size()
Get the number of problems that are in this collection

Specified by:
size in interface Problems
Overrides:
size in class AbstractProblems
Returns:
the number of problems; never negative
See Also:
AbstractProblems.size()


Copyright © 2008-2010 JBoss, a division of Red Hat. All Rights Reserved.