bdi4jade.goal

## Class BeliefGoal

- java.lang.Object
- - bdi4jade.goal.BeliefGoal

- All Implemented Interfaces:
    Goal, jade.content.Concept, jade.content.ContentElement, jade.content.Term, java.io.Serializable
  Direct Known Subclasses:
    BeliefValueGoal

      public class BeliefGoal
      extends java.lang.Object
      implements Goal

  This class represents the goal of an agent to believe in a certain belief, that is, the agent has a belief whose name is specified in this goal.
  Author:
    Ingrid Nunes
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `BeliefGoal(java.lang.String beliefName)` Creates a new BeliefGoal with the provided belief name.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.String` | `getBeliefName()` Returns the name of the belief associated with this goal.
    `boolean` | `isAchieved(BeliefBase beliefBase)` Checks whether this goal is achieved by verifying if the provided belief base contains the belief of this goal.
    `java.lang.String` | `toString()` Returns a string representation of this goal, in the form "BeliefGoal: belief name".

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

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### BeliefGoal

          public BeliefGoal(java.lang.String beliefName)

      Creates a new BeliefGoal with the provided belief name.
      Parameters:
        `beliefName` - the belief name.

  - ### Method Detail

    - #### getBeliefName

          public java.lang.String getBeliefName()

      Returns the name of the belief associated with this goal.
      Returns:
        the belief name.

    - #### isAchieved

          public boolean isAchieved(BeliefBase beliefBase)

      Checks whether this goal is achieved by verifying if the provided belief base contains the belief of this goal.
      Parameters:
        `beliefBase` - the belief base to be checked.
      Returns:
        true if the belief base contains the belief of this goal.

    - #### toString

          public java.lang.String toString()

      Returns a string representation of this goal, in the form "BeliefGoal: belief name".
      Overrides:
        `toString` in class `java.lang.Object`
      Returns:
        the string representation of this belief goal.
      See Also:
        `Object.toString()`