io.sarl.api.core
Capacity InnerContextAccess
All Superinterfaces:
Capacity
All Known Implementing Classes:
InnerContextAccessSkill
capacity InnerContextAccess
implements Capacity
Provides functions for accessing and managing the internal contexts of an agent.
Property Summary
Modifier and type Property and description
AgentContext innerContext
Replies the inner context.
EventSpace innerDefaultSpace
Replies the inner context.
int memberAgentCount
Replies the number of agents that are members of the inner context of the calling agent.
ConcurrentSet<T> memberAgents
Replies all the member agents in the inner context.
Action Summary
Modifier and type Action and description
abstract AgentContext getInnerContext
Replies the inner context.
abstract EventSpace getInnerDefaultSpace
Replies the inner context.
abstract int getMemberAgentCount
Replies the number of agents that are members of the inner context of the calling agent.
abstract ConcurrentSet<T> getMemberAgents
Replies all the member agents in the inner context.
abstract boolean hasMemberAgent
Replies if the calling agent has other agents as members of its inner context.
abstract boolean isInInnerDefaultSpace(Event)
Replies if the given event was emitted in the default space of the inner context.
abstract boolean isInnerDefaultSpace(Space)
Replies if the given space is the default space of the inner context.
abstract boolean isInnerDefaultSpace(SpaceID)
Replies if the given identifier is the identifier of the default space of the inner context.
abstract boolean isInnerDefaultSpace(UUID)
Replies if the given identifier is the identifier of the default space of the inner context.
Property Details
innerContext
val innerContext : AgentContext
Replies the inner context.

This property is an alias for the action: getInnerContext

Returns:
the instance of the internal agent context.
innerDefaultSpace
val innerDefaultSpace : EventSpace
Replies the inner context.

This property is an alias for the action: getInnerDefaultSpace

Returns:
the instanceof the internal agent context.
Since:
0.12
memberAgentCount
val memberAgentCount : int
Replies the number of agents that are members of the inner context of the calling agent. A member agent is an agent which is not the calling agent, and is a member of at least one space of the inner context.

The replied number includes the current agent. Indeed, the current agent is member of its internal context with the role of super-holon.

This property is an alias for the action: getMemberAgentCount

Returns:
the number of members in the internal context of the current agent.
memberAgents
val memberAgents : ConcurrentSet<T>
Replies all the member agents in the inner context. A member agent is an agent which is not the calling agent, and is a member of at least one space of the inner context.

This property is an alias for the action: getMemberAgents

Returns:
the identifiers of the members of the internal context of the current agent.
Action Details
getInnerContext
def getInnerContext : AgentContext
Replies the inner context.
Returns:
the instance of the internal agent context.
getInnerDefaultSpace
def getInnerDefaultSpace : EventSpace
Replies the inner context.
Returns:
the instanceof the internal agent context.
Since:
0.12
getMemberAgentCount
def getMemberAgentCount : int
Replies the number of agents that are members of the inner context of the calling agent. A member agent is an agent which is not the calling agent, and is a member of at least one space of the inner context.

The replied number includes the current agent. Indeed, the current agent is member of its internal context with the role of super-holon.
Returns:
the number of members in the internal context of the current agent.
getMemberAgents
def getMemberAgents : ConcurrentSet<T>
Replies all the member agents in the inner context. A member agent is an agent which is not the calling agent, and is a member of at least one space of the inner context.
Returns:
the identifiers of the members of the internal context of the current agent.
hasMemberAgent
def hasMemberAgent : boolean
Replies if the calling agent has other agents as members of its inner context. A member agent is an agent which is not the calling agent, and is a member of at least one space of the inner context.
Returns:
true if the current agent has other agents as member of its internal context; otherwise false
isInInnerDefaultSpace(Event)
def isInInnerDefaultSpace(Event) : boolean
Replies if the given event was emitted in the default space of the inner context.
Parameters:
event - the event to test.
Returns:
true if the given event was emitted in the default space of the inner context. Otherwise false .
Since:
0.2
isInnerDefaultSpace(Space)
def isInnerDefaultSpace(Space) : boolean
Replies if the given space is the default space of the inner context.
Parameters:
space - the space to test.
Returns:
true if the given space is the default space of the inner context. Otherwise false .
Since:
0.2
isInnerDefaultSpace(SpaceID)
def isInnerDefaultSpace(SpaceID) : boolean
Replies if the given identifier is the identifier of the default space of the inner context.
Parameters:
spaceID - the identifier to test.
Returns:
true if the given identifier is the identifier of the default space of the inner context. Otherwise false .
Since:
0.2
isInnerDefaultSpace(UUID)
def isInnerDefaultSpace(UUID) : boolean
Replies if the given identifier is the identifier of the default space of the inner context.
Parameters:
spaceID - the identifier to test.
Returns:
true if the given identifier is the identifier of the default space of the inner context. Otherwise false .
Since:
0.2