FDO API Reference Feature Data Objects

IDelete.h

Go to the documentation of this file.
00001 #ifndef _IDELETE_H_
00002 #define _IDELETE_H_
00003 // 
00004 
00005 //
00006 // Copyright (C) 2004-2006  Autodesk, Inc.
00007 // 
00008 // This library is free software; you can redistribute it and/or
00009 // modify it under the terms of version 2.1 of the GNU Lesser
00010 // General Public License as published by the Free Software Foundation.
00011 // 
00012 // This library is distributed in the hope that it will be useful,
00013 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00014 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00015 // Lesser General Public License for more details.
00016 // 
00017 // You should have received a copy of the GNU Lesser General Public
00018 // License along with this library; if not, write to the Free Software
00019 // Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
00020 //
00021 
00022 #ifdef _WIN32
00023 #pragma once
00024 #endif
00025 
00026 #include <FdoStd.h>
00027 #include <Fdo/Commands/IFeatureCommand.h>
00028 #include <Fdo/Connections/IConnection.h>
00029 #include <Fdo/Commands/Locking/ILockConflictReader.h>
00030 
00031 /// \brief
00032 /// The FdoIDelete interface defines the Delete command, which deletes instances of
00033 /// a given class that match the specified criteria. Input to the delete command
00034 /// includes the name of the class, and filter criteria by which to identify the
00035 /// instances to be deleted. The filter may be specified either as text or as an
00036 /// expression tree (most likely produced by a query builder). The delete
00037 /// command can delete instances at global scope or instances/values nested
00038 /// within an object collection property. Instances at global scope are referred
00039 /// to simply by the class name. Instances at a nested scope (i.e. instances
00040 /// within a object collection property) are referred to by the containing class
00041 /// name, followed by a '.', followed by the object collection property name.
00042 class FdoIDelete : public FdoIFeatureCommand
00043 {
00044     friend class FdoIConnection; 
00045 
00046 public:
00047     /// \brief
00048     /// Executes the delete command and returns the number of instances
00049     /// deleted
00050     /// 
00051     /// \return
00052     /// Returns the number of instances deleted.
00053     /// 
00054     FDO_API virtual FdoInt32 Execute() = 0;
00055 
00056     /// \brief
00057     ///  Deleting objects might result in lock conflicts if objects
00058     /// to be deleted are not exclusively locked for the user attempting to
00059     /// delete the object. A lock conflict report is generated.
00060     /// The function GetLockConflicts returns a lock conflict reader that provides
00061     /// access to the list of lock conflicts that occurred during the execution
00062     /// of the delete operation.
00063     /// 
00064     /// \return
00065     /// Returns a lock conflict reader.
00066     /// 
00067     FDO_API virtual FdoILockConflictReader* GetLockConflicts() = 0;
00068 
00069 };
00070 #endif
00071 
00072 

Comments or suggestions? Send us feedback.