FDO API Reference Feature Data Objects

ReadOnlyDataPropertyDefinitionCollection.h

Go to the documentation of this file.
00001 #ifndef _READONLYDATAPROPERTYDEFINITIONCOLLECTION_H_
00002 #define _READONLYDATAPROPERTYDEFINITIONCOLLECTION_H_
00003 
00004 //
00005 // Copyright (C) 2004-2006  Autodesk, Inc.
00006 // 
00007 // This library is free software; you can redistribute it and/or
00008 // modify it under the terms of version 2.1 of the GNU Lesser
00009 // General Public License as published by the Free Software Foundation.
00010 // 
00011 // This library is distributed in the hope that it will be useful,
00012 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014 // Lesser General Public License for more details.
00015 // 
00016 // You should have received a copy of the GNU Lesser General Public
00017 // License along with this library; if not, write to the Free Software
00018 // Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
00019 //
00020 
00021 #ifdef _WIN32
00022 #pragma once
00023 #endif
00024 
00025 #include <FdoStd.h>
00026 #include <Fdo/Schema/SchemaElement.h>
00027 #include <Fdo/Schema/SchemaException.h>
00028 #include <Fdo/Schema/ClassDefinition.h>
00029 #include <Fdo/Schema/DataPropertyDefinitionCollection.h>
00030 #include <Fdo/IDisposableCollection.h>
00031 #include <Fdo/ReadOnlyCollection.h>
00032 
00033 class FdoClassDefinition;
00034 
00035 /// \brief
00036 /// The FdoReadOnlyDataPropertyDefinitionCollection class represents a read-only collection of FdoDataPropertyDefinition objects.
00037 class FdoReadOnlyDataPropertyDefinitionCollection : public FdoReadOnlyCollection<FdoDataPropertyDefinition, FdoIDisposableCollection, FdoSchemaException>
00038 {
00039 protected:
00040 /// \cond DOXYGEN-IGNORE
00041     FdoReadOnlyDataPropertyDefinitionCollection()
00042     {
00043     }
00044     FdoReadOnlyDataPropertyDefinitionCollection(FdoDataPropertyDefinitionCollection* properties);
00045 
00046     virtual void Dispose();
00047 /// \endcond
00048 
00049 public:
00050     /// \brief
00051     /// Constructs and populates an instance of an FdoReadOnlyDataPropertyDefinitionCollection.
00052     /// 
00053     /// \param properties 
00054     /// Input collection of FdoDataPropertyDefinition objects
00055     /// 
00056     /// \return
00057     /// Returns an FdoReadOnlyDataPropertyDefinitionCollection
00058     /// 
00059     FDO_API static FdoReadOnlyDataPropertyDefinitionCollection* Create(FdoDataPropertyDefinitionCollection* properties);
00060 
00061     /// \brief
00062     /// Gets the number of items in the collection.
00063     /// 
00064     /// \return
00065     /// Returns the number of items in the collection
00066     /// 
00067     FDO_API FdoInt32 GetCount();
00068 
00069     /// \brief
00070     /// Gets the item in the collection at the specified index. Throws an
00071     /// invalid argument exception if the index is out of range.
00072     /// 
00073     /// \param index 
00074     /// Input index
00075     /// 
00076     /// \return
00077     /// Returns the item in the collection at the specified index
00078     /// 
00079     FDO_API FdoDataPropertyDefinition* GetItem(FdoInt32 index);
00080 
00081     /// \brief
00082     /// Gets the item in the collection with the specified name. Throws an invalid argument exception if an item with the specified name does not exist in the collection.
00083     /// 
00084     /// \param name 
00085     /// Input name to find
00086     /// 
00087     /// \return
00088     /// Returns the item in the collection with the specified name
00089     /// 
00090     FDO_API FdoDataPropertyDefinition* GetItem(FdoString* name);
00091 
00092     /// \brief
00093     /// Determines if the collection contains the specified item.
00094     /// 
00095     /// \param value 
00096     /// Input FdoDataPropertyDefinition
00097     /// 
00098     /// \return
00099     /// Returns true if the collection contains the specified item
00100     /// 
00101     FDO_API bool Contains(FdoDataPropertyDefinition* value);
00102 
00103     /// \brief
00104     /// Returns the index of the specified item in the collection.
00105     /// If the item does not exist, the IndexOf function returns -1.
00106     /// 
00107     /// \param value 
00108     /// Input FdoDataPropertyDefinition
00109     /// 
00110     /// \return
00111     /// Returns the index of the specified item in the collection
00112     /// 
00113     FDO_API FdoInt32 IndexOf(FdoDataPropertyDefinition* value);
00114 };
00115 #endif
00116 
00117 

Comments or suggestions? Send us feedback.