- Main Page
- Related Pages
- Modules
- Classes
- Files

# IUpdate.h

Go to the documentation of this file.

    00001 #ifndef _IUPDATE_H_
    00002 #define _IUPDATE_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/PropertyValueCollection.h>
    00030 #include <Fdo/Commands/Locking/ILockConflictReader.h>
    00031
    00032 /// \brief
    00033 /// The FdoIUpdate interface defines the Update command, which modifies instances
    00034 /// of a given class that match the specified criteria. Input to the update
    00035 /// command includes the name of the class, the list of property name/value
    00036 /// pairs to be updated, and the filter criteria by which to identify the
    00037 /// instances to be updated. The filter may be specified either as text or as an
    00038 /// expression tree (most likely produced by a query builder). The update
    00039 /// command can update instances at global scope or nested within an
    00040 /// object collection property. Instances at global scope are referred to simply
    00041 /// by the class name. Instances at a nested scope (i.e., instances within an
    00042 /// object collection property) are referred to by the containing class name,
    00043 /// followed by a '.', followed by the object collection property name.
    00044 class FdoIUpdate : public FdoIFeatureCommand
    00045 {
    00046     friend class FdoIConnection;
    00047
    00048 public:
    00049     /// \brief
    00050     /// Gets the FdoPropertyValueCollection that specifies the names and values of the
    00051     /// properties to be updated.
    00052     ///
    00053     /// \return
    00054     /// Returns the list of properties and their values.
    00055     ///
    00056     FDO_API virtual FdoPropertyValueCollection* GetPropertyValues() = 0;
    00057
    00058     /// \brief
    00059     /// Executes the update command and returns the number of modified
    00060     /// instances.
    00061     ///
    00062     /// \return
    00063     /// Returns nothing
    00064     ///
    00065     FDO_API virtual FdoInt32 Execute() = 0;
    00066
    00067     /// \brief
    00068     ///  Updating objects might result in lock conflicts if objects
    00069     /// to be updated are not exclusively locked for the user attempting to
    00070     /// update the object. If objects to be updated are not exclusively locked for the
    00071     /// user attempting to update the object, a lock conflict report is generated.
    00072     /// The function GetLockConflicts returns a lock conflict reader providing
    00073     /// access to the list of lock conflicts that occurred during the execution
    00074     /// of the update operation.
    00075     ///
    00076     /// \return
    00077     /// Returns a lock conflict reader.
    00078     ///
    00079     FDO_API virtual FdoILockConflictReader* GetLockConflicts() = 0;
    00080
    00081 };
    00082 #endif
    00083
    00084

Please send us your comment about this page