Friends | List of all members
cwchess::Type Class Reference

A chess piece type. More...

#include <Type.h>

Inheritance diagram for cwchess::Type:
Inheritance graph

Public Member Functions

 Type (void)
 Construct an uninitialized Type.
 Type (Type const& type)
 Type (TypeData type)
 Construct a Type from a constant.
Assignment operators
Type&  operator= (Type const& type)
 Assign from another Type.
Type&  operator= (TypeData type)
 Assign from a constant.
bool is_a_slider (void) const
 Returns TRUE if the type is a bishop, rook or queen.
bool is_a_rookmover (void) const
 Returns TRUE if the type is a rook or queen.
bool is_a_bishopmover (void) const
 Returns TRUE if the type is a bishop or queen.
uint8_t operator() (void) const
 Return the underlaying integral value.


class Code
Comparison operators
bool operator== (Type const& t1, Type const& t2)
bool operator== (Type const& t1, TypeData t2)
bool operator== (TypeData t1, Type const& t2)
bool operator!= (Type const& t1, Type const& t2)
bool operator!= (Type const& t1, TypeData t2)
bool operator!= (TypeData t1, Type const& t2)

Additional Inherited Members

- Protected Attributes inherited from cwchess::TypeData
uint8_t M_bits
 00000STT, where STT is the type. If S == 1 then the piece is a slider.

Detailed Description

A chess piece type.

This class represents a chess piece type.

The class Code is a friend of this class.

Definition at line 87 of file Type.h.

The documentation for this class was generated from the following file:

Copyright © 2006 - 2010 Carlo Wood.  All rights reserved.