Files
egtbeamwall/EgtBEAMWALL.Core/Lib/MachGroupM.vb
T
2021-04-12 16:35:18 +02:00

69 lines
1.7 KiB
VB.net

Imports System.Collections.ObjectModel
Imports System.IO
Imports System.Windows
Imports EgtUILib
Imports EgtWPFLib5
Public Class MachGroupM
Protected m_Id As Integer
Public ReadOnly Property Id As Integer
Get
Return m_Id
End Get
End Property
Protected m_Name As String
Public ReadOnly Property Name As String
Get
Return m_Name
End Get
End Property
Protected m_Machine As String
Public ReadOnly Property Machine As String
Get
Return m_Machine
End Get
End Property
Protected m_IsEnabled As Boolean
Public Property IsEnabled As Boolean
Get
Return m_IsEnabled
End Get
Set(value As Boolean)
m_IsEnabled = value
End Set
End Property
#Region "CONSTRUCTORS"
Protected Sub New()
End Sub
Public Shared Function CreateNewMachGroup() As MachGroupM
Return New MachGroupM
End Function
Public Shared Function CreateMachGroup(nId As Integer, sName As String, sMachine As String) As MachGroupM
Dim NewMachGroupM As New MachGroupM
NewMachGroupM.m_Id = nId
NewMachGroupM.m_Name = sName
NewMachGroupM.m_Machine = sMachine
Return NewMachGroupM
End Function
Public Shared Function CreateMachGroup(sName As String, sMachine As String) As MachGroupM
Dim NewMachGroupM As New MachGroupM
' Creo il nuovo gruppo di lavorazione con i dati ottenuti a seconda del caso in cui mi trovo
NewMachGroupM.m_Id = EgtAddMachGroup(sName, sMachine)
If NewMachGroupM.m_Id = GDB_ID.NULL Then Return Nothing
NewMachGroupM.m_Name = sName
NewMachGroupM.m_Machine = sMachine
Return NewMachGroupM
End Function
#End Region ' CONSTRUCTORS
End Class