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. | |
Outcome of a lock_token_in_designmd call.
ok is the only success path; on failure updated_markdown equals the input byte-for-byte.
| std::string pulp::view::TokenLockResult::error |
Human-readable failure reason when ok is false; empty on success.
| 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.
| bool pulp::view::TokenLockResult::ok = false |
| 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.
| 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).