# class JBConnect | A socket connector. More...
Full name | `TelEngine::JBConnect`
Definition | `#include <libs/yjabber/yatejabber.h>`
Inherits | TelEngine::GenObject [public ]
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

#### Public Types

- enum Status { Start = 0, Address, Srv, Domain }

#### Public Methods

- JBConnect (const JBStream& stream)
- virtual ~JBConnect ()
- virtual void stopConnect ()
- virtual const String& toString () const

#### Public Members

- static const TokenDict s_statusName[]

#### Protected Methods

- void connect ()

## Detailed Description

This class holds data used to connect an outgoing stream A descendant class should implement the thread run method

enum Status { Start = 0, Address, Srv, Domain } | ### Status

JBConnect (const JBStream& stream) | ### JBConnect

Constructor. Add itself to the stream's engine

Parameters:

stream | The stream to connect

~JBConnect () | ### ~JBConnect

[virtual]

Destructor. Remove from engine if still there

void stopConnect () | ### stopConnect

[virtual]

Stop the thread. This method should be re-implemented

const String& toString () | ### toString

[const virtual]

Retrieve the stream name

Returns: Stream name

Reimplemented from GenObject.

static const TokenDict s_statusName[] | ### s_statusName[]

void connect () | ### connect

[protected]

Connect the socket. Retrieve ip/port from engine ant use them if valid or try to use SRV records returned by the given domain or use the domain's ip address and the default port given by the stream type. Notify the stream on termination. This method should be called from it's own thread

Generated by: paulc on bussard on Mon Feb 10 13:15:47 2014, using kdoc 2.0a54.