Thread Attribute Portability
Thread attributes and attribute values are not uniformly supported across all environments. Some of the policies and attribute values described in this guide might be available only under specific operating systems.
NOTE: Once you begin using thread attributes, you risk compromising the cross-platform portability of your code.
This is largely due to the fact that scheduling and stack allocation policies tend to vary significantly between each of the environments supported by the Threading package. Rogue Wave has made every attempt to alleviate or hide these differences without prohibiting access to the platform-specific controls that some developers require. It is up to you to carefully review and understand the implementation differences between each platform that you plan to support.
To find out which attributes are supported:
*Read the detailed information about each attribute and attribute value in the platform-specific section in the Threads Module Platform Guide.
*Use the feature test macros and functions that allow you to determine, at compile or run-time, which attributes and attribute values are supported in the current environment.
*Use the member functions that manipulate attributes. The member functions are always present, regardless of whether or not the current environment supports the attributes. You can always rely on the existence of the functions and attribute values described in this guide.
If you attempt to access an unsupported attribute or use an illegal or unsupported attribute value:
*An RWTHROperationNotSupported exception is produced if an attribute is not supported.
*An RWTHROperationNotAvailable exception is produced if an attribute value is not supported under current circumstances.
*An RWTHRBoundsError is produced if the value falls outside the legal range for that attribute.
The first two exceptions can always be avoided by using the feature-test functionality included by the library.