cz.cuni.jagrlib
Interface PieceReference


public interface PieceReference

Abstract Piece-referencing interface. Can be used for 1D and 2D Piece-arrays, too.

Since:
0.11
See Also:
PieceReference.java, Piece

Method Summary
 Piece getPiece(java.lang.String iface)
          Simple Piece de-referencing.
 Piece getPiece(java.lang.String iface, int i)
          1D Piece-array fetching.
 Piece getPiece(java.lang.String iface, int i, int j)
          2D Piece-array fetching.
 

Method Detail

getPiece

Piece getPiece(java.lang.String iface)
               throws BadInterfaceException
Simple Piece de-referencing.

Parameters:
iface - Fully-qualified interface name or null if no checking is necessary.
Returns:
The requested Piece-reference.
Throws:
BadInterfaceException - If the Piece doesn't implemented the requested interface.
See Also:
getPiece(String,int), getPiece(String,int,int)

getPiece

Piece getPiece(java.lang.String iface,
               int i)
               throws BadInterfaceException
1D Piece-array fetching.

Parameters:
iface - Fully-qualified interface name or null if no checking is necessary.
i - Piece-index.
Returns:
The requested Piece-reference.
Throws:
BadInterfaceException - If the Piece doesn't implemented the requested interface.
See Also:
getPiece(String), getPiece(String,int,int)

getPiece

Piece getPiece(java.lang.String iface,
               int i,
               int j)
               throws BadInterfaceException
2D Piece-array fetching.

Parameters:
iface - Fully-qualified interface name or null if no checking is necessary.
i - Primary Piece-index.
j - Secondary Piece-index.
Returns:
The requested Piece-reference.
Throws:
BadInterfaceException - If the Piece doesn't implemented the requested interface.
See Also:
getPiece(String), getPiece(String,int)