org.vizzini.game
Class AgentFactory

java.lang.Object
  extended by org.vizzini.game.AgentFactory

public class AgentFactory
extends Object

Provides a factory for creating and configuring agents in the game framework.

Since:
v0.2
Version:
v0.2
Author:
Jeffrey M. Thompson

Constructor Summary
AgentFactory()
          Construct this object.
 
Method Summary
static IAgent create(Class agentClass, Properties properties, int index)
          Create and return the desired agent.
static IAgent create(Class agentClass, Properties properties, int index, String name, ITeam team, int searchDepth)
          Create and return the desired agent.
static IAgent create(Properties properties, int index)
          Create and return the desired agent.
static IAgent create(Properties properties, int index, String name, ITeam team)
          Create and return the desired agent.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AgentFactory

public AgentFactory()
Construct this object.

Since:
v0.2
Method Detail

create

public static IAgent create(Properties properties,
                            int index)
                     throws ClassNotFoundException,
                            InstantiationException,
                            IllegalAccessException
Create and return the desired agent.

Throws:
IllegalArgumentException - if properties is null, or index is less than zero.
ClassNotFoundException
InstantiationException
IllegalAccessException
Since:
v0.2

create

public static IAgent create(Class agentClass,
                            Properties properties,
                            int index)
                     throws InstantiationException,
                            IllegalAccessException
Create and return the desired agent.

Throws:
IllegalArgumentException - if agentClass is null, properties is null, or index is less than zero.
InstantiationException
IllegalAccessException
Since:
v0.2

create

public static IAgent create(Properties properties,
                            int index,
                            String name,
                            ITeam team)
                     throws ClassNotFoundException,
                            InstantiationException,
                            IllegalAccessException
Create and return the desired agent.

Throws:
IllegalArgumentException - if properties is null, index is less than zero, name is null, or team is null.
ClassNotFoundException
InstantiationException
IllegalAccessException
Since:
v0.2

create

public static IAgent create(Class agentClass,
                            Properties properties,
                            int index,
                            String name,
                            ITeam team,
                            int searchDepth)
                     throws InstantiationException,
                            IllegalAccessException
Create and return the desired agent.

Throws:
IllegalArgumentException - if agentClass is null, properties is null, index is less than zero, name is null, or team is null.
InstantiationException
IllegalAccessException
Since:
v0.2


Copyright © 2007 Vizzini.org. All Rights Reserved. 2007.12.25.03.00.02