Result Object

Hierarchy

  • ResultWrapper

Constructors

Properties

datasets: Map<any, Dataset>

Map of Datasets created using addNewDataset

params: Map<any, any>

Map of Result params.

Example

Here's some example code to add Result param:

var resultObj = voltMX.getResultObject();
resultObj.params['Param1']='P1Val';
resultObj.update();

Methods

  • Add New Dataset to Result.

    Example

    Here's some example code to Add New Dataset:

    var resultObj = voltMX.getResultObject();
    resultObj.addNewDataset('id1');
    resultObj.dataset['id1'].addNewRecord('r00');
    resultObj.dataset['id1'].addNewRecord('r00').param['p1']='v1';
    resultObj.update();

    Parameters

    • arg: any

      record id

    Returns Dataset

  • append Json Object data to Result

    Example

    • Here's some example code to set OpStatus Result param:
      • ```ts
      • var resultObj = voltMX.getResultObject(); var jsonStr = '{ x: 5, y: 6 }'; var jsonObject = JSON.parse(jsonStr);
      • resultObj.appendJson(jsonObject);
      • resultObj.update();
      • ```

    Parameters

    • arg: object

    Returns void

  • Set HttpStatus in Result params.

    Example

    Here's some example code to set HttpStatus Result param:

    var resultObj = voltMX.getResultObject();
    resultObj.setHttpStatus(400);
    resultObj.update();

    Parameters

    • arg: any

    Returns void

  • Set OpStatus in Result params.

    Example

    Here's some example code to set OpStatus Result param:

    var resultObj = voltMX.getResultObject();
    resultObj.setOpStatus(1);
    resultObj.update();

    Parameters

    • arg: any

    Returns void

  • Return Result data as Json data Object

    Example

    • Here's some example code to set OpStatus Result param:
      • ```ts
      • var resultObj = voltMX.getResultObject();
      • var jsonObject = resultObj.toJson();
      • ```

    Returns object

  • Returns void

Generated using TypeDoc