com.atlassian.jira.webtest.framework.core.condition
Class AbstractTimedCondition
java.lang.Object
com.atlassian.jira.webtest.framework.core.AbstractPollingQuery
com.atlassian.jira.webtest.framework.core.condition.AbstractTimedCondition
- All Implemented Interfaces:
- ClockAware, TimedCondition, PollingQuery
- Direct Known Subclasses:
- AbstractSeleniumTimedCondition
@NotThreadSafe
public abstract class AbstractTimedCondition
- extends AbstractPollingQuery
- implements TimedCondition, ClockAware
Abstract condition that implements by(long)
in terms of
TimedCondition.now()
(to implement by derived classes) and a configured interval between
attempts to evaluate TimedCondition.now()
.
- Since:
- v4.3
Method Summary |
boolean |
by(long timeout)
Evaluate the condition by given timeout. |
boolean |
byDefaultTimeout()
Evaluate the condition by a timeout deemed default by the condition in the given test context. |
com.atlassian.core.util.Clock |
clock()
Clock used by this instance. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.atlassian.jira.webtest.framework.core.condition.TimedCondition |
now |
AbstractTimedCondition
protected AbstractTimedCondition(com.atlassian.core.util.Clock clock,
long defTimeout,
long interval)
AbstractTimedCondition
protected AbstractTimedCondition(long defTimeout,
long interval)
AbstractTimedCondition
protected AbstractTimedCondition(PollingQuery other)
by
public final boolean by(long timeout)
- Description copied from interface:
TimedCondition
- Evaluate the condition by given timeout. That is, return
true
as soon as the
condition is true
, otherwise return false when the given timeout expires.
- Specified by:
by
in interface TimedCondition
- Parameters:
timeout
- timeout in milliseconds (must be greater than 0)
- Returns:
true
, if the underlying condition evaluates to true
before the timeout
expires
byDefaultTimeout
public final boolean byDefaultTimeout()
- Description copied from interface:
TimedCondition
- Evaluate the condition by a timeout deemed default by the condition in the given test context.
- Specified by:
byDefaultTimeout
in interface TimedCondition
- Returns:
true
, if the underlying condition evaluates to true
before the default timeout
expires
clock
public com.atlassian.core.util.Clock clock()
- Description copied from interface:
ClockAware
- Clock used by this instance.
- Specified by:
clock
in interface ClockAware
- Returns:
- clock
Copyright © 2002-2012 Atlassian. All Rights Reserved.