www.mooseframework.org
PointValueSampler.C
Go to the documentation of this file.
1 /****************************************************************/
2 /* DO NOT MODIFY THIS HEADER */
3 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
4 /* */
5 /* (c) 2010 Battelle Energy Alliance, LLC */
6 /* ALL RIGHTS RESERVED */
7 /* */
8 /* Prepared by Battelle Energy Alliance, LLC */
9 /* Under Contract No. DE-AC07-05ID14517 */
10 /* With the U. S. Department of Energy */
11 /* */
12 /* See COPYRIGHT for full restrictions */
13 /****************************************************************/
14 
15 #include "PointValueSampler.h"
16 
17 template <>
20 {
22 
23  params.addRequiredParam<std::vector<Point>>(
24  "points", "The points where you want to evaluate the variables");
25 
26  return params;
27 }
28 
30  : PointSamplerBase(parameters)
31 {
32  _points = getParam<std::vector<Point>>("points");
33 
34  _ids.resize(_points.size());
35 
36  for (unsigned int i = 0; i < _points.size(); i++)
37  _ids[i] = i;
38 }
PointValueSampler(const InputParameters &parameters)
std::vector< Real > _ids
The ID to use for each point (yes, this is Real on purpose)
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
std::vector< Point > _points
The points to evaluate at.
InputParameters validParams< PointValueSampler >()
void addRequiredParam(const std::string &name, const std::string &doc_string)
This method adds a parameter and documentation string to the InputParameters object that will be extr...
InputParameters validParams< PointSamplerBase >()