nars.main
Class Center

java.lang.Object
  extended by nars.main.Center

public class Center
extends java.lang.Object

The control center of the system.

Create static main window and input channel, reset memory, and manage system clock.


Field Summary
private static long clock
          System clock, relatively defined to guaranttee the repeatability of behaviors
static ExperienceIO experienceIO
          The unique input channel
static MainWindow mainWindow
          The unique main window
private static boolean running
          Flag for running continously
private static long stoper
          Timer for fixed distance walking
 
Constructor Summary
Center()
           
 
Method Summary
static long getTime()
          Get the current time from the clock Called in nars.entity.Stamp
static void reset()
          Reset the system with an empty memory and reset clock.
static void setStoper(long i)
          Walk a fixed number of steps or continously.
static void start()
          Start the initial windows and memory.
static void tick()
          A clock tick.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

mainWindow

public static MainWindow mainWindow
The unique main window


experienceIO

public static ExperienceIO experienceIO
The unique input channel


clock

private static long clock
System clock, relatively defined to guaranttee the repeatability of behaviors


stoper

private static long stoper
Timer for fixed distance walking


running

private static boolean running
Flag for running continously

Constructor Detail

Center

public Center()
Method Detail

start

public static void start()
Start the initial windows and memory. Called from NARS only.


reset

public static void reset()
Reset the system with an empty memory and reset clock. Called locally and from MainWindow.


setStoper

public static void setStoper(long i)
Walk a fixed number of steps or continously. Called from MainWindow only.

Parameters:
i - The number of steps of inference, or infinite if negative

tick

public static void tick()
A clock tick. Run one working cycle or read input. Called from NARS only.


getTime

public static long getTime()
Get the current time from the clock Called in nars.entity.Stamp

Returns:
The current time