CpntNgsIndSrc.hpp
3.43 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
//**************************************************************************************************
// CpntNgsIndSrc.hpp *
// ------------------- *
// Description : This class represents a component definition line for an NG-Spice independent *
// voltage or current source. *
// Started : 2008-06-12 *
// Last Update : 2015-04-16 *
// Copyright : (C) 2008-2016 MSWaters *
//**************************************************************************************************
//**************************************************************************************************
// *
// This program is free software; you can redistribute it and/or modify it under the *
// terms of the GNU General Public License as published by the Free Software Foundation; *
// either version 3 of the License, or (at your option) any later version. *
// *
//**************************************************************************************************
#ifndef CPNTNGSINDSRC_HPP
#define CPNTNGSINDSRC_HPP
// Application Includes
#include "TypeDefs.hpp"
#include "netlist/Component.hpp"
#include "gnucap/commands/CmdGnuCapGEN.hpp"
class CmdGnuCapGEN;
// wxWidgets Includes
#include <wx/tokenzr.h>
// Local Constant Declarations
#define NGS_SINAMP wxT("1.0")
#define NGS_SINOFFSET wxT("0.0")
#define NGS_SINFREQ wxT("1.0K")
#define NGS_SINDELAY wxT("0.0m")
#define NGS_SINDAMP wxT("0.0")
#define NGS_PULINITIAL wxT("0.0")
#define NGS_PULMAX wxT("0.0")
#define NGS_PULDELAY wxT("0.0m")
#define NGS_PULRISE wxT("0.0m")
#define NGS_PULWIDTH wxT("0.0m")
#define NGS_PULFALL wxT("0.0m")
#define NGS_PULPERIOD wxT("0.0m")
//**************************************************************************************************
class CpntNgsIndSrc : public Component
{
private :
virtual bool bParseValue ( void );
virtual bool bFormatValue( void );
virtual bool bValidate ( void );
void ClrValues( void );
public :
// Value for a sinusoidal source
wxString m_osSinOffset;
wxString m_osSinAmp;
wxString m_osSinFreq;
wxString m_osSinDelay;
wxString m_osSinDamp;
// Value for a pulse source
wxString m_osPulInitial;
wxString m_osPulMax;
wxString m_osPulDelay;
wxString m_osPulRise;
wxString m_osPulWidth;
wxString m_osPulFall;
wxString m_osPulPeriod;
CpntNgsIndSrc( void );
virtual ~CpntNgsIndSrc( );
virtual bool bClear( void );
CpntNgsIndSrc & operator = ( const Component & roCpnt );
CpntNgsIndSrc & operator = ( const CmdGnuCapGEN & roCmdGEN );
void Print( const wxString & rosPrefix=wxT(" ") );
};
//**************************************************************************************************
#endif // CPNTNGSINDSRC_HPP