Class TitledWorld

java.lang.Object
edu.uky.cs.nil.tt.world.World
edu.uky.cs.nil.tt.world.TitledWorld
All Implemented Interfaces:
Described, Named, Titled

public class TitledWorld extends World implements Titled
A story world that includes a name, title, and description.
Author:
Stephen G. Ware
  • Field Details

    • title

      public final String title
      The short natural language title of the world
    • description

      public final String description
      The longer natural language description of the world
  • Constructor Details

    • TitledWorld

      public TitledWorld(String name, String title, String description, Collection<Entity> entities, Collection<Variable> variables, Collection<Action> actions, Collection<Ending> endings)
      Constructs a titled world from its name, title, description, and elements.
      Parameters:
      name - the unique system name for the world
      title - the short natural language title of the world
      description - the longer natural language description of the world
      entities - a collection of objects that exist in the world
      variables - a collection of variables whose values can change and whose current values reflect the current state of the world
      actions - a collection of ways the world state can change
      endings - a collection of ways a story in this world can end
    • TitledWorld

      public TitledWorld(Database.WorldEntry entry)
      Constructs a titled world from its database entry.
      Parameters:
      entry - the world's entry in the database
  • Method Details

    • getTitle

      public String getTitle()
      Description copied from interface: Titled
      Returns a short human-readable natural language title for the object.
      Specified by:
      getTitle in interface Titled
      Returns:
      a short human-readable natural language title
    • getDescription

      public String getDescription()
      Description copied from interface: Described
      Returns a human-readable natural language description of the object.
      Specified by:
      getDescription in interface Described
      Returns:
      a human-readable natural language description of the object