All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class pinball.buffer.Buffer

java.lang.Object
   |
   +----pinball.buffer.Buffer

public class Buffer
extends Object
The buffer. Has a information buffer containing data collected by the frame. The buffers are stored as a circular linked list.

See Also:
BuffInfo

Variable Index

 o id
The buffer's id.
 o info
The information of the buffer.
 o lock
The lock for the buffer.
 o next
The next buffer.
 o recordable
Is this buffer able to be recorded.
 o skipped
Indicates if the buffer was skipped in by a thread.
 o strategyUnlock
The strategy's unlock status.

Constructor Index

 o Buffer()
For extended use.
 o Buffer(int)
Set's the id of the buffer.
 o Buffer(int, BufferInfo, Watcher)
Set's the id of the buffer.

Method Index

 o canRecord()
Returns recordable status.
 o clone()
Used to clone the buffer.
 o id()
Get the buffer's id.
 o info()
Get the buffer info.
 o info(BufferInfo)
Set the information.
 o lock()
The mutex for the buffer in the processing threads.
 o next()
Get the next buffer.
 o next(Buffer)
Set the next buffer.
 o recordable()
The buffer can be recorded.
 o skipped()
Was the buffer skipped by a thread.
 o skipped(boolean)
Set skip status.
 o strategyUnlock(String)
Get's the strategy unlock status.

Variables

 o lock
 private Watcher lock
The lock for the buffer.

 o next
 private transient Buffer next
The next buffer.

 o info
 private BufferInfo info
The information of the buffer.

 o id
 private int id
The buffer's id.

 o strategyUnlock
 private String strategyUnlock
The strategy's unlock status. Determines whether the buffer was unlocked naturally or forced unlocked. Naturally means that it was unlocked properly. Forced means that it never got the signal to unlock and was forced unlocked by another buffer being unlocked. This is used in network play, should an unlock command be lost in the network.

 o skipped
 private boolean skipped
Indicates if the buffer was skipped in by a thread.

 o recordable
 private boolean recordable
Is this buffer able to be recorded.

Constructors

 o Buffer
 public Buffer(int id)
Set's the id of the buffer.

Parameters:
id - the id for this buffer.
 o Buffer
 public Buffer()
For extended use.

 o Buffer
 public Buffer(int id,
               BufferInfo info,
               Watcher lock)
Set's the id of the buffer.

Parameters:
id - the id for this buffer.
info - the information of the buffer.
lock - The lock for the buffer. Used in clone.

Methods

 o skipped
 public boolean skipped()
Was the buffer skipped by a thread.

Returns:
skipped status.
 o skipped
 public void skipped(boolean s)
Set skip status.

Parameters:
s - skip status.
 o clone
 public Object clone()
Used to clone the buffer.

Returns:
clone of buffers.
Overrides:
clone in class Object
 o next
 public void next(Buffer buffer)
Set the next buffer.

Parameters:
buffer - The next buffer.
 o next
 public Buffer next()
Get the next buffer.

Parameters:
the - next buffer.
 o lock
 public Watcher lock()
The mutex for the buffer in the processing threads.

Returns:
the lock for the buffer.
 o info
 public BufferInfo info()
Get the buffer info.

Returns:
the information buffer.
 o info
 public void info(BufferInfo i)
Set the information.

Parameters:
i - information buffer to be set.
 o id
 public int id()
Get the buffer's id.

Returns:
the id of this buffer.
 o strategyUnlock
 public void strategyUnlock(String u)
Get's the strategy unlock status.

Returns:
strategy unlock status.
 o recordable
 public void recordable()
The buffer can be recorded.

 o canRecord
 public boolean canRecord()
Returns recordable status.

Returns:
Status of buffer's recordablity.

All Packages  Class Hierarchy  This Package  Previous  Next  Index