IceIce
Home
  • Getting Started

    • Quick Start
    • Core Concepts
    • Architecture
  • SDK Guide

    • Java SDK
    • Go SDK
    • Python SDK
  • Reference

    • Node Types
    • Roam API
    • Server Config
    • Client Config
Playground
FAQ
  • Changelog
  • Upgrade Guide
Sponsor
Community
GitHub
  • English
  • 简体中文
Home
  • Getting Started

    • Quick Start
    • Core Concepts
    • Architecture
  • SDK Guide

    • Java SDK
    • Go SDK
    • Python SDK
  • Reference

    • Node Types
    • Roam API
    • Server Config
    • Client Config
Playground
FAQ
  • Changelog
  • Upgrade Guide
Sponsor
Community
GitHub
  • English
  • 简体中文
  • Reference

    • Node Types
    • Roam API
    • Server Config
    • Client Config

Roam API

Roam is the core container for passing data between nodes. Thread-safe, with support for multi-level keys and reference syntax.

Implementation Basis

LanguageUnderlying ImplementationThread Safety Mechanism
JavaConcurrentHashMap<String, Object>CAS + segmented locks
Gosync.RWMutex + map[string]anyRead-write lock
Pythonthreading.RLock + dictReentrant lock

Basic Read/Write

Multi-Level Keys

Keys separated by . automatically build nested data structures:

Reference Syntax

The @ prefix indicates indirect value retrieval from Roam. Non-@ prefixed values are returned as-is:

Use Cases for Reference Syntax

In the Server configuration interface, leaf node field values can be set as @key to dynamically retrieve values from Roam instead of hardcoding them.

Complete Method List

Java (IceRoam)

MethodDescription
put(key, value)Write a value. Removes the key when value is null
get(key)Read a value, returns Object
putValue(key, value)Write a value (generic, no cast needed)
getValue(key)Read a value (generic, no cast needed)
putMulti(multiKey, value)Write nested structure using .-separated key
getMulti(multiKey)Read nested value using .-separated key
getUnion(union)Reference syntax: @ prefix fetches from roam

Go (Roam)

MethodDescription
Put(key, value)Write a value
Get(key)Read a value, returns any
GetInt(key, default)Read int
GetFloat64(key, default)Read float64
GetString(key)Read string
PutMulti(multiKey, value)Nested write
GetMulti(multiKey)Nested read
GetUnion(union)Reference syntax
Data()Return underlying map (read-only)
String()JSON-formatted output

Python (Roam)

MethodDescription
put(key, value)Write a value
get(key, default=None)Read a value
get_int(key, default=0)Read int
get_float(key, default=0.0)Read float
get_str(key, default="")Read str
get_bool(key, default=False)Read bool
get_list(key, default=None)Read list
get_dict(key, default=None)Read dict
put_multi(key, value)Nested write
get_multi(key)Nested read
get_union(union)Reference syntax
contains(key)Check if key exists
remove(key)Remove key
keys()All keys
to_dict()Convert to dict
shallow_copy()Shallow copy (used during parallel execution)
Edit this page on GitHub
Prev
Node Types
Next
Server Config