AWS IoT Device SDK C++ v2  1.32.6
AWS IoT Device SDK C++ v2
Public Member Functions | Friends | List of all members
Aws::Iotsecuretunneling::SecureTunnel Class Referencefinal

#include <SecureTunnel.h>

Public Member Functions

 SecureTunnel (Crt::Allocator *allocator, Crt::Io::ClientBootstrap *clientBootstrap, const Crt::Io::SocketOptions &socketOptions, const std::string &accessToken, aws_secure_tunneling_local_proxy_mode localProxyMode, const std::string &endpointHost, const std::string &rootCa, OnConnectionComplete onConnectionComplete, OnConnectionShutdown onConnectionShutdown, OnSendDataComplete onSendDataComplete, OnDataReceive onDataReceive, OnStreamStart onStreamStart, OnStreamReset onStreamReset, OnSessionReset onSessionReset)
 
 SecureTunnel (Crt::Allocator *allocator, const Crt::Io::SocketOptions &socketOptions, const std::string &accessToken, aws_secure_tunneling_local_proxy_mode localProxyMode, const std::string &endpointHost, const std::string &rootCa, OnConnectionComplete onConnectionComplete, OnConnectionShutdown onConnectionShutdown, OnSendDataComplete onSendDataComplete, OnDataReceive onDataReceive, OnStreamStart onStreamStart, OnStreamReset onStreamReset, OnSessionReset onSessionReset)
 
virtual ~SecureTunnel ()
 
 SecureTunnel (const SecureTunnel &)=delete
 
SecureTunneloperator= (const SecureTunnel &)=delete
 
 SecureTunnel (SecureTunnel &&) noexcept
 
SecureTunneloperator= (SecureTunnel &&) noexcept
 
bool IsValid ()
 
int Start ()
 
int Stop ()
 
int SendMessage (std::shared_ptr< Message > messageOptions) noexcept
 
int SendStreamStart ()
 
int SendStreamStart (std::string serviceId)
 
int SendStreamStart (Crt::ByteCursor serviceId)
 
int SendStreamStart (std::string serviceId, uint32_t connectionId)
 
int SendStreamStart (Crt::ByteCursor serviceId, uint32_t connectionId)
 
int SendConnectionStart (uint32_t connectionId)
 
int SendConnectionStart (std::string serviceId, uint32_t connectionId)
 
int SendConnectionStart (Crt::ByteCursor serviceId, uint32_t connectionId)
 
aws_secure_tunnel * GetUnderlyingHandle ()
 
int Connect ()
 
int Close ()
 
void Shutdown ()
 
int SendData (const Crt::ByteCursor &data)
 
int SendStreamReset ()
 

Friends

class SecureTunnelBuilder
 

Constructor & Destructor Documentation

◆ SecureTunnel() [1/4]

Aws::Iotsecuretunneling::SecureTunnel::SecureTunnel ( Crt::Allocator allocator,
Crt::Io::ClientBootstrap clientBootstrap,
const Crt::Io::SocketOptions socketOptions,
const std::string &  accessToken,
aws_secure_tunneling_local_proxy_mode  localProxyMode,
const std::string &  endpointHost,
const std::string &  rootCa,
OnConnectionComplete  onConnectionComplete,
OnConnectionShutdown  onConnectionShutdown,
OnSendDataComplete  onSendDataComplete,
OnDataReceive  onDataReceive,
OnStreamStart  onStreamStart,
OnStreamReset  onStreamReset,
OnSessionReset  onSessionReset 
)

Deprecated - Use SecureTunnelBuilder

◆ SecureTunnel() [2/4]

Aws::Iotsecuretunneling::SecureTunnel::SecureTunnel ( Crt::Allocator allocator,
const Crt::Io::SocketOptions socketOptions,
const std::string &  accessToken,
aws_secure_tunneling_local_proxy_mode  localProxyMode,
const std::string &  endpointHost,
const std::string &  rootCa,
OnConnectionComplete  onConnectionComplete,
OnConnectionShutdown  onConnectionShutdown,
OnSendDataComplete  onSendDataComplete,
OnDataReceive  onDataReceive,
OnStreamStart  onStreamStart,
OnStreamReset  onStreamReset,
OnSessionReset  onSessionReset 
)

Deprecated - Use SecureTunnelBuilder

◆ ~SecureTunnel()

Aws::Iotsecuretunneling::SecureTunnel::~SecureTunnel ( )
virtual

◆ SecureTunnel() [3/4]

Aws::Iotsecuretunneling::SecureTunnel::SecureTunnel ( const SecureTunnel )
delete

◆ SecureTunnel() [4/4]

Aws::Iotsecuretunneling::SecureTunnel::SecureTunnel ( SecureTunnel &&  other)
noexcept

Member Function Documentation

◆ Close()

int Aws::Iotsecuretunneling::SecureTunnel::Close ( )

Deprecated - Use Stop()

◆ Connect()

int Aws::Iotsecuretunneling::SecureTunnel::Connect ( )

Deprecated - use Start()

◆ GetUnderlyingHandle()

aws_secure_tunnel * Aws::Iotsecuretunneling::SecureTunnel::GetUnderlyingHandle ( )

◆ IsValid()

bool Aws::Iotsecuretunneling::SecureTunnel::IsValid ( )

◆ operator=() [1/2]

SecureTunnel& Aws::Iotsecuretunneling::SecureTunnel::operator= ( const SecureTunnel )
delete

◆ operator=() [2/2]

SecureTunnel & Aws::Iotsecuretunneling::SecureTunnel::operator= ( SecureTunnel &&  other)
noexcept

◆ SendConnectionStart() [1/3]

int Aws::Iotsecuretunneling::SecureTunnel::SendConnectionStart ( Crt::ByteCursor  serviceId,
uint32_t  connectionId 
)

Notifies the secure tunnel that you want to start a connection with the Destination device.

Parameters
serviceIdThe Service Id to start the connection on.
connectionIdThe connection id to start the connection on.
Returns
success/failure in the synchronous logic that kicks off the Stream Start operation

◆ SendConnectionStart() [2/3]

int Aws::Iotsecuretunneling::SecureTunnel::SendConnectionStart ( std::string  serviceId,
uint32_t  connectionId 
)

Notifies the secure tunnel that you want to start a connection with the Destination device.

Parameters
serviceIdThe Service Id to start the connection on.
connectionIdThe connection id to start the connection on.
Returns
success/failure in the synchronous logic that kicks off the Stream Start operation

◆ SendConnectionStart() [3/3]

int Aws::Iotsecuretunneling::SecureTunnel::SendConnectionStart ( uint32_t  connectionId)

Notifies the secure tunnel that you want to start a connection with the Destination device.

Parameters
connectionIdThe connection id to start the connection on.
Returns
success/failure in the synchronous logic that kicks off the Stream Start operation

◆ SendData()

int Aws::Iotsecuretunneling::SecureTunnel::SendData ( const Crt::ByteCursor data)

Deprecated - Use SendMessage()

◆ SendMessage()

int Aws::Iotsecuretunneling::SecureTunnel::SendMessage ( std::shared_ptr< Message messageOptions)
noexcept

Tells the secure tunnel to attempt to send a Message

Parameters
messageOptionsMessage to send to the secure tunnel service.
Returns
success/failure in the synchronous logic that kicks off the Send Message operation

◆ SendStreamReset()

int Aws::Iotsecuretunneling::SecureTunnel::SendStreamReset ( )

◆ SendStreamStart() [1/5]

int Aws::Iotsecuretunneling::SecureTunnel::SendStreamStart ( )

Notifies the secure tunnel that you want to start a stream with the Destination device. This will result in a V1 stream.

Returns
success/failure in the synchronous logic that kicks off the Stream Start operation

◆ SendStreamStart() [2/5]

int Aws::Iotsecuretunneling::SecureTunnel::SendStreamStart ( Crt::ByteCursor  serviceId)

Notifies the secure tunnel that you want to start a stream with the Destination device on a specific service id. This will result in a V2 stream.

Parameters
serviceIdThe Service Id to start a stream on.
Returns
success/failure in the synchronous logic that kicks off the Stream Start operation

◆ SendStreamStart() [3/5]

int Aws::Iotsecuretunneling::SecureTunnel::SendStreamStart ( Crt::ByteCursor  serviceId,
uint32_t  connectionId 
)

Notifies the secure tunnel that you want to start a stream with the Destination device on a specific service id. This will result in a V2 stream.

Parameters
serviceIdThe Service Id to start a stream on.
connectionIdThe Connection Id to start the stream on.
Returns
success/failure in the synchronous logic that kicks off the Stream Start operation

◆ SendStreamStart() [4/5]

int Aws::Iotsecuretunneling::SecureTunnel::SendStreamStart ( std::string  serviceId)

Notifies the secure tunnel that you want to start a stream with the Destination device on a specific service id. This will result in a V2 stream.

Parameters
serviceIdThe Service Id to start a stream on.
Returns
success/failure in the synchronous logic that kicks off the Stream Start operation

◆ SendStreamStart() [5/5]

int Aws::Iotsecuretunneling::SecureTunnel::SendStreamStart ( std::string  serviceId,
uint32_t  connectionId 
)

Notifies the secure tunnel that you want to start a stream with the Destination device on a specific service id. This will result in a V2 stream.

Parameters
serviceIdThe Service Id to start a stream on.
connectionIdThe Connection Id to start the stream on.
Returns
success/failure in the synchronous logic that kicks off the Stream Start operation

◆ Shutdown()

void Aws::Iotsecuretunneling::SecureTunnel::Shutdown ( )

Deprecated - Use Stop()

◆ Start()

int Aws::Iotsecuretunneling::SecureTunnel::Start ( )

Notifies the secure tunnel that you want it to attempt to connect to the configured endpoint. The secure tunnel will attempt to stay connected and attempt to reconnect if disconnected.

Returns
success/failure in the synchronous logic that kicks off the start process

◆ Stop()

int Aws::Iotsecuretunneling::SecureTunnel::Stop ( )

Notifies the secure tunnel that you want it to transition to the stopped state, disconnecting any existing connection and stopping subsequent reconnect attempts.

Returns
success/failure in the synchronous logic that kicks off the stop process

Friends And Related Function Documentation

◆ SecureTunnelBuilder

friend class SecureTunnelBuilder
friend

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