Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members  

TFuelScoop Class Reference

TFuelScoop represents the fuel scoop for a ship. More...

#include <item.h>

Inheritance diagram for TFuelScoop:

Inheritance graph
[legend]
Collaboration diagram for TFuelScoop:

Collaboration graph
[legend]
List of all members.

Public Methods

 TFuelScoop ()
 TFuelScoop (const TFuelScoop &OldFuelScoop)
virtual ~TFuelScoop ()
virtual bool load (TDataPackageList *in)
virtual bool save (TDataPackageList *out) const
virtual TItem::tItemType getItemType () const
virtual void setScoopCapacity (const int2 Capacity)
virtual int2 getScoopCapacity () const
virtual bool operator== (const TFuelScoop &FuelScoop) const
virtual TFuelScoop & operator= (const TFuelScoop &FuelScoop)

Protected Attributes

int2 fScoopCapacity

Detailed Description

TFuelScoop represents the fuel scoop for a ship.

Author:
Ralf Laue
Version:
Id:
item.h,v 1.34 2002/04/02 22:33:08 prolator Exp
See also:
TShipDesign
The class TFuelScoop is derived from TItem and can therefore be put on a ship design. TFuelScoop represents the fuel scoop of a ship. As all other items it has mass, volume and surface area. Additionally it has value for its ability to collect fuel during flight. With increasing tech level this ability should increase. How this is exactly handled and how much fuel it can collect is up to rule set/battle engine and of no direct concern of TFuleScoop


Constructor & Destructor Documentation

TFuelScoop::TFuelScoop  
 

This constructor generates a new TFuelScoop object with all properties resetted. This means you have to set all properties like name and mass afterwards with help of the respective set<something> methods.

TFuelScoop::TFuelScoop const TFuelScoop &    OldFuelScoop
 

This constructor creates also a new fuel scoop, but the attributes are copied from the fuel scoop given in OldFuelScoop. Mostly implemented to provide a copy constructor.

Parameters:
OldFuelScoop  the fuel scoop which shall be copied

virtual TFuelScoop::~TFuelScoop   [virtual]
 

Destructs the object. Has nothing else to do, because no memory has to be freed or similar stuff.


Member Function Documentation

virtual TItem::tItemType TFuelScoop::getItemType   const [virtual]
 

The method getItemType returns the type of the item, in this case TItem::FUELSCOOP for fuel scoop.

Returns:
TItem::FUELSCOOP

Reimplemented from TItem.

virtual int2 TFuelScoop::getScoopCapacity   const [virtual]
 

With the method getScoopCapacity you can the capacity of the scoop to collect fuel.

Returns:
the fuel scoop's capacity collecting capacity

virtual bool TFuelScoop::load TDataPackageList   in [virtual]
 

The method Load loads a TFuelScoop object from the data packages in the list.

Parameters:
in  the list of data packages
Returns:
true means that everything was loaded correctly, otherwise this method will return false.
See also:
TLinkable

Reimplemented from TItem.

virtual TFuelScoop& TFuelScoop::operator= const TFuelScoop &    FuelScoop [virtual]
 

This is the assignment operator for TFuelScoop.

virtual bool TFuelScoop::operator== const TFuelScoop &    FuelScoop const [virtual]
 

With the method operator== you can compare two TFuelScoop objects. This is of course the behaviour one would expect from "operator==".

Parameters:
FuelScoop  the fuel scoop object to be compared with "*this"
Returns:
true if the fuel scoop objects are equal, false if not

virtual bool TFuelScoop::save TDataPackageList   out const [virtual]
 

The method Save saves a TFuelScoop object by adding the data packages to the list.

Parameters:
out  the output stream of data packages
Returns:
true means that everything was saved correctly, otherwise this method will return false.
See also:
TLinkable

Reimplemented from TItem.

virtual void TFuelScoop::setScoopCapacity const int2    Capacity [virtual]
 

The method setScoopCapacity sets the capacity of the scoop to collect fuel.

Parameters:
Capacity  the fuel scoop's collecting capacity


Member Data Documentation

int2 TFuelScoop::fScoopCapacity [protected]
 

the capacity of the fuel scoop object


The documentation for this class was generated from the following file:
Generated on Thu Jun 20 18:13:21 2002 for Stellar Legacy by doxygen1.2.13.1 written by Dimitri van Heesch, © 1997-2001