Xyce
6.1
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
N_DEV_Op.C
Go to the documentation of this file.
1
//-----------------------------------------------------------------------------
2
// Copyright Notice
3
//
4
// Copyright 2002 Sandia Corporation. Under the terms
5
// of Contract DE-AC04-94AL85000 with Sandia Corporation, the U.S.
6
// Government retains certain rights in this software.
7
//
8
// Xyce(TM) Parallel Electrical Simulator
9
// Copyright (C) 2002-2014 Sandia Corporation
10
//
11
// This program is free software: you can redistribute it and/or modify
12
// it under the terms of the GNU General Public License as published by
13
// the Free Software Foundation, either version 3 of the License, or
14
// (at your option) any later version.
15
//
16
// This program is distributed in the hope that it will be useful,
17
// but WITHOUT ANY WARRANTY; without even the implied warranty of
18
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19
// GNU General Public License for more details.
20
//
21
// You should have received a copy of the GNU General Public License
22
// along with this program. If not, see <http://www.gnu.org/licenses/>.
23
//-----------------------------------------------------------------------------
24
25
//-----------------------------------------------------------------------------
26
// Filename : $RCSfile: N_DEV_Op.C,v $
27
//
28
// Purpose : Provide tools for accessing output data in parallel or
29
// serial
30
//
31
// Special Notes :
32
//
33
// Creator : David Baur
34
//
35
// Creation Date : 11/15/2013
36
//
37
// Revision Information:
38
// ---------------------
39
//
40
// Revision Number: $Revision: 1.2 $
41
//
42
// Revision Date : $Date: 2014/08/08 20:02:38 $
43
//
44
// Current Owner : $Author: dgbaur $
45
//-----------------------------------------------------------------------------
46
47
#include <Xyce_config.h>
48
49
#include <
N_DEV_Op.h
>
50
#include <
N_DEV_DeviceEntity.h
>
51
#include <
N_DEV_DeviceMgr.h
>
52
53
namespace
Xyce {
54
namespace
Device {
55
56
//-----------------------------------------------------------------------------
57
// Function : DeviceMgrGlobalParameterOp::get
58
// Purpose : get the current value of a global param from the device
59
// package
60
// Special Notes : It is inappropriate for the Device package to be in charge
61
// of global params, but that's where they are right now.
62
// Scope : public
63
// Creator : David Baur, Raytheon
64
// Creation Date : 11/15/2013
65
//-----------------------------------------------------------------------------
66
complex
67
DeviceMgrGlobalParameterOp::get
(
const
DeviceMgrGlobalParameterOp
&op,
const
Util::Op::OpData &op_data)
68
{
69
return
op.
deviceManager_
.
getGlobalPar
(op.
deviceParameterName_
);
70
}
71
72
//-----------------------------------------------------------------------------
73
// Function : DeviceEntityParameterOp::get
74
// Purpose : get the current value of a device parameter from a device
75
// entity
76
// Special Notes :
77
// Scope : public
78
// Creator : David Baur, Raytheon
79
// Creation Date : 11/15/2013
80
//-----------------------------------------------------------------------------
81
complex
82
DeviceEntityParameterOp::get
(
const
DeviceEntityParameterOp
&op,
const
Util::Op::OpData &op_data)
83
{
84
double
result;
85
86
const_cast<
DeviceEntity
&
>
(op.
deviceEntity_
).getParam(op.
deviceParameterName_
, result);
87
88
return
result;
89
}
90
91
//-----------------------------------------------------------------------------
92
// Function : DeviceMgrParameterOp::get
93
// Purpose : get the current value of a device parameter from the device
94
// package
95
// Special Notes :
96
// Scope : public
97
// Creator : David Baur, Raytheon
98
// Creation Date : 11/15/2013
99
//-----------------------------------------------------------------------------
100
complex
101
DeviceMgrParameterOp::get
(
const
DeviceMgrParameterOp
&op,
const
Util::Op::OpData &op_data)
102
{
103
return
op.
deviceManager_
.
getParamNoReduce
(op.
deviceParameterName_
);
104
}
105
106
}
// namespace Device
107
}
// namespace Xyce
src
DeviceModelPKG
Core
src
N_DEV_Op.C
Generated on Thu Sep 25 2014 15:20:28 for Xyce by
1.8.3.1