ERUCES::TETransportPrincipalInfo
#include <tetransport.h>
The TETransportPrincipalInfo class provides methods for maintaining transportation principal information.
It is derived from the TEPrincipalInfo class. This class builds connections between a Remote Engine and a Key Service, which contains a certificate and a list of principals. The certificate is used to establish a secure connection between the Remote Engine and the Key Service, while the list of principals is used to limit who can access the Remote Engine.Transportation class. It is used to build connection between two client engine and server. It contains a certificate and a list of principals. The certificate is used to build secure connection between client engine and server. The list of principals is used to limit principals that can use client engine. If the list is empty, all legal users can use client engine. Otherwise only attached principals can use client engine.
Inheritance
- Inherits ERUCES::TEPrincipalInfo
Static Public Attributes
| Type | Name | Description |
|---|---|---|
| _TESTD string | CLASSNAME |
Public Member Functions
| Member | Description |
|---|---|
TETransportPrincipalInfo() | The TETransportPrincipalInfo constructor is the default class constructor. |
TETransportPrincipalInfo(const TETransportPrincipalInfo &) | The TETransportPrincipalInfo constructor copies a TETransportPrincipalInfo object. |
~TETransportPrincipalInfo() | The TETransportPrincipalInfo destructor is the class destructor. |
const _TESTD string getPrincipalName() const | The getPrincipalName method gets the name of a principal. The same as the certificate. |
void setCertificateId(const _TESTD string &cid) | The setCertificateID method sets a certificate ID. |
const _TESTD string getCertificateId() const | The getCertificateID method gets a certificate ID. |
void setCertificate(const _TESTD string &cert) | The setCertificate method sets a certificate. |
const _TESTD string getCertificate() const | The getCertificate method gets a certificate. |
const _TESTD string getSubject() const | The getSubject method gets the subject of a certificate. |
void setSubject(const _TESTD string &sub) | Set subject of certificate. |
size_t PrincipalCount() const | The PrincipalCount method gets the total number of principals. |
void getPrincipalIds(TEObjectContainer &ids) const | The getPrincipalIDs method gets a list of all principal IDs. |
bool addPrincipal(te_oid pid) | The addPrincipal method adds a principal. |
bool removePrincipal(te_oid pid) | The removePrincipal method remove a principal. |
void clearPrincipals() | The clearPrincipals method removes all principals. |
TEObject * clone() const | The clone method clones a TETransportPrincipalInfo object. |
const _TESTD string getClassName() const | The getClassName method gets the name of the TETransportPrincipalInfo class. |
Member Function Documentation
TETransportPrincipalInfo()
The TETransportPrincipalInfo constructor is the default class constructor.
TETransportPrincipalInfo(const TETransportPrincipalInfo &)
The TETransportPrincipalInfo constructor copies a TETransportPrincipalInfo object.
~TETransportPrincipalInfo()
The TETransportPrincipalInfo destructor is the class destructor.
const _TESTD string getPrincipalName() const
The getPrincipalName method gets the name of a principal. The same as the certificate.
Returns: Returns a string representing the name of a principal.
void setCertificateId(const _TESTD string &cid)
The setCertificateID method sets a certificate ID.
Parameters
| Parameter | Description |
|---|---|
cid | A string representing a certificate ID. |
const _TESTD string getCertificateId() const
The getCertificateID method gets a certificate ID.
Returns: Returns a string representing a certificate ID.
void setCertificate(const _TESTD string &cert)
The setCertificate method sets a certificate.
Parameters
| Parameter | Description |
|---|---|
cert | A string representing a certificate. |
const _TESTD string getCertificate() const
The getCertificate method gets a certificate.
Returns: Returns a string representing a certificate.
const _TESTD string getSubject() const
The getSubject method gets the subject of a certificate.
Returns: Returns a string representing a certificate's subject.
void setSubject(const _TESTD string &sub)
Set subject of certificate.
Parameters
| Parameter | Description |
|---|---|
sub | String of subject |
size_t PrincipalCount() const
The PrincipalCount method gets the total number of principals.
Returns: Returns the total number of principals.
void getPrincipalIds(TEObjectContainer &ids) const
The getPrincipalIDs method gets a list of all principal IDs.
Parameters
| Parameter | Description |
|---|---|
ids | A container to hold the list of principal IDs. Type of object in the container will be TEOID. |
bool addPrincipal(te_oid pid)
The addPrincipal method adds a principal.
Parameters
| Parameter | Description |
|---|---|
pid | A principal ID. |
Returns: A boolean value indicating whether the action has been successfully completed; TRUE = principal has been added; FALSE = principal has not been added.
bool removePrincipal(te_oid pid)
The removePrincipal method remove a principal.
Parameters
| Parameter | Description |
|---|---|
pid | A principal ID |
Returns: Returns a boolean value indicating whether the action has been successfully completed; TRUE = principal has been removed; FALSE = principal has not been removed.
void clearPrincipals()
The clearPrincipals method removes all principals.
TEObject * clone() const
The clone method clones a TETransportPrincipalInfo object.
Returns: TETransportPrincipalInfo object cloned.
const _TESTD string getClassName() const
The getClassName method gets the name of the TETransportPrincipalInfo class.
Returns: Returns a string representing the name of the TETransportPrincipalInfo class.