kernel

## Class World

- java.lang.Object
- - kernel.World

All Implemented Interfaces:
  java.io.Serializable

    public class World
    extends java.lang.Object
    implements java.io.Serializable

The Class World.

See Also:
  Serialized Form

### Field Summary

Fields
`int` `testValue` The test value.

### Constructor Summary

Constructors
Constructor and Description
`World(Scheduler scheduler, java.io.File systemFile, BlackBox blackbox)` Instantiates a new world.

### Method Summary

All Methods Static Methods Instance Methods Concrete Methods
`LocalModelAgent` `buildLocalModel(Context context)` Builds the local model.
`void` `changeAgentNumber(int x, java.lang.String cl)` Change agent number.
`void` `changeNCSNumber(int x, NCS ncs)` Change NCS number.
`void` `changeOracleConnection()` Change oracle connection.
`void` `destroy(java.lang.Class<Context> cl)` Destroy.
`void` `exportAsPicture(int pasX, double startX, double endX, Percept pX, int pasY, double startY, double endY, Percept pY, double minTol, double maxTol)` Export as picture.
`java.util.HashMap<java.lang.String,SystemAgent>` `getAgents()` Gets the agents.
`java.util.ArrayList<? extends Agent>` `getAllAgentInstanceOf(java.lang.Class<? extends Agent> cl)` Gets the all agent instance of.
`java.util.HashMap<NCS,java.lang.Integer>` `getAllNCS()` Gets the all NCS.
`java.util.ArrayList<Percept>` `getAllPercept()` Gets the all percept.
`AMOEBA` `getAmoeba()` Gets the amoeba.
`double` `getAVT_acceleration()` Gets the AV T acceleration.
`double` `getAVT_deceleration()` Gets the AV T deceleration.
`double` `getAVT_percentAtStart()` Gets the AV T percent at start.
`BlackBox` `getBlackbox()` Gets the blackbox.
`java.io.File` `getFileToSerialize()` Gets the file to serialize.
`static <T> java.util.ArrayList<T>` `getIntersection(java.util.ArrayList<java.util.ArrayList<T>> list)` Gets the intersection.
`TypeLocalModel` `getLocalModel()` Gets the local model.
`java.util.HashMap<java.lang.String,java.lang.Integer>` `getNumberOfAgents()` Gets the number of agents.
`java.util.HashMap<NCS,java.lang.Integer>` `getNumberOfNCS()` Gets the number of NCS.
`Scheduler` `getScheduler()` Gets the scheduler.
`java.util.ArrayList<Agent>` `getSelectableContext()` Gets the selectable context.
`StudiedSystem` `getStudiedSystem()` Gets the studied system.
`java.util.HashMap<NCS,java.lang.Integer>` `getThisLoopNCS()` Gets the this loop NCS.
`boolean` `isStartSerialization()` Checks if is start serialization.
`void` `kill(Agent agent)` Kill.
`void` `manageWorld()` Manage world.
`void` `raiseNCS(NCS ncs)` Raise NCS.
`void` `readRessourceFile(java.io.File systemFile)` Read ressource file.
`void` `setAgents(java.util.HashMap<java.lang.String,SystemAgent> agents)` Sets the agents.
`void` `setAllNCS(java.util.HashMap<NCS,java.lang.Integer> allNCS)` Sets the all NCS.
`void` `setAmoeba(AMOEBA amoeba)` Sets the amoeba.
`void` `setAVT_acceleration(double aVT_acceleration)` Sets the AV T acceleration.
`void` `setAVT_deceleration(double aVT_deceleration)` Sets the AV T deceleration.
`void` `setAVT_percentAtStart(double aVT_percentAtStart)` Sets the AV T percent at start.
`void` `setBlackbox(BlackBox blackbox)` Sets the blackbox.
`void` `setBlackBox(BlackBox blackbox)` Sets the black box.
`void` `setLocalModel(TypeLocalModel localModel)` Define the kind of local model used by newly created Context Agent.
`void` `setNumberOfAgents(java.util.HashMap<java.lang.String,java.lang.Integer> numberOfAgents)` Sets the number of agents.
`void` `setNumberOfNCS(java.util.HashMap<NCS,java.lang.Integer> numberOfNCS)` Sets the number of NCS.
`void` `setScheduler(Scheduler scheduler)` Sets the scheduler.
`void` `setStartSerialization(boolean startSerialization, java.io.File file)` Sets the start serialization.
`void` `setThisLoopNCS(java.util.HashMap<NCS,java.lang.Integer> thidLoopNCS)` Sets the this loop NCS.
`void` `startAgent(SystemAgent a)` Start agent.

### Methods inherited from class java.lang.Object

`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Field Detail

#### testValue

    public int testValue

The test value.

### Constructor Detail

#### World

    public World(Scheduler scheduler,
                 java.io.File systemFile,
                 BlackBox blackbox)

Instantiates a new world.

Parameters:
  `scheduler` - the scheduler
  `systemFile` - the system file
  `blackbox` - the blackbox

### Method Detail

#### readRessourceFile

    public void readRessourceFile(java.io.File systemFile)

Read ressource file.

Parameters:
  `systemFile` - the system file

#### manageWorld

    public void manageWorld()

Manage world.

#### getScheduler

    public Scheduler getScheduler()

Gets the scheduler.

Returns:
  the scheduler

#### setScheduler

    public void setScheduler(Scheduler scheduler)

Sets the scheduler.

Parameters:
  `scheduler` - the new scheduler

#### setBlackBox

    public void setBlackBox(BlackBox blackbox)

Sets the black box.

Parameters:
  `blackbox` - the new black box

#### getBlackbox

    public BlackBox getBlackbox()

Gets the blackbox.

Returns:
  the blackbox

#### getAgents

    public java.util.HashMap<java.lang.String,SystemAgent> getAgents()

Gets the agents.

Returns:
  the agents

#### setAgents

    public void setAgents(java.util.HashMap<java.lang.String,SystemAgent> agents)

Sets the agents.

Parameters:
  `agents` - the agents

#### setBlackbox

    public void setBlackbox(BlackBox blackbox)

Sets the blackbox.

Parameters:
  `blackbox` - the new blackbox

#### getAllAgentInstanceOf

    public java.util.ArrayList<? extends Agent> getAllAgentInstanceOf(java.lang.Class<? extends Agent> cl)

Gets the all agent instance of.

Parameters:
  `cl` - the cl
Returns:
  the all agent instance of

#### startAgent

    public void startAgent(SystemAgent a)

Start agent.

Parameters:
  `a` - the a

#### getAllNCS

    public java.util.HashMap<NCS,java.lang.Integer> getAllNCS()

Gets the all NCS.

Returns:
  the all NCS

#### setAllNCS

    public void setAllNCS(java.util.HashMap<NCS,java.lang.Integer> allNCS)

Sets the all NCS.

Parameters:
  `allNCS` - the all NCS

#### getThisLoopNCS

    public java.util.HashMap<NCS,java.lang.Integer> getThisLoopNCS()

Gets the this loop NCS.

Returns:
  the this loop NCS

#### setThisLoopNCS

    public void setThisLoopNCS(java.util.HashMap<NCS,java.lang.Integer> thidLoopNCS)

Sets the this loop NCS.

Parameters:
  `thidLoopNCS` - the thid loop NCS

#### raiseNCS

    public void raiseNCS(NCS ncs)

Raise NCS.

Parameters:
  `ncs` - the ncs

#### destroy

    public void destroy(java.lang.Class<Context> cl)

Destroy.

Parameters:
  `cl` - the cl

#### getNumberOfAgents

    public java.util.HashMap<java.lang.String,java.lang.Integer> getNumberOfAgents()

Gets the number of agents.

Returns:
  the number of agents

#### setNumberOfAgents

    public void setNumberOfAgents(java.util.HashMap<java.lang.String,java.lang.Integer> numberOfAgents)

Sets the number of agents.

Parameters:
  `numberOfAgents` - the number of agents

#### changeAgentNumber

    public void changeAgentNumber(int x,
                                  java.lang.String cl)

Change agent number.

Parameters:
  `x` - the x
  `cl` - the cl

#### changeNCSNumber

    public void changeNCSNumber(int x,
                                NCS ncs)

Change NCS number.

Parameters:
  `x` - the x
  `ncs` - the ncs

#### getNumberOfNCS

    public java.util.HashMap<NCS,java.lang.Integer> getNumberOfNCS()

Gets the number of NCS.

Returns:
  the number of NCS

#### setNumberOfNCS

    public void setNumberOfNCS(java.util.HashMap<NCS,java.lang.Integer> numberOfNCS)

Sets the number of NCS.

Parameters:
  `numberOfNCS` - the number of NCS

#### kill

    public void kill(Agent agent)

Kill.

Parameters:
  `agent` - the agent

#### exportAsPicture

    public void exportAsPicture(int pasX,
                                double startX,
                                double endX,
                                Percept pX,
                                int pasY,
                                double startY,
                                double endY,
                                Percept pY,
                                double minTol,
                                double maxTol)

Export as picture.

Parameters:
  `pasX` - the pas X
  `startX` - the start X
  `endX` - the end X
  `pX` - the p X
  `pasY` - the pas Y
  `startY` - the start Y
  `endY` - the end Y
  `pY` - the p Y
  `minTol` - the min tol
  `maxTol` - the max tol

#### changeOracleConnection

    public void changeOracleConnection()

Change oracle connection.

#### getSelectableContext

    public java.util.ArrayList<Agent> getSelectableContext()

Gets the selectable context.

Returns:
  the selectable context

#### getIntersection

    public static <T> java.util.ArrayList<T> getIntersection(java.util.ArrayList<java.util.ArrayList<T>> list)

Gets the intersection.

Type Parameters:
  `T` - the generic type
Parameters:
  `list` - the list
Returns:
  the intersection

#### isStartSerialization

    public boolean isStartSerialization()

Checks if is start serialization.

Returns:
  true, if is start serialization

#### setStartSerialization

    public void setStartSerialization(boolean startSerialization,
                                      java.io.File file)

Sets the start serialization.

Parameters:
  `startSerialization` - the start serialization
  `file` - the file

#### getAmoeba

    public AMOEBA getAmoeba()

Gets the amoeba.

Returns:
  the amoeba

#### setAmoeba

    public void setAmoeba(AMOEBA amoeba)

Sets the amoeba.

Parameters:
  `amoeba` - the new amoeba

#### buildLocalModel

    public LocalModelAgent buildLocalModel(Context context)

Builds the local model.

Parameters:
  `context` - the context
Returns:
  the local model agent

#### getFileToSerialize

    public java.io.File getFileToSerialize()

Gets the file to serialize.

Returns:
  the file to serialize

#### getLocalModel

    public TypeLocalModel getLocalModel()

Gets the local model.

Returns:
  the local model

#### setLocalModel

    public void setLocalModel(TypeLocalModel localModel)

Define the kind of local model used by newly created Context Agent. Ancient name of local model was proposition function.

Parameters:
  `localModel` - the new local model

#### getAllPercept

    public java.util.ArrayList<Percept> getAllPercept()

Gets the all percept.

Returns:
  the all percept

#### getStudiedSystem

    public StudiedSystem getStudiedSystem()

Gets the studied system.

Returns:
  the studied system

#### getAVT_acceleration

    public double getAVT_acceleration()

Gets the AV T acceleration.

Returns:
  the AV T acceleration

#### setAVT_acceleration

    public void setAVT_acceleration(double aVT_acceleration)

Sets the AV T acceleration.

Parameters:
  `aVT_acceleration` - the new AV T acceleration

#### getAVT_deceleration

    public double getAVT_deceleration()

Gets the AV T deceleration.

Returns:
  the AV T deceleration

#### setAVT_deceleration

    public void setAVT_deceleration(double aVT_deceleration)

Sets the AV T deceleration.

Parameters:
  `aVT_deceleration` - the new AV T deceleration

#### getAVT_percentAtStart

    public double getAVT_percentAtStart()

Gets the AV T percent at start.

Returns:
  the AV T percent at start

#### setAVT_percentAtStart

    public void setAVT_percentAtStart(double aVT_percentAtStart)

Sets the AV T percent at start.

Parameters:
  `aVT_percentAtStart` - the new AV T percent at start