|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ibm.retail.AEF.thread.ConditionLock | +--com.ibm.retail.AEF.thread.ObjectDetectorLock
An synchronization mechanism for use with ObjectDetectors.
Field Summary | |
---|---|
protected com.ibm.retail.AEF.automation.ObjectDetector |
detector
|
protected com.ibm.retail.AEF.util.AEFMessage |
msg
|
protected boolean |
objectDetected
|
protected com.ibm.retail.AEF.session.AEFSession |
session
|
protected com.ibm.retail.si.util.AEFException |
unblockException
|
Fields inherited from class com.ibm.retail.AEF.thread.ConditionLock |
---|
action, lock, name, returnIndex, timeout, unblockRuntimeException |
Constructor Summary | |
---|---|
ObjectDetectorLock()
Constructs a ObjectDetectorLock. |
Method Summary | |
---|---|
(package private) static java.lang.String |
copyright()
|
void |
exceptionDetected(com.ibm.retail.si.util.AEFException e)
Called by the ObjectDetector when it throws an AEFException. |
void |
objectDetected()
Called by the ObjectDetector when an object has been created. |
java.lang.Object |
waitForNewObject(java.lang.String name,
com.ibm.retail.AEF.automation.ObjectDetector detector,
int oldInstanceNumber,
int timeout)
Blocks the calling thread on the condition variable or a timeout |
java.lang.Object |
waitForNewObject(java.lang.String name,
com.ibm.retail.AEF.automation.ObjectDetector detector,
int oldInstanceNumber,
int timeout,
boolean ignoreTimeout)
Blocks the calling thread on the condition variable or a timeout |
java.lang.Object |
waitForNewObjectOrError(java.lang.String name,
com.ibm.retail.AEF.automation.ObjectDetector detector,
int oldInstanceNumber,
com.ibm.retail.AEF.automation.Condition[] errorConditions,
boolean immediateEval,
int timeout)
Blocks the calling thread on the condition variable or a timeout |
java.lang.Object |
waitForNewObjectOrError(java.lang.String name,
com.ibm.retail.AEF.automation.ObjectDetector detector,
int oldInstanceNumber,
com.ibm.retail.AEF.automation.Condition[] errorConditions,
boolean immediateEval,
int timeout,
boolean ignoreTimeout)
Blocks the calling thread on the condition variable or a timeout |
Methods inherited from class com.ibm.retail.AEF.thread.ConditionLock |
---|
getLock, getLockOwner, notify, notify, notify, performActionAndWait, performActionAndWait, performActionAndWait, performActionAndWait, wait, wait, wait, wait, wait, wait, wait, wait |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected boolean objectDetected
protected com.ibm.retail.AEF.automation.ObjectDetector detector
protected com.ibm.retail.si.util.AEFException unblockException
protected com.ibm.retail.AEF.util.AEFMessage msg
protected com.ibm.retail.AEF.session.AEFSession session
Constructor Detail |
public ObjectDetectorLock()
Method Detail |
static java.lang.String copyright()
public java.lang.Object waitForNewObject(java.lang.String name, com.ibm.retail.AEF.automation.ObjectDetector detector, int oldInstanceNumber, int timeout) throws AEFException
name
- A debug aid. Give a unique name to the detector lock
such as "wait-for-operator".detector
- If this detector senses an object, the calling thread will be
unblocked.oldInstanceNumber
- Each object detected by the detector has an instance
number. The caller should pass in the prior instance
number from the detector so that if the new object has
been detected prior to entry into this routine, it can
be returned without waiting.timeout
- The number of milliseconds to wait for the object.
AEFException
- Because of the nature of this method, just about any error code could be returned.
public java.lang.Object waitForNewObject(java.lang.String name, com.ibm.retail.AEF.automation.ObjectDetector detector, int oldInstanceNumber, int timeout, boolean ignoreTimeout) throws AEFException
name
- A debug aid. Give a unique name to the detector lock
such as "wait-for-operator".detector
- If this detector senses an object, the calling thread will be
unblocked.oldInstanceNumber
- Each object detected by the detector has an instance
number. The caller should pass in the prior instance
number from the detector so that if the new object has
been detected prior to entry into this routine, it can
be returned without waiting.timeout
- The number of milliseconds to wait for the object.ignoreTimeout
- If true, do not log error message if timeout situation occurs.
In some conditions (e.g., in the ACEApplyDelayedCoupons.wait
ForCoupons() method), the timeout is a nominal value since
there may or may not be any object created
AEFException
- Because of the nature of this method, just about any error code could be returned.
public java.lang.Object waitForNewObjectOrError(java.lang.String name, com.ibm.retail.AEF.automation.ObjectDetector detector, int oldInstanceNumber, com.ibm.retail.AEF.automation.Condition[] errorConditions, boolean immediateEval, int timeout) throws AEFException
name
- A debug aid. Give a unique name to the detector lock
such as "wait-for-operator".detector
- If this detector senses an object, the calling thread will be
unblocked.oldInstanceNumber
- Each object detected by the detector has an instance
number. The caller should pass in the prior instance
number from the detector so that if the new object has
been detected prior to entry into this routine, it can
be returned without waiting.errorConditions
- An array of conditions which will cause the calling thread to unblock
if one of the conditions evaluates to true. These conditions are
considered "error" conditions.immediateEval
- If true, the conditions are evaluated immediately without first
waiting for a property change.timeout
- The number of milliseconds to wait for the object.
AEFException
- Because of the nature of this method, just about any error code could be returned.
public java.lang.Object waitForNewObjectOrError(java.lang.String name, com.ibm.retail.AEF.automation.ObjectDetector detector, int oldInstanceNumber, com.ibm.retail.AEF.automation.Condition[] errorConditions, boolean immediateEval, int timeout, boolean ignoreTimeout) throws AEFException
name
- A debug aid. Give a unique name to the detector lock
such as "wait-for-operator".detector
- If this detector senses an object, the calling thread will be
unblocked.oldInstanceNumber
- Each object detected by the detector has an instance
number. The caller should pass in the prior instance
number from the detector so that if the new object has
been detected prior to entry into this routine, it can
be returned without waiting.errorConditions
- An array of conditions which will cause the calling thread to unblock
if one of the conditions evaluates to true. These conditions are
considered "error" conditions.immediateEval
- If true, the conditions are evaluated immediately without first
waiting for a property change.timeout
- The number of milliseconds to wait for the object.ignoreTimeout
- If true, do not log error message if timeout situation occurs.
In some conditions (e.g., in the ACEApplyDelayedCoupons.wait
ForCoupons() method), the timeout is a nominal value since
there may or may not be any object created
AEFException
- Because of the nature of this method, just about any error code could be returned.
public void objectDetected()
objectDetected
in interface com.ibm.retail.AEF.automation.ObjectDetectorListener
public void exceptionDetected(com.ibm.retail.si.util.AEFException e)
exceptionDetected
in interface com.ibm.retail.AEF.automation.ObjectDetectorListener
e
- The AEFException that was detected.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |