Xyce  6.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Xyce::Device::Device Class Referenceabstract

The Device class is an interface for device implementations. More...

#include <N_DEV_Device.h>

Inheritance diagram for Xyce::Device::Device:

Public Member Functions

 Device ()
 
virtual ~Device ()
 
virtual bool isLinearDevice () const =0
 Returns true if the device is linear. More...
 
virtual bool isPDEDevice () const =0
 Returns true is the device is a PDE device. More...
 
virtual const std::string & getName () const =0
 Returns the name given to the device. More...
 
virtual const std::string & getDefaultModelName () const =0
 Returns the name of the default model that would to used for this device. More...
 
virtual DeviceModelfindModel (const ModelName &model_name)=0
 Returns the device entity with the specified name. More...
 
virtual const DeviceModelfindModel (const ModelName &model_name) const =0
 Returns the device entity with the specified name. More...
 
virtual DeviceEntityfindInstance (const InstanceName &instance_name)=0
 Returns the device entity with the specified name. More...
 
virtual const DeviceEntityfindInstance (const InstanceName &instance_name) const =0
 Returns the device entity with the specified name. More...
 
virtual DeviceModeladdModel (const ModelBlock &model_block, const FactoryBlock &factory_block)=0
 Creates a device model and adds it to the device's list of models. More...
 
virtual DeviceInstanceaddInstance (const InstanceBlock &instance_block, const FactoryBlock &factory_block)=0
 Creates a device instance and adds to the device model's instance list. More...
 
virtual bool updateSources ()
 Updates the devices source information. More...
 
virtual bool updateState (double *solVec, double *staVec, double *stoVec)
 Updates the devices state information. More...
 
virtual bool updateSecondaryState (double *staDerivVec, double *stoVec)
 Updates the devices secondary state information. More...
 
virtual bool loadDAEVectors (double *solVec, double *fVec, double *qVec, double *bVec, double *storeLeadF, double *storeLeadQ)
 Populates the device's ExternData object with these pointers. More...
 
virtual bool loadDAEMatrices (N_LAS_Matrix &dFdx, N_LAS_Matrix &dQdx)
 Populates the device's Jacobian object with these pointers. More...
 
virtual void forEachModel (DeviceModelOp &op) const =0
 Executes op on each DeviceModel pointer of the device. More...
 
virtual void forEachInstance (DeviceInstanceOp &op) const =0
 Executes op on each DeviceInstance pointer of the device. More...
 

Private Member Functions

 Device (const Device &)
 No copying. More...
 
Deviceoperator= (const Device &)
 No assignment. More...
 

Detailed Description

The Device class is an interface for device implementations.

In general, DeviceMaster is the only class that actually inherits from Device. Most devices either use the DeviceMaster class, but some derive from DeviceMaster in what is known as a Master class.

The interfaces are unfortunately used for but derived implementation as well as usage. This should be changed at some point, but this is the currently basic design of most interface classes.

Author
Eric Keiter, SNL, Parallel Computational Sciences
Date
3/16/00

Definition at line 102 of file N_DEV_Device.h.

Constructor & Destructor Documentation

Xyce::Device::Device::Device ( )
inline

Definition at line 105 of file N_DEV_Device.h.

virtual Xyce::Device::Device::~Device ( )
inlinevirtual

Definition at line 108 of file N_DEV_Device.h.

Xyce::Device::Device::Device ( const Device )
private

No copying.

Member Function Documentation

virtual DeviceInstance* Xyce::Device::Device::addInstance ( const InstanceBlock instance_block,
const FactoryBlock factory_block 
)
pure virtual

Creates a device instance and adds to the device model's instance list.

Parameters
instance_blockconst reference to the model block describing the instance to create
factory_blockconst reference to the factory data needed to create the instance
Returns
pointer to the newly creates device instance

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual DeviceModel* Xyce::Device::Device::addModel ( const ModelBlock model_block,
const FactoryBlock factory_block 
)
pure virtual

Creates a device model and adds it to the device's list of models.

Parameters
model_blockconst reference to the model block describing the model to create
factory_blockconst reference to the factory data needed to create the model
Returns
pointer to the newly created device model

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual DeviceEntity* Xyce::Device::Device::findInstance ( const InstanceName instance_name)
pure virtual

Returns the device entity with the specified name.

Parameters
instance_nameconst reference to the name of the entity
Returns
pointer to the device entity

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual const DeviceEntity* Xyce::Device::Device::findInstance ( const InstanceName instance_name) const
pure virtual

Returns the device entity with the specified name.

Parameters
instance_nameconst reference name of the entity
Returns
const pointer to the device entity

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual DeviceModel* Xyce::Device::Device::findModel ( const ModelName model_name)
pure virtual

Returns the device entity with the specified name.

Parameters
model_nameconst reference to the name of the entity
Returns
pointer to the device entity

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual const DeviceModel* Xyce::Device::Device::findModel ( const ModelName model_name) const
pure virtual

Returns the device entity with the specified name.

Parameters
model_nameconst reference name of the entity
Returns
const pointer to the device entity

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual void Xyce::Device::Device::forEachInstance ( DeviceInstanceOp op) const
pure virtual

Executes op on each DeviceInstance pointer of the device.

To use this function, create a class which derives from DeviceInstanceOp. Then implement the operator()(DeviceInstance *). Sample classes are defined in N_DEV_Algorithm.C.

Parameters
opreference to operator functor

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual void Xyce::Device::Device::forEachModel ( DeviceModelOp op) const
pure virtual

Executes op on each DeviceModel pointer of the device.

To use this function, create a class which derives from DeviceModelOp. Then implement the operator()(DeviceModel/// ). Sample classes are defined in N_DEV_Algorithm.C.

Parameters
opreference to operator functor

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual const std::string& Xyce::Device::Device::getDefaultModelName ( ) const
pure virtual

Returns the name of the default model that would to used for this device.

Returns
const reference to the name of the default model

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual const std::string& Xyce::Device::Device::getName ( ) const
pure virtual

Returns the name given to the device.

Returns
const reference to the device name.

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual bool Xyce::Device::Device::isLinearDevice ( ) const
pure virtual

Returns true if the device is linear.

Returns
true if the device is linear.

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual bool Xyce::Device::Device::isPDEDevice ( ) const
pure virtual

Returns true is the device is a PDE device.

Returns
true is the device is a PDE device.

Implemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

virtual bool Xyce::Device::Device::loadDAEVectors ( double *  solVec,
double *  fVec,
double *  qVec,
double *  bVec,
double *  storeLeadF,
double *  storeLeadQ 
)
inlinevirtual

Populates the device's ExternData object with these pointers.

THIS FUNCTION MUST BE CALLED PRIOR TO CALLING loadDAEMatrices.

Parameters
solVecpointer to the analysis solution vector for this device
fVecpointer to the analysis f vector for this device
qVecpointer to the analysis q vector for this device
storeLeadFpointer to the analysis lead store f vector for this device
storeLeadQpoitner to the analysis load store q vector for this device
Returns
true if the update was successful

Reimplemented in Xyce::Device::MOSFET_B3SOI::Master, Xyce::Device::MOSFET_B4::Master, Xyce::Device::MOSFET_B3::Master, Xyce::Device::VDMOS::Master, Xyce::Device::MOSFET1::Master, Xyce::Device::BJT::Master, Xyce::Device::MOSFET2::Master, Xyce::Device::MOSFET3::Master, Xyce::Device::MOSFET6::Master, Xyce::Device::Diode::Master, Xyce::Device::LTRA::Master, Xyce::Device::JFET::Master, Xyce::Device::MESFET::Master, Xyce::Device::Resistor::Master, Xyce::Device::Capacitor::Master, Xyce::Device::MutIndNonLin::Master, Xyce::Device::MutIndLin::Master, Xyce::Device::Vsrc::Master, Xyce::Device::DeviceMaster< T >, Xyce::Device::DeviceMaster< Traits >, Xyce::Device::Inductor::Master, Xyce::Device::Resistor3::Master, Xyce::Device::Bsrc::Master, Xyce::Device::SW::Master, Xyce::Device::ThermalResistor::Master, Xyce::Device::Synapse4::Master, Xyce::Device::ROM::Master, Xyce::Device::ISRC::Master, Xyce::Device::DAC::Master, Xyce::Device::ADC::Master, Xyce::Device::Vcvs::Master, and Xyce::Device::VCCS::Master.

Definition at line 361 of file N_DEV_Device.h.

Device& Xyce::Device::Device::operator= ( const Device )
private

No assignment.

virtual bool Xyce::Device::Device::updateSecondaryState ( double *  staDerivVec,
double *  stoVec 
)
inlinevirtual

Updates the devices secondary state information.

This function is called by the analysis subsystem when it is time to update the device secondary state information.

Returns
true if the update was successful

Reimplemented in Xyce::Device::VDMOS::Master, Xyce::Device::BJT::Master, Xyce::Device::LTRA::Master, Xyce::Device::MutIndNonLin::Master, Xyce::Device::DeviceMaster< T >, Xyce::Device::DeviceMaster< Traits >, Xyce::Device::Inductor::Master, Xyce::Device::Bsrc::Master, Xyce::Device::SW::Master, Xyce::Device::Synapse4::Master, Xyce::Device::DAC::Master, Xyce::Device::Synapse::Master, Xyce::Device::Synapse2::Master, and Xyce::Device::ADC::Master.

Definition at line 335 of file N_DEV_Device.h.

virtual bool Xyce::Device::Device::updateSources ( )
inlinevirtual

Updates the devices source information.

This function is called by the analysis subsystem when it is time to update the device source information.

Returns
true if the update was successful

Reimplemented in Xyce::Device::DeviceMaster< T >, and Xyce::Device::DeviceMaster< Traits >.

Definition at line 295 of file N_DEV_Device.h.


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