VR-Forces 4.0.4 Class Documentation
include/vrfplan/whileStmt.h
Go to the documentation of this file.
00001 /*******************************************************************************
00002 ** Copyright (c) 2004 MAK Technologies, Inc.
00003 ** All rights reserved.
00004 *******************************************************************************/
00005 /*******************************************************************************
00006 ** $RCSfile: whileStmt.h,v $ $Revision: 1.7 $ $State: Exp $
00007 *******************************************************************************/
00008 
00011 
00012 #ifndef DtWhileStmt_H_
00013 #define DtWhileStmt_H_
00014 
00015 #include "vrfplan/rwCondExpr.h"
00016 #include "vrfplan/simStmt.h"
00017 
00018 #include <vlutil/vlNetTypes.h>
00019 
00020 const char DtWhileStmtTypeName[] = "While";
00021 
00022 class DtRwCondExpr;
00023 class DtWhileBlock;
00024 class DtSimCondExpr;
00025 
00038 
00039 struct DtNetWhileStatement
00040 {
00041    DtNetU16 myCondExprSize;            
00042    DtNetU8  myStatementCount;          
00043    DtNetU8  myCondExprType;            
00044    DtNetU16 myPadding1;                
00045    DtNetU16 myPadding2;                
00046 };                                     
00047 
00055 #include "vrfplan/vrfplanDefines.h"
00056 class DT_DLL_vrfplan DtWhileStmt : public DtSimStatement
00057 {
00058 public:
00059 
00061    DtWhileStmt(DtReaderWriterRegistry* parentRegistry = NULL);
00062 
00064    DtWhileStmt(const DtWhileStmt& orig,
00065       DtReaderWriterRegistry* parentRegistry = NULL);
00066 
00068    virtual ~DtWhileStmt();
00069 
00071    DtWhileStmt& operator=(const DtWhileStmt& orig);
00072 
00074    virtual DtSimStatement* clone(
00075       DtReaderWriterRegistry* parentRegistry = NULL) const;
00076 
00078    virtual int type() const;
00079 
00083    virtual bool validate();
00084 
00087    virtual void execute(DtPlan& planContext);
00088 
00090    virtual int subBlockCount() const;
00092    virtual DtSimBlock* subBlock(int index);
00093 
00103    virtual DtString stringRep(int subBlockIndex = DtSR_STMT) const;
00104 
00106    virtual const DtSimCondExpr* condExpr() const;
00108    virtual void setCondExpr(DtSimCondExpr* arg);
00109 
00110    virtual DtWhileBlock* whileBlock() const;
00111    virtual void setWhileBlock(DtWhileBlock* arg);
00112 
00115    virtual int netRepSize() const;
00116 
00118    virtual bool setFromNet(const char* contentBuffer, 
00119       unsigned contentSize);
00120 
00132    virtual bool setToNet();
00133 
00134 public:
00136    static DtSimStatement* creator(DtReaderWriterRegistry* parentRegistry=NULL);
00137 
00138 protected:
00139    virtual bool compare(DtSimStatement* rhs);
00140 
00141 protected:
00142 
00143    DtRwCondExpr myCondExpr;
00144    DtWhileBlock* myBlock;
00145 };
00146 
00147 #endif

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)