Class: TPropertySet

Declaration: Property.h

Taxonomy Categories:

Member Functions:


Interface Category:

API.

Inherits From:

MCollectible, MQueryTarget

Inherited By:

None.

Purpose:

Provides a set of properties that can be stored in or retrieved from an MPropertyStore object. This class enables a collection of properties to be read or written in a single operation.

Instantiation:

Allocate on the heap or the stack.

Deriving Classes:

This class is not intended to be derived from.

Concurrency:

Not multithread safe.

Resource Use:

No special requirements.

Member Function: TPropertySet::TPropertySet

  1. TPropertySet ()
  2. TPropertySet (const TPropertySet & copy)
  3. TPropertySet (const TPropertyIDSet & copy)

Interface Category:

API.

Purpose:

  1. Default constructor. Constructs an empty property set.
  2. Copy constructor. Constructs a property set from the contents of another property set.
  3. Constructs a property set from the contents of an identifier set. The set will contain no valid values.

Calling Context:

  1. Called by the stream-in operators and to create an instance to assign to.
  2. Called to copy an object.
  3. Call this function directly.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::operator=

  1. TPropertySet & operator =(const TPropertySet & copy)
  2. TPropertySet & operator =(const TPropertyIDSet & copy)

Interface Category:

API.

Purpose:

  1. Assignment operator.
  2. Replaces the contents of this property set with the contents of an identifier set. The set will contain no valid values.

Calling Context:

  1. Called when an object is assigned to another compatible object.
  2. Call this function directly.

Parameters:

Return Value:

A non-const reference to the left-hand side object.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::~TPropertySet

virtual ~ TPropertySet ()

Interface Category:

API.

Purpose:

Destructor.

Calling Context:

Called to destroy an object.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::Add

  1. virtual void Add (const TPropertyID & id)
  2. virtual void Add (const TPropertyIDSet & set)
  3. virtual void Add (const TProperty & property)
  4. virtual void Add (const TPropertySet & set)

Interface Category:

API.

Purpose:

  1. Constructs a property, using the specified identifier and an invalid value, and adds it to this set.
  2. Constructs a property set, using the specified identifier set and a set of invalid values, and adds it to this set.
  3. Adds a property to this property set. If the property argument is TProperty::kInvalid or TPropertySetIterator::kEndOfIteration, or if the property already exists in the set, no operation is performed.
  4. Adds a property set to this property set. If any property in the set is TProperty::kInvalid or TPropertySetIterator::kEndOfIteration, or if any property already exists in the set, no operation is performed for that property.

Calling Context:

  1. Call this function directly.
  2. Call this function directly.
  3. Call this function directly.
  4. Call this function directly.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::Get

virtual bool Get (TProperty & fillin) const

Interface Category:

API.

Purpose:

Retrieves the property designated by its argument.

Calling Context:

Call this function directly.

Parameters:

Return Value:

Returns true if fillin is present in the set.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::Delete

  1. virtual bool Delete (const TPropertyID & id)
  2. virtual bool Delete (const TPropertyIDSet & set)

Interface Category:

API.

Purpose:

  1. Deletes the specified property from this set.
  2. Deletes the specified property set from this set.

Calling Context:

  1. Call this function directly.
  2. Call this function directly.

Parameters:

Return Value:

Returns true if all the specified properties were present in the set.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::DeleteAll

virtual void DeleteAll ()

Interface Category:

API.

Purpose:

Deletes all the properties from this set.

Calling Context:

Call this function directly.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::Member

virtual bool Member (const TPropertyID & id) const

Interface Category:

API.

Purpose:

Determines if the specified property is present in this set.

Calling Context:

Call this function directly.

Parameters:

Return Value:

Returns true if the specified property is present in this set.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::Members

virtual bool Members (const TPropertyIDSet & set) const

Interface Category:

API.

Purpose:

Determines if all properties specified by the set are present in this set.

Calling Context:

Call this function directly.

Parameters:

Return Value:

Returns true if all properties specified by the set are present in this set.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::Count

virtual unsigned long Count () const

Interface Category:

API.

Purpose:

Returns the number of properties in this set.

Calling Context:

Call this function directly.

Parameters:

Return Value:

The number of properties present in this set.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::ValidValues

  1. virtual unsigned long ValidValues () const
  2. virtual unsigned long ValidValues (TPropertySet & fillin) const

Interface Category:

API.

Purpose:

  1. Returns the count of properties with valid values in this set.
  2. Retrieves all properties with valid values in this set.

Calling Context:

  1. Call this function directly.
  2. Call this function directly.

Parameters:

Return Value:

The count of properties with valid values in this set.

Exceptions:

  1. Throws no exceptions, passes all exceptions through.
  2. Throws TObjectPassedToSelf if the set equals this.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::InvalidValues

  1. virtual unsigned long InvalidValues () const
  2. virtual unsigned long InvalidValues (TPropertyIDSet & fillin) const

Interface Category:

API.

Purpose:

  1. Returns the count of properties with invalid values in this set.
  2. Retrieves the identifiers for all properties with invalid values in this set.

Calling Context:

  1. Call this function directly.
  2. Call this function directly.

Parameters:

Return Value:

The count of properties with invalid values in this set.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::HasValidValue

virtual bool HasValidValue (const TPropertyID & id) const

Interface Category:

API.

Purpose:

Determines if the specified property is a member of this set and has a valid value.

Calling Context:

Call this function directly.

Parameters:

Return Value:

Returns true if the specified property is a member of this set and has a valid value.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::operator==

bool operator ==(const TPropertyIDSet & set) const

Interface Category:

API.

Purpose:

Determines if this set contains exactly the same identifiers as specified in its argument.

Calling Context:

Call this function directly.

Parameters:

Return Value:

Returns true if this set contains exactly the same identifiers as specified in its argument.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::operator!=

bool operator != (const TPropertyIDSet & set) const

Interface Category:

API.

Purpose:

Determines if this set does not contain exactly the same identifiers as specified in its argument.

Calling Context:

Call this function directly.

Parameters:

Return Value:

Returns true if this set does not contain exactly the same identifiers as specified in its argument.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::operator>>=

virtual TStream & operator >>=(TStream & toWhere) const

Interface Category:

API.

Purpose:

Stream-out operator.

Calling Context:

Called to stream out data.

Parameters:

Return Value:

Returns a reference to the stream the object streams itself out to.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TPropertySet::operator<<=

virtual TStream & operator <<= (TStream & fromWhere)

Interface Category:

API.

Purpose:

Stream-in operator.

Calling Context:

Called to stream in data. Call this function directly.

Parameters:

Return Value:

Returns a reference to the stream the object streams itself in from.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.