Counter Strike : Global Offensive Source Code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

42 lines
1.3 KiB

  1. //====== Copyright � 1996-2004, Valve Corporation, All rights reserved. =======
  2. //
  3. // The abstract base operator class - all actions within the scenegraph happen via operators
  4. //
  5. //=============================================================================
  6. #ifndef DMEOPERATOR_H
  7. #define DMEOPERATOR_H
  8. #ifdef _WIN32
  9. #pragma once
  10. #endif
  11. #include "datamodel/dmelement.h"
  12. #include "datamodel/dmattributevar.h"
  13. #include "tier1/utlvector.h"
  14. //-----------------------------------------------------------------------------
  15. // A class representing an generic operator
  16. //-----------------------------------------------------------------------------
  17. class CDmeOperator : public IDmeOperator, public CDmElement
  18. {
  19. DEFINE_ELEMENT( CDmeOperator, CDmElement );
  20. public:
  21. virtual bool IsDirty(); // ie needs to operate
  22. virtual void Operate() {}
  23. virtual const char* GetOperatorName() const { return m_Name.Get(); }
  24. virtual void GetInputAttributes ( CUtlVector< CDmAttribute * > &attrs ) {}
  25. virtual void GetOutputAttributes( CUtlVector< CDmAttribute * > &attrs ) {}
  26. virtual void GatherInputOperators( CUtlVector< CDmeOperator * > &operators );
  27. virtual void SetSortKey( int key );
  28. virtual int GetSortKey() const;
  29. int m_nSortKey;
  30. };
  31. void GatherOperatorsForElement( CDmElement *pElement, CUtlVector< CDmeOperator * > &operators );
  32. #endif // DMEOPERATOR_H