org.mars_sim.msp.simulation.mars
Class RandomMineralMap

java.lang.Object
  extended by org.mars_sim.msp.simulation.mars.RandomMineralMap
All Implemented Interfaces:
java.io.Serializable, MineralMap

public class RandomMineralMap
extends java.lang.Object
implements java.io.Serializable, MineralMap

A randomly generated mineral map of Mars.

See Also:
Serialized Form

Method Summary
 java.util.Map<java.lang.String,java.lang.Double> getAllMineralConcentrations(Coordinates location)
          Gets all of the mineral concentrations at a given location.
 double getMineralConcentration(java.lang.String mineralType, Coordinates location)
          Gets the mineral concentration at a given location.
 java.lang.String[] getMineralTypeNames()
          Gets an array of all mineral type names.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getAllMineralConcentrations

public java.util.Map<java.lang.String,java.lang.Double> getAllMineralConcentrations(Coordinates location)
Gets all of the mineral concentrations at a given location.

Specified by:
getAllMineralConcentrations in interface MineralMap
Parameters:
location - the coordinate location.
Returns:
map of mineral types and percentage concentration (0 to 100.0)

getMineralConcentration

public double getMineralConcentration(java.lang.String mineralType,
                                      Coordinates location)
Gets the mineral concentration at a given location.

Specified by:
getMineralConcentration in interface MineralMap
Parameters:
mineralType - the mineral type (see MineralMap.java)
location - the coordinate location.
Returns:
percentage concentration (0 to 100.0)

getMineralTypeNames

public java.lang.String[] getMineralTypeNames()
Gets an array of all mineral type names.

Specified by:
getMineralTypeNames in interface MineralMap
Returns:
array of name strings.