LightJason - AgentSpeak(L++)
|
default behaviour of a beliefbase More...
Public Member Functions | |
ILiteral | add ( @Nonnull final ILiteral p_literal) |
adds a literal More... | |
final IView | create ( @Nonnull final String p_name) |
returns a new view of the belief base More... | |
final IView | create ( @Nonnull final String p_name, final IView p_parent) |
ILiteral | remove ( @Nonnull final ILiteral p_literal) |
removes a literal More... | |
Stream< ITrigger > | trigger ( @Nonnull final IView p_view) |
returns all trigger of the beliefbase More... | |
IAgent<?> | update ( @Nonnull final IAgent<?> p_agent) |
updates all items More... | |
Public Member Functions inherited from org.lightjason.agentspeak.beliefbase.IBeliefbase | |
IView | add ( @Nonnull final IView p_view) |
adds a view More... | |
IBeliefbase | clear () |
clears all elements More... | |
boolean | containsLiteral ( @Nonnull final String p_key) |
contains a multi-element More... | |
boolean | containsView ( @Nonnull final String p_key) |
contains a single-element More... | |
IView | create ( @Nonnull final String p_name, @Nullable final IView p_parent) |
returns a new view of the belief base More... | |
Collection< ILiteral > | literal ( @Nonnull final String p_key) |
returns a literal by the name More... | |
IView | remove ( @Nonnull final IView p_view) |
removes a view More... | |
Stream< ILiteral > | streamLiteral () |
returns a stream over all literals More... | |
Stream< IView > | streamView () |
returns a stream over all views More... | |
IView | view ( @Nonnull final String p_key) |
returns a view element More... | |
IView | viewOrDefault ( @Nonnull final String p_key, @Nullable final IView p_default) |
returns a view element More... | |
Public Member Functions inherited from org.lightjason.agentspeak.beliefbase.IStructure | |
boolean | empty () |
checks if the structure empty More... | |
int | size () |
returns the size of literals More... | |
Protected Member Functions | |
final Stream< ITrigger > | cleartrigger (final IView p_view) |
copy of all trigger values More... | |
ILiteral | event (final ITrigger.EType p_event, final ILiteral p_literal) |
push an event and literal to the event map More... | |
IView | eventreference (final IView p_view) |
adds a view to the event referencing structure More... | |
final IView | internalremove (final IView p_view) |
removes the interal view references More... | |
Private Attributes | |
final Multimap< IView, ITrigger > | m_events = Multimaps.synchronizedSetMultimap( HashMultimap.create() ) |
map with events for a mask More... | |
final ReferenceQueue< IView > | m_maskreference = new ReferenceQueue<>() |
weak reference queue of all masks to avoid memory-leaks of belief events More... | |
final Set< IView > | m_views = Collections.synchronizedSet( new HashSet<>() ) |
set with all current views More... | |
Additional Inherited Members | |
Public Attributes inherited from org.lightjason.agentspeak.beliefbase.IBeliefbase | |
IBeliefbase | EMPY |
empty beliefbase More... | |
T | agent type |
Definition at line 58 of file IBaseBeliefbase.java.
ILiteral org.lightjason.agentspeak.beliefbase.IBaseBeliefbase.add | ( | @Nonnull final ILiteral | p_literal | ) |
p_literal | literal without path |
Implements org.lightjason.agentspeak.beliefbase.IBeliefbase.
Definition at line 91 of file IBaseBeliefbase.java.
References org.lightjason.agentspeak.language.instantiable.plan.trigger.ITrigger.EType.ADDBELIEF.
|
protected |
p_view | trigger of this view |
Definition at line 174 of file IBaseBeliefbase.java.
final IView org.lightjason.agentspeak.beliefbase.IBaseBeliefbase.create | ( | @Nonnull final String | p_name | ) |
p_name | name of the view |
Implements org.lightjason.agentspeak.beliefbase.IBeliefbase.
Definition at line 77 of file IBaseBeliefbase.java.
Referenced by org.lightjason.agentspeak.beliefbase.TestCView.CGenerator.apply(), org.lightjason.agentspeak.consistency.TestCMetric.CGenerator.apply(), org.lightjason.agentspeak.configuration.CDefaultAgentConfiguration< T extends IAgent<?>.beliefbase(), org.lightjason.agentspeak.beliefbase.TestCView.testManual(), and org.lightjason.agentspeak.beliefbase.TestCView.testTree().
final IView org.lightjason.agentspeak.beliefbase.IBaseBeliefbase.create | ( | @Nonnull final String | p_name, |
final IView | p_parent | ||
) |
Definition at line 84 of file IBaseBeliefbase.java.
|
protected |
p_event | event |
p_literal | literal |
Definition at line 135 of file IBaseBeliefbase.java.
References org.lightjason.agentspeak.language.instantiable.plan.trigger.CTrigger.from().
Referenced by org.lightjason.agentspeak.beliefbase.CBeliefbase.clear().
|
protected |
p_view | view |
Definition at line 161 of file IBaseBeliefbase.java.
References org.lightjason.agentspeak.beliefbase.view.IView.add().
|
protected |
p_view | view to remove |
Definition at line 148 of file IBaseBeliefbase.java.
References org.lightjason.agentspeak.beliefbase.view.IView.remove().
Referenced by org.lightjason.agentspeak.beliefbase.CBeliefbase.remove().
ILiteral org.lightjason.agentspeak.beliefbase.IBaseBeliefbase.remove | ( | @Nonnull final ILiteral | p_literal | ) |
p_literal | without path |
Implements org.lightjason.agentspeak.beliefbase.IBeliefbase.
Definition at line 98 of file IBaseBeliefbase.java.
References org.lightjason.agentspeak.language.instantiable.plan.trigger.ITrigger.EType.DELETEBELIEF.
Stream<ITrigger> org.lightjason.agentspeak.beliefbase.IBaseBeliefbase.trigger | ( | @Nonnull final IView | p_view | ) |
p_view | mask for events |
Implements org.lightjason.agentspeak.beliefbase.IBeliefbase.
Definition at line 123 of file IBaseBeliefbase.java.
IAgent<?> org.lightjason.agentspeak.beliefbase.IBaseBeliefbase.update | ( | @Nonnull final IAgent<?> | p_agent | ) |
p_agent | agent which runs the update call |
Implements org.lightjason.agentspeak.beliefbase.IStructure.
Definition at line 105 of file IBaseBeliefbase.java.
References org.lightjason.agentspeak.beliefbase.view.IView.remove().
|
private |
Definition at line 64 of file IBaseBeliefbase.java.
|
private |
Definition at line 72 of file IBaseBeliefbase.java.
|
private |
Definition at line 68 of file IBaseBeliefbase.java.