cmFunctionBlocker.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. /*=========================================================================
  2. Program: Insight Segmentation & Registration Toolkit
  3. Module: $RCSfile$
  4. Language: C++
  5. Date: $Date$
  6. Version: $Revision$
  7. Copyright (c) 2000 National Library of Medicine
  8. All rights reserved.
  9. See COPYRIGHT.txt for copyright details.
  10. =========================================================================*/
  11. #ifndef cmFunctionBlocker_h
  12. #define cmFunctionBlocker_h
  13. #include "cmStandardIncludes.h"
  14. class cmMakefile;
  15. /** \class cmFunctionBlocker
  16. * \brief A class that defines an interface for blocking cmake functions
  17. *
  18. * This is the superclass for any classes that need to block a cmake function
  19. */
  20. class cmFunctionBlocker
  21. {
  22. public:
  23. /**
  24. * should a function be blocked
  25. */
  26. virtual bool IsFunctionBlocked(const char *name, const std::vector<std::string> &args,
  27. const cmMakefile &mf) const = 0;
  28. /**
  29. * should this function blocker be removed, useful when one function adds a blocker
  30. * and another must remove it
  31. */
  32. virtual bool ShouldRemove(const char *name, const std::vector<std::string> &args,
  33. const cmMakefile &mf) const {return false;}
  34. };
  35. #endif