summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormph2 <mph2@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2002-03-15 17:43:10 +0000
committermph2 <mph2@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2002-03-15 17:43:10 +0000
commit08540729256ca3e98ff57f6d81bb2de9939f7d19 (patch)
tree8757f81f48b9f0a7743d71f34f1a1ad9520d1b59
parent6c50fc804034fbed46a6b6973be3e51d50254868 (diff)
downloadATCD-08540729256ca3e98ff57f6d81bb2de9939f7d19.tar.gz
updated Fixed Set docs
-rw-r--r--ace/Containers_T.h33
1 files changed, 30 insertions, 3 deletions
diff --git a/ace/Containers_T.h b/ace/Containers_T.h
index 451c32c4ba3..aff3967456c 100644
--- a/ace/Containers_T.h
+++ b/ace/Containers_T.h
@@ -1140,7 +1140,8 @@ private:
* @brief Implement a simple unordered set of <T> with maximum <ACE_SIZE>.
*
* This implementation of an unordered set uses a fixed array.
- * This implementation does not allow duplicates...
+ * It does not allow duplicate members. The set provides linear insertion/deletion
+ * operations.
*/
template <class T, size_t ACE_SIZE>
class ACE_Fixed_Set
@@ -1154,28 +1155,47 @@ public:
typedef ACE_Fixed_Set_Iterator<T, ACE_SIZE> CONST_ITERATOR;
// = Initialization and termination methods.
- /// Constructor.
+ /// Default Constructor.
+ /**
+ * Creates an empy set
+ */
ACE_Fixed_Set (void);
/// Copy constructor.
+ /**
+ * Initializes a set to be a copy of the set parameter.
+ */
ACE_Fixed_Set (const ACE_Fixed_Set<T, ACE_SIZE> &);
/// Assignment operator.
+ /**
+ * Deep copy of one set to another.
+ */
void operator= (const ACE_Fixed_Set<T, ACE_SIZE> &);
/// Destructor.
+ /**
+ * Destroys a set.
+ */
~ACE_Fixed_Set (void);
// = Check boundary conditions.
/// Returns 1 if the container is empty, otherwise returns 0.
+ /**
+ * Performs constant time check to determine if a set is empty.
+ */
int is_empty (void) const;
/// Returns 1 if the container is full, otherwise returns 0.
+ /**
+ * Performs a constant time check to see if the set is full.
+ */
int is_full (void) const;
// = Classic unordered set operations.
+ ///Linear time insertion of an item unique to the set.
/**
* Insert <new_item> into the set (doesn't allow duplicates).
* Returns -1 if failures occur, 1 if item is already present, else
@@ -1183,17 +1203,24 @@ public:
*/
int insert (const T &new_item);
+ ///Linear time removal operation of an item.
/**
* Remove first occurrence of <item> from the set. Returns 0 if
* it removes the item, -1 if it can't find the item, and -1 if a
- * failure occurs.
+ * failure occurs. Removal doesn't reclaim memory for the <item>.
*/
int remove (const T &item);
/// Finds if <item> occurs in the set. Returns 0 if finds, else -1.
+ /**
+ * Performs a linear find operation for the specified <item>.
+ */
int find (const T &item) const;
/// Size of the set.
+ /**
+ * Returns the current size of the set.
+ */
size_t size (void) const;
/// Dump the state of an object.