home *** CD-ROM | disk | FTP | other *** search
/ ActiveX Programming Unleashed CD / AXU.iso / componen / interact / demo / data.1 / IDOOWL.H < prev    next >
Encoding:
C/C++ Source or Header  |  1996-05-22  |  34.0 KB  |  1,557 lines

  1. /***************************************************************************\
  2.  
  3.    (c) 1995-1996, ProtoView Development Co., All rights reserved
  4. \***************************************************************************/
  5.  
  6. //============================================================================
  7. //
  8. //        Borland C++ Class Library for the IDO Custom Control
  9. //
  10. //============================================================================
  11.  
  12. #ifndef __IDOOWL_H__
  13. #define __IDOOWL_H__
  14.  
  15. //============================================================================
  16.  
  17. #if !defined(__OWL_CONTROL_H)
  18.   #include <owl\control.h>
  19. #endif
  20. #if !defined(__CLASSLIB_ARRAYS_H)
  21.   #include <classlib\arrays.h>
  22. #endif
  23.  
  24. #include "pvido.h"
  25.  
  26. #ifndef EXPORT
  27.    #ifdef __DLL__
  28.       #define EXPORT _export
  29.    #else
  30.       #define EXPORT huge
  31.    #endif
  32. #endif
  33.  
  34. class TIDO;
  35. class TEntity;
  36. class TRelation;
  37. class TIDORule;
  38.  
  39. //============================================================================
  40. // IDO Rule Class Definition
  41. class TIDORule
  42. {
  43.  
  44.  
  45. //******* Constructors *******
  46. public:
  47.  
  48.    TIDORule ()
  49.    {
  50.       lstrcpy(m_rule.E1, "");
  51.       lstrcpy(m_rule.R1, "");
  52.       lstrcpy(m_rule.E2, "");
  53.       m_rule.MaxCount = 0;
  54.    }
  55.    TIDORule (LPIDO_RULE lpRule)
  56.    {
  57.       lstrcpy(m_rule.E1, lpRule->E1);
  58.       lstrcpy(m_rule.R1, lpRule->R1);
  59.       lstrcpy(m_rule.E2, lpRule->E2);
  60.       m_rule.MaxCount = lpRule->MaxCount;
  61.    }
  62.  
  63.  
  64. //******* Destructors *******
  65. public:
  66.  
  67.   virtual ~TIDORule()
  68.   {
  69.      ;
  70.   }
  71.  
  72.  
  73. //******* Public Data Members *******
  74. public :
  75.  
  76.    IDO_RULE m_rule;
  77.  
  78.  
  79. //******* Public Member Functions *******
  80. public :
  81.  
  82.    LPCSTR DestinationEntityClassName()
  83.    {
  84.       return (LPCSTR)idoRuleDestinationEntityClassName(&m_rule);
  85.    }
  86.  
  87.    LPCSTR SourceEntityClassName()
  88.    {
  89.       return (LPCSTR)idoRuleSourceEntityClassName(&m_rule);
  90.    }
  91.  
  92.    LPCSTR RelationClassName()
  93.    {
  94.       return (LPCSTR)idoRuleRelationClassName(&m_rule);
  95.    }
  96.  
  97. };
  98.  
  99.  
  100. //============================================================================
  101. // Entity Class Definition
  102. class TEntity
  103. {
  104. friend class TIDO;
  105. friend class TRelation;
  106.  
  107.  
  108.    //******* Constructors *******
  109. public:
  110.  
  111.    TEntity ()
  112.    {
  113.       m_entity.id = 0L;
  114.       lstrcpy(m_entity.name, "");
  115.       m_entity.hIDO = 0;
  116.    }
  117.    TEntity (TWindow *pIDO, int UserID, LPCSTR lpszUserName)
  118.    {
  119.       m_entity.id = UserID;
  120.       lstrcpy(m_entity.name, lpszUserName);
  121.       m_entity.hIDO = pIDO->HWindow;
  122.    }
  123.    TEntity (LPENTITY lpEnt)
  124.    {
  125.       m_entity.id = lpEnt->id;
  126.       lstrcpy(m_entity.name, lpEnt->name);
  127.       lstrcpy(m_entity.classname, lpEnt->classname);
  128.       m_entity.hIDO = lpEnt->hIDO;
  129.    }
  130.  
  131.  
  132.    //******* Destructors *******
  133.   virtual ~TEntity()
  134.   {
  135.      ;
  136.   }
  137.  
  138.  
  139.    //******* Public Data Members *******
  140. public :
  141.  
  142.    ENTITY m_entity;
  143.  
  144.  
  145.    //******* Public Member Functions *******
  146.    void   SetUserData(LPVOID lpData)
  147.    {
  148.       idoEntitySetUserData(&m_entity, lpData);
  149.    }
  150.    LPVOID GetUserData()
  151.    {
  152.       return idoEntityGetUserData(&m_entity);
  153.    }
  154.  
  155.    void     SetBackColor(COLORREF clrVal)
  156.    {
  157.       idoEntitySetBackColor(&m_entity, clrVal);
  158.    }
  159.    COLORREF GetBackColor()
  160.    {
  161.       return idoEntityGetBackColor(&m_entity);
  162.    }
  163.  
  164.    void   SetInetUrl(LPCSTR lpszText)
  165.    {
  166.       idoEntitySetInetUrl(&m_entity, lpszText);
  167.    }
  168.    LPCSTR GetInetUrl()
  169.    {
  170.       return idoEntityGetInetUrl(&m_entity);
  171.    }
  172.    void   SetInetHost(INET_HOST Host)
  173.    {
  174.       idoEntitySetInetHost(&m_entity, Host);
  175.    }
  176.    INET_HOST GetInetHost()
  177.    {
  178.       return idoEntityGetInetHost(&m_entity);
  179.    }
  180.  
  181.    void     SetTextColor(COLORREF clrVal)
  182.    {
  183.       idoEntitySetTextColor(&m_entity, clrVal);
  184.    }
  185.    COLORREF GetTextColor()
  186.    {
  187.       return idoEntityGetTextColor(&m_entity);
  188.    }
  189.  
  190.    void   SetText(LPCSTR lpszText)
  191.    {
  192.       idoEntitySetText(&m_entity, lpszText);
  193.    }
  194.    LPCSTR GetText()
  195.    {
  196.       return idoEntityGetText(&m_entity);
  197.    }
  198.  
  199.    int GetTop()
  200.    {
  201.       return idoEntityGetTop(&m_entity);
  202.    }
  203.    void SetTop(int cVal)
  204.    {
  205.       idoEntitySetTop(&m_entity, cVal);
  206.    }
  207.    int GetBottom()
  208.    {
  209.       return idoEntityGetBottom(&m_entity);
  210.    }
  211.    void SetBottom(int cVal)
  212.    {
  213.       idoEntitySetBottom(&m_entity, cVal);
  214.    }
  215.    int GetLeft()
  216.    {
  217.       return idoEntityGetLeft(&m_entity);
  218.    }
  219.    void SetLeft(int cVal)
  220.    {
  221.       idoEntitySetLeft(&m_entity, cVal);
  222.    }
  223.    int GetRight()
  224.    {
  225.       return idoEntityGetRight(&m_entity);
  226.    }
  227.    void SetRight(int cVal)
  228.    {
  229.       idoEntitySetRight(&m_entity, cVal);
  230.    }
  231.    int GetRect(LPRECT lpRect)
  232.    {
  233.       return idoEntityGetRect(&m_entity, lpRect);
  234.    }
  235.    void SetRect(LPRECT lpRect)
  236.    {
  237.       idoEntitySetRect(&m_entity, lpRect);
  238.    }
  239.  
  240.    void SetCoordX(int cVal)
  241.    {
  242.       idoEntitySetCoordX(&m_entity, cVal);
  243.    }
  244.    int  GetCoordX()
  245.    {
  246.       return idoEntityGetCoordX(&m_entity);
  247.    }
  248.    void SetCoordY(int cVal)
  249.    {
  250.       idoEntitySetCoordY(&m_entity, cVal);
  251.    }
  252.    int  GetCoordY()
  253.    {
  254.       return idoEntityGetCoordY(&m_entity);
  255.    }
  256.  
  257.    void        SetShape(ENTITYSHAPE cVal)
  258.    {
  259.       idoEntitySetShape(&m_entity, cVal);
  260.    }
  261.    ENTITYSHAPE GetShape()
  262.    {
  263.       return idoEntityGetShape(&m_entity);
  264.    }
  265.  
  266.    void          SetFrame(THREE_D_STYLE cVal)
  267.    {
  268.       idoEntitySetFrame(&m_entity, cVal);
  269.    }
  270.    THREE_D_STYLE GetFrame()
  271.    {
  272.       return idoEntityGetFrame(&m_entity);
  273.    }
  274.  
  275.    void SetSelect(BOOL bVal)
  276.    {
  277.       idoEntitySetSelect(&m_entity, bVal);
  278.    }
  279.    BOOL GetSelect()
  280.    {
  281.       return (BOOL)idoEntityGetSelect(&m_entity);
  282.    }
  283.  
  284.    void SetBorder(BOOL bVal)
  285.    {
  286.       idoEntitySetBorder(&m_entity, bVal);
  287.    }
  288.    BOOL GetBorder()
  289.    {
  290.       return (BOOL)idoEntityGetBorder(&m_entity);
  291.    }
  292.  
  293.    void SetContainer(long lVal)
  294.    {
  295.       idoEntitySetContainer(&m_entity, lVal);
  296.    }
  297.    long GetContainer()
  298.    {
  299.       return idoEntityGetContainer(&m_entity);
  300.    }
  301.  
  302.    void   SetGraphic(LPCSTR lpszVal)
  303.    {
  304.       idoEntitySetGraphic(&m_entity, lpszVal);
  305.    }
  306.    LPCSTR GetGraphic()
  307.    {
  308.       return idoEntityGetGraphic(&m_entity);
  309.    }
  310.  
  311.    void   SetTextOrientation(TEXTPOSSTYLE cVal)
  312.    {
  313.       idoEntitySetTextOrientation(&m_entity, cVal);
  314.    }
  315.    TEXTPOSSTYLE GetTextOrientation()
  316.    {
  317.       return idoEntityGetTextOrientation(&m_entity);
  318.    }
  319.  
  320.    void   SetFont(LPIDO_FONT lpFont)
  321.    {
  322.       idoEntitySetFont(&m_entity, lpFont);
  323.    }
  324.    LPIDO_FONT GetFont()
  325.    {
  326.       return idoEntityGetFont(&m_entity);
  327.    }
  328.  
  329.    BOOL GetValidRelationDragSource()
  330.    {
  331.       return idoEntityGetValidRelationDragSource(&m_entity);
  332.    }
  333.    void SetValidRelationDragSource(BOOL bVal)
  334.    {
  335.       idoEntitySetValidRelationDragSource(&m_entity, bVal);
  336.    }
  337.  
  338.    BOOL GetCanResize()
  339.    {
  340.       return idoEntityGetCanResize(&m_entity);
  341.    }
  342.    void SetCanResize(BOOL bVal)
  343.    {
  344.       idoEntitySetCanResize(&m_entity, bVal);
  345.    }
  346.  
  347.    BOOL GetCanMove()
  348.    {
  349.       return idoEntityGetCanMove(&m_entity);
  350.    }
  351.    void SetCanMove(BOOL bVal)
  352.    {
  353.       idoEntitySetCanMove(&m_entity, bVal);
  354.    }
  355.  
  356.    BOOL GetCanDelete()
  357.    {
  358.       return idoEntityGetCanDelete(&m_entity);
  359.    }
  360.    void SetCanDelete(BOOL bVal)
  361.    {
  362.       idoEntitySetCanDelete(&m_entity, bVal);
  363.    }
  364.  
  365.    BOOL GetReadOnly()
  366.    {
  367.       return idoEntityGetReadOnly(&m_entity);
  368.    }
  369.    void SetReadOnly(BOOL bVal)
  370.    {
  371.       idoEntitySetReadOnly(&m_entity, bVal);
  372.    }
  373.  
  374.    BOOL GetAutoResize()
  375.    {
  376.       return idoEntityGetAutoResize(&m_entity);
  377.    }
  378.    void SetAutoResize(BOOL bVal)
  379.    {
  380.       idoEntitySetAutoResize(&m_entity, bVal);
  381.    }
  382.  
  383.    BOOL GetStretchBitmap()
  384.    {
  385.       return idoEntityGetStretchBitmap(&m_entity);
  386.    }
  387.    void SetStretchBitmap(BOOL bVal)
  388.    {
  389.       idoEntitySetStretchBitmap(&m_entity, bVal);
  390.    }
  391.  
  392.    BOOL GetTransparent()
  393.    {
  394.       return idoEntityGetTransparent(&m_entity);
  395.    }
  396.    void SetTransparent(BOOL bVal)
  397.    {
  398.       idoEntitySetTransparent(&m_entity, bVal);
  399.    }
  400.  
  401.  
  402. //******* Explicit inline Public Member Functions *******
  403. public :
  404.  
  405.    BOOL IterateRelationInNext(LPRELATION lpRel);
  406.    BOOL IterateRelationInNext(TRelation * lpRel);
  407.    TRelation * IterateRelationInNext();
  408.  
  409.    BOOL IterateRelationOutNext(LPRELATION lpRel);
  410.    BOOL IterateRelationOutNext(TRelation * lpRel);
  411.    TRelation * IterateRelationOutNext();
  412.  
  413.    BOOL IterateContainedEntityNext(LPENTITY lpEnt);
  414.    BOOL IterateContainedEntityNext(TEntity * lpEnt);
  415.    TEntity * IterateContainedEntityNext();
  416.  
  417.  
  418.    //******* Public Member Functions *******
  419.    long GetUserID()
  420.    {
  421.       return m_entity.id;
  422.    }
  423.    LPCSTR GetUserName()
  424.    {
  425.       return (LPCSTR)m_entity.name;
  426.    }
  427.    LPCSTR GetClassName()
  428.    {
  429.       return (LPCSTR)m_entity.classname;
  430.    }
  431.  
  432.    long GetRelationInCount()
  433.    {
  434.       return idoEntityGetRelationInCount(&m_entity);
  435.    }
  436.    BOOL IterateRelationInFirst()
  437.    {
  438.       return idoEntityIterateRelationInFirst(&m_entity);
  439.    }
  440.  
  441.    long GetRelationOutCount()
  442.    {
  443.       return idoEntityGetRelationOutCount(&m_entity);
  444.    }
  445.    BOOL IterateRelationOutFirst()
  446.    {
  447.       return idoEntityIterateRelationOutFirst(&m_entity);
  448.    }
  449.  
  450.    long GetContainedEntityCount()
  451.    {
  452.       return idoEntityGetContainedEntityCount(&m_entity);
  453.    }
  454.    BOOL IterateContainedEntityFirst()
  455.    {
  456.       return idoEntityIterateContainedEntityFirst(&m_entity);
  457.    }
  458.    BOOL AddEntityToContainer(TEntity * lpTEntity)
  459.    {
  460.       if(!lpTEntity)
  461.          return FALSE;
  462.       return idoEntityAddEntityToContainer(&m_entity, &(lpTEntity->m_entity));
  463.    }
  464.    BOOL RemoveEntityFromContainer(TEntity * lpTEntity)
  465.    {
  466.       if(!lpTEntity)
  467.          return FALSE;
  468.       return idoEntityRemoveEntityFromContainer(&m_entity, &(lpTEntity->m_entity));
  469.    }
  470.  
  471.    BOOL Delete()
  472.    {
  473.       return (BOOL)idoEntityDelete(&m_entity);
  474.    }
  475.  
  476.    BOOL Repaint()
  477.    {
  478.       return idoEntityRepaint(&m_entity);
  479.    }
  480.  
  481.    BOOL BringIntoView()
  482.    {
  483.       return idoEntityBringIntoView(&m_entity);
  484.    }
  485.  
  486.    void PropertyPage(int cVal)
  487.    {
  488.       idoEntityPropertyPage(&m_entity, cVal);
  489.    }
  490.  
  491. };
  492.  
  493.  
  494. //============================================================================
  495. // Relation Class Definition
  496. class TRelation
  497. {
  498. friend class TIDO;
  499. friend class TEntity;
  500.  
  501.  
  502.    //******* Constructors *******
  503. public:
  504.  
  505.    TRelation ()
  506.    {
  507.       m_relation.id = 0L;
  508.       lstrcpy(m_relation.name, "");
  509.       m_relation.hIDO = 0;
  510.    }
  511.    TRelation (TWindow *pIDO, int UserID, LPCSTR lpszUserName)
  512.    {
  513.       m_relation.id = UserID;
  514.       lstrcpy(m_relation.name, lpszUserName);
  515.       m_relation.hIDO = pIDO->HWindow;
  516.    }
  517.    TRelation (LPRELATION lpRel)
  518.    {
  519.       m_relation.id = lpRel->id;
  520.       lstrcpy(m_relation.name, lpRel->name);
  521.       lstrcpy(m_relation.classname, lpRel->classname);
  522.       m_relation.hIDO = lpRel->hIDO;
  523.    }
  524.  
  525.  
  526.    //******* Destructors *******
  527.    virtual
  528.    ~TRelation()
  529.    {
  530.       ;
  531.    }
  532.  
  533.  
  534.    //******* Public Data Members *******
  535. public :
  536.  
  537.    RELATION m_relation;
  538.  
  539.  
  540.  
  541.    //******* Public Member Functions *******
  542. public :
  543.  
  544.    void   SetUserData(LPVOID lpData)
  545.    {
  546.       idoRelationSetUserData(&m_relation, lpData);
  547.    }
  548.    LPVOID GetUserData()
  549.    {
  550.       return idoRelationGetUserData(&m_relation);
  551.    }
  552.  
  553.    void     SetBackColor(COLORREF clrVal)
  554.    {
  555.       idoRelationSetBackColor(&m_relation, clrVal);
  556.    }
  557.    COLORREF GetBackColor()
  558.    {
  559.       return idoRelationGetBackColor(&m_relation);
  560.    }
  561.  
  562.    void     SetTextColor(COLORREF clrVal)
  563.    {
  564.       idoRelationSetTextColor(&m_relation, clrVal);
  565.    }
  566.    COLORREF GetTextColor()
  567.    {
  568.       return idoRelationGetTextColor(&m_relation);
  569.    }
  570.  
  571.    void   SetText(LPCSTR lpszText)
  572.    {
  573.       idoRelationSetText(&m_relation, lpszText);
  574.    }
  575.    LPCSTR GetText()
  576.    {
  577.       return idoRelationGetText(&m_relation);
  578.    }
  579.  
  580.    void       SetSourceArrow(ARROWSTYLE cVal)
  581.    {
  582.       idoRelationSetSourceArrow(&m_relation, cVal);
  583.    }
  584.    ARROWSTYLE GetSourceArrow()
  585.    {
  586.       return idoRelationGetSourceArrow(&m_relation);
  587.    }
  588.  
  589.    void       SetDestinationArrow(ARROWSTYLE cVal)
  590.    {
  591.       idoRelationSetDestinationArrow(&m_relation, cVal);
  592.    }
  593.    ARROWSTYLE GetDestinationArrow()
  594.    {
  595.       return idoRelationGetDestinationArrow(&m_relation);
  596.    }
  597.  
  598.    void      SetType(LINESTYLE cVal)
  599.    {
  600.       idoRelationSetType(&m_relation, cVal);
  601.    }
  602.    LINESTYLE GetType()
  603.    {
  604.       return idoRelationGetType(&m_relation);
  605.    }
  606.  
  607.    void SetThickness(long lVal)
  608.    {
  609.       idoRelationSetThickness(&m_relation, lVal);
  610.    }
  611.    long GetThickness()
  612.    {
  613.       return idoRelationGetThickness(&m_relation);
  614.    }
  615.  
  616.    void SetFont(LPIDO_FONT lpFont)
  617.    {
  618.       idoRelationSetFont(&m_relation, lpFont);
  619.    }
  620.    LPIDO_FONT GetFont()
  621.    {
  622.       return idoRelationGetFont(&m_relation);
  623.    }
  624.  
  625.    BOOL GetReadOnly()
  626.    {
  627.       return idoRelationGetReadOnly(&m_relation);
  628.    }
  629.    void SetReadOnly(LPRELATION, BOOL bVal)
  630.    {
  631.       idoRelationSetReadOnly(&m_relation, bVal);
  632.    }
  633.  
  634.    BOOL GetCanDelete()
  635.    {
  636.       return idoRelationGetCanDelete(&m_relation);
  637.    }
  638.    void SetCanDelete(BOOL bVal)
  639.    {
  640.       idoRelationSetCanDelete(&m_relation, bVal);
  641.    }
  642.  
  643.    BOOL GetCanMoveEndPoints()
  644.    {
  645.       return idoRelationGetCanMoveEndPoints(&m_relation);
  646.    }
  647.    void SetCanMoveEndPoints(BOOL bVal)
  648.    {
  649.       idoRelationSetCanMoveEndPoints(&m_relation, bVal);
  650.    }
  651.  
  652.    BOOL GetCanMoveMidPoints()
  653.    {
  654.       return idoRelationGetCanMoveMidPoints(&m_relation);
  655.    }
  656.    void SetCanMoveMidPoints(BOOL bVal)
  657.    {
  658.       idoRelationSetCanMoveMidPoints(&m_relation, bVal);
  659.    }
  660.  
  661.  
  662.  
  663. //******* Explicit inline Public Member Functions *******
  664. public :
  665.  
  666.    BOOL SourceEntity(LPENTITY lpEnt);
  667.    BOOL SourceEntity(TEntity * lpEnt);
  668.    TEntity * SourceEntity();
  669.  
  670.    BOOL DestinationEntity(LPENTITY lpEnt);
  671.    BOOL DestinationEntity(TEntity * lpEnt);
  672.    TEntity * DestinationEntity();
  673.  
  674.  
  675.    //******* Public Member Functions *******
  676.    long GetUserID()
  677.    {
  678.       return m_relation.id;
  679.    }
  680.    LPCSTR GetUserName()
  681.    {
  682.       return (LPCSTR)m_relation.name;
  683.    }
  684.    LPCSTR GetClassName()
  685.    {
  686.       return (LPCSTR)m_relation.classname;
  687.    }
  688.  
  689.    BOOL Repaint()
  690.    {
  691.       return idoRelationRepaint(&m_relation);
  692.    }
  693.  
  694.    BOOL BringIntoView()
  695.    {
  696.       return idoRelationBringIntoView(&m_relation);
  697.    }
  698.  
  699.    BOOL Delete()
  700.    {
  701.       return idoRelationDelete(&m_relation);
  702.    }
  703.  
  704.    void PropertyPage(int cVal)
  705.    {
  706.       idoRelationPropertyPage(&m_relation, cVal);
  707.    }
  708.  
  709. };
  710.  
  711.  
  712. //============================================================================
  713. // IDO Class Definition
  714. class TIDO : public TControl
  715. {
  716. friend class TEntity;
  717. friend class TRelation;
  718.  
  719.  
  720. //******* Constructors *******
  721. public:
  722.  
  723.  
  724.    TIDO::TIDO (TWindow * AParent, int AnId, int X, int Y, int W, int H, TModule * AModule)
  725.                : TControl(AParent, AnId, NULL, X, Y, W, H, AModule)
  726.    {
  727.        EnableTransfer ();
  728.    }
  729.  
  730.    TIDO::TIDO (TWindow * AParent, int ResourceId, TModule * AModule)
  731.                : TControl (AParent, ResourceId, AModule)
  732.    {
  733.        EnableTransfer ();
  734.    }
  735.  
  736. //******* Destructors *******
  737.    virtual
  738.    ~TIDO()
  739.    {
  740.       ;
  741.    }
  742.  
  743. //******* Protected Member Functions *******
  744. protected:
  745.  
  746.    char far *
  747.    GetClassName()
  748.    {
  749.       // Returns the MS Window's registered Class Name
  750.       static char IDOClassName[30];
  751.  
  752.       #ifdef WIN32
  753.          lstrcpy(IDOClassName, "pvIDO32");
  754.       #else
  755.          lstrcpy(IDOClassName, "pvIDO");
  756.       #endif
  757.  
  758.       return IDOClassName;
  759.    }
  760.  
  761.    virtual void
  762.    GetWindowClass (WNDCLASS _FAR & AWndClass)
  763.    {
  764.        TControl::GetWindowClass (AWndClass);
  765.        // not neaded since class should have already been registered
  766.    }
  767.  
  768.    virtual bool
  769.    Register (void)
  770.    {
  771.       // not needed since class should have already been registered
  772.       return TRUE;
  773.    }
  774.  
  775.    void
  776.    EvHScroll(UINT scrollCode, UINT thumbPos, HWND hWndCtl)
  777.    {
  778.       DefaultProcessing();
  779.    }
  780.  
  781.    void
  782.    EvVScroll(UINT scrollCode, UINT thumbPos, HWND hWndCtl)
  783.    {
  784.       DefaultProcessing();
  785.    }
  786.  
  787.  
  788.    //******* Public Member Functions *******
  789. public:
  790.  
  791.    void SetModified(BOOL bVal)
  792.    {
  793.       idoSetModified(HWindow, bVal);
  794.    }
  795.    BOOL GetModified()
  796.    {
  797.       return idoGetModified(HWindow);
  798.    }
  799.  
  800.    BOOL GetEditMode()
  801.    {
  802.       return idoGetEditMode(HWindow);
  803.    }
  804.    void SetEditMode(BOOL bVal)
  805.    {
  806.       idoSetEditMode(HWindow, bVal);
  807.    }
  808.  
  809.    int  GetGridHeight()
  810.    {
  811.       return idoGetGridHeight(HWindow);
  812.    }
  813.    void SetGridHeight(int cVal)
  814.    {
  815.       idoSetGridHeight(HWindow, cVal);
  816.    }
  817.  
  818.    int  GetGridWidth()
  819.    {
  820.       return idoGetGridWidth(HWindow);
  821.    }
  822.    void SetGridWidth(int cVal)
  823.    {
  824.       idoSetGridWidth(HWindow, cVal);
  825.    }
  826.  
  827.    COLORREF GetGridLineColor()
  828.    {
  829.       return idoGetGridLineColor(HWindow);
  830.    }
  831.    void     SetGridLineColor(COLORREF clrVal)
  832.    {
  833.       idoSetGridLineColor(HWindow, clrVal);
  834.    }
  835.  
  836.    COLORREF GetBackColor()
  837.    {
  838.       return idoGetBackColor(HWindow);
  839.    }
  840.    void     SetBackColor(COLORREF clrVal)
  841.    {
  842.       idoSetBackColor(HWindow, clrVal);
  843.    }
  844.  
  845.    BOOL GetGridLines()
  846.    {
  847.       return idoGetGridLines(HWindow);
  848.    }
  849.    void SetGridLines(BOOL bVal)
  850.    {
  851.       idoSetGridLines(HWindow, bVal);
  852.    }
  853.  
  854.    BOOL GetSnapToGrid()
  855.    {
  856.       return idoGetSnapToGrid(HWindow);
  857.    }
  858.    void SetSnapToGrid(BOOL bVal)
  859.    {
  860.       idoSetSnapToGrid(HWindow, bVal);
  861.    }
  862.  
  863.    BOOL GetToolsPalette()
  864.    {
  865.       return idoGetToolsPalette(HWindow);
  866.    }
  867.    void SetToolsPalette(BOOL bVal)
  868.    {
  869.       idoSetToolsPalette(HWindow, bVal);
  870.    }
  871.  
  872.    void SetToolsPaletteButtonText(LPCSTR lpText)
  873.    {
  874.       idoSetToolsPaletteButtonText(HWindow, lpText);
  875.    }
  876.  
  877.    BOOL GetRulesEnforced()
  878.    {
  879.       return idoGetRulesEnforced(HWindow);
  880.    }
  881.    void SetRulesEnforced(BOOL bVal)
  882.    {
  883.       idoSetRulesEnforced(HWindow, bVal);
  884.    }
  885.  
  886.    BOOL GetCurrentEntity(LPENTITY lpEnt)
  887.    {
  888.       return idoGetCurrentEntity(HWindow, lpEnt);
  889.    }
  890.    BOOL GetCurrentEntity(TEntity * lpEnt)
  891.    {
  892.       return idoGetCurrentEntity(HWindow, &(lpEnt->m_entity));
  893.    }
  894.    TEntity * GetCurrentEntity()
  895.    {
  896.       ENTITY entity;
  897.       TEntity * lpEnt = NULL;
  898.  
  899.       if(idoGetCurrentEntity(HWindow, &entity))
  900.          lpEnt = new TEntity(&entity);
  901.  
  902.       return lpEnt;
  903.    }
  904.  
  905.    BOOL SetCurrentEntity(LPENTITY lpEnt)
  906.    {
  907.       return idoSetCurrentEntity(HWindow, lpEnt);
  908.    }
  909.    BOOL SetCurrentEntity(TEntity * lpEnt)
  910.    {
  911.       return idoSetCurrentEntity(HWindow, &(lpEnt->m_entity));
  912.    }
  913.  
  914.    BOOL GetCurrentRelation(LPRELATION lpRel)
  915.    {
  916.       return idoGetCurrentRelation(HWindow, lpRel);
  917.    }
  918.    BOOL GetCurrentRelation(TRelation * lpRel)
  919.    {
  920.       return idoGetCurrentRelation(HWindow, &(lpRel->m_relation));
  921.    }
  922.    TRelation * GetCurrentRelation()
  923.    {
  924.       RELATION relation;
  925.       TRelation * lpRel = NULL;
  926.  
  927.       if(idoGetCurrentRelation(HWindow, &relation))
  928.          lpRel = new TRelation(&relation);
  929.  
  930.       return lpRel;
  931.    }
  932.  
  933.    BOOL SetCurrentRelation(LPRELATION lpRel)
  934.    {
  935.       return idoSetCurrentRelation(HWindow, lpRel);
  936.    }
  937.    BOOL SetCurrentRelation(TRelation * lpRel)
  938.    {
  939.       return idoSetCurrentRelation(HWindow, &(lpRel->m_relation));
  940.    }
  941.  
  942.    BOOL GetPopupMenu(long lVal)
  943.    {
  944.       return idoGetPopupMenu(HWindow, lVal);
  945.    }
  946.    void SetPopupMenu(long lVal, BOOL bVal)
  947.    {
  948.       idoSetPopupMenu(HWindow, lVal, bVal);
  949.    }
  950.  
  951. //   conflicts with WINDOWSX.H
  952. //   long idoGetWindowStyle()
  953. //   {
  954. //      return idoGetWindowStyle(HWindow);
  955. //   }
  956. //   void idoSetWindowStyle(long lVal)
  957. //   {
  958. //      idoSetWindowStyle(HWindow, lVal);
  959. //   }
  960.  
  961.    BOOL GetBorder()
  962.    {
  963.       return idoGetBorder(HWindow);
  964.    }
  965.    void SetBorder(BOOL bVal)
  966.    {
  967.       idoSetBorder(HWindow, bVal);
  968.    }
  969.  
  970.    BOOL GetPrinterLines()
  971.    {
  972.       return idoGetPrinterLines(HWindow);
  973.    }
  974.    void SetPrinterLines(BOOL bVal)
  975.    {
  976.       idoSetPrinterLines(HWindow, bVal);
  977.    }
  978.  
  979.    BOOL GetPrinterLandscape()
  980.    {
  981.       return idoGetPrinterLandscape(HWindow);
  982.    }
  983.    void SetPrinterLandscape(BOOL bVal)
  984.    {
  985.       idoSetPrinterLandscape(HWindow, bVal);
  986.    }
  987.  
  988.    long GetScrollBars()
  989.    {
  990.       return idoGetScrollBars(HWindow);
  991.    }
  992.    void SetScrollBars(long lVal)
  993.    {
  994.       idoSetScrollBars(HWindow, lVal);
  995.    }
  996.  
  997.    BOOL GetRedraw()
  998.    {
  999.       return idoGetRedraw(HWindow);
  1000.    }
  1001.    void SetRedraw(BOOL bVal)
  1002.    {
  1003.       idoSetRedraw(HWindow, bVal);
  1004.    }
  1005.  
  1006.  
  1007.    LPCSTR GetInetPath()
  1008.    {
  1009.       return (LPCSTR)idoGetInetPath(HWindow);
  1010.    }
  1011.    void SetInetPath(LPCSTR lpPath)
  1012.    {
  1013.      idoSetInetPath(HWindow, (LPCSTR)lpPath);
  1014.    }
  1015.  
  1016.  
  1017.    short GetZoomValue()
  1018.    {
  1019.       return idoGetZoomValue(HWindow);
  1020.    }
  1021.    void SetZoomValue(short cVal)
  1022.    {
  1023.      idoSetZoomValue(HWindow, cVal);
  1024.    }
  1025.  
  1026.  
  1027.    //******* Public Member Functions *******
  1028.    void CancelAction()
  1029.    {
  1030.       idoCancelAction(HWindow);
  1031.    }
  1032.    void AllowAction()
  1033.    {
  1034.       idoAllowAction(HWindow);
  1035.    }
  1036.  
  1037.    BOOL DragAddEntity(LPCSTR lpszVal)
  1038.    {
  1039.       return idoDragAddEntity(HWindow, lpszVal);
  1040.    }
  1041.  
  1042.    BOOL AddEntityFromClass(long lID, LPSTR lpszName, LPSTR lpszClass, LPSTR lpszText, int cX, int cY, int cWidth, int cHeight)
  1043.    {
  1044.       return idoAddEntityFromClass(HWindow, lID, lpszName, lpszClass, lpszText, cX, cY, cWidth, cHeight);
  1045.    }
  1046.  
  1047.    BOOL DeleteEntity(LPENTITY lpEnt)
  1048.    {
  1049.       return idoDeleteEntity(HWindow, lpEnt);
  1050.    }
  1051.    BOOL DeleteEntity(TEntity * lpEnt)
  1052.    {
  1053.       return idoDeleteEntity(HWindow, &(lpEnt->m_entity));
  1054.    }
  1055.  
  1056.    BOOL DoesEntityExist(long lID, LPSTR lpszName)
  1057.    {
  1058.       return idoDoesEntityExist(HWindow, lID, lpszName);
  1059.    }
  1060.  
  1061.    long GetNumberOfSelectedEntities()
  1062.    {
  1063.       return idoGetNumberOfSelectedEntities(HWindow);
  1064.    }
  1065.    long GetNumberOfEntities()
  1066.    {
  1067.       return idoGetNumberOfEntities(HWindow);
  1068.    }
  1069.    long GetNumberOfRelations()
  1070.    {
  1071.       return idoGetNumberOfRelations(HWindow);
  1072.    }
  1073.  
  1074.    BOOL DragAddRelation(LPCSTR lpszVal)
  1075.    {
  1076.       return idoDragAddRelation(HWindow, lpszVal);
  1077.    }
  1078.  
  1079.    BOOL AddRelationFromClass(long lID, LPSTR lpszName, LPSTR lpszClass, LPSTR lpszText, long lsID, LPSTR lpszsName, long ldID, LPSTR lpszdName)
  1080.    {
  1081.       return idoAddRelationFromClass(HWindow, lID, lpszName, lpszClass, lpszText, lsID, lpszsName, ldID, lpszdName);
  1082.    }
  1083.  
  1084.    BOOL DeleteRelation(LPRELATION lpRel)
  1085.    {
  1086.       return idoDeleteRelation(HWindow, lpRel);
  1087.    }
  1088.    BOOL DeleteRelation(TRelation * lpRel)
  1089.    {
  1090.       return idoDeleteRelation(HWindow, &(lpRel->m_relation));
  1091.    }
  1092.  
  1093.    BOOL DoesRelationExist(long lID, LPSTR lpszName)
  1094.    {
  1095.       return idoDoesRelationExist(HWindow, lID, lpszName);
  1096.    }
  1097.  
  1098.    BOOL ReadDiagram(LPSTR lpszVal)
  1099.    {
  1100.       return idoReadDiagram(HWindow, lpszVal);
  1101.    }
  1102.  
  1103.    BOOL SaveDiagram(LPSTR lpszVal)
  1104.    {
  1105.       return idoSaveDiagram(HWindow, lpszVal);
  1106.    }
  1107.  
  1108.    void ResetDiagram()
  1109.    {
  1110.       idoResetDiagram(HWindow);
  1111.    }
  1112.    void ResetPalette()
  1113.    {
  1114.      idoResetPalette(HWindow);
  1115.    }
  1116.  
  1117.    LPCSTR GetFileName()
  1118.    {
  1119.       return (LPCSTR)idoGetFileName(HWindow);
  1120.    }
  1121.    void SetFileName(LPCSTR lpFileName)
  1122.    {
  1123.      idoSetFileName(HWindow, (LPCSTR)lpFileName);
  1124.    }
  1125.  
  1126.    long GetVersion()
  1127.    {
  1128.      return idoGetVersion(HWindow);
  1129.    }
  1130.  
  1131.    BOOL ReadPalette(LPSTR lpszVal)
  1132.    {
  1133.       return idoReadPalette(HWindow, lpszVal);
  1134.    }
  1135.  
  1136.    BOOL SavePalette(LPSTR lpszVal)
  1137.    {
  1138.       return idoSavePalette(HWindow, lpszVal);
  1139.    }
  1140.  
  1141.    void Zoom(int cVal, long lVal)
  1142.    {
  1143.       idoZoom(HWindow, cVal, lVal);
  1144.    }
  1145.  
  1146.    BOOL GetNotifyEntity(LPENTITY lpEnt)
  1147.    {
  1148.       return idoGetNotifyEntity(HWindow, lpEnt);
  1149.    }
  1150.    BOOL GetNotifyEntity(TEntity * lpEnt)
  1151.    {
  1152.       return idoGetNotifyEntity(HWindow, &(lpEnt->m_entity));
  1153.    }
  1154.    TEntity * GetNotifyEntity()
  1155.    {
  1156.       ENTITY entity;
  1157.       TEntity * lpEnt = NULL;
  1158.  
  1159.       if(idoGetNotifyEntity(HWindow, &entity))
  1160.          lpEnt = new TEntity(&entity);
  1161.  
  1162.       return lpEnt;
  1163.    }
  1164.  
  1165.    BOOL GetNotifyRelation(LPRELATION lpRel)
  1166.    {
  1167.       return idoGetNotifyRelation(HWindow, lpRel);
  1168.    }
  1169.    BOOL GetNotifyRelation(TRelation * lpRel)
  1170.    {
  1171.       return idoGetNotifyRelation(HWindow, &(lpRel->m_relation));
  1172.    }
  1173.    TRelation * GetNotifyRelation()
  1174.    {
  1175.       RELATION relation;
  1176.       TRelation * lpRel = NULL;
  1177.  
  1178.       if(idoGetNotifyRelation(HWindow, &relation))
  1179.          lpRel = new TRelation(&relation);
  1180.  
  1181.       return lpRel;
  1182.    }
  1183.  
  1184.    void Cut()
  1185.    {
  1186.       idoCut(HWindow);
  1187.    }
  1188.    void Copy()
  1189.    {
  1190.       idoCopy(HWindow);
  1191.    }
  1192.    void Paste()
  1193.    {
  1194.       idoPaste(HWindow);
  1195.    }
  1196.  
  1197.    void ManageClasses()
  1198.    {
  1199.       idoManageClasses(HWindow);
  1200.    }
  1201.    void ManageRules()
  1202.    {
  1203.       idoManageRules(HWindow);
  1204.    }
  1205.    void PrintDiagram()
  1206.    {
  1207.       idoPrintDiagram(HWindow);
  1208.    }
  1209.  
  1210.    void PropertyPage(int cVal)
  1211.    {
  1212.       idoPropertyPage(HWindow, cVal);
  1213.    }
  1214.  
  1215.    BOOL IterateSelectedEntityFirst()
  1216.    {
  1217.       return idoIterateSelectedEntityFirst(HWindow);
  1218.    }
  1219.    BOOL IterateSelectedEntityNext(LPENTITY lpEnt)
  1220.    {
  1221.       return idoIterateSelectedEntityNext(HWindow, lpEnt);
  1222.    }
  1223.    BOOL IterateSelectedEntityNext(TEntity * lpEnt)
  1224.    {
  1225.       return idoIterateSelectedEntityNext(HWindow, &(lpEnt->m_entity));
  1226.    }
  1227.    TEntity * IterateSelectedEntityNext()
  1228.    {
  1229.       ENTITY entity;
  1230.       TEntity * pEnt = NULL;
  1231.  
  1232.       if(idoIterateSelectedEntityNext(HWindow, &entity))
  1233.          pEnt = new TEntity(&entity);
  1234.  
  1235.       return pEnt;
  1236.    }
  1237.  
  1238.    BOOL IterateEntityFirst()
  1239.    {
  1240.       return idoIterateEntityFirst(HWindow);
  1241.    }
  1242.    BOOL IterateEntityNext(LPENTITY lpEnt)
  1243.    {
  1244.       return idoIterateEntityNext(HWindow, lpEnt);
  1245.    }
  1246.    BOOL IterateEntityNext(TEntity * lpEnt)
  1247.    {
  1248.       return idoIterateEntityNext(HWindow, &(lpEnt->m_entity));
  1249.    }
  1250.    TEntity * IterateEntityNext()
  1251.    {
  1252.       ENTITY entity;
  1253.       TEntity * pEnt = NULL;
  1254.  
  1255.       if(idoIterateEntityNext(HWindow, &entity))
  1256.          pEnt = new TEntity(&entity);
  1257.  
  1258.       return pEnt;
  1259.    }
  1260.  
  1261.    BOOL IterateRelationFirst()
  1262.    {
  1263.       return idoIterateRelationFirst(HWindow);
  1264.    }
  1265.    BOOL IterateRelationNext(LPRELATION lpRel)
  1266.    {
  1267.       return idoIterateRelationNext(HWindow, lpRel);
  1268.    }
  1269.    BOOL IterateRelationNext(TRelation * lpRel)
  1270.    {
  1271.       return idoIterateRelationNext(HWindow, &(lpRel->m_relation));
  1272.    }
  1273.    TRelation * IterateRelationNext()
  1274.    {
  1275.       RELATION relation;
  1276.       TRelation * lpRel = NULL;
  1277.  
  1278.       if(idoIterateRelationNext(HWindow, &relation))
  1279.          lpRel = new TRelation(&relation);
  1280.  
  1281.       return lpRel;
  1282.    }
  1283.  
  1284.    BOOL AddEntityClass(LPSTR lpszClass, LPSTR lpszBitmap, TEntity * lpCEnt)
  1285.    {
  1286.       if(lpCEnt)
  1287.          return idoAddEntityClass(HWindow, lpszClass, lpszBitmap, &(lpCEnt->m_entity));
  1288.       else
  1289.          return idoAddEntityClass(HWindow, lpszClass, lpszBitmap, NULL);
  1290.    }
  1291.    BOOL DeleteEntityClass(LPSTR lpszClass)
  1292.    {
  1293.       return idoDeleteEntityClass(HWindow, lpszClass);
  1294.    }
  1295.    BOOL RedefineFromEntityClass(LPSTR lpszClass)
  1296.    {
  1297.       return idoRedefineFromEntityClass(HWindow, lpszClass);
  1298.    }
  1299.    BOOL GetEntityClass(LPSTR lpszClassName, LPENTITY lpEnt)
  1300.    {
  1301.       return idoGetEntityClass(HWindow, lpszClassName, lpEnt);
  1302.    }
  1303.    BOOL GetEntityClass(LPSTR lpszClassName, TEntity * lpEnt)
  1304.    {
  1305.       return idoGetEntityClass(HWindow, lpszClassName, &(lpEnt->m_entity));
  1306.    }
  1307.    TEntity * GetEntityClass(LPSTR lpszClassName)
  1308.    {
  1309.       ENTITY entity;
  1310.       TEntity * lpEnt = NULL;
  1311.  
  1312.       if(idoGetEntityClass(HWindow, lpszClassName, &entity))
  1313.          lpEnt = new TEntity(&entity);
  1314.  
  1315.       return lpEnt;
  1316.    }
  1317.    BOOL DoesEntityClassExist(LPSTR lpszClassName)
  1318.    {
  1319.       return idoDoesEntityClassExist(HWindow, lpszClassName);
  1320.    }
  1321.    BOOL IterateEntityClassFirst()
  1322.    {
  1323.       return idoIterateEntityClassFirst(HWindow);
  1324.    }
  1325.    BOOL IterateEntityClassNext(LPSTR lpszVal)
  1326.    {
  1327.       return idoIterateEntityClassNext(HWindow, lpszVal);
  1328.    }
  1329.  
  1330.  
  1331.    BOOL AddRelationClass(LPSTR lpszClass, LPSTR lpszBitmap, TRelation * lpCRel)
  1332.    {
  1333.       if(lpCRel)
  1334.          return idoAddRelationClass(HWindow, lpszClass, lpszBitmap, &(lpCRel->m_relation));
  1335.       else
  1336.          return idoAddRelationClass(HWindow, lpszClass, lpszBitmap, NULL);
  1337.    }
  1338.    BOOL DeleteRelationClass(LPSTR lpszClass)
  1339.    {
  1340.       return idoDeleteRelationClass(HWindow, lpszClass);
  1341.    }
  1342.    BOOL RedefineFromRelationClass(LPSTR lpszClass)
  1343.    {
  1344.       return idoRedefineFromRelationClass(HWindow, lpszClass);
  1345.    }
  1346.    BOOL GetRelationClass(LPSTR lpszClassName, LPRELATION lpRel)
  1347.    {
  1348.       return idoGetRelationClass(HWindow, lpszClassName, lpRel);
  1349.    }
  1350.    BOOL GetRelationClass(LPSTR lpszClassName, TRelation * lpRel)
  1351.    {
  1352.       return idoGetRelationClass(HWindow, lpszClassName, &(lpRel->m_relation));
  1353.    }
  1354.    TRelation * GetRelationClass(LPSTR lpszClassName)
  1355.    {
  1356.       RELATION relation;
  1357.       TRelation * lpRel = NULL;
  1358.  
  1359.       if(idoGetRelationClass(HWindow, lpszClassName, &relation))
  1360.          lpRel = new TRelation(&relation);
  1361.  
  1362.       return lpRel;
  1363.    }
  1364.    BOOL DoesRelationClassExist(LPSTR lpszClassName)
  1365.    {
  1366.       return idoDoesRelationClassExist(HWindow, lpszClassName);
  1367.    }
  1368.    BOOL IterateRelationClassFirst()
  1369.    {
  1370.       return idoIterateRelationClassFirst(HWindow);
  1371.    }
  1372.    BOOL IterateRelationClassNext(LPSTR lpszVal)
  1373.    {
  1374.       return idoIterateRelationClassNext(HWindow, lpszVal);
  1375.    }
  1376.  
  1377.  
  1378.    BOOL AddRule(LPSTR lpszE1, LPSTR lpszR, LPSTR lpszE2)
  1379.    {
  1380.       return idoAddRule(HWindow, lpszE1, lpszR, lpszE2);
  1381.    }
  1382.    BOOL DeleteRule(TIDORule * lpRule)
  1383.    {
  1384.       return idoDeleteRule(HWindow, &(lpRule->m_rule));
  1385.    }
  1386.    BOOL DoesRuleExist(LPSTR lpszE1, LPSTR lpszR, LPSTR lpszE2)
  1387.    {
  1388.       return idoDoesRuleExist(HWindow, lpszE1, lpszR, lpszE2);
  1389.    }
  1390.    BOOL IterateRuleFirst()
  1391.    {
  1392.       return idoIterateRuleFirst(HWindow);
  1393.    }
  1394.    BOOL IterateRuleNext(TIDORule * lpRule)
  1395.    {
  1396.       return idoIterateRuleNext(HWindow, &(lpRule->m_rule));
  1397.    }
  1398.    TIDORule * IterateRuleNext()
  1399.    {
  1400.       IDO_RULE rule;
  1401.       TIDORule * lpRule = NULL;
  1402.  
  1403.       if(idoIterateRuleNext(HWindow, &rule))
  1404.          lpRule = new TIDORule(&rule);
  1405.  
  1406.       return lpRule;
  1407.    }
  1408.  
  1409.  
  1410.    BOOL GetEntity(long lID, LPSTR lpszName, LPENTITY lpEnt)
  1411.    {
  1412.       return idoGetEntity(HWindow, lID, lpszName, lpEnt);
  1413.    }
  1414.    BOOL GetEntity(long lID, LPSTR lpszName, TEntity * lpEnt)
  1415.    {
  1416.       return idoGetEntity(HWindow, lID, lpszName, &(lpEnt->m_entity));
  1417.    }
  1418.    TEntity * GetEntity(long lID, LPSTR lpszName)
  1419.    {
  1420.       ENTITY entity;
  1421.       TEntity * lpEnt = NULL;
  1422.  
  1423.       if(idoGetEntity(HWindow, lID, lpszName, &entity))
  1424.          lpEnt = new TEntity(&entity);
  1425.  
  1426.       return lpEnt;
  1427.    }
  1428.  
  1429.    BOOL GetRelation(long lID, LPSTR lpszName, LPRELATION lpRel)
  1430.    {
  1431.       return idoGetRelation(HWindow, lID, lpszName, lpRel);
  1432.    }
  1433.    BOOL GetRelation(long lID, LPSTR lpszName, TRelation * lpRel)
  1434.    {
  1435.       return idoGetRelation(HWindow, lID, lpszName, &(lpRel->m_relation));
  1436.    }
  1437.    TRelation * GetRelation(long lID, LPSTR lpszName)
  1438.    {
  1439.       RELATION relation;
  1440.       TRelation * lpRel = NULL;
  1441.  
  1442.       if(idoGetRelation(HWindow, lID, lpszName, &relation))
  1443.          lpRel = new TRelation(&relation);
  1444.  
  1445.       return lpRel;
  1446.    }
  1447.  
  1448. //  DECLARE_RESPONSE_TABLE(TIDO);
  1449.  
  1450. };
  1451.  
  1452.  
  1453. //============================================================================
  1454. // TEntity Class Explicit inline functions.
  1455.  
  1456. inline BOOL TEntity::IterateRelationInNext(LPRELATION lpRel)
  1457.    {
  1458.       return idoEntityIterateRelationInNext(&m_entity, lpRel);
  1459.    }
  1460. inline BOOL TEntity::IterateRelationInNext(TRelation * lpRel)
  1461.    {
  1462.       return idoEntityIterateRelationInNext(&m_entity, &(lpRel->m_relation));
  1463.    }
  1464. inline TRelation * TEntity::IterateRelationInNext()
  1465.    {
  1466.       RELATION relation;
  1467.       TRelation * lpRel = NULL;
  1468.  
  1469.       if(idoEntityIterateRelationInNext(&m_entity, &relation))
  1470.          lpRel = new TRelation(&relation);
  1471.  
  1472.       return lpRel;
  1473.    }
  1474.  
  1475. inline BOOL TEntity::IterateRelationOutNext(LPRELATION lpRel)
  1476.    {
  1477.       return idoEntityIterateRelationOutNext(&m_entity, lpRel);
  1478.    }
  1479. inline BOOL TEntity::IterateRelationOutNext(TRelation * lpRel)
  1480.    {
  1481.       return idoEntityIterateRelationOutNext(&m_entity, &(lpRel->m_relation));
  1482.    }
  1483. inline TRelation * TEntity::IterateRelationOutNext()
  1484.    {
  1485.       RELATION relation;
  1486.       TRelation * lpRel = NULL;
  1487.  
  1488.       if(idoEntityIterateRelationOutNext(&m_entity, &relation))
  1489.          lpRel = new TRelation(&relation);
  1490.  
  1491.       return lpRel;
  1492.    }
  1493.  
  1494. inline BOOL TEntity::IterateContainedEntityNext(LPENTITY lpEnt)
  1495.    {
  1496.       return idoEntityIterateContainedEntityNext(&m_entity, lpEnt);
  1497.    }
  1498. inline BOOL TEntity::IterateContainedEntityNext(TEntity * lpEnt)
  1499.    {
  1500.       return idoEntityIterateContainedEntityNext(&m_entity, &(lpEnt->m_entity));
  1501.    }
  1502. inline TEntity * TEntity::IterateContainedEntityNext()
  1503.    {
  1504.       ENTITY entity;
  1505.       TEntity * lpEnt = NULL;
  1506.  
  1507.       if(idoEntityIterateContainedEntityNext(&m_entity, &entity))
  1508.          lpEnt = new TEntity(&entity);
  1509.  
  1510.       return lpEnt;
  1511.    }
  1512.  
  1513.  
  1514. //============================================================================
  1515. // TRelation Class Explicit inline functions.
  1516.  
  1517. inline BOOL TRelation::SourceEntity(LPENTITY lpEnt)
  1518.    {
  1519.       return idoRelationSourceEntity(&m_relation, lpEnt);
  1520.    }
  1521. inline BOOL TRelation::SourceEntity(TEntity * lpEnt)
  1522.    {
  1523.       return idoRelationSourceEntity(&m_relation, &(lpEnt->m_entity));
  1524.    }
  1525. inline TEntity * TRelation::SourceEntity()
  1526.    {
  1527.       ENTITY entity;
  1528.       TEntity *lpEntity = NULL;
  1529.  
  1530.       if(idoRelationSourceEntity(&m_relation, &entity))
  1531.          lpEntity = new TEntity(&entity);
  1532.  
  1533.       return lpEntity;
  1534.    }
  1535.  
  1536. inline BOOL TRelation::DestinationEntity(LPENTITY lpEnt)
  1537.    {
  1538.       return idoRelationDestinationEntity(&m_relation, lpEnt);
  1539.    }
  1540. inline BOOL TRelation::DestinationEntity(TEntity * lpEnt)
  1541.    {
  1542.       return idoRelationDestinationEntity(&m_relation, &(lpEnt->m_entity));
  1543.    }
  1544. inline TEntity * TRelation::DestinationEntity()
  1545.    {
  1546.       ENTITY entity;
  1547.       TEntity *lpEntity = NULL;
  1548.  
  1549.       if(idoRelationDestinationEntity(&m_relation, &entity))
  1550.          lpEntity = new TEntity(&entity);
  1551.  
  1552.       return lpEntity;
  1553.    }
  1554.  
  1555. #endif   // ifndef __IDOOWL_H__
  1556.  
  1557.