On this page

# NetworkRequestsHandler

This is the manager keeping track of all the open transactions published for the network nodes.

## Constructor

### new NetworkRequestsHandler()

Source
  - models/network.requests.handler.js, line 427

## Members

### (private) pendingRequests :Object

The list of open transactions.

Type:

- Object

Source
  - models/network.requests.handler.js, line 434

### (private) requestsIndexes :Object

The list of object transactions indexed by the notification `path`s targeted.

Type:

- Object

Source
  - models/network.requests.handler.js, line 442

## Methods

### createRequest(action, onSuccess, onFail) → {NetworkRequest}

Creates a new transaction handling the message publishing for a network node.

Parameters:

Name | Type | Description
--- | --- | ---
`action` | string |
`onSuccess` | function |
`onFail` | function |

Source
  - models/network.requests.handler.js, line 452

Returns:

Type:
  NetworkRequest

### destroy(path) → {NetworkRequestsHandler}

Cleans up the transaction handler related to the supplied `path`.

Parameters:

Name | Type | Description
--- | --- | ---
`path` | Array.<string> |

Source
  - models/network.requests.handler.js, line 503

Returns:

Type:
  NetworkRequestsHandler

### find(path) → {NetworkRequest|null}

Retrieves the transaction handler watching for the supplied `path`.

Parameters:

Name | Type | Description
--- | --- | ---
`path` | Array.<string> |

Source
  - models/network.requests.handler.js, line 493

Returns:

Type:
  NetworkRequest | null

### index(path, request) → {NetworkRequestsHandler}

Indexes the transaction `request` by the specified notification `path` to watch for.

Parameters:

Name | Type | Description
--- | --- | ---
`path` | Array.<string> |
`request` | NetworkRequest |

Source
  - models/network.requests.handler.js, line 481

Returns:

Type:
  NetworkRequestsHandler

Type anything to view search result