oaCMProtocol Class Reference


Public Methods

 oaCMProtocol ()
 oaCMProtocol (const oaString &nameIn, const oaString &plugInNameIn)
 oaCMProtocol (const oaString &nameIn, const oaString &plugInNameIn, const oaCMAttrArray &fixedAttrsIn, const oaCMAttrArray &modAttrsIn)
 oaCMProtocol (const oaCMProtocol &protocolIn)
const oaStringgetName () const
const oaStringgetPlugInName () const
const oaCMAttrArraygetFixedAttrs () const
const oaCMAttrArraygetModAttrs () const
void setFixedAttrs (const oaCMAttrArray &arrayIn)
void setModAttrs (const oaCMAttrArray &arrayIn)
oaBoolean hasUnsetAttrs () const
oaBoolean match (const oaCMProtocol &protoIn) const
const oaCMAttrfindAttr (const oaString &name) const
oaCMProtocol & operator= (const oaCMProtocol &rhs)
oaBoolean operator== (const oaCMProtocol &rhs) const
oaBoolean operator!= (const oaCMProtocol &rhs) const

Detailed Description

The oaCMProtocol class defines a specific protocol for use by a plug-in. A protocol has a name, plug-in name, and optional arrays of fixed and modifiable attributes. The oaCMProtocol class is used to construct an oaCMProtocolArray, which represents the array of oaCMProtocols supported by a plug-in and available for selection by an application.


Constructor & Destructor Documentation

oaCMProtocol::oaCMProtocol  
 

This is the default oaCMProtocol constructor.

oaCMProtocol::oaCMProtocol const oaString &    nameIn,
const oaString &    plugInNameIn
 

This oaCMProtocol constructor specifies the protocol name and plug-in name.

Parameters:
nameIn The name of the protocol.
plugInNameIn The name of the plug-in.

oaCMProtocol::oaCMProtocol const oaString &    nameIn,
const oaString &    plugInNameIn,
const oaCMAttrArray &    fixedAttrsIn,
const oaCMAttrArray &    modAttrsIn
 

This oaCMProtocol constructor specifies the protocol name, plug-in name, and arrays for fixed and modifiable attributes.

Parameters:
nameIn The name of the protocol.
plugInNameIn The name of the plug-in.
fixedAttrsIn An array of fixed attributes.
modAttrsIn An array of modifiable attributes.

oaCMProtocol::oaCMProtocol const oaCMProtocol &    protocolIn
 

This is the oaCMProtocol copy constructor.

Parameters:
protocolIn The protocol to copy.


Member Function Documentation

const oaCMAttr *const oaCMProtocol::findAttr const oaString &    name const
 

This function finds the attribute that matches the specified name. First, the fixed attribute array is searched; then the modifiable attribute array is searched. NULL is returned if the named attributed is not found in either array.

Parameters:
name The name of attribute to find.

const oaCMAttrArray & oaCMProtocol::getFixedAttrs   const
 

This function returns this protocol's fixed attributes array.

const oaCMAttrArray oaCMProtocol::getModAttrs   const
 

This function returns this protocol's modifiable attributes array.

const oaString & oaCMProtocol::getName   const
 

This function returns the name of this protocol.

const oaString & oaCMProtocol::getPlugInName   const
 

This function returns this protocol's plug-in name.

oaBoolean oaCMProtocol::hasUnsetAttrs   const
 

Returns true if at least one of the modifiable attributes of this protocol does not have its value set.

oaBoolean oaCMProtocol::match const oaCMProtocol &    protoIn const
 

This function matches this protocol to the specified protoIn and returns true if their names, plug-in names, fixed attribute names and values, and the number and names of modifiable attributes are the same. It returns false otherwise.

Parameters:
protoIn The protocol to match with this protocol.

oaBoolean oaCMProtocol::operator!= const oaCMProtocol &    protocol const
 

This is the oaCMProtocol inequality operator. It compares this protocol to protocol and returns true if their names, plug-in names, or any of the names or values of their fixed and modifiable attributes are not the same. It returns false otherwise (if all of these names and values are the same).

Parameters:
protocol The protocol to compare to this protocol.

oaCMProtocol & oaCMProtocol::operator= const oaCMProtocol &    rhs
 

This is the oaCMProtocol assignment operator. It copies the rhs protocol's name, plugInName, fixed attributes, and modifiable attributes to this protocol.

Parameters:
rhs The protocol to assign to this protocol.

oaBoolean oaCMProtocol::operator== const oaCMProtocol &    protocol const
 

This is the oaCMProtocol equality operator. It compares this protocol to the specified protocol and returns true if their names, plug-in names, and the names and values of their fixed and modifiable attributes are the same. It returns false otherwise.

Parameters:
protocol The protocol to compare to this protocol.

void oaCMProtocol::setFixedAttrs const oaCMAttrArray &    arrayIn
 

This function sets the fixed-attributes array of arrayIn on this protocol. The arrayIn array must not have any attributes with unset values.

Parameters:
arrayIn The fixed-attributes array to set on this protocol
Exceptions:
oacCMUnsetAttributesNotAllowed 

void oaCMProtocol::setModAttrs const oaCMAttrArray &    arrayIn
 

This function sets the modifiable-attributes array of arrayIn on this protocol.

Parameters:
arrayIn The modifiable-attributes array to set on this protocol.


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

Return to top of page