Enum Class MemoryProfile

java.lang.Object
java.lang.Enum<MemoryProfile>
laas.openrobots.ontology.modules.memory.MemoryProfile
All Implemented Interfaces:
Serializable, Comparable<MemoryProfile>, Constable

public enum MemoryProfile extends Enum<MemoryProfile>
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    Default memory profile is equivalent to the long term memory profile.
    This represents episodic memory (memory of personal experience).
    This represents long term memory.
    This represents short term memory (or working memory).
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static int
    The time base states "how long a second lasts in milliseconds".
    The default value is obviously 1000, but you can alter this value to accelerate (or slow down) the behaviour of the memory storage.
    For instance, if you set timeBase = 500, the actual duration a short term statement is divided by 2 (ie 5 seconds instead of the default 10 seconds)
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Returns the lifespan associated to the memory profile, in milliseconds, scaled with the TimeBase.
    fromString(String literalMemProfile)
    Returns a MemoryProfile constant from its string representation, or DEFAULT if the string is not recognized.
    Returns the enum constant of this class with the specified name.
    static MemoryProfile[]
    Returns an array containing the constants of this enum class, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • SHORTTERM

      public static final MemoryProfile SHORTTERM
      This represents short term memory (or working memory). A statement added in short term memory is held for 10 seconds.
    • EPISODIC

      public static final MemoryProfile EPISODIC
      This represents episodic memory (memory of personal experience). A statement added in episodic memory is held for 5 minutes.
    • LONGTERM

      public static final MemoryProfile LONGTERM
      This represents long term memory. A statement added in long term memory is never forgotten.
    • DEFAULT

      public static final MemoryProfile DEFAULT
      Default memory profile is equivalent to the long term memory profile.
      See Also:
  • Field Details

    • TimeBase

      public static int TimeBase
      The time base states "how long a second lasts in milliseconds".
      The default value is obviously 1000, but you can alter this value to accelerate (or slow down) the behaviour of the memory storage.
      For instance, if you set timeBase = 500, the actual duration a short term statement is divided by 2 (ie 5 seconds instead of the default 10 seconds)
  • Method Details

    • values

      public static MemoryProfile[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static MemoryProfile valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • duration

      public int duration()
      Returns the lifespan associated to the memory profile, in milliseconds, scaled with the TimeBase.
      Returns:
      the lifespan associated to the memory profile, in milliseconds
      See Also:
    • fromString

      public static MemoryProfile fromString(String literalMemProfile)
      Returns a MemoryProfile constant from its string representation, or DEFAULT if the string is not recognized.
      Parameters:
      literalMemProfile - the string representation of a MemoryProfile
      Returns:
      The corresponding MemoryProfile constant.