File size: 3,493 Bytes
b1b3bae
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
'    DWSIM Interface definitions
'    Copyright 2010-2017 Daniel Wagner O. de Medeiros
'
'    This file is part of DWSIM.
'
'    DWSIM 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.
'
'    DWSIM is distributed in the hope that it will be useful,
'    but WITHOUT ANY WARRANTY; without even the implied warranty of
'    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
'    GNU General Public License for more details.
'
'    You should have received a copy of the GNU General Public License
'    along with DWSIM.  If not, see <http://www.gnu.org/licenses/>.

''' <summary>
''' This is the interface which defines the basic properties of a Material Stream.
''' </summary>
<InterfaceType(ComInterfaceType.InterfaceIsIDispatch)>
Public Interface IMaterialStream

    Property StreamType As Enums.StreamType

    Property ForcePhase As Enums.ForcedPhase

    Property SpecType As Enums.StreamSpec

    Property DefinedFlow As Enums.FlowSpec

    Property IsElectrolyteStream As Boolean

    Property ReferenceSolvent As String

    Property InputComposition As Dictionary(Of String, Double)

    Property CompositionBasis As Enums.CompositionBasis

    ReadOnly Property Phases() As Dictionary(Of Integer, IPhase)

    ReadOnly Property PhasesArray As IPhase()

    Function GetPhase(ByVal phasename As String) As IPhase

    Property AtEquilibrium As Boolean

    Sub SetPhaseComposition(Vx As Array, phs As Integer)

    Sub SetOverallComposition(Vx As Array)

    Sub SetOverallMassComposition(Vx As Double())

    Function GetPhaseComposition(phs As Integer) As Double()

    Function GetOverallComposition() As Double()

    Function GetOverallMassComposition() As Double()

    Function Clone() As IMaterialStream

    ReadOnly Property Flowsheet As IFlowsheet

    Sub Validate()

    Sub ClearAllProps()

    Function GetPropertyPackageObject() As Object

    Function GetPropertyPackageObjectCopy() As Object

    Sub SetPropertyPackageObject(pp As Object)

    Sub SetCurrentMaterialStream(ms As Object)

    Property FloatingTableAmountBasis As Enums.CompositionBasis

    Function GetOverallHeatOfFormation() As Double

    Function GetTemperature() As Double

    Function GetPressure() As Double

    Function GetMassFlow() As Double

    Function GetMolarFlow() As Double

    Function GetVolumetricFlow() As Double

    Function GetMassEnthalpy() As Double

    Function GetEnergyFlow() As Double

    Function GetCompoundMassFlow(name As String) As Double

    Function GetCompoundMassConcentration(name As String) As Double

    Function SetTemperature(value As Double) As String

    Function SetPressure(value As Double) As String

    Function SetMassFlow(value As Double) As String

    Function SetMolarFlow(value As Double) As String

    Function SetVolumetricFlow(value As Double) As String

    Function SetMassEnthalpy(value As Double) As String

    Function GetCompoundMolarFlow(name As String) As Double

    Sub SetOverallMolarComposition(Vx() As Double)

    Property SolidParticleData As ISolidParticleData

    Property AdditionalSolidPhaseProperties As IAdditionalSolidPhaseProperties

    Sub UpdateStreamType()

End Interface