CVB++ 15.1
Loading...
Searching...
No Matches
ServerBase Class Referenceabstract

Base class for a GigE Vision server object. More...

#include <decl_server_base.hpp>

Inherits enable_shared_from_this< ServerBase >.

Inherited by Server, and ServerGev3.

Public Member Functions

virtual void * Handle () const noexcept=0
 Returns the internal handle of this server object.
 
virtual GevServer::State State ()
 Gets the the current state this server is in.
 
virtual GevServer::DriverType DriverType ()
 Gets the GigE Vision driver used by this server object.
 
virtual String UserVersion () const
 Gets the user defined version that is appended to the device version.
 
virtual void SetUserVersion (const String &value)
 Sets the user defined version that is appended to the device version.
 
virtual Cvb::NetworkConnection LocalEndpoint () const
 Gets the local end point this server is bound to.
 
virtual Cvb::NetworkConnection RemoteEndpoint () const
 Gets the remote end point this server is connected to.
 
virtual NodeMapPtr NodeMap () const
 Returns the GenApi node map of this server.
 
virtual void Start (const Cvb::NetworkConnection::IPAddress &address)
 Starts this server and binds it to the given address .
 
virtual void Start (const Cvb::NetworkConnection::IPAddressUInt &address)
 Starts this server and binds it to the given address .
 
virtual void Stop ()
 Stops this server.
 

Detailed Description

Base class for a GigE Vision server object.

Member Function Documentation

◆ Handle()

virtual void * Handle ( ) const
pure virtualnoexcept

Returns the internal handle of this server object.

Returns

Implemented in Server, and ServerGev3.

◆ LocalEndpoint()

Cvb::NetworkConnection LocalEndpoint ( ) const
inlinevirtual

Gets the local end point this server is bound to.

This value is only set if State is not State::Configuration.

NetworkConnection containing the current IPAddress and port.

◆ NodeMap()

NodeMapPtr NodeMap ( ) const
inlinevirtual

Returns the GenApi node map of this server.

Returns

◆ RemoteEndpoint()

Cvb::NetworkConnection RemoteEndpoint ( ) const
inlinevirtual

Gets the remote end point this server is connected to.

This value is only set if State is State::Connected or State::AcquisitionEnabled.

NetworkConnection containing the current IPAddress and port. null if not connected.

◆ SetUserVersion()

void SetUserVersion ( const String & value)
inlinevirtual

Sets the user defined version that is appended to the device version.

This property is mandatory as soon as you change anything about the GenApi nodes! As the GenApi XML description is auto-generated the client needs a way to distinguish between different Server instances with differing feature sets.

If you change anything about the GenApi nodes on certain user version, you must increase the NodeMap::XmlFileVersion.

This version information is appended to the CVGevServer version. The available memory for the overall information is limited by the GigE Vision standard to 32 bytes which results in up to 31 ASCII characters text (actual encoding is UTF-8) as strings must be null-terminated. Longer version information is silently cropped!

◆ Start() [1/2]

void Start ( const Cvb::NetworkConnection::IPAddress & address)
inlinevirtual

Starts this server and binds it to the given address .

All communication channels are bound and the GenApi XML description is generated.

On success the state changes to State.Disconnected.

Parameters
addressIP address version 4 to bind to.

◆ Start() [2/2]

void Start ( const Cvb::NetworkConnection::IPAddressUInt & address)
inlinevirtual

Starts this server and binds it to the given address .

All communication channels are bound and the GenApi XML description is generated.

On success the state changes to State.Disconnected.

Parameters
addressIP address version 4 as unsigned integer to bind to.

◆ Stop()

void Stop ( )
inlinevirtual

Stops this server.

Stopping the server results, depending on the current state, in a chain from State.AcquisitionEnabled to State::Connected to State::Disconnected to State::Configuration.

◆ UserVersion()

String UserVersion ( ) const
inlinevirtual

Gets the user defined version that is appended to the device version.

This property is mandatory as soon as you change anything about the GenApi nodes! As the GenApi XML description is auto-generated the client needs a way to distinguish between different Server instances with differing feature sets.

If you change anything about the GenApi nodes on certain user version, you must increase the NodeMap::XmlFileVersion.

This version information is appended to the CVGevServer version. The available memory for the overall information is limited by the GigE Vision standard to 32 bytes which results in up to 31 ASCII characters text (actual encoding is UTF-8) as strings must be null-terminated. Longer version information is silently cropped!