|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.kuka.roboticsAPI.controllerModel.sunrise.FencedArea
public class FencedArea
See IFencedArea.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface com.kuka.roboticsAPI.controllerModel.sunrise.IFencedArea |
|---|
IFencedArea.GateState |
| Constructor Summary | |
|---|---|
FencedArea()
|
|
| Method Summary | |
|---|---|
void |
await(IFencedArea.GateState state)
Waits till the specified state is reached. |
boolean |
await(IFencedArea.GateState state,
long timeout,
TimeUnit unit)
Waits till the specified state is reached. |
com.kuka.common.concurrent.IWaitToken |
closeGate()
Closes the gate. |
void |
dispose()
Does the following: closes the gate, interrupts all threads which are currently waiting at the gate. |
void |
enterArea()
This method has to be called when a thread wants to enter the area. |
boolean |
isGateClosed()
States if the gate is closed while the threads are made to wait at the gate. |
void |
leaveArea()
This method has to be called as soon as a threads leaves the area. |
void |
openGate()
Open the gate and allow all new arriving and waiting threads to enter the area. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public FencedArea()
| Method Detail |
|---|
public void openGate()
IFencedArea
openGate in interface IFencedAreapublic com.kuka.common.concurrent.IWaitToken closeGate()
IFencedArea
Please note:
The gate is only closed if it is currently open.
closeGate in interface IFencedAreaIWaitToken which can be used to wait till the area is empty. If the gate is not open when the
method is called, null is returned.
public void enterArea()
throws InterruptedException
IFencedArea
enterArea in interface IFencedAreaInterruptedException - Exception which is thrown when the thread is interrupted while waiting for the permission to enter
the area.public void leaveArea()
IFencedArea
leaveArea in interface IFencedArea
public void await(IFencedArea.GateState state)
throws InterruptedException
IFencedArea
await in interface IFencedAreastate - to wait for.
InterruptedException - if the waiting process was interrupted.
public boolean await(IFencedArea.GateState state,
long timeout,
TimeUnit unit)
throws InterruptedException
IFencedArea
await in interface IFencedAreastate - to wait for.timeout - States how long to wait for the state to reach.unit - of the timeout argument.
true if the state is reached and false if the time is up before the state is reached.
InterruptedException - if the waiting process was interrupted.public boolean isGateClosed()
IFencedArea
isGateClosed in interface IFencedAreatrue if gate is closed while the threads have to wait at the gate, otherwise false.public void dispose()
IFencedArea
dispose in interface IFencedAreapublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||