Options
All
  • Public
  • Public/Protected
  • All
Menu

Class GrafanaHTTP

Hierarchy

Implements

Index

Constructors

constructor

  • Construct a new GrafanaHTTP implementation

    constructor

    Parameters

    • backendSrv: any

      the Grafana BackendSrv object to use for requests

    • Optional server: OnmsServer

      the OpenNMS server to make requests to

    Returns GrafanaHTTP

Properties

Private backendSrv

backendSrv: any

the Grafana backend object we'll use for making ReST calls

options

the authorization config associated with this ReST client

timeout

timeout: number = 10000

how long to wait before giving up on a given request

Accessors

server

  • the server associated with this HTTP implementation

    Returns OnmsServer

  • the server associated with this HTTP implementation

    Parameters

    Returns void

Methods

get

  • make an HTTP GET call using the Grafana backendSrv

    Parameters

    Returns any

Private getConfig

  • internal method to turn OnmsHTTPOptions into a Grafana BackendSrv request object.

    Parameters

    Returns any

Protected getOptions

  • combine all options from the given options, the current server, and the default options

    Parameters

    Returns any

Protected getServer

Protected onSetServer

  • onSetServer(): void
  • useful for performing an action (like clearing caches) when the server is set

    Returns void

put

  • make an HTTP PUT call using the Grafana backendSrv

    Parameters

    Returns any

Protected transformJSON

  • transformJSON(data: any): any
  • a convenience method for implementers to use to turn JSON into a javascript object

    Parameters

    • data: any

    Returns any

Protected transformXML

  • transformXML(data: any): any
  • a convenience method for implementers to use to turn XML into a javascript object

    Parameters

    • data: any

    Returns any

Generated using TypeDoc