class H323Capabilities

This class contains all of the capabilities and their combinations

Inheritance:


Public Methods

[more] Construction
[more] Overrides from class PObject
[more] Operations


Documentation

This class contains all of the capabilities and their combinations
o Construction

o H323Capabilities()
Construct an empty capability set

o H323Capabilities( const H323Connection & connection, const H245_TerminalCapabilitySet & pdu )
Construct a capability set from the H245 PDU provided.
Parameters:
connection - Connection for capabilities
pdu - PDU to convert to a capability set.

o H323Capabilities( const H323Capabilities & original )
Construct a copy of a capability set. Note this will completely duplicate the set by making clones of every capability in the original set.
Parameters:
original - Original capabilities to duplicate

oH323Capabilities& operator=( const H323Capabilities & original )
Assign a copy of a capability set. Note this will completely duplicate the set by making clones of every capability in the original set.
Parameters:
original - Original capabilities to duplicate

o Overrides from class PObject

ovoid PrintOn( ostream & strm ) const
Print out the object to the stream, virtual version of << operator.
Parameters:
strm - Stream to print out to.

o Operations

oPINDEX GetSize() const
Get the number of capabilities in the set

oH323Capability& operator[](PINDEX i) const
Get the capability at the specified index

oPINDEX SetCapability( PINDEX descriptorNum, PINDEX simultaneous, H323Capability* cap )
Set the capability descriptor lists. This is three tier set of codecs. The top most level is a list of particular capabilities. Each of these consists of a list of alternatives that can operate simultaneously. The lowest level is a list of codecs that cannot operate together. See H323 section 6.2.8.1 and H245 section 7.2 for details.

If descriptorNum is P_MAX_INDEX, the the next available index in the array of descriptors is used. Similarly if simultaneous is P_MAX_INDEX the the next available SimultaneousCapabilitySet is used. The return value is the index used for the new entry. Note if both are P_MAX_INDEX then the return value is the descriptor index as the simultaneous index must be zero.

Note that the capability specified here is automatically added to the capability table using the AddCapability() function. A specific instance of a capability is only ever added once, so multiple SetCapability() calls with the same H323Capability pointer will only add that capability once.

Parameters:
descriptorNum - The member of the capabilityDescriptor to add
simultaneous - The member of the SimultaneousCapabilitySet to add
cap - New capability specification

oPINDEX AddAllCapabilities( H323EndPoint & ep, PINDEX descriptorNum, PINDEX simultaneous, const PString & name )
Add all matching capabilities to descriptor lists. All capabilities that match the specified name are added as in the other form of the SetCapability() function.
Parameters:
ep - The endpoint adding the capabilities.
descriptorNum - The member of the capabilityDescriptor to add
simultaneous - The member of the SimultaneousCapabilitySet to add
name - New capabilities name, if using "known" one.

ovoid Add( H323Capability* capability )
Add a codec to the capabilities table. This will assure that the assignedCapabilityNumber field in the capability is unique for all capabilities installed on this set.

If the specific instance of the capability is already in the table, it is not added again. Ther can be multiple instances of the same capability class however.

Parameters:
capability - New capability specification

oH323Capability* Copy( const H323Capability & capability )
Copy a codec to the capabilities table. This will make a clone of the capability and assure that the assignedCapabilityNumber field in the capability is unique for all capabilities installed on this set.

Returns the copy that is put in the table.

Parameters:
capability - New capability specification

ovoid Remove( H323Capability* capability )
Remove a capability from the table. Note that the the parameter must be the actual instance of the capability in the table. The instance is deleted when removed from the table.
Parameters:
capability - Existing capability specification

ovoid Remove( const PString & formatName )
Remove all capabilities matching the string. This uses FindCapability() to locate the first capability whose format name does a partial match for the argument.
Parameters:
formatName - Format name to search for.

ovoid Remove( const PStringArray & formatNames )
Remove all capabilities matching any of the strings provided. This simply calls Remove() for each string in the list.
Parameters:
formatNames - Array of format names to remove

ovoid RemoveAll()
Remove all of the capabilities

oH323Capability* FindCapability( unsigned capabilityNumber ) const
Find the capability given the capability number. This number is guarenteed to be unique for a give capability table. Note that is may not be the same as the index into the table.

Returns: NULL if no capability meeting the criteria was found

oH323Capability* FindCapability( const PString & formatName, H323Capability::CapabilityDirection direction = H323Capability::e_Unknown ) const
Find the capability given the capability format name string. This does a partial match for the supplied argument. If the argument matches a substring of the actual capabilities name, then it is returned. For example "GSM" or "0610" will match "GSM 0610". Note case is not significant.

The user should be carefull of using short strings such as "G"!

The direction parameter can further refine the search for specific receive or transmit capabilities. The default value of e_Unknown will wildcard that field.

Returns: NULL if no capability meeting the criteria was found

Parameters:
formatName - Wildcard format name to search for
direction - Optional direction to include into search criteria

oH323Capability* FindCapability( H323Capability::CapabilityDirection direction ) const
Find the first capability in the table of the specified direction.

Returns: NULL if no capability meeting the criteria was found

Parameters:
direction - Direction to search for

oH323Capability* FindCapability( const H323Capability & capability ) const
Find the capability given the capability. This does a value compare of the two capabilities. Usually this means the mainType and subType are the same.

Returns: NULL if no capability meeting the criteria was found

Parameters:
capability - Capability to search for

oH323Capability* FindCapability( const H245_Capability & cap ) const
Find the capability given the H245 capability PDU.

Returns: NULL if no capability meeting the criteria was found

Parameters:
cap - H245 capability table entry

oH323Capability* FindCapability( const H245_DataType & dataType ) const
Find the capability given the H245 data type PDU.

Returns: NULL if no capability meeting the criteria was found

Parameters:
dataType - H245 data type of codec

oH323Capability* FindCapability( const H245_ModeElement & modeElement ) const
Find the capability given the H245 data type PDU.

Returns: NULL if no capability meeting the criteria was found

Parameters:
modeElement - H245 data type of codec

oH323Capability* FindCapability( H323Capability::MainTypes mainType, const PASN_Choice & subTypePDU, unsigned nonStandardTag ) const
Find the capability given the sub-type info.

Returns: NULL if no capability meeting the criteria was found

Parameters:
mainType - Main type to find
subTypePDU - Sub-type info
nonStandardTag - NOn-standard tag ID for sub-type

oH323Capability* FindCapability( H323Capability::MainTypes mainType, unsigned subType = UINT_MAX ) const
Find the capability given the type codecs.

Returns: NULL if no capability meeting the criteria was found

Parameters:
mainType - Main type to find
subType - Sub-type to find (UINT_MAX=ignore)

ovoid BuildPDU( const H323Connection & connection, H245_TerminalCapabilitySet & pdu ) const
Build a H245 PDU from the information in the capability set.
Parameters:
connection - Connection building PDU for
pdu - PDU to build

oBOOL Merge( const H323Capabilities & newCaps )
Merge the capabilities into this set

ovoid Reorder( const PStringArray & preferenceOrder )
Change the order of capabilities in the table to the order specified. Note that this does not change the unique capability numbers assigned when the capability is first added to the set.

The string matching rules are as for the FindCapability() function.

Parameters:
preferenceOrder - New order

oBOOL IsAllowed( const H323Capability & capability )
Test if the capability is allowed

oBOOL IsAllowed( unsigned capabilityNumber )
Test if the capability is allowed

oBOOL IsAllowed( const H323Capability & capability1, const H323Capability & capability2 )
Test if the capabilities are an allowed combination

oBOOL IsAllowed( unsigned capabilityNumber1, unsigned capabilityNumber2 )
Test if the capabilities are an allowed combination


This class has no child classes.

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.