Discrete Element Methods (Alpha)
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.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. /* This file is part of Lemma, a geophysical modelling and inversion API.
  2. * More information is available at http://lemmasoftware.org
  3. */
  4. /* This Source Code Form is subject to the terms of the Mozilla Public
  5. * License, v. 2.0. If a copy of the MPL was not distributed with this
  6. * file, You can obtain one at http://mozilla.org/MPL/2.0/.
  7. */
  8. /**
  9. * @file
  10. * @date 06/16/2016 02:10:28 PM
  11. * @version $Id$
  12. * @author Trevor Irons (ti)
  13. * @email tirons@egi.utah.edu
  14. * @copyright Copyright (c) 2016, University of Utah
  15. * @copyright Copyright (c) 2016, Trevor Irons & Lemma Software, LLC
  16. */
  17. #ifndef DEMGRAIN_INC
  18. #define DEMGRAIN_INC
  19. #pragma once
  20. #include "DEMParticle.h"
  21. namespace Lemma {
  22. /**
  23. \brief
  24. \details
  25. */
  26. class DEMGrain : public DEMParticle {
  27. friend std::ostream &operator<<(std::ostream &stream, const DEMGrain &ob);
  28. public:
  29. // ==================== LIFECYCLE =======================
  30. /*
  31. * Factory method for generating concrete class.
  32. * @return a std::shared_ptr of type DEMGrain
  33. */
  34. static std::shared_ptr< DEMGrain > NewSP();
  35. /**
  36. * Uses YAML to serialize this object.
  37. * @return a YAML::Node
  38. * @see DEMGrain::DeSerialize
  39. */
  40. YAML::Node Serialize() const;
  41. /**
  42. * Constructs an DEMGrain object from a YAML::Node.
  43. * @see DEMGrain::Serialize
  44. */
  45. static std::shared_ptr<DEMGrain> DeSerialize(const YAML::Node& node);
  46. // ==================== OPERATORS =======================
  47. // ==================== OPERATIONS =======================
  48. // ==================== ACCESS =======================
  49. // ==================== INQUIRY =======================
  50. virtual inline std::string GetName () const {
  51. return std::string(this->CName);
  52. }
  53. protected:
  54. // ==================== LIFECYCLE =======================
  55. /**
  56. * Default protected constructor, use NewSP methods to construct
  57. * @see DEMGrain::NewSP
  58. */
  59. DEMGrain ( );
  60. /**
  61. * Protected DeDerializing constructor, use factory DeSerialize method.
  62. * @see DEMGrain::DeSerialize
  63. */
  64. DEMGrain (const YAML::Node& node);
  65. /** Default protected destructor, use smart pointers (std::shared_ptr) */
  66. ~DEMGrain ();
  67. // ==================== DATA MEMBERS =========================
  68. private:
  69. static constexpr auto CName = "DEMGrain";
  70. }; // ----- end of class DEMGrain -----
  71. } // ----- end of namespace Lemma ----
  72. /* vim: set tabstop=4 expandtab: */
  73. /* vim: set filetype=cpp: */
  74. #endif // ----- #ifndef DEMGRAIN_INC -----