Line data Source code
1 : //* This file is part of the MOOSE framework 2 : //* https://mooseframework.inl.gov 3 : //* 4 : //* All rights reserved, see COPYRIGHT for full restrictions 5 : //* https://github.com/idaholab/moose/blob/master/COPYRIGHT 6 : //* 7 : //* Licensed under LGPL 2.1, please see LICENSE for details 8 : //* https://www.gnu.org/licenses/lgpl-2.1.html 9 : 10 : #include "MaterialProperty.h" 11 : 12 : void 13 89829 : dataStore(std::ostream & stream, PropertyValue & p, void *) 14 : { 15 89829 : p.store(stream); 16 89829 : } 17 : 18 : void 19 58764 : dataLoad(std::istream & stream, PropertyValue & p, void *) 20 : { 21 58764 : p.load(stream); 22 58764 : } 23 : 24 : void 25 6571 : dataStore(std::ostream & stream, MaterialProperties & v, void * context) 26 : { 27 6571 : std::size_t prop_size = v.size(); 28 6571 : dataStore(stream, prop_size, context); 29 : 30 13142 : for (const auto i : index_range(v)) 31 6571 : dataStore(stream, v[i], context); 32 6571 : } 33 : 34 : void 35 6571 : dataLoad(std::istream & stream, MaterialProperties & v, void * context) 36 : { 37 : std::size_t prop_size; 38 6571 : dataLoad(stream, prop_size, context); 39 : mooseAssert(prop_size == v.size(), "Loading MaterialProperties data into mis-sized target"); 40 : 41 13142 : for (const auto i : make_range(prop_size)) 42 6571 : dataLoad(stream, v[i], context); 43 6571 : }