Skip to content

Class: ConfigTransaction ​

Defined in: netconf/src/content/configure.ts:44

Collects edits for one <edit-config>. Paths may be @name aliases from the device profile, given every parameter they take. A malformed path throws when the edit is added; module namespaces (and aliases) are resolved when the transaction is built, so the client can learn them from the YANG library first.

Accessors ​

size ​

Get Signature ​

ts
get size(): number;

Defined in: netconf/src/content/configure.ts:95

How many edits have been added so far, path and JSON edits alike.

Returns ​

number

Methods ​

create() ​

ts
create(path, value): this;

Defined in: netconf/src/content/configure.ts:80

Create the node; the server reports data-exists if it already exists.

Parameters ​

path ​

string

value ​

EditValue

Returns ​

this


delete() ​

ts
delete(path): this;

Defined in: netconf/src/content/configure.ts:85

Delete the node; the server reports data-missing if it doesn't exist.

Parameters ​

path ​

string

Returns ​

this


merge() ​

ts
merge(json): this;

Defined in: netconf/src/content/configure.ts:75

Merge an RFC 7951 JSON object into the configuration, as JSON config on edit-config is: converted with the YANG schema of the workflow's edit target, its RFC 7952 metadata (ietf-netconf:operation, yang:insert) becoming the edit attributes. Mixes with path edits, as long as they don't share a top-level node.

Parameters ​

json ​

YangJsonObject

Returns ​

this


remove() ​

ts
remove(path): this;

Defined in: netconf/src/content/configure.ts:90

Delete the node if it exists (idempotent).

Parameters ​

path ​

string

Returns ​

this


replace() ​

Call Signature ​

ts
replace(path, value): this;

Defined in: netconf/src/content/configure.ts:61

Replace the node at path and everything under it with value; or, given only an RFC 7951 JSON object, replace each of its top-level members (sent with the NETCONF replace operation).

Parameters ​
path ​

string

value ​

EditValue

Returns ​

this

Call Signature ​

ts
replace(json): this;

Defined in: netconf/src/content/configure.ts:62

Replace the node at path and everything under it with value; or, given only an RFC 7951 JSON object, replace each of its top-level members (sent with the NETCONF replace operation).

Parameters ​
json ​

YangJsonObject

Returns ​

this


set() ​

ts
set(path, value): this;

Defined in: netconf/src/content/configure.ts:52

Merge a value into the configuration (creates the node if needed).

Parameters ​

path ​

string

value ​

EditValue

Returns ​

this

Released under the MIT Licence.