Source: xql/xqlobjectwithattributes.h


Annotated List
Files
Globals
Hierarchy
Index
/***************************************************************************
                          xqlObjectWithAttributes.h  -  description
                             -------------------
    begin                : Mon Jun 26 2000
    copyright            : (C) 2000 by Raoul Markus
    email                : raoul.markus@arcormail.de
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 ***************************************************************************/
#ifndef _xqlObjectWithAttributes
#define _xqlObjectWithAttributes

#include "xqltypes.h"
#include "xqlobject.h"
#include "xqlattribute.h"
#include "xqlsession.h"
#include "xqlint.h"
#include "xqlstring.h"
#include 
#include 
#include 

class xqlObjectList;

/**
 * Object which can have an internal structure, i. e. xqlAttribute
 */ 
class xqlObjectWithAttributes: public xqlObject 
{
  public:
    xqlObjectWithAttributes(xqlSession* pSession);
  protected:
    xqlAttribute * mAttributes[MAX_NUM_ATTRIBS];
    int mCurrentNumberOfAttributes;
    char * mClassName;
  public:
    const bool addAttribute(xqlAttribute * pAttribute); 
    virtual bool saveInstance();
    virtual bool createInstance();
    virtual bool loadInstance(int pInstId);
    virtual bool createType();
    virtual bool loadType(int pTypeId);
    virtual char*  className() const;
  /** creates a new Attribute of the given Type. */
  void addType(char * pType);
  /** this function creates the table for the 
given object type. for xqlObjectWithAttributes 
it has a different structure than for xqlAttributes. */
  void createTables();
  /** use this function if an ObjectWithAttributes has been changed (added or removed 
attributes).  */
  bool saveType();
  /** No descriptions */
  bool loadType(std::string& pType);
  /** returns the attribute of the given name */
  xqlAttribute * getAttribute(std::string pAttribute);
  /** returns the list of the attributes */
  xqlObjectList * getAttributes();
  /** returns a store identifier for the given file */

  /** returns the table name for the object in pTableName */
//Del by KDevelop:
};
#endif

Generated by: markus on hobbes on Fri Mar 29 16:15:24 2002, using kdoc 2.0a53.