# ConnectionGraph2 Class Reference
[ConnectionGraph]

A one hop connection graph. Sends ID_CONNECTION_GRAPH_DISCONNECTION_NOTIFICATION, ID_CONNECTION_GRAPH_CONNECTION_LOST, ID_CONNECTION_GRAPH_NEW_CONNECTION All identifiers are followed by SystemAddress, then RakNetGUID. More...

`#include <ConnectionGraph2.h>`

Inheritance diagram for ConnectionGraph2:

List of all members.

## Protected Member Functions
virtual void | OnClosedConnection (SystemAddress systemAddress, RakNetGUID rakNetGUID, PI2_LostConnectionReason lostConnectionReason)
virtual void | OnNewConnection (SystemAddress systemAddress, RakNetGUID rakNetGUID, bool isIncoming)

## Detailed Description

A one hop connection graph. Sends ID_CONNECTION_GRAPH_DISCONNECTION_NOTIFICATION, ID_CONNECTION_GRAPH_CONNECTION_LOST, ID_CONNECTION_GRAPH_NEW_CONNECTION All identifiers are followed by SystemAddress, then RakNetGUID.

## Member Function Documentation

void ConnectionGraph2::OnClosedConnection | ( | SystemAddress | systemAddress,
|  | RakNetGUID | rakNetGUID,
|  | PI2_LostConnectionReason | lostConnectionReason |
| ) |  |  | `[protected, virtual]`

Called when a connection is dropped because the user called RakPeer::CloseConnection() for a particular system

Parameters:

  `[in]` | systemAddress | The system whose connection was closed
  `[in]` | rakNetGuid | The guid of the specified system
  `[in]` | lostConnectionReason | How the connection was closed: manually, connection lost, or notification of disconnection

Reimplemented from PluginInterface2.

void ConnectionGraph2::OnNewConnection | ( | SystemAddress | systemAddress,
|  | RakNetGUID | rakNetGUID,
|  | bool | isIncoming |
| ) |  |  | `[protected, virtual]`

Called when we got a new connection

Parameters:

  `[in]` | systemAddress | Address of the new connection
  `[in]` | rakNetGuid | The guid of the specified system
  `[in]` | isIncoming | If true, this is ID_NEW_INCOMING_CONNECTION, or the equivalent

Reimplemented from PluginInterface2.

The documentation for this class was generated from the following files:

- C:/RakNet/Source/ConnectionGraph2.h
- C:/RakNet/Source/ConnectionGraph2.cpp