DumontEXE 0.0.1
cmcSubField.h
00001 /* ***************************************************************************
00002 **
00003 ** Copyright (C) 2007 Lorimark Solutions, LLC. All rights reserved.
00004 **
00005 ** This file is part of the DumontEXE Scripting Extension Kit
00006 **
00007 ** This file may be used under the terms of the GNU General Public
00008 ** License version 2.0 as published by the Free Software Foundation
00009 ** and appearing in the file LICENSE.GPL included in the packaging of
00010 ** this file.  Please review the following information to ensure GNU
00011 ** General Public Licensing requirements will be met:
00012 ** http://dumont.showoff-db.org/opensource.html
00013 **
00014 ** If you are unsure which license is appropriate for your use, please
00015 ** review the following information:
00016 ** http://dumont.showoff-db.org/licensing.html 
00017 ** or contact the sales department at sales@lorimarksolutions.com.
00018 **
00019 ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
00020 ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
00021 **
00022 ** author: Mark Petryk ~ Lorimark Solutions, LLC
00023 ** **************************************************************************/
00024 
00025 #ifndef CDA_EXT_FIELD_H_422FD07F_0597_4cbb_A034_9AE85166472E
00026 #define CDA_EXT_FIELD_H_422FD07F_0597_4cbb_A034_9AE85166472E
00027 
00028 #include <QDate>
00029 #include <QTime>
00030 #include <QPointer>
00031 
00032 #include "cmcField.h"
00033 
00034 namespace cmcDatabaseApi {
00035 
00036 class cmcFieldDef;
00037 
00038 /*!
00039 ** \brief Extended Field
00040 **
00041 ** The Extended Field is an object that encapsulates the 100-field limit
00042 **  extended field functionality.  It is designed to operate  just like
00043 **  a normal field, but to take care of manipulating the data on an
00044 **  extended field.
00045 **
00046 */
00047 class cmcSubField:
00048   public cmcField
00049 {
00050   Q_OBJECT
00051   public:
00052 
00053     cmcSubField( const cmcSubField & copy );
00054 
00055     cmcSubField
00056     (
00057       const QString & fieldName,
00058       cmcApplication * application,
00059       cmcField * parentField
00060     );
00061 
00062     virtual ~cmcSubField();
00063 
00064   public slots:
00065 
00066     /*!
00067     ** \brief 
00068     **
00069     **
00070     */
00071     cmcField * field();
00072 
00073     /*!
00074     ** \brief Field Text Label (passthru)
00075     **
00076     ** This returns the 'Label' of the Form field.  This is a passthrough function
00077     **  that transfers control directly to the Commence Form.Field object and
00078     **  therefore returns the same data as the standard Form.Field("Name").Label call.
00079     **
00080     ** \par vbScript example:
00081     ** \code
00082     ** msgbox dfrm.Field("calendarKey").Label
00083     ** \endcode
00084     **
00085     ** \note This value is cached so that repeated lookups do not make repeated
00086     **  calls into the Commence API.
00087     **
00088     */
00089     virtual QString label();
00090 
00091     /*!
00092     ** \brief Get Field Text Value (passthru)
00093     **
00094     ** This returns the 'Value' of the Form field.  This is a passthrough function
00095     **  that transfers control directly to the Commence Form.Field object and
00096     **  therefore returns the same data as the standard Form.Field("Name").Value
00097     **  call.
00098     **
00099     ** \par vbScript example:
00100     ** \code
00101     ** msgbox dfrm.Field("calendarKey").Value
00102     ** \endcode
00103     **
00104     */
00105     virtual QString value();
00106 
00107     /*!
00108     ** \brief Set Field Text Value
00109     **
00110     ** This sets the 'Value' of the Form field.  This is a passthrough function
00111     **  that transfers control directly to the Commence Form.Field object and
00112     **  therefore sets the same data as the standard Form.Field("FieldName").Value = "xyz"
00113     **  call.
00114     **
00115     ** \note This function also tests the new value against the current value, and if
00116     **        there is no change then no updates will be performed on the database.
00117     **        This can help reduce the number of updates the database has to sync
00118     **        around the workgroup in the event no real data is changing on the field.
00119     **        This is particularily useful when scripted-updates are occuring on 
00120     **        various text-type-memo fields that the user doesn't update, but the script
00121     **        updates automatically.  The script can just update the field value 
00122     **        blindly and if there is an actual data field change, then, and only then
00123     **        will that change be written to the commence field, thus reducing the amount
00124     **        of data that has to get synced around the workgroup.
00125     **
00126     ** \par vbScript example:
00127     ** \code
00128     ** dfrm.Field("calendarKey").Value = "new value"
00129     ** \endcode
00130     **
00131     */
00132     virtual void value( QString value );
00133 
00134     /*!
00135     ** \brief Set a Boolean
00136     **
00137     */
00138     virtual void value( bool value );
00139 
00140     /*!
00141     ** \brief Delete a sub field
00142     **
00143     */
00144     virtual void del();
00145 
00146   signals:
00147 
00148   protected:
00149 
00150   private:
00151 
00152 }; // endclass cmcItemField:
00153 
00154 } // endnamespace cmcDatabaseApi
00155 
00156 #endif // #ifndef CDA_FIELD_H
00157 
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties




~ ~ ~ ~ ~ ~
Source Code without Comments is like a Cranberry Garland
without the berries. Comment your Code!
 
Commence Database User Support Group Forum
http://newsgroup.showoff-db.org/
~ ~ ~ ~ ~ ~
Author: Mark Petryk
Lorimark Solutions, LLC
mark@lorimarksolutions.com