Struct SessionIdentity#

Struct Documentation#

struct SessionIdentity#

Who and what a recording is of. Every field is optional — an operator in a hurry must never be blocked from pressing Record, so an entirely empty identity is legal and falls back to the timestamp-only naming this app used before any of this existed.

Public Functions

bool has_entities() const#

True when no entity is set, i.e. this recording gets the legacy timestamp-only folder name. Notes deliberately do not count: a note is not an identity, and attaching one must not change where data lands.

QJsonObject to_json() const#

Entities only — notes are excluded on purpose. This goes into session_meta.json, which is written once and never rewritten; notes have to stay editable after the fact, so they cannot live there.

Public Members

QString subject#

BIDS “sub” label.

QString session#

BIDS “ses” label.

QString task#

BIDS “task” label.

QString notes#

Free text from the operator. Never enters a path, never sanitized as a label, and stored beside the session as notes.txt rather than inside session_meta.json — see RecordManager::start().

int run = 0#

1-based; 0 means “not yet resolved”, which is what the UI holds until build_session_path() scans the recordings directory for siblings.

Public Static Functions

static SessionIdentity from_json(const QJsonObject &obj)#

Re-sanitizes every label. Values reaching this have been round-tripped through settings.json, which a user can hand-edit, so a label arriving as “../../etc” must not be able to reach a path.