Pulp 1.88.0
Cross-platform audio plugin framework
Loading...
Searching...
No Matches
pulp::view::TokenLockResult Struct Reference

Outcome of a lock_token_in_designmd call. More...

#include <token_lock.hpp>

Public Attributes

bool ok = false
std::string error
 Human-readable failure reason when ok is false; empty on success.
std::string updated_markdown
 The rewritten DESIGN.md text.
std::string previous_value
 The value found at the token before the rewrite — lets the inspector show a "was X, now Y" confirmation and supports an eventual Unlock (inverse delta).
int line = 0
 1-based line number within DESIGN.md that was rewritten; 0 on failure.

Detailed Description

Outcome of a lock_token_in_designmd call.

ok is the only success path; on failure updated_markdown equals the input byte-for-byte.

Member Data Documentation

◆ error

std::string pulp::view::TokenLockResult::error

Human-readable failure reason when ok is false; empty on success.

◆ line

int pulp::view::TokenLockResult::line = 0

1-based line number within DESIGN.md that was rewritten; 0 on failure.

Useful for a diff-preview UI.

◆ ok

bool pulp::view::TokenLockResult::ok = false

◆ previous_value

std::string pulp::view::TokenLockResult::previous_value

The value found at the token before the rewrite — lets the inspector show a "was X, now Y" confirmation and supports an eventual Unlock (inverse delta).

Empty on failure.

◆ updated_markdown

std::string pulp::view::TokenLockResult::updated_markdown

The rewritten DESIGN.md text.

On success this differs from the input by exactly the one token value; on failure it is the input unchanged (callers may write it back unconditionally and be safe).


The documentation for this struct was generated from the following file:
  • /home/runner/work/pulp/pulp/core/view/include/pulp/view/token_lock.hpp