org.gjt.universe
Class TerrainType

java.lang.Object
  |
  +--org.gjt.universe.Classification
        |
        +--org.gjt.universe.TerrainType
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
TerrainType.DesertTerrainType, TerrainType.GasGiantTerrainType, TerrainType.IceboundOceanTerrainType, TerrainType.IceTerrainType, TerrainType.MixedTerrainType, TerrainType.OceanTerrainType, TerrainType.RockTerrainType

public abstract class TerrainType
extends Classification
implements java.io.Serializable

See Also:
Serialized Form

Nested Class Summary
static class TerrainType.DesertTerrainType
          This standard subclass is used to represent a planet covered in a vast desert (e.g.
static class TerrainType.GasGiantTerrainType
          This standard subclass is used as the catch-all for those terrains whose make-up falls outside the character of all other terrain types.
static class TerrainType.IceboundOceanTerrainType
          This standard subclass is used to represent a planet completely covered in an ocean encased beneath a layer of ice (e.g.
static class TerrainType.IceTerrainType
          This standard subclass is used to represent a planet completely covered by a layer of ice (e.g.
static class TerrainType.MixedTerrainType
          This standard subclass is used to represent a planet containing a mix of various land and ocean terrain (e.g.
static class TerrainType.OceanTerrainType
          This standard subclass is used to represent a planet almost completely covered by an ocean.
static class TerrainType.RockTerrainType
          This standard subclass is used to represent a barren rocky planet (e.g.
 
Field Summary
private static java.util.Vector allInstances
           
static TerrainType DESERT
           
static TerrainType GAS_GIANT
           
static TerrainType ICE
           
static TerrainType ICEBOUND_OCEAN
           
static TerrainType MIXED
           
private  java.awt.Color myColor
           
static TerrainType OCEAN
           
static TerrainType ROCK
           
 
Fields inherited from class org.gjt.universe.Classification
 
Constructor Summary
protected TerrainType(java.lang.String aName, java.lang.String aBackStory, java.awt.Color aColor)
          This constructor is used to construct instances of this class.
 
Method Summary
 java.awt.Color getColor()
           
static TerrainType instanceForMakeup(SimpleAccrete.PlanetaryMakeup aMakeup)
          This class method returns the terrain type instance which best matches the given planetary make-up.
 
Methods inherited from class org.gjt.universe.Classification
getBackStory, getName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

allInstances

private static java.util.Vector allInstances

MIXED

public static TerrainType MIXED

GAS_GIANT

public static TerrainType GAS_GIANT

ROCK

public static TerrainType ROCK

DESERT

public static TerrainType DESERT

ICE

public static TerrainType ICE

OCEAN

public static TerrainType OCEAN

ICEBOUND_OCEAN

public static TerrainType ICEBOUND_OCEAN

myColor

private java.awt.Color myColor
Constructor Detail

TerrainType

protected TerrainType(java.lang.String aName,
                      java.lang.String aBackStory,
                      java.awt.Color aColor)
This constructor is used to construct instances of this class. It should not be necessary for callers to invoke this directly, since all terrain types should be created automatically.

Parameters:
aName - The short localized name of the terrain type.
aBackStory - A localized description of the terrain type.
Method Detail

instanceForMakeup

public static TerrainType instanceForMakeup(SimpleAccrete.PlanetaryMakeup aMakeup)
This class method returns the terrain type instance which best matches the given planetary make-up.

Parameters:
aMakeup - A planetary make-up to be matched against.

getColor

public java.awt.Color getColor()


Copyright © 2001 Universe Dev Team All Rights Reserved.