home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftptest.leeds.ac.uk
/
2015.02.ftptest.leeds.ac.uk.tar
/
ftptest.leeds.ac.uk
/
bionet
/
CAE-GROUP
/
SCL-WIN3x
/
SCL.EXE
/
INSTMGR.H
< prev
next >
Wrap
C/C++ Source or Header
|
1994-09-07
|
3KB
|
100 lines
#ifndef instmgr_h
#define instmgr_h
/*
* NIST STEP Editor Class Library
* cleditor/instmgr.h
* February, 1994
* David Sauder
* K. C. Morris
* Development of this software was funded by the United States Government,
* and is not subject to copyright.
*/
/* $Id: instmgr.h,v 2.0.1.1 1994/04/05 16:41:54 sauderd Exp $ */
///// future? ////////////////
// InstMgr can maintain an undo list for the last operation
// performed on a node
// InstMgr can have a startUndo() and endUndo() so it knows when to
// start a new undo list and delete the old undo list.
/////////////////////
typedef unsigned boolean;
extern char * EntityClassName ( char *);
// IT IS VERY IMPORTANT THAT THE ORDER OF THE FOLLOWING INCLUDE FILES
// BE PRESERVED
#include <gennode.h>
#include <gennodelist.h>
#include <gennodeinline.h>
#include <gennodearray.h>
#include <mgrnode.h>
#include <mgrnodelist.h>
#include <dispnode.h>
#include <dispnodlist.h>
#include <mgrnodearray.h>
class InstMgr
{
protected:
MgrNodeArray *master; // master array of all MgrNodes made up of
// complete, incomplete, new, delete MgrNodes lists
// this corresponds to the display list object by index
MgrNodeArraySorted *sortedMaster; // master array sorted by fileId
// StateList *master; // this will be an sorted array of ptrs to MgrNodes
int maxFileId;
public:
InstMgr();
~InstMgr() {};
// MASTER LIST OPERATIONS
int InstanceCount() { return master->Count(); }
void ClearInstances();
Severity VerifyInstances(ErrorDescriptor& e);
// DAS PORT possible BUG two funct's below may create a temp for the cast
MgrNode *&operator[](int index)
{ return (MgrNode* &)((*master)[index]); }
MgrNode *&GetMgrNode(int index)
{ return (MgrNode* &)((*master)[index]); }
MgrNode *FindFileId(int fileId);
// get the index into display list given a STEPentity
// called by see initiated functions
int GetIndex(STEPentity *se);
int GetIndex(MgrNode *mn);
int VerifyEntity(int fileId, const char *expectedType);
// void Append(MgrNode *node);
MgrNode *Append(STEPentity *se, stateEnum listState);
// deletes node from master list structure
void Delete(MgrNode *node);
void Delete(STEPentity *se);
void ChangeState(MgrNode *node, stateEnum listState);
int MaxFileId() { return maxFileId; }
int NextFileId() { return maxFileId = maxFileId +1; }
int EntityKeywordCount(const char* name);
STEPentity *GetSTEPentity(int index);
STEPentity *GetSTEPentity(const char* entityKeyword,int starting_index);
STEPentity *GetSTEPentity(MgrNode *node)
{ return node->GetSTEPentity(); };
void *GetSEE(int index);
void *GetSEE(MgrNode *node) { return node->SEE(); };
};
#endif