Main Lemma Repository
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

Grid.h 2.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. /* This file is part of Lemma, a geophysical modelling and inversion API */
  2. /* This Source Code Form is subject to the terms of the Mozilla Public
  3. * License, v. 2.0. If a copy of the MPL was not distributed with this
  4. * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  5. /**
  6. @file
  7. @author Trevor Irons
  8. @date 10/25/2009
  9. @version $Id: grid.h 193 2014-11-10 23:51:41Z tirons $
  10. **/
  11. #ifndef __GRID_H
  12. #define __GRID_H
  13. #include "LemmaObject.h"
  14. namespace Lemma {
  15. // ===============================================================================
  16. // Class: Grid
  17. /// \brief Abstract base class for grids.
  18. /// \details Grids define values in space, they may either be an integral part
  19. /// of models, or simply the output of a forward modelling procedure.
  20. // ===============================================================================
  21. class Grid : public LemmaObject {
  22. friend std::ostream &operator<<(std::ostream &stream,
  23. const Grid &ob);
  24. public:
  25. // ==================== LIFECYCLE ===================================
  26. // ==================== OPERATORS ===================================
  27. // ==================== OPERATIONS ===================================
  28. // ==================== ACCESS ===================================
  29. // ==================== INQUIRY ===================================
  30. /** Returns the name of the underlying class, similiar to Python's type */
  31. virtual inline std::string GetName() const {
  32. return this->CName;
  33. }
  34. protected:
  35. // ==================== LIFECYCLE ===================================
  36. /// Default protected constructor.
  37. Grid ( );
  38. /// Default protected constructor.
  39. ~Grid ();
  40. // ==================== DATA MEMBERS ===================================
  41. private:
  42. /** ASCII string representation of the class name */
  43. static constexpr auto CName = "Grid";
  44. }; // ----- end of class Grid -----
  45. } // namespace Lemma
  46. #endif // __GRID_H