Options
All
  • Public
  • Public/Protected
  • All
Menu

OpenNMS.js

Index

DAO Classes

Filtering API Classes

Internal Classes

Model Classes

Rest API Classes

Rest Implementation Classes

DAO Interfaces

Filtering API Interfaces

Internal Interfaces

Rest Interfaces

API Variables

Filtering API Variables

Filtering API Functions

Model Object literals

Other Object literals

API Variables

Const log

log: Logger = new Logger()

The default logging implementation. Import a logger using:

import {log} from 'api/Logger';

Filtering API Variables

Const Comparators

Comparators: object = {/** Equals (`=` or `==`) */EQ: new Comparator(1, 'EQ', '=', '=='),/** Not Equals (`!=`) */NE: new Comparator(2, 'NE', '!='),/** Case-Insensitive Substring Match (`ILIKE`) */ILIKE: new Comparator(3, 'ILIKE'),/** Case-Sensitive Substring Match (`LIKE`) */LIKE: new Comparator(4, 'LIKE'),/** Greater Than (`>`) */GT: new Comparator(5, 'GT', '>'),/** Less Than (`<`) */LT: new Comparator(6, 'LT', '<'),/** Greater Than or Equal To (`>=`) */GE: new Comparator(7, 'GE', '>='),/** Less Than or Equal To (`<=`) */LE: new Comparator(8, 'LE', '<='),/** Is Null (`NULL`) */NULL: new Comparator(9, 'NULL', 'ISNULL'),/** Is Not Null (`NOTNULL`) */NOTNULL: new Comparator(10, 'NOTNULL'),/*ALL: new Comparator(9, 'ALL'),ANY: new Comparator(10, 'ANY'),BETWEEN: new Comparator(15, 'BETWEEN'),NOT: new Comparator(14, 'NOT'),IN: new Comparator(13, 'IN'),IPLIKE: new Comparator(17, 'IPLIKE'),SQL: new Comparator(16, 'SQL'),*/} as { [key: string]: Comparator }

Contains constant instances of all available comparators.

Type declaration

Filtering API Functions

Const addParameter

  • addParameter(hash: IHash<string | string[]>, key: string, value: any): void
  • A utility method to be used by IFilterProcessor to handle multi-value parameters.

    Parameters

    • hash: IHash<string | string[]>
    • key: string
    • value: any

    Returns void

Model Object literals

Const AlarmTypes

AlarmTypes: object

Contains constant instances of all available alarm types.

1

1: OnmsAlarmType = new OnmsAlarmType(1, 'possible resolution')

Possible Resolution

2

2: OnmsAlarmType = new OnmsAlarmType(2, 'resolution event')

Resolution Event

3

3: OnmsAlarmType = new OnmsAlarmType(3, 'no possible resolution')

No Possible Resolution

Const CollectTypes

CollectTypes: object

Contains constant instances of all available collect types.

COLLECT

COLLECT: OnmsCollectType = new OnmsCollectType('C', 'COLLECT')

Collection Enabled

DO_NOT_COLLECT

DO_NOT_COLLECT: OnmsCollectType = new OnmsCollectType('N', 'DO_NOT_COLLECT')

Collection is disabled

FORCE_COLLECT

FORCE_COLLECT: OnmsCollectType = new OnmsCollectType('UC', 'FORCE_COLLECT')

User has forced collection

FORCE_DO_NOT_COLLECT

FORCE_DO_NOT_COLLECT: OnmsCollectType = new OnmsCollectType('UN', 'FORCE_DO_NOT_COLLECT')

User has forced collection to be disabled

Const FeedbackTypes

FeedbackTypes: object

Contains constant instances of all feedback types.

CORRECT

CORRECT: OnmsSituationFeedbackType = new OnmsSituationFeedbackType('CORRECT', 'CORRECT')

Alarm is correctly correlated

CREATE_SITUATION

CREATE_SITUATION: OnmsSituationFeedbackType = new OnmsSituationFeedbackType('CREATE_SITUATION', 'CREATE_SITUATION')

Alarm should be correlated in a new Situation

FALSE_NEGATIVE

FALSE_NEGATIVE: OnmsSituationFeedbackType = new OnmsSituationFeedbackType('FALSE_NEGATIVE', 'FALSE_NEGATIVE')

Alarm was incorrectly ommitted

FALSE_POSITIVE

FALSE_POSITIVE: OnmsSituationFeedbackType = new OnmsSituationFeedbackType('FALSE_POSITIVE', 'FALSE_POSITIVE')

Alarm was incorrectly correlated

Const ManagedTypes

ManagedTypes: object

Contains constant instances of all managed types.

ALIAS

ALIAS: OnmsManagedType = new OnmsManagedType('A', 'ALIAS')

Interface is an alias

DELETED

DELETED: OnmsManagedType = new OnmsManagedType('D', 'DELETED')

Interface is deleted

FORCE_UNMANAGED

FORCE_UNMANAGED: OnmsManagedType = new OnmsManagedType('F', 'FORCE_UNMANAGED')

User has forced management to be disabled

MANAGED

MANAGED: OnmsManagedType = new OnmsManagedType('M', 'MANAGED')

Interface is managed

NOT_POLLED

NOT_POLLED: OnmsManagedType = new OnmsManagedType('N', 'NOT_POLLED')

Interface is not polled

REMOTE_ONLY

REMOTE_ONLY: OnmsManagedType = new OnmsManagedType('X', 'REMOTE_ONLY')

Interface should only be polled remotely

UNMANAGED

UNMANAGED: OnmsManagedType = new OnmsManagedType('U', 'UNMANAGED')

Interface is not managed

Const NodeLabelSources

NodeLabelSources: object

Contains constant instances of all available node label sources.

ADDRESS

ADDRESS: OnmsNodeLabelSource = new OnmsNodeLabelSource('A', 'ADDRESS')

Node label is the node's primary IP address

HOSTNAME

HOSTNAME: OnmsNodeLabelSource = new OnmsNodeLabelSource('H', 'HOSTNAME')

Node label is the node's hostname

NETBIOS

NETBIOS: OnmsNodeLabelSource = new OnmsNodeLabelSource('N', 'NETBIOS')

Node label was retrieved from NETBIOS/Windows

SYSNAME

SYSNAME: OnmsNodeLabelSource = new OnmsNodeLabelSource('S', 'SYSNAME')

Node label is the node's SNMP sysname

UNKNOWN

UNKNOWN: OnmsNodeLabelSource = new OnmsNodeLabelSource(' ', 'UNKNOWN')

Node label source is unknown

USER

USER: OnmsNodeLabelSource = new OnmsNodeLabelSource('U', 'USER')

Node label is set by the user.

Const NodeTypes

NodeTypes: object

Contains constant instances of all node types.

ACTIVE

ACTIVE: OnmsNodeType = new OnmsNodeType('A', 'ACTIVE')

Node is active

DELETED

DELETED: OnmsNodeType = new OnmsNodeType('D', 'DELETED')

Node is disabled

UNKNOWN

UNKNOWN: OnmsNodeType = new OnmsNodeType(' ', 'UNKNOWN')

Node state is unknown

Const Operators

Operators: object

Contains constant instances of all operators.

AND

AND: Operator = new Operator(1, 'AND')

AND (all must match)

OR

OR: Operator = new Operator(2, 'OR')

OR (at least one must match)

Const PrimaryTypes

PrimaryTypes: object

Contains constant instances of all primary SNMP types.

NOT_ELIGIBLE

NOT_ELIGIBLE: OnmsPrimaryType = new OnmsPrimaryType('N', 'NOT_ELIGIBLE')

SNMP interface is not eligible for collection

PRIMARY

PRIMARY: OnmsPrimaryType = new OnmsPrimaryType('P', 'PRIMARY')

Primary SNMP interface

SECONDARY

SECONDARY: OnmsPrimaryType = new OnmsPrimaryType('S', 'SECONDARY')

Secondary SNMP interface

Const SearchPropertyTypes

SearchPropertyTypes: object

Contains constant instances of all search property types.

FLOAT

FLOAT: SearchPropertyType = new SearchPropertyType('FLOAT', 'floating-point number', NumberComparators)

INTEGER

INTEGER: SearchPropertyType = new SearchPropertyType('INTEGER', 'integer', NumberComparators)

IP_ADDRESS

IP_ADDRESS: SearchPropertyType = new SearchPropertyType('IP_ADDRESS', 'IP address', StringComparators)

LONG

LONG: SearchPropertyType = new SearchPropertyType('LONG', 'long integer', NumberComparators)

STRING

STRING: SearchPropertyType = new SearchPropertyType('STRING', 'string', StringComparators)

TIMESTAMP

TIMESTAMP: SearchPropertyType = new SearchPropertyType('TIMESTAMP', 'date and time', NumberComparators)

Const ServerTypes

ServerTypes: object

Contains constant instances of all server types.

HORIZON

HORIZON: ServerType = new ServerType(1, 'HORIZON')

OpenNMS Horizon

MERIDIAN

MERIDIAN: ServerType = new ServerType(2, 'MERIDIAN')

OpenNMS Meridian

Const ServiceStatusTypes

ServiceStatusTypes: object

Contains constant instances of all service status types.

DELETED

DELETED: OnmsServiceStatusType = new OnmsServiceStatusType('D', 'DELETED')

Service has been deleted

FORCED_UNMANAGED

FORCED_UNMANAGED: OnmsServiceStatusType = new OnmsServiceStatusType('F', 'FORCED_UNMANAGED')

User has forced the service to be unmanaged

MANAGED

MANAGED: OnmsServiceStatusType = new OnmsServiceStatusType('A', 'MANAGED')

Service is managed

NOT_MONITORED

NOT_MONITORED: OnmsServiceStatusType = new OnmsServiceStatusType('N', 'NOT_MONITORED')

Service is not monitored

REMOTELY_MONITORED

REMOTELY_MONITORED: OnmsServiceStatusType = new OnmsServiceStatusType('X', 'REMOTELY_MONITORED')

Service should only be monitored from remote locations

RESCAN_TO_RESUME

RESCAN_TO_RESUME: OnmsServiceStatusType = new OnmsServiceStatusType('R', 'RESCAN_TO_RESUME')

Service is temporarily unmanaged, rescan to resume

RESCAN_TO_SUSPEND

RESCAN_TO_SUSPEND: OnmsServiceStatusType = new OnmsServiceStatusType('S', 'RESCAN_TO_SUSPEND')

Service is managed, rescan to suspend monitoring

UNMANAGED

UNMANAGED: OnmsServiceStatusType = new OnmsServiceStatusType('U', 'UNMANAGED')

Service is unmanaged

Const Severities

Severities: object

Contains constant instances of all severities.

CLEARED

CLEARED: OnmsSeverity = new OnmsSeverity(2, 'CLEARED')

CRITICAL

CRITICAL: OnmsSeverity = new OnmsSeverity(7, 'CRITICAL')

INDETERMINATE

INDETERMINATE: OnmsSeverity = new OnmsSeverity(1, 'INDETERMINATE')

MAJOR

MAJOR: OnmsSeverity = new OnmsSeverity(6, 'MAJOR')

MINOR

MINOR: OnmsSeverity = new OnmsSeverity(5, 'MINOR')

NORMAL

NORMAL: OnmsSeverity = new OnmsSeverity(3, 'NORMAL')

WARNING

WARNING: OnmsSeverity = new OnmsSeverity(4, 'WARNING')

Const SnmpStatusTypes

SnmpStatusTypes: object

Contains constant instances of all SNMP status types.

1

1: OnmsSnmpStatusType = new OnmsSnmpStatusType(1, 'UP')

Device is up

2

2: OnmsSnmpStatusType = new OnmsSnmpStatusType(2, 'DOWN')

Device is down

3

3: OnmsSnmpStatusType = new OnmsSnmpStatusType(3, 'TESTING')

Device is in "testing" mode

Const TroubleTicketStates

TroubleTicketStates: object

Contains constant instances of all trouble ticket states.

CANCELLED

CANCELLED: OnmsTroubleTicketState = new OnmsTroubleTicketState(11, 'CANCELLED')

Trouble ticket has been canceled

CANCEL_FAILED

CANCEL_FAILED: OnmsTroubleTicketState = new OnmsTroubleTicketState(13, 'CANCEL_FAILED')

An attempt to mark the ticket canceled in the remote helpdesk system has failed

CANCEL_PENDING

CANCEL_PENDING: OnmsTroubleTicketState = new OnmsTroubleTicketState(12, 'CANCEL_PENDING')

Trouble ticket is in the process of being marked as canceled

CLOSED

CLOSED: OnmsTroubleTicketState = new OnmsTroubleTicketState(5, 'CLOSED')

Trouble ticket has been closed

CLOSE_FAILED

CLOSE_FAILED: OnmsTroubleTicketState = new OnmsTroubleTicketState(7, 'CLOSE_FAILED')

An attempt to mark the ticket closed in the remote helpdesk system has failed

CLOSE_PENDING

CLOSE_PENDING: OnmsTroubleTicketState = new OnmsTroubleTicketState(6, 'CLOSE_PENDING')

Trouble ticket is pending closure in the remote helpdesk system

CREATE_FAILED

CREATE_FAILED: OnmsTroubleTicketState = new OnmsTroubleTicketState(2, 'CREATE_FAILED')

Trouble ticket creation has failed

CREATE_PENDING

CREATE_PENDING: OnmsTroubleTicketState = new OnmsTroubleTicketState(1, 'CREATE_PENDING')

Trouble ticket is being created

OPEN

OPEN: OnmsTroubleTicketState = new OnmsTroubleTicketState(0, 'OPEN')

Trouble ticket is currently open

RESOLVED

RESOLVED: OnmsTroubleTicketState = new OnmsTroubleTicketState(8, 'RESOLVED')

Trouble ticket has been resolved

RESOLVE_FAILED

RESOLVE_FAILED: OnmsTroubleTicketState = new OnmsTroubleTicketState(10, 'RESOLVE_FAILED')

Resolving ticket in the remote helpdesk system has failed

RESOLVE_PENDING

RESOLVE_PENDING: OnmsTroubleTicketState = new OnmsTroubleTicketState(9, 'RESOLVE_PENDING')

Trouble ticket is in the process of being marked resolved

UPDATE_FAILED

UPDATE_FAILED: OnmsTroubleTicketState = new OnmsTroubleTicketState(4, 'UPDATE_FAILED')

Updating ticket state from the remote helpdesk system failed

UPDATE_PENDING

UPDATE_PENDING: OnmsTroubleTicketState = new OnmsTroubleTicketState(3, 'UPDATE_PENDING')

Trouble ticket is pending an update from the remote helpdesk system

Other Object literals

Const Orders

Orders: object

ASC

ASC: Order = new Order('ASC', 'ASC')

DESC

DESC: Order = new Order('DESC', 'DESC')

Generated using TypeDoc