org.gscg.gameactors.statistics
Class Region

java.lang.Object
  extended byorg.gscg.gameactors.statistics.Region
All Implemented Interfaces:
RegionInterface, java.io.Serializable

public class Region
extends java.lang.Object
implements RegionInterface

A region is used to specify the geographical bounds. For the actors part of an region statistics are collected, in this case statistics with regards to orders. Regions may overlap eachother. Using lat/lon coordinates, a rough estimation of the North-American region is new Region(new Point(-125, 49), new Point(-68, 23)).

(c) copyright 2005 Delft University of Technology , the Netherlands.
See for project information www.simulation.tudelft.nl
Copyright (c) 2003-2005 Delft University of Technology, Jaffalaan 5, 2628 BX Delft, the Netherlands. All rights reserved. See for project information www.simulation.tudelft.nl . The source code and binary code of this software are proprietary information of Delft University of Technology.

Since:
1.1.3
Version:
$Revision: 1.1 $ $Date: 2005/08/03 08:52:49 $
Author:
Stijn-Pieter van Houten
See Also:
Serialized Form

Constructor Summary
Region(java.lang.String name, java.awt.Point upperLeft, java.awt.Point downRight)
          constructs a new Region
 
Method Summary
 void addStatisticHandler(java.lang.Class contentClass, nl.tudelft.simulation.content.HandlerInterface handler)
          adds a statistic handler to a region
 boolean addSupplyChainActor(nl.tudelft.simulation.supplychain.actor.SupplyChainActor actor)
          adds a supply chain actor to a region
 java.lang.String getName()
           
 java.util.List getStatisticHandlers()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Region

public Region(java.lang.String name,
              java.awt.Point upperLeft,
              java.awt.Point downRight)
constructs a new Region

Parameters:
name - the name of the region
upperLeft - the upper left of the region
downRight - the down right of the region
Method Detail

addStatisticHandler

public void addStatisticHandler(java.lang.Class contentClass,
                                nl.tudelft.simulation.content.HandlerInterface handler)
Description copied from interface: RegionInterface
adds a statistic handler to a region

Specified by:
addStatisticHandler in interface RegionInterface
Parameters:
contentClass - the class of the content to get statistics for
handler - the handler to process the content and compose statistics
See Also:
RegionInterface.addStatisticHandler(java.lang.Class, nl.tudelft.simulation.content.HandlerInterface)

addSupplyChainActor

public boolean addSupplyChainActor(nl.tudelft.simulation.supplychain.actor.SupplyChainActor actor)
Description copied from interface: RegionInterface
adds a supply chain actor to a region

Specified by:
addSupplyChainActor in interface RegionInterface
Parameters:
actor - the actor to add
Returns:
returns false if the actor is not contained by the region, or is already
See Also:
RegionInterface.addSupplyChainActor(nl.tudelft.simulation.supplychain.actor.SupplyChainActor)

getName

public java.lang.String getName()
Specified by:
getName in interface RegionInterface
Returns:
retuns the name of the region

getStatisticHandlers

public java.util.List getStatisticHandlers()
Specified by:
getStatisticHandlers in interface RegionInterface
Returns:
returns the list with statistic handlers
See Also:
RegionInterface.getStatisticHandlers()


Copyright © 2002-2005 Delft University of Technology, the Netherlands. All Rights Reserved.