Enum asi_core0::Action
[−]
[src]
pub enum Action { Terminate, Wait(f64), Output { actuator: ActuatorId, memory: MemoryId, }, Input { sensor: SensorId, memory: MemoryId, }, Alloc { slots: usize, }, Free { memory: MemoryId, }, Swap { memory_a: MemoryId, memory_b: MemoryId, }, }
Represents an action that the agent takes.
Variants
Terminate
Terminate the runtime.
Wait(f64)
Wait a number of seconds.
Output
Send an output signal to actuator from memory slot.
Fields of Output
actuator: ActuatorId | The actuator to write output to. |
memory: MemoryId | The memory slot to write output from. |
Input
Read an input signal from sensor and stores it memory slot.
Fields of Input
sensor: SensorId | The sensor to read input from. |
memory: MemoryId | The memory slot to store input. |
Alloc
Allocate new memory states. Creates N number of new states.
Fields of Alloc
slots: usize | The number of slots to be allocated. |
Free
Free memory state (index). This will insert a default memory state in the middle and shrink memory at the end.
Fields of Free
memory: MemoryId | The memory slot to be freed. |
Swap
Swap two memory states, likely in order to free memory at the end.
Fields of Swap
memory_a: MemoryId | The first memory slot. |
memory_b: MemoryId | The second memory slot. |
Trait Implementations
impl Debug for Action
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more