www.mooseframework.org
NeighborCoupleableMooseVariableDependencyIntermediateInterface.h
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 #ifndef NEIGHBORCOUPLEABLEMOOSEVARIABLEDEPENDENCYINTERMEDIATEINTERFACE_H
16 #define NEIGHBORCOUPLEABLEMOOSEVARIABLEDEPENDENCYINTERMEDIATEINTERFACE_H
17 
18 #include "NeighborCoupleable.h"
19 #include "ScalarCoupleable.h"
22 
28  : public NeighborCoupleable,
29  public ScalarCoupleable,
32 {
33 public:
35  bool nodal,
36  bool neighbor_nodal)
37  : NeighborCoupleable(moose_object, nodal, neighbor_nodal),
38  ScalarCoupleable(moose_object),
39  NeighborMooseVariableInterface(moose_object, nodal)
40  {
41  const std::vector<MooseVariable *> & coupled_vars = getCoupledMooseVars();
42  for (unsigned int i = 0; i < coupled_vars.size(); i++)
43  addMooseVariableDependency(coupled_vars[i]);
44 
46  }
47 };
48 
49 #endif // NEIGHBORCOUPLEABLEMOOSEVARIABLEDEPENDENCYINTERMEDIATEINTERFACE_H
Intermediate base class that ties together all the interfaces for getting MooseVariables with the Moo...
const std::vector< MooseVariable * > & getCoupledMooseVars() const
Get the list of coupled variables.
Definition: Coupleable.h:63
void addMooseVariableDependency(MooseVariable *var)
Call this function to add the passed in MooseVariable as a variable that this object depends on...
Enhances MooseVariableInterface interface provide values from neighbor elements.
MooseVariable * mooseVariable()
Get the variable that this object is using.
Every object that can be built by the factory should be derived from this class.
Definition: MooseObject.h:36
NeighborCoupleableMooseVariableDependencyIntermediateInterface(const MooseObject *moose_object, bool nodal, bool neighbor_nodal)
Interface for objects that needs scalar coupling capabilities.
Enhances Coupleable interface to also couple the values from neighbor elements.