nl.tudelft.simulation.yellowpage
Class YellowPage

java.lang.Object
  extended bynl.tudelft.simulation.yellowpage.YellowPage
All Implemented Interfaces:
YellowPageInterface

public class YellowPage
extends java.lang.Object
implements YellowPageInterface

A YellowPage implementation, which uses the Context package to store information about actors.

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 is proprietary information of Delft University of Technology.

Version:
$$Revision: 1.3 $$ $$Date: 2005/04/08 11:29:13 $$
Author:
Peter Jacobs

Field Summary
protected  java.util.Map entries
          a map of entries
protected  YellowPage parent
          the parent of this yellowPage
 
Constructor Summary
protected YellowPage()
          constructs a new YellowPage
 
Method Summary
 ActorInterface[] findActor(Category category)
          finds an actor based on the category
 ActorInterface[] findActor(java.lang.String regex)
          finds an actor based on the regex
 ActorInterface[] findActor(java.lang.String regex, Category category)
          finds an actor based on the regex
static YellowPageInterface getYellowPage(nl.tudelft.simulation.dsol.simulators.SimulatorInterface simulator)
          resolves the yellowPage
 boolean register(ActorInterface actor, Category category)
          registers an actor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

entries

protected java.util.Map entries
a map of entries


parent

protected YellowPage parent
the parent of this yellowPage

Constructor Detail

YellowPage

protected YellowPage()
constructs a new YellowPage

Method Detail

getYellowPage

public static YellowPageInterface getYellowPage(nl.tudelft.simulation.dsol.simulators.SimulatorInterface simulator)
resolves the yellowPage

Parameters:
simulator - the simulator
Returns:
YellowPage

findActor

public ActorInterface[] findActor(java.lang.String regex)
Description copied from interface: YellowPageInterface
finds an actor based on the regex

Specified by:
findActor in interface YellowPageInterface
Parameters:
regex - the name of the actor as regular expression
Returns:
ActorInterface[] the result
See Also:
#findActor(java.lang.String)

findActor

public ActorInterface[] findActor(java.lang.String regex,
                                  Category category)
Description copied from interface: YellowPageInterface
finds an actor based on the regex

Specified by:
findActor in interface YellowPageInterface
Parameters:
regex - the name of the actor as regular expression
category - the category for this actor
Returns:
ActorInterface[] the result
See Also:
#findActor(java.lang.String, nl.tudelft.simulation.yellowpage.Category)

findActor

public ActorInterface[] findActor(Category category)
Description copied from interface: YellowPageInterface
finds an actor based on the category

Specified by:
findActor in interface YellowPageInterface
Parameters:
category - the category for this actor
Returns:
ActorInterface[] the result
See Also:
YellowPageInterface.findActor(nl.tudelft.simulation.yellowpage.Category)

register

public boolean register(ActorInterface actor,
                        Category category)
Description copied from interface: YellowPageInterface
registers an actor

Specified by:
register in interface YellowPageInterface
Parameters:
actor - the actor
category - the category
Returns:
succes
See Also:
YellowPageInterface.register(nl.tudelft.simulation.actor.ActorInterface, nl.tudelft.simulation.yellowpage.Category)


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