acs_ex v0.3.9 ACS.Session.Script.Vendor.Helpers View Source

Link to this section Summary

Functions

args must be a map with keys: “object_name” where the object name ends with

Sends a GetOptions request info the session

Sends a ChangeDUState request info the session

args must be a map with keys: “object_name” where the object name ends with

Sends a Download request info the session

Extracts the Parameters from an inform. Returns a map with parameters and values

Sends a FactoryReset request info the session

Sends an GetAllQueuedTransfers request info the session

Sends a GetOptions request info the session

args will be a list of string with paramter names for which you want to retrieve attributes

args will be a maps with keys “parameter_path” and “next_level”

args will be a list of names for the actual cwmp request

Sends a GetQueuedTransfers request info the session

GetRPCMethods, no args

Determines if an EventStruct of an Inform contains a specific event

call the session server with the script_commmand: reboot

Sends a ScheduleDownload request info the session

Sends a ScheduleInform request info the session

Get the current list of ACS messages, i.e. TransferComplete aso from the session

args will be a list of maps each with keys “name”, “notification_change”, “notification”, “accesslist_change” and “accesslist”

args must be a list of maps with “name”, “type”, “value”

Sends a SetVouchers request info the session

Sends an Upload request info the session

Link to this section Functions

Link to this function addObject(session, args) View Source

args must be a map with keys: “object_name” where the object name ends with .

Link to this function cancelTransfer(session, args) View Source

Sends a GetOptions request info the session.

Args is a commandkey, just a string

Link to this function changeDUState(session, args) View Source

Sends a ChangeDUState request info the session.

args is a map containing the keys needed to generate at CWMP.Protocol.Messages.ChangeDUState structure. This means that the elements in the operations list need to be one (or more) of the struct types: %CWMP.Protocol.Messages.InstallOpStruct{url: url, uuid: uuid, username: user, password: pass, execution_env_ref: eer} %CWMP.Protocol.Messages.UpdateOpStruct{url: url, uuid: uuid, username: user, password: pass, version: ver} %CWMP.Protocol.Messages.UninstallOpStruct{url: url, uuid: uuid, execution_env_ref: eer}

For example:

  commandkey (May be "")
  operations: [
    %CWMP.Protocol.Messages.InstallOpStruct{
      url
      uuid
      username (May be "")
      password (May be "")
      execution_env_ref
    }]
Link to this function deleteObject(session, args) View Source

args must be a map with keys: “object_name” where the object name ends with .

An optional parameter_key can be given

Returns a CWMP.Protocol.Messages.AddObjectResponse

Sends a Download request info the session.

args is a map containing the keys needed to generate at CWMP.Protocol.Messages.Download structure. i.e. “url”, “filetype”, “filesize” at least.

Extracts the Parameters from an inform. Returns a map with parameters and values.

Sends a FactoryReset request info the session.

Link to this function getAllQueuedTransfers(session) View Source

Sends an GetAllQueuedTransfers request info the session.

Link to this function getOptions(session, args) View Source

Sends a GetOptions request info the session.

Args is the option name, just a string

Link to this function getParameterAttributes(session, args) View Source

args will be a list of string with paramter names for which you want to retrieve attributes.

Return value will be a CWMP.Protocol.Messages.GetParameterAttributesResponse struct

Link to this function getParameterNames(session, args) View Source

args will be a maps with keys “parameter_path” and “next_level”

Link to this function getParameterValues(session, args) View Source

args will be a list of names for the actual cwmp request.

Link to this function getQueuedTransfers(session) View Source

Sends a GetQueuedTransfers request info the session.

GetRPCMethods, no args

Link to this function has_event?(inform, eventname) View Source

Determines if an EventStruct of an Inform contains a specific event.

call the session server with the script_commmand: reboot

Link to this function scheduleDownload(session, args) View Source

Sends a ScheduleDownload request info the session.

args is a map containing the keys needed to generate at CWMP.Protocol.Messages.ScheduleDownload structure. i.e.

  commandkey (May be empty)
  filetype
  url
  username (Optional)
  password (Optional)
  filesize
  target_filename (Optional)
  timewindowlist [%{
    window_start
    window_end
    window_mode
    user_message (May be "")
    max_retries}]
Link to this function scheduleInform(session, args) View Source

Sends a ScheduleInform request info the session.

Link to this function session_call(session, command) View Source
Link to this function session_messages(session) View Source

Get the current list of ACS messages, i.e. TransferComplete aso from the session.

Link to this function setParameterAttributes(session, args) View Source

args will be a list of maps each with keys “name”, “notification_change”, “notification”, “accesslist_change” and “accesslist”.

Link to this function setParameterValues(session, args) View Source

args must be a list of maps with “name”, “type”, “value”

Link to this function setVouchers(session, args) View Source

Sends a SetVouchers request info the session.

Sends an Upload request info the session.

Args is a map containing at least commandkey, filetype and url out of the following possible keys, here listed with defaults:

      commandkey: "",
      filetype: nil,
      url: nil,
      username: "",
      password: "",
      delay_seconds: 0