YARP  2.3.70.1
Yet Another Robot Platform
yarp::os::Name Class Reference

Simple abstraction for a YARP port name. More...

#include <yarp/os/Name.h>

Public Member Functions

 Name (const ConstString &txt)
 Constructor. More...
 
bool isRooted () const
 Check if port name begins with "/". More...
 
Contact toAddress () const
 Create an address from the name. More...
 
ConstString getCarrierModifier (const char *mod, bool *hasModifier=YARP_NULLPTR)
 

Private Attributes

ConstString txt
 

Detailed Description

Simple abstraction for a YARP port name.

Definition at line 21 of file Name.h.

Constructor & Destructor Documentation

◆ Name()

Name::Name ( const ConstString txt)

Constructor.

Parameters
txtthe port name.

Definition at line 12 of file Name.cpp.

Member Function Documentation

◆ getCarrierModifier()

ConstString Name::getCarrierModifier ( const char *  mod,
bool *  hasModifier = YARP_NULLPTR 
)

Definition at line 42 of file Name.cpp.

◆ isRooted()

bool Name::isRooted ( ) const

Check if port name begins with "/".

Returns
true if port name begins with "/"

Definition at line 16 of file Name.cpp.

◆ toAddress()

Contact Name::toAddress ( ) const

Create an address from the name.

Fills in carrier and name fields. Deals with "tcp://port/name" style syntax.

Returns
a partially filled address (there is no communication with the name server, just parsing of information in the name).

Definition at line 26 of file Name.cpp.

Member Data Documentation

◆ txt

ConstString yarp::os::Name::txt
private

Definition at line 51 of file Name.h.


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