MBDyn-1.7.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups
FileDriveCaller Class Reference

#include <filedrv.h>

Inheritance diagram for FileDriveCaller:
Collaboration diagram for FileDriveCaller:

Public Member Functions

 FileDriveCaller (const DriveHandler *pDH, const FileDrive *p, integer i, const doublereal &da)
 
virtual ~FileDriveCaller (void)
 
virtual DriveCallerpCopy (void) const
 
virtual std::ostream & Restart (std::ostream &out) const
 
virtual doublereal dGet (const doublereal &dVal) const
 
- Public Member Functions inherited from DriveCaller
 DriveCaller (const DriveHandler *pDH)
 
virtual ~DriveCaller (void)
 
virtual doublereal dGet (void) const
 
virtual bool bIsDifferentiable (void) const
 
virtual doublereal dGetP (const doublereal &dVar) const
 
virtual doublereal dGetP (void) const
 
virtual void SetDrvHdl (const DriveHandler *pDH)
 
virtual const DriveHandlerpGetDrvHdl (void) const
 
virtual void Output (OutputHandler &OH) const
 
virtual void Trace (OutputHandler &OH) const
 
- Public Member Functions inherited from WithLabel
 WithLabel (unsigned int uL=0, const std::string &sN="")
 
virtual ~WithLabel (void)
 
void PutLabel (unsigned int uL)
 
void PutName (const std::string &sN)
 
unsigned int GetLabel (void) const
 
const std::string & GetName (void) const
 
- Public Member Functions inherited from ToBeOutput
 ToBeOutput (flag fOut=fDefaultOut)
 
virtual ~ToBeOutput (void)
 
virtual void OutputPrepare (OutputHandler &OH)
 
virtual void Output (OutputHandler &OH, const VectorHandler &X, const VectorHandler &XP) const
 
virtual flag fToBeOutput (void) const
 
virtual bool bToBeOutput (void) const
 
virtual void SetOutputFlag (flag f=flag(1))
 
- Public Member Functions inherited from Traceable
 Traceable (flag fTrace=0)
 
virtual ~Traceable (void)
 
virtual flag fToBeTraced (void) const
 
virtual void SetTraceFlag (flag f=TRACE)
 

Protected Attributes

const FileDrivepFileDrive
 
integer iNumDrive
 
doublereal dAmplitude
 
- Protected Attributes inherited from DriveCaller
DriveHandlerpDrvHdl
 
- Protected Attributes inherited from WithLabel
unsigned int uLabel
 
std::string sName
 
- Protected Attributes inherited from ToBeOutput
flag fOutput
 

Additional Inherited Members

- Public Types inherited from DriveCaller
enum  OutputFlags { OUTPUT_VALUE = OUTPUT_PRIVATE << 0, OUTPUT_DERIVATIVE = OUTPUT_PRIVATE << 1 }
 
enum  TraceFlags { TRACE_VALUE = TRACE_PRIVATE << 0, TRACE_DERIVATIVE = TRACE_PRIVATE << 1 }
 
- Public Types inherited from ToBeOutput
enum  { OUTPUT = 0x1U, OUTPUT_MASK = 0xFU, OUTPUT_PRIVATE = 0x10U, OUTPUT_PRIVATE_MASK = ~OUTPUT_MASK }
 
- Public Types inherited from Traceable
enum  { TRACE = 0x01U, TRACE_PUBLIC_MASK = 0x0FU, TRACE_PRIVATE = 0x10U, TRACE_PRIVATE_MASK = ~TRACE_PUBLIC_MASK }
 

Detailed Description

Definition at line 82 of file filedrv.h.

Constructor & Destructor Documentation

FileDriveCaller::FileDriveCaller ( const DriveHandler pDH,
const FileDrive p,
integer  i,
const doublereal da 
)

Definition at line 99 of file filedrv.cc.

References ASSERT, iNumDrive, and pFileDrive.

Referenced by pCopy().

102 : DriveCaller(pDH), pFileDrive(p), iNumDrive(i), dAmplitude(da)
103 {
104  ASSERT(pFileDrive != NULL);
105  ASSERT(iNumDrive > 0 && iNumDrive <= pFileDrive->iGetNumDrives());
106 }
doublereal dAmplitude
Definition: filedrv.h:86
DriveCaller(const DriveHandler *pDH)
Definition: drive.cc:475
#define ASSERT(expression)
Definition: colamd.c:977
const FileDrive * pFileDrive
Definition: filedrv.h:84
integer iNumDrive
Definition: filedrv.h:85
FileDriveCaller::~FileDriveCaller ( void  )
virtual

Definition at line 109 of file filedrv.cc.

References NO_OP.

110 {
111  NO_OP;
112 }
#define NO_OP
Definition: myassert.h:74

Member Function Documentation

doublereal FileDriveCaller::dGet ( const doublereal dVal) const
inlinevirtual

Implements DriveCaller.

Definition at line 106 of file filedrv.h.

References dAmplitude, FileDrive::dGet(), iNumDrive, and pFileDrive.

107 {
108  return dAmplitude*pFileDrive->dGet(dVal, iNumDrive);
109 }
doublereal dAmplitude
Definition: filedrv.h:86
virtual doublereal dGet(const doublereal &t, int i=1) const
Definition: filedrv.cc:88
const FileDrive * pFileDrive
Definition: filedrv.h:84
integer iNumDrive
Definition: filedrv.h:85

Here is the call graph for this function:

DriveCaller * FileDriveCaller::pCopy ( void  ) const
virtual

Implements DriveCaller.

Definition at line 115 of file filedrv.cc.

References dAmplitude, FileDriveCaller(), iNumDrive, DriveCaller::pDrvHdl, pFileDrive, and SAFENEWWITHCONSTRUCTOR.

116 {
117  DriveCaller* pDC = NULL;
122 
123  return pDC;
124 }
doublereal dAmplitude
Definition: filedrv.h:86
FileDriveCaller(const DriveHandler *pDH, const FileDrive *p, integer i, const doublereal &da)
Definition: filedrv.cc:99
DriveHandler * pDrvHdl
Definition: drive.h:444
#define SAFENEWWITHCONSTRUCTOR(pnt, item, constructor)
Definition: mynewmem.h:698
const FileDrive * pFileDrive
Definition: filedrv.h:84
integer iNumDrive
Definition: filedrv.h:85

Here is the call graph for this function:

std::ostream & FileDriveCaller::Restart ( std::ostream &  out) const
virtual

Implements DriveCaller.

Definition at line 129 of file filedrv.cc.

References dAmplitude, WithLabel::GetLabel(), iNumDrive, and pFileDrive.

130 {
131  out << " file, " << pFileDrive->GetLabel()
132  << ", " << iNumDrive;
133  if (dAmplitude != 1.) {
134  out << ", amplitude, " << dAmplitude;
135  }
136  return out;
137 }
doublereal dAmplitude
Definition: filedrv.h:86
const FileDrive * pFileDrive
Definition: filedrv.h:84
integer iNumDrive
Definition: filedrv.h:85
unsigned int GetLabel(void) const
Definition: withlab.cc:62

Here is the call graph for this function:

Member Data Documentation

doublereal FileDriveCaller::dAmplitude
protected

Definition at line 86 of file filedrv.h.

Referenced by dGet(), pCopy(), and Restart().

integer FileDriveCaller::iNumDrive
protected

Definition at line 85 of file filedrv.h.

Referenced by dGet(), FileDriveCaller(), pCopy(), and Restart().

const FileDrive* FileDriveCaller::pFileDrive
protected

Definition at line 84 of file filedrv.h.

Referenced by dGet(), FileDriveCaller(), pCopy(), and Restart().


The documentation for this class was generated from the following files: