LocalBlock

class pyrogue.LocalBlock(*, variable, localSet, localGet, minimum, maximum, value)[source]

Back-end Block class used by LocalVariable.

Stores value in local memory.

Parameters:
property path: str

Return the block path.

property mode: str

Return the variable access mode. (‘RW’, ‘RO’, etc).

property bulkOpEn: bool

Return True to enable bulk operations.

forceStale()[source]

Mark the block as stale (no-op for local blocks).

Return type:

None

setEnable(value)[source]

Enable or disable local access.

Parameters:

value (bool) – True to enable local access, False to disable.

Return type:

None

property variables: list

Return the list of variables in this block.

set(var, value, index=-1)[source]

Set the block value, optionally for an index.

Parameters:
  • var (LocalVariable) – Variable associated with this block.

  • value (Any) – Value to write.

  • index (int, default: -1) – Index for array variables.

Return type:

None

get(var, index=-1)[source]

Get the block value, optionally for an index.

Parameters:
  • var (LocalVariable) – Variable associated with this block.

  • index (int, default: -1) – Index for array variables.

Returns:

Current value.

Return type:

Any