Path

ExecuteRPC(provider ServiceProvider, entity Entity, filter string, dataTag string, setConfigFlag bool)

Executes payload converted from entity.

Parameters:
  • provider – (Service Providers).
  • entity – (Entity).
  • filter – (string) A Go string.
  • dataTag – (string) A Go string.
  • setConfigFlag – (bool) A Go bool.
Returns:

A data node representing the result of the executed rpc.

Return type:

DataNode

ExecuteRPCEntity(provider ServiceProvider, rpcEntity, topEntity types.Entity)

Executes payload converted from entity.

Parameters:
Returns:

An entity representing the result of the executed rpc.

Return type:

Entity

ReadDatanode(filter Entity, readDataNode DataNode)

Populates entity by reading the top level entity from a given data node

Parameters:
Returns:

The top entity from readDataNode.

Return type:

Entity

ConnectToNetconfProvider(state *State, repo Repository, address, username, password string, port int)

Connects to NETCONF service provider by creating a connection to the given provider using given address, username, password, and port.

Parameters:
  • state – (pointer to State) Current state of execution
  • repo – (Repository).
  • address – (string) A Go string.
  • username – (string) A Go string.
  • password – (string) A Go string.
  • port – (int) An integer.
Returns:

The connected service provider.

Return type:

CServiceProvider

DisconnectFromNetconfProvider(provider CServiceProvider)

Disconnects from NETCONF device and frees the given service provider

Param:provider: (CServiceProvider) A service provider instance.
GetCapabilitesFromNetconfProvider(provider CServiceProvider)

Gets the of capabilities supported by the given provider.

Param:provider: (CServiceProvider) A service provider instance.
Returns:The list of capabilities.
Return type:[]string
CleanUpErrorState(state *State)

CleanUpErrorState cleans up memory for CState

Parameters:state – (pointer to State) Current state of execution
ConnectToRestconfProvider(state *State, path, address, username, password string, port int)

ConnectToRestconfProvider connects to RESTCONF device by creating a connection to the provider using given path, address, username, password, and port.

Parameters:
  • state – (pointer to State) Current state of execution
  • path – (string) A Go string.
  • address – (string) A Go string.
  • username – (string) A Go string.
  • password – (string) A Go string.
  • port – (int) An integer.
Returns:

The connected service provider.

Return type:

CServiceProvider

DisconnectFromRestconfProvider(provider CServiceProvider)

DisconnectFromRestconfProvider disconnects from RESTCONF device and frees the given service provider

Param:provider: (CServiceProvider) A service provider instance.
InitCodecServiceProvider(state *State, entity Entity, repo Repository)

InitCodecServiceProvider initializes CodecServiceProvider

Parameters:
Returns:

The root schema node parsed from repository

Return type:

RootSchemaNode

CodecServiceEncode(state *State, entity Entity, rootSchema RootSchemaNode, encoding EncodingFormat)

CodecServiceEncode encodes entity to XML/JSON payloads based on encoding format passed in

Parameters:
Returns:

The resulting payload.

Return type:

(string) A Go string.

CodecServiceDecode(state *State, rootSchema RootSchemaNode, payload string, encoding EncodingFormat, topEntity Entity)

CodecServiceDecode decodes XML/JSON payloads passed in to entity.

Parameters:
Returns:

The top level entity from resulting data node.

Return type:

Entity

ConnectToOpenDaylightProvider(state *State, path, address, username, password string, port int, encoding EncodingFormat, protocol Protocol)

ConnectToOpenDaylightProvider connects to OpenDaylight device.

Parameters:
  • state – (pointer to State) Current state of execution
  • path – (string) A Go string.
  • address – (string) A Go string.
  • username – (string) A Go string.
  • password – (string) A Go string.
  • port – (int) An integer.
  • encoding – (Encoding Format).
  • protocol – (Protocol).
Returns:

The connected service provider.

Return type:

COpenDaylightServiceProvider

DisconnectFromOpenDaylightProvider(provider COpenDaylightServiceProvider)

DisconnectFromOpenDaylightProvider disconnects from OpenDaylight device and frees allocated memory.

Parameters:provider – (COpenDaylightServiceProvider).
OpenDaylightServiceProviderGetNodeIDs(state *State, provider COpenDaylightServiceProvider)

A getter function for the node ids given the opendaylight service provider.

Parameters:
Returns:

A slice of Go strings representing node ids.

Return type:

[]string

OpenDaylightServiceProviderGetNodeProvider(provider COpenDaylightServiceProvider, nodeID string)

A getter function for the node provider given the opendaylight service provider and node id.

Parameters:
Returns:

The service provider.

Return type:

CServiceProvider

AddCState(state *State)

AddCState creates and adds cstate to given state.

Parameters:state – (pointer to State) Current state of execution