IParticleChannelAmount.h

Go to the documentation of this file.
00001 
00008 /**********************************************************************
00009  *<
00010     CREATED BY: Oleg Bayborodin
00011 
00012     HISTORY: created 10-05-01
00013 
00014  *> Copyright (c) 2001, All Rights Reserved.
00015  **********************************************************************/
00016 
00017 #pragma once
00018 
00019 #include "..\ifnpub.h"
00020 
00021 // interface ID
00022 #define PARTICLECHANNELAMOUNTR_INTERFACE Interface_ID(0x74f93b00, 0x1eb34500)
00023 #define PARTICLECHANNELAMOUNTW_INTERFACE Interface_ID(0x74f93b00, 0x1eb34501)
00024 
00025 #define GetParticleChannelAmountRInterface(obj) ((IParticleChannelAmountR*)obj->GetInterface(PARTICLECHANNELAMOUNTR_INTERFACE))
00026 #define GetParticleChannelAmountWInterface(obj) ((IParticleChannelAmountW*)obj->GetInterface(PARTICLECHANNELAMOUNTW_INTERFACE))
00027 
00028 
00029 class IParticleChannelAmountR : public FPMixinInterface
00030 {
00031 public:
00032 
00033     // function IDs Read
00034     enum {  kCount
00035     };
00036 
00037     // Function Map for Function Publish System
00038     //***********************************
00039     #pragma warning(push)
00040     #pragma warning(disable:4100)
00041     BEGIN_FUNCTION_MAP
00042 
00043     FN_0(kCount, TYPE_INT, Count);
00044 
00045     END_FUNCTION_MAP
00046     #pragma warning(pop)
00047 
00054     virtual int     Count() const = 0; 
00055 
00059     FPInterfaceDesc* GetDesc() { return GetDescByID(PARTICLECHANNELAMOUNTR_INTERFACE); }
00060 };
00061 
00062 class IParticleChannelAmountW : public FPMixinInterface
00063 {
00064 public:
00065 
00066     // function IDs Write
00067     enum {  kZeroCount,
00068             kSetCount,
00069             kDeleteByIndex,
00070             kDeleteByArray,
00071             kSplit,
00072             kSpawn,
00073             kAppendNum,
00074             kAppend
00075     };
00076 
00077     // Function Map for Function Publish System
00078     //***********************************
00079     BEGIN_FUNCTION_MAP
00080 
00081     VFN_0(kZeroCount, ZeroCount);
00082     FN_1(kSetCount, TYPE_bool, SetCount, TYPE_INT);
00083     FN_2(kDeleteByIndex, TYPE_INT, Delete, TYPE_INT, TYPE_INT);
00084     FN_1(kDeleteByArray, TYPE_INT, Delete, TYPE_BITARRAY_BR);
00085     FN_1(kSplit, TYPE_IOBJECT, Split, TYPE_BITARRAY_BR);
00086     FN_1(kSpawn, TYPE_bool, Spawn, TYPE_INT_TAB_BR);
00087     FN_1(kAppendNum, TYPE_bool, AppendNum, TYPE_INT);
00088     FN_1(kAppend, TYPE_bool, Append, TYPE_IOBJECT);
00089 
00090     END_FUNCTION_MAP
00091 
00092 
00100     virtual void    ZeroCount() = 0;  
00101 
00105     virtual bool    SetCount(int n) = 0; 
00106 
00110     virtual int     Delete(int start,int num) = 0;
00111 
00115     virtual int     Delete(BitArray& toRemove) = 0;
00116 
00121     virtual IObject*        Split(BitArray& toSplit) = 0;
00122        
00127     virtual bool    Spawn( Tab<int>& spawnTable ) = 0; 
00128 
00132     virtual bool    AppendNum(int num) = 0; 
00133 
00138     virtual bool    Append(IObject* obj) = 0; 
00139 
00143     virtual void    ResetAddedAmount() { ; }
00144 
00148     virtual int     GetAddedAmount() { return 0; }
00149 
00153     FPInterfaceDesc* GetDesc() { return GetDescByID(PARTICLECHANNELAMOUNTW_INTERFACE); }
00154 };
00155