diff --git a/build/MTConnect.NET-SysML-Import/CSharp/Templates/Devices.ComponentType.scriban b/build/MTConnect.NET-SysML-Import/CSharp/Templates/Devices.ComponentType.scriban index 4a518b3e8..474b82d13 100644 --- a/build/MTConnect.NET-SysML-Import/CSharp/Templates/Devices.ComponentType.scriban +++ b/build/MTConnect.NET-SysML-Import/CSharp/Templates/Devices.ComponentType.scriban @@ -19,10 +19,9 @@ namespace MTConnect.Devices.Components {{ if (minimum_version_enum) }}public override System.Version MinimumVersion => {{minimum_version_enum}};{{ end }} - public {{name}}() - { + public {{name}}() + { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ActuatorComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ActuatorComponent.g.cs index 955e78b4e..dd9abdd2c 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ActuatorComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ActuatorComponent.g.cs @@ -22,7 +22,6 @@ public class ActuatorComponent : Component public ActuatorComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/AdapterComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/AdapterComponent.g.cs index c6454c358..4706b689c 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/AdapterComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/AdapterComponent.g.cs @@ -22,7 +22,6 @@ public class AdapterComponent : Component public AdapterComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/AdaptersComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/AdaptersComponent.g.cs index 8b350f82e..01be11a8b 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/AdaptersComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/AdaptersComponent.g.cs @@ -22,7 +22,6 @@ public class AdaptersComponent : Component, IOrganizerComponent public AdaptersComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/AirHandlerComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/AirHandlerComponent.g.cs index 7109adfb7..ecaa9b4fe 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/AirHandlerComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/AirHandlerComponent.g.cs @@ -22,7 +22,6 @@ public class AirHandlerComponent : Component public AirHandlerComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/AmplifierComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/AmplifierComponent.g.cs index 99938d8fc..4bfc5f392 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/AmplifierComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/AmplifierComponent.g.cs @@ -22,7 +22,6 @@ public class AmplifierComponent : Component public AmplifierComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/AutomaticToolChangerComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/AutomaticToolChangerComponent.g.cs index e44f2e810..e4f5fafdd 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/AutomaticToolChangerComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/AutomaticToolChangerComponent.g.cs @@ -22,7 +22,6 @@ public class AutomaticToolChangerComponent : Component public AutomaticToolChangerComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/AuxiliariesComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/AuxiliariesComponent.g.cs index 4ef2f1cb4..6afeab56a 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/AuxiliariesComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/AuxiliariesComponent.g.cs @@ -22,7 +22,6 @@ public class AuxiliariesComponent : Component, IOrganizerComponent public AuxiliariesComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/AuxiliaryComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/AuxiliaryComponent.g.cs index 20faef33e..5eeaae2e9 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/AuxiliaryComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/AuxiliaryComponent.g.cs @@ -22,7 +22,6 @@ public abstract class AuxiliaryComponent : Component public AuxiliaryComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/AxesComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/AxesComponent.g.cs index be0d73de3..f6c05725c 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/AxesComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/AxesComponent.g.cs @@ -22,7 +22,6 @@ public class AxesComponent : Component, IOrganizerComponent public AxesComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/AxisComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/AxisComponent.g.cs index 1aa87e818..4df30aa03 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/AxisComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/AxisComponent.g.cs @@ -22,7 +22,6 @@ public abstract class AxisComponent : Component public AxisComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/BallscrewComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/BallscrewComponent.g.cs index a9d021069..c0affaa18 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/BallscrewComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/BallscrewComponent.g.cs @@ -22,7 +22,6 @@ public class BallscrewComponent : Component public BallscrewComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/BarFeederComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/BarFeederComponent.g.cs index c37bdae24..acaa4c1fa 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/BarFeederComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/BarFeederComponent.g.cs @@ -22,7 +22,6 @@ public class BarFeederComponent : Component public BarFeederComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/BeltComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/BeltComponent.g.cs index bcd2803b1..8ebaaa6e6 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/BeltComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/BeltComponent.g.cs @@ -22,7 +22,6 @@ public class BeltComponent : Component public BeltComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/BrakeComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/BrakeComponent.g.cs index b52c797b1..ba12a92ad 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/BrakeComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/BrakeComponent.g.cs @@ -22,7 +22,6 @@ public class BrakeComponent : Component public BrakeComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ChainComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ChainComponent.g.cs index 0ed9b7b8e..d0767d2f0 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ChainComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ChainComponent.g.cs @@ -22,7 +22,6 @@ public class ChainComponent : Component public ChainComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ChopperComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ChopperComponent.g.cs index a877c1c8a..f2f454a8d 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ChopperComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ChopperComponent.g.cs @@ -22,7 +22,6 @@ public class ChopperComponent : Component public ChopperComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ChuckComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ChuckComponent.g.cs index 233bdf9e4..0484b5a9f 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ChuckComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ChuckComponent.g.cs @@ -22,7 +22,6 @@ public class ChuckComponent : Component public ChuckComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ChuteComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ChuteComponent.g.cs index 427be5242..bf3ae058e 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ChuteComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ChuteComponent.g.cs @@ -22,7 +22,6 @@ public class ChuteComponent : Component public ChuteComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/CircuitBreakerComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/CircuitBreakerComponent.g.cs index c59394902..eac717758 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/CircuitBreakerComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/CircuitBreakerComponent.g.cs @@ -22,7 +22,6 @@ public class CircuitBreakerComponent : Component public CircuitBreakerComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ClampComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ClampComponent.g.cs index fde93af8e..4480aeeeb 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ClampComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ClampComponent.g.cs @@ -22,7 +22,6 @@ public class ClampComponent : Component public ClampComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/CompressorComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/CompressorComponent.g.cs index 5da5587ea..8bbc91d9b 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/CompressorComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/CompressorComponent.g.cs @@ -22,7 +22,6 @@ public class CompressorComponent : Component public CompressorComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ControllerComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ControllerComponent.g.cs index fa7768874..fb8c374a2 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ControllerComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ControllerComponent.g.cs @@ -22,7 +22,6 @@ public class ControllerComponent : Component public ControllerComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ControllersComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ControllersComponent.g.cs index c0607d3c1..0753d8a51 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ControllersComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ControllersComponent.g.cs @@ -22,7 +22,6 @@ public class ControllersComponent : Component, IOrganizerComponent public ControllersComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/CoolantComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/CoolantComponent.g.cs index c439c3f2e..64f5f805e 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/CoolantComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/CoolantComponent.g.cs @@ -22,7 +22,6 @@ public class CoolantComponent : Component public CoolantComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/CoolingComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/CoolingComponent.g.cs index f9e882ac8..462476418 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/CoolingComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/CoolingComponent.g.cs @@ -22,7 +22,6 @@ public class CoolingComponent : Component public CoolingComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/CoolingTowerComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/CoolingTowerComponent.g.cs index ab337ea70..657ef6e1b 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/CoolingTowerComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/CoolingTowerComponent.g.cs @@ -22,7 +22,6 @@ public class CoolingTowerComponent : Component public CoolingTowerComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/DepositionComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/DepositionComponent.g.cs index 23cba40e5..3872a1569 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/DepositionComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/DepositionComponent.g.cs @@ -22,7 +22,6 @@ public class DepositionComponent : Component public DepositionComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/DielectricComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/DielectricComponent.g.cs index 9994ef5ae..24d7963dc 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/DielectricComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/DielectricComponent.g.cs @@ -22,7 +22,6 @@ public class DielectricComponent : Component public DielectricComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/DoorComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/DoorComponent.g.cs index 6d5c08331..ef409c228 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/DoorComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/DoorComponent.g.cs @@ -22,7 +22,6 @@ public class DoorComponent : Component public DoorComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/DrainComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/DrainComponent.g.cs index 822f42c9a..2ae6b12db 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/DrainComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/DrainComponent.g.cs @@ -22,7 +22,6 @@ public class DrainComponent : Component public DrainComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ElectricComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ElectricComponent.g.cs index 0e3b80ba8..a0b8f3210 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ElectricComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ElectricComponent.g.cs @@ -22,7 +22,6 @@ public class ElectricComponent : Component public ElectricComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/EnclosureComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/EnclosureComponent.g.cs index 9da9ad5f3..891ac02ae 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/EnclosureComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/EnclosureComponent.g.cs @@ -22,7 +22,6 @@ public class EnclosureComponent : Component public EnclosureComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/EncoderComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/EncoderComponent.g.cs index 52cb49cfb..853859aa3 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/EncoderComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/EncoderComponent.g.cs @@ -22,7 +22,6 @@ public class EncoderComponent : Component public EncoderComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/EndEffectorComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/EndEffectorComponent.g.cs index 3738296fd..27dcb468b 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/EndEffectorComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/EndEffectorComponent.g.cs @@ -22,7 +22,6 @@ public class EndEffectorComponent : Component public EndEffectorComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/EnvironmentalComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/EnvironmentalComponent.g.cs index a4fca7049..0a38bba32 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/EnvironmentalComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/EnvironmentalComponent.g.cs @@ -22,7 +22,6 @@ public class EnvironmentalComponent : Component public EnvironmentalComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ExpiredPotComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ExpiredPotComponent.g.cs index bac87c34a..c0f5e3ce0 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ExpiredPotComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ExpiredPotComponent.g.cs @@ -22,7 +22,6 @@ public class ExpiredPotComponent : Component public ExpiredPotComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ExposureUnitComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ExposureUnitComponent.g.cs index 108e77fbc..2811e3baa 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ExposureUnitComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ExposureUnitComponent.g.cs @@ -22,7 +22,6 @@ public class ExposureUnitComponent : Component public ExposureUnitComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ExtrusionUnitComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ExtrusionUnitComponent.g.cs index 43b4e76ea..b914f5c08 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ExtrusionUnitComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ExtrusionUnitComponent.g.cs @@ -22,7 +22,6 @@ public class ExtrusionUnitComponent : Component public ExtrusionUnitComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/FanComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/FanComponent.g.cs index 2b87488f8..7f8e55e53 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/FanComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/FanComponent.g.cs @@ -22,7 +22,6 @@ public class FanComponent : Component public FanComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/FeatureOccurrenceComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/FeatureOccurrenceComponent.g.cs index 9fa56c03a..c863dfbb1 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/FeatureOccurrenceComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/FeatureOccurrenceComponent.g.cs @@ -22,7 +22,6 @@ public class FeatureOccurrenceComponent : Component public FeatureOccurrenceComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/FeederComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/FeederComponent.g.cs index d9604ae75..e1e29f8e5 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/FeederComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/FeederComponent.g.cs @@ -22,7 +22,6 @@ public class FeederComponent : Component public FeederComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/FilterComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/FilterComponent.g.cs index cba952fc1..d7ca4435c 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/FilterComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/FilterComponent.g.cs @@ -22,7 +22,6 @@ public class FilterComponent : Component public FilterComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/GalvanomotorComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/GalvanomotorComponent.g.cs index d75525a43..e264a650f 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/GalvanomotorComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/GalvanomotorComponent.g.cs @@ -22,7 +22,6 @@ public class GalvanomotorComponent : Component public GalvanomotorComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/GangToolBarComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/GangToolBarComponent.g.cs index dc2f134d9..0788417be 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/GangToolBarComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/GangToolBarComponent.g.cs @@ -22,7 +22,6 @@ public class GangToolBarComponent : Component public GangToolBarComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/GripperComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/GripperComponent.g.cs index 3e30fd263..a0083ead7 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/GripperComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/GripperComponent.g.cs @@ -22,7 +22,6 @@ public class GripperComponent : Component public GripperComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/HeatingComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/HeatingComponent.g.cs index ad84529ec..1fe7d238f 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/HeatingComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/HeatingComponent.g.cs @@ -22,7 +22,6 @@ public class HeatingComponent : Component public HeatingComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/HopperComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/HopperComponent.g.cs index d0071237d..25cafcac3 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/HopperComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/HopperComponent.g.cs @@ -22,7 +22,6 @@ public class HopperComponent : Component public HopperComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/HydraulicComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/HydraulicComponent.g.cs index bfc1e5ac6..c719ed3c7 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/HydraulicComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/HydraulicComponent.g.cs @@ -22,7 +22,6 @@ public class HydraulicComponent : Component public HydraulicComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/InterfacesComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/InterfacesComponent.g.cs index 621445e7c..e94bb7ba0 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/InterfacesComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/InterfacesComponent.g.cs @@ -22,7 +22,6 @@ public class InterfacesComponent : Component, IOrganizerComponent public InterfacesComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/LinearComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/LinearComponent.g.cs index 30e86e98a..57bc027dd 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/LinearComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/LinearComponent.g.cs @@ -22,7 +22,6 @@ public class LinearComponent : Component public LinearComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/LinearPositionFeedbackComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/LinearPositionFeedbackComponent.g.cs index 7a13c087b..952db56bd 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/LinearPositionFeedbackComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/LinearPositionFeedbackComponent.g.cs @@ -22,7 +22,6 @@ public class LinearPositionFeedbackComponent : Component public LinearPositionFeedbackComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/LinkComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/LinkComponent.g.cs index a9ba4b078..6da56f928 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/LinkComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/LinkComponent.g.cs @@ -22,7 +22,6 @@ public class LinkComponent : Component public LinkComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/LoaderComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/LoaderComponent.g.cs index 2c3fa768d..709abcc7c 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/LoaderComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/LoaderComponent.g.cs @@ -22,7 +22,6 @@ public class LoaderComponent : Component public LoaderComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/LockComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/LockComponent.g.cs index 65a49de13..7bae8104f 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/LockComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/LockComponent.g.cs @@ -22,7 +22,6 @@ public class LockComponent : Component public LockComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/LubricationComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/LubricationComponent.g.cs index b8625931d..f0714085c 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/LubricationComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/LubricationComponent.g.cs @@ -22,7 +22,6 @@ public class LubricationComponent : Component public LubricationComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/MaterialComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/MaterialComponent.g.cs index 7ab1513ee..9abba2534 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/MaterialComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/MaterialComponent.g.cs @@ -22,7 +22,6 @@ public class MaterialComponent : Component public MaterialComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/MaterialsComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/MaterialsComponent.g.cs index 94cf5eec1..bd104804e 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/MaterialsComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/MaterialsComponent.g.cs @@ -22,7 +22,6 @@ public class MaterialsComponent : Component, IOrganizerComponent public MaterialsComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/MotorComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/MotorComponent.g.cs index f9c8e7cc9..fddf6b32e 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/MotorComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/MotorComponent.g.cs @@ -22,7 +22,6 @@ public class MotorComponent : Component public MotorComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/OilComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/OilComponent.g.cs index a844b51d6..3a96e088f 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/OilComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/OilComponent.g.cs @@ -22,7 +22,6 @@ public class OilComponent : Component public OilComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PartComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PartComponent.g.cs index 7ad99751e..869469061 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PartComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PartComponent.g.cs @@ -22,7 +22,6 @@ public abstract class PartComponent : Component public PartComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PartOccurrenceComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PartOccurrenceComponent.g.cs index cb31eb08d..c38e7db76 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PartOccurrenceComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PartOccurrenceComponent.g.cs @@ -22,7 +22,6 @@ public class PartOccurrenceComponent : Component public PartOccurrenceComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PartsComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PartsComponent.g.cs index bffaa1f41..95aeea265 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PartsComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PartsComponent.g.cs @@ -22,7 +22,6 @@ public class PartsComponent : Component, IOrganizerComponent public PartsComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PathComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PathComponent.g.cs index 9b36a6726..7a040cb92 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PathComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PathComponent.g.cs @@ -22,7 +22,6 @@ public class PathComponent : Component public PathComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PersonnelComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PersonnelComponent.g.cs index 9b04dd496..c56cb1311 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PersonnelComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PersonnelComponent.g.cs @@ -22,7 +22,6 @@ public class PersonnelComponent : Component public PersonnelComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PneumaticComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PneumaticComponent.g.cs index 4674240b7..2abf6a822 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PneumaticComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PneumaticComponent.g.cs @@ -22,7 +22,6 @@ public class PneumaticComponent : Component public PneumaticComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PotComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PotComponent.g.cs index 385598a97..26f7a96bd 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PotComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PotComponent.g.cs @@ -22,7 +22,6 @@ public class PotComponent : Component public PotComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PowerComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PowerComponent.g.cs index 1afb989f4..e1fff29f0 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PowerComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PowerComponent.g.cs @@ -22,7 +22,6 @@ public class PowerComponent : Component public PowerComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PowerSupplyComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PowerSupplyComponent.g.cs index 2d271497a..0ec36452d 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PowerSupplyComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PowerSupplyComponent.g.cs @@ -22,7 +22,6 @@ public class PowerSupplyComponent : Component public PowerSupplyComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PressureComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PressureComponent.g.cs index 64c05442b..e7a3018a1 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PressureComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PressureComponent.g.cs @@ -22,7 +22,6 @@ public class PressureComponent : Component public PressureComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ProcessComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ProcessComponent.g.cs index a1432ae1b..e6f619ace 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ProcessComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ProcessComponent.g.cs @@ -22,7 +22,6 @@ public abstract class ProcessComponent : Component public ProcessComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ProcessOccurrenceComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ProcessOccurrenceComponent.g.cs index 60eb2e759..9ddc9d590 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ProcessOccurrenceComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ProcessOccurrenceComponent.g.cs @@ -22,7 +22,6 @@ public class ProcessOccurrenceComponent : Component public ProcessOccurrenceComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ProcessPowerComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ProcessPowerComponent.g.cs index ec47b8fd5..1d1cb4064 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ProcessPowerComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ProcessPowerComponent.g.cs @@ -22,7 +22,6 @@ public class ProcessPowerComponent : Component public ProcessPowerComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ProcessesComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ProcessesComponent.g.cs index 27d07820c..4ff9110cf 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ProcessesComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ProcessesComponent.g.cs @@ -22,7 +22,6 @@ public class ProcessesComponent : Component, IOrganizerComponent public ProcessesComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ProtectiveComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ProtectiveComponent.g.cs index 9a36173b6..810cbe3e5 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ProtectiveComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ProtectiveComponent.g.cs @@ -22,7 +22,6 @@ public class ProtectiveComponent : Component public ProtectiveComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PulleyComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PulleyComponent.g.cs index 125760b03..f829749e7 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PulleyComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PulleyComponent.g.cs @@ -22,7 +22,6 @@ public class PulleyComponent : Component public PulleyComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/PumpComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/PumpComponent.g.cs index 8d20836c0..221539c7e 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/PumpComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/PumpComponent.g.cs @@ -22,7 +22,6 @@ public class PumpComponent : Component public PumpComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ReelComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ReelComponent.g.cs index 183c5a5a2..774a99f89 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ReelComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ReelComponent.g.cs @@ -22,7 +22,6 @@ public class ReelComponent : Component public ReelComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/RemovalPotComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/RemovalPotComponent.g.cs index afb01888c..9ec8c77c3 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/RemovalPotComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/RemovalPotComponent.g.cs @@ -22,7 +22,6 @@ public class RemovalPotComponent : Component public RemovalPotComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ResourceComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ResourceComponent.g.cs index 98923eff7..600c89d6d 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ResourceComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ResourceComponent.g.cs @@ -22,7 +22,6 @@ public abstract class ResourceComponent : Component public ResourceComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ResourcesComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ResourcesComponent.g.cs index 616e49230..58e2695d8 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ResourcesComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ResourcesComponent.g.cs @@ -22,7 +22,6 @@ public class ResourcesComponent : Component, IOrganizerComponent public ResourcesComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ReturnPotComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ReturnPotComponent.g.cs index 29a7ee9c7..a7265afb0 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ReturnPotComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ReturnPotComponent.g.cs @@ -22,7 +22,6 @@ public class ReturnPotComponent : Component public ReturnPotComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/RotaryComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/RotaryComponent.g.cs index 7c3d17052..d2e9b939f 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/RotaryComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/RotaryComponent.g.cs @@ -22,7 +22,6 @@ public class RotaryComponent : Component public RotaryComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/SensingElementComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/SensingElementComponent.g.cs index 7e9e3ad74..0db19ef72 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/SensingElementComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/SensingElementComponent.g.cs @@ -22,7 +22,6 @@ public class SensingElementComponent : Component public SensingElementComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/SensorComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/SensorComponent.g.cs index 705653c57..22b432c6a 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/SensorComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/SensorComponent.g.cs @@ -22,7 +22,6 @@ public class SensorComponent : Component public SensorComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/SpindleComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/SpindleComponent.g.cs index cd3c3398b..00994d109 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/SpindleComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/SpindleComponent.g.cs @@ -22,7 +22,6 @@ public class SpindleComponent : Component public SpindleComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/SpreaderComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/SpreaderComponent.g.cs index ed7e7e936..1ebd252c5 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/SpreaderComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/SpreaderComponent.g.cs @@ -22,7 +22,6 @@ public class SpreaderComponent : Component public SpreaderComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/StagingPotComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/StagingPotComponent.g.cs index 7640a2b0a..80bfbfe8d 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/StagingPotComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/StagingPotComponent.g.cs @@ -22,7 +22,6 @@ public class StagingPotComponent : Component public StagingPotComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/StationComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/StationComponent.g.cs index bcec97598..8dda99a49 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/StationComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/StationComponent.g.cs @@ -22,7 +22,6 @@ public class StationComponent : Component public StationComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/StockComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/StockComponent.g.cs index 853ebcdd0..6495ab188 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/StockComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/StockComponent.g.cs @@ -22,7 +22,6 @@ public class StockComponent : Component public StockComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/StorageBatteryComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/StorageBatteryComponent.g.cs index 15e2f2ad0..590cb55bf 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/StorageBatteryComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/StorageBatteryComponent.g.cs @@ -22,7 +22,6 @@ public class StorageBatteryComponent : Component public StorageBatteryComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/StructureComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/StructureComponent.g.cs index fcf0af259..ada4c5727 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/StructureComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/StructureComponent.g.cs @@ -22,7 +22,6 @@ public class StructureComponent : Component public StructureComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/StructuresComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/StructuresComponent.g.cs index 7f23a7469..09a822619 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/StructuresComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/StructuresComponent.g.cs @@ -22,7 +22,6 @@ public class StructuresComponent : Component, IOrganizerComponent public StructuresComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/SwitchComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/SwitchComponent.g.cs index 0f5bd1a4e..029094b40 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/SwitchComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/SwitchComponent.g.cs @@ -22,7 +22,6 @@ public class SwitchComponent : Component public SwitchComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/SystemComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/SystemComponent.g.cs index 10ffa7632..d73c942f5 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/SystemComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/SystemComponent.g.cs @@ -22,7 +22,6 @@ public abstract class SystemComponent : Component public SystemComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/SystemsComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/SystemsComponent.g.cs index 6dddb7461..c2f9eacb4 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/SystemsComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/SystemsComponent.g.cs @@ -22,7 +22,6 @@ public class SystemsComponent : Component, IOrganizerComponent public SystemsComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/TableComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/TableComponent.g.cs index 6f8ae7b59..b75d362ec 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/TableComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/TableComponent.g.cs @@ -22,7 +22,6 @@ public class TableComponent : Component public TableComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/TankComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/TankComponent.g.cs index db0f39550..c37cf1392 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/TankComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/TankComponent.g.cs @@ -22,7 +22,6 @@ public class TankComponent : Component public TankComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/TensionerComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/TensionerComponent.g.cs index ef57f7970..4b07a7380 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/TensionerComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/TensionerComponent.g.cs @@ -22,7 +22,6 @@ public class TensionerComponent : Component public TensionerComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ThermostatComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ThermostatComponent.g.cs index 0fe05427d..9da88201d 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ThermostatComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ThermostatComponent.g.cs @@ -22,7 +22,6 @@ public class ThermostatComponent : Component public ThermostatComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ToolMagazineComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ToolMagazineComponent.g.cs index 2378f362f..8dcecf191 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ToolMagazineComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ToolMagazineComponent.g.cs @@ -22,7 +22,6 @@ public class ToolMagazineComponent : Component public ToolMagazineComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ToolRackComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ToolRackComponent.g.cs index 06dc986b0..cd29f87d5 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ToolRackComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ToolRackComponent.g.cs @@ -22,7 +22,6 @@ public class ToolRackComponent : Component public ToolRackComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ToolingDeliveryComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ToolingDeliveryComponent.g.cs index 22cb72593..b944f54f6 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ToolingDeliveryComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ToolingDeliveryComponent.g.cs @@ -22,7 +22,6 @@ public class ToolingDeliveryComponent : Component public ToolingDeliveryComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/TransferArmComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/TransferArmComponent.g.cs index af0ca316a..cbc4d60ef 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/TransferArmComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/TransferArmComponent.g.cs @@ -22,7 +22,6 @@ public class TransferArmComponent : Component public TransferArmComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/TransferPotComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/TransferPotComponent.g.cs index 5f76b0f4f..e74abdf02 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/TransferPotComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/TransferPotComponent.g.cs @@ -22,7 +22,6 @@ public class TransferPotComponent : Component public TransferPotComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/TransformerComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/TransformerComponent.g.cs index f2a681842..e7a1fa473 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/TransformerComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/TransformerComponent.g.cs @@ -22,7 +22,6 @@ public class TransformerComponent : Component public TransformerComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/TurretComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/TurretComponent.g.cs index 10963050a..2faee98c8 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/TurretComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/TurretComponent.g.cs @@ -22,7 +22,6 @@ public class TurretComponent : Component public TurretComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/VacuumComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/VacuumComponent.g.cs index 425e7428d..68f954c4f 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/VacuumComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/VacuumComponent.g.cs @@ -22,7 +22,6 @@ public class VacuumComponent : Component public VacuumComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/ValveComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/ValveComponent.g.cs index 6f62252e9..41a7f64b5 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/ValveComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/ValveComponent.g.cs @@ -22,7 +22,6 @@ public class ValveComponent : Component public ValveComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/VatComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/VatComponent.g.cs index 1ca07e6e8..79d80a583 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/VatComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/VatComponent.g.cs @@ -22,7 +22,6 @@ public class VatComponent : Component public VatComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/VibrationComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/VibrationComponent.g.cs index 52bd478f0..3d6e20bdd 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/VibrationComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/VibrationComponent.g.cs @@ -22,7 +22,6 @@ public class VibrationComponent : Component public VibrationComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/WasteDisposalComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/WasteDisposalComponent.g.cs index e32174eed..8fe3e1099 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/WasteDisposalComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/WasteDisposalComponent.g.cs @@ -22,7 +22,6 @@ public class WasteDisposalComponent : Component public WasteDisposalComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/WaterComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/WaterComponent.g.cs index e79b60c6b..04fbea601 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/WaterComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/WaterComponent.g.cs @@ -22,7 +22,6 @@ public class WaterComponent : Component public WaterComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/WireComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/WireComponent.g.cs index 9a83057aa..5b7f6598f 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/WireComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/WireComponent.g.cs @@ -22,7 +22,6 @@ public class WireComponent : Component public WireComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/WorkEnvelopeComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/WorkEnvelopeComponent.g.cs index 77c8c4f48..def7ac512 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/WorkEnvelopeComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/WorkEnvelopeComponent.g.cs @@ -22,7 +22,6 @@ public class WorkEnvelopeComponent : Component public WorkEnvelopeComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Components/WorkpieceComponent.g.cs b/libraries/MTConnect.NET-Common/Devices/Components/WorkpieceComponent.g.cs index af32d7497..8d8279711 100644 --- a/libraries/MTConnect.NET-Common/Devices/Components/WorkpieceComponent.g.cs +++ b/libraries/MTConnect.NET-Common/Devices/Components/WorkpieceComponent.g.cs @@ -22,7 +22,6 @@ public class WorkpieceComponent : Component public WorkpieceComponent() { Type = TypeId; - Name = NameId; } } } \ No newline at end of file diff --git a/libraries/MTConnect.NET-Common/Devices/Device.cs b/libraries/MTConnect.NET-Common/Devices/Device.cs index 02cb05872..715a6f449 100644 --- a/libraries/MTConnect.NET-Common/Devices/Device.cs +++ b/libraries/MTConnect.NET-Common/Devices/Device.cs @@ -93,9 +93,6 @@ public partial class Device : IDevice public Device() { - Id = StringFunctions.RandomString(10); - Name = "dev"; - Uuid = Guid.NewGuid().ToString(); Type = TypeId; DataItems = new List(); Components = new List(); diff --git a/tests/MTConnect.NET-Common-Tests/Devices/Components/ComponentCtorDefaultsTests.cs b/tests/MTConnect.NET-Common-Tests/Devices/Components/ComponentCtorDefaultsTests.cs new file mode 100644 index 000000000..f3c7ecb1f --- /dev/null +++ b/tests/MTConnect.NET-Common-Tests/Devices/Components/ComponentCtorDefaultsTests.cs @@ -0,0 +1,114 @@ +// Copyright (c) 2026 TrakHound Inc., All Rights Reserved. +// TrakHound Inc. licenses this file to you under the MIT license. + +using System; +using System.Linq; +using System.Reflection; +using MTConnect.Devices; +using MTConnect.Devices.Components; +using MTConnect.Tests.Common.TestHelpers; +using NUnit.Framework; + +namespace MTConnect.Tests.Common.Devices.Components +{ + /// + /// Pins the contract that every concrete + /// subclass leaves Name null after default + /// construction. Back-filling Name from the lowercase + /// NameId constant on each subclass would silently inject + /// the placeholder values "axes", "linear", + /// "systems", etc., into wire output for any consumer that + /// does not set Component.Name explicitly. + /// + [TestFixture] + [Category("DeviceComponentDefaultsRemoved")] + public class ComponentCtorDefaultsTests + { + /// + /// Walks every concrete -derived type + /// in the production assembly that has a public default + /// constructor and lives in + /// MTConnect.Devices.Components (i.e. every generated + /// component subclass) and asserts the default constructor + /// leaves Name null. The out-of-scope set is + /// imported from + /// to keep this fixture and the regression fixture in lockstep. + /// + [Test] + public void Every_concrete_Component_subclass_default_ctor_leaves_Name_null() + { + foreach (var subclass in EnumerateConcreteComponentSubclasses()) + { + if (NameBackfillRemovalOutOfScope.ComponentTypeNames.Contains(subclass.FullName!)) + continue; + + var instance = (Component)Activator.CreateInstance(subclass)!; + Assert.That(instance.Name, Is.Null, + $"{subclass.FullName} default ctor back-filled Name."); + } + } + + /// + /// Verifies that Type remains non-null after default + /// construction — the campaign removes only the Name + /// back-fill, not the Type assignment. + /// + [Test] + public void Every_concrete_Component_subclass_default_ctor_still_sets_Type() + { + foreach (var subclass in EnumerateConcreteComponentSubclasses()) + { + var instance = (Component)Activator.CreateInstance(subclass)!; + Assert.That(instance.Type, Is.Not.Null.And.Not.Empty, + $"{subclass.FullName} default ctor failed to set Type."); + } + } + + /// + /// Returns the generated concrete *Component subclasses + /// — i.e. those in the MTConnect.Devices.Components + /// namespace. The base MTConnect.Devices.Component is + /// concrete (and is callable directly), but it is the base + /// class itself, not a generated subclass; its default ctor + /// doesn't set Type and doesn't back-fill Name + /// either, so it is out of scope for the back-fill assertion. + /// + private static System.Collections.Generic.IEnumerable EnumerateConcreteComponentSubclasses() + { + var componentType = typeof(Component); + var assembly = componentType.Assembly; + + var concreteSubclasses = assembly.GetTypes() + .Where(t => componentType.IsAssignableFrom(t) + && t != componentType + && t.Namespace == "MTConnect.Devices.Components" + && !t.IsAbstract + && t.GetConstructor(Type.EmptyTypes) is not null) + .ToList(); + + // Sanity check — the production assembly defines many + // concrete component subclasses. If reflection finds + // none the test is silently passing for the wrong + // reason. + Assert.That(concreteSubclasses.Count, Is.GreaterThan(50), + "Expected the assembly to expose many concrete Component subclasses."); + + return concreteSubclasses; + } + + [Test] + public void Object_initializer_still_sets_Component_Name() + { + var component = new AxesComponent { Name = "explicit" }; + Assert.That(component.Name, Is.EqualTo("explicit")); + } + + [Test] + public void Direct_setter_still_sets_Component_Name() + { + var component = new ControllerComponent(); + component.Name = "controller-1"; + Assert.That(component.Name, Is.EqualTo("controller-1")); + } + } +} diff --git a/tests/MTConnect.NET-Common-Tests/Devices/DeviceCtorDefaultsTests.cs b/tests/MTConnect.NET-Common-Tests/Devices/DeviceCtorDefaultsTests.cs new file mode 100644 index 000000000..17f8fd865 --- /dev/null +++ b/tests/MTConnect.NET-Common-Tests/Devices/DeviceCtorDefaultsTests.cs @@ -0,0 +1,116 @@ +// Copyright (c) 2026 TrakHound Inc., All Rights Reserved. +// TrakHound Inc. licenses this file to you under the MIT license. + +using MTConnect.Devices; +using NUnit.Framework; + +namespace MTConnect.Tests.Common.DeviceCtorDefaults +{ + /// + /// Pins the contract that the parameterless + /// and constructors leave identity and naming + /// fields null. Stamping a placeholder identifier, the + /// placeholder name "dev", or a fresh random UUID per + /// construction would silently inject those placeholders into wire + /// output for any caller that does not set the fields explicitly. + /// + [TestFixture] + [Category("DeviceComponentDefaultsRemoved")] + public class DeviceCtorDefaultsTests + { + [Test] + public void Default_constructor_leaves_Id_null() + { + var device = new Device(); + Assert.That(device.Id, Is.Null); + } + + [Test] + public void Default_constructor_leaves_Name_null() + { + var device = new Device(); + Assert.That(device.Name, Is.Null); + } + + [Test] + public void Default_constructor_leaves_Uuid_null() + { + var device = new Device(); + Assert.That(device.Uuid, Is.Null); + } + + [Test] + public void Object_initializer_still_sets_Id() + { + var device = new Device { Id = "device-1" }; + Assert.That(device.Id, Is.EqualTo("device-1")); + } + + [Test] + public void Object_initializer_still_sets_Name() + { + var device = new Device { Name = "spindle-A" }; + Assert.That(device.Name, Is.EqualTo("spindle-A")); + } + + [Test] + public void Object_initializer_still_sets_Uuid() + { + var device = new Device { Uuid = "F1" }; + Assert.That(device.Uuid, Is.EqualTo("F1")); + } + + [Test] + public void Sequential_default_constructors_produce_identical_null_identity() + { + var first = new Device(); + var second = new Device(); + + Assert.That(first.Id, Is.Null); + Assert.That(second.Id, Is.Null); + Assert.That(first.Name, Is.Null); + Assert.That(second.Name, Is.Null); + Assert.That(first.Uuid, Is.Null); + Assert.That(second.Uuid, Is.Null); + } + + [Test] + public void Default_constructor_still_sets_Type() + { + // Type is infrastructure, not identity — left alone by the campaign. + var device = new Device(); + Assert.That(device.Type, Is.EqualTo(Device.TypeId)); + } + + [Test] + public void Default_constructor_still_initialises_collections() + { + // Collections are infrastructure for later population — left alone. + var device = new Device(); + Assert.That(device.DataItems, Is.Not.Null); + Assert.That(device.Components, Is.Not.Null); + Assert.That(device.Compositions, Is.Not.Null); + } + + [Test] + public void Agent_default_constructor_leaves_Uuid_null() + { + var agent = new Agent(); + Assert.That(agent.Uuid, Is.Null); + } + + [Test] + public void Agent_default_constructor_leaves_Id_null() + { + var agent = new Agent(); + Assert.That(agent.Id, Is.Null); + } + + [Test] + public void Agent_default_constructor_leaves_Name_null() + { + var agent = new Agent(); + Assert.That(agent.Name, Is.Null); + } + } +} diff --git a/tests/MTConnect.NET-Common-Tests/Regressions/DeviceComponentDefaultsRegressionTests.cs b/tests/MTConnect.NET-Common-Tests/Regressions/DeviceComponentDefaultsRegressionTests.cs new file mode 100644 index 000000000..b164fc84a --- /dev/null +++ b/tests/MTConnect.NET-Common-Tests/Regressions/DeviceComponentDefaultsRegressionTests.cs @@ -0,0 +1,156 @@ +// Copyright (c) 2026 TrakHound Inc., All Rights Reserved. +// TrakHound Inc. licenses this file to you under the MIT license. + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Reflection; +using MTConnect.Devices; +using MTConnect.Devices.Components; +using MTConnect.Tests.Common.TestHelpers; +using NUnit.Framework; + +namespace MTConnect.Tests.Common.Regressions +{ + /// + /// Regression pins for the contract that and + /// every concrete subclass leave identity + /// and naming fields null after default construction. + /// + /// These tests outlast the red-category fixtures: the red fixtures + /// describe the work that landed; this fixture protects the + /// contract over time. The reflection guard catches any future + /// subclass that re-introduces the back-fill. + /// + [TestFixture] + public class DeviceComponentDefaultsRegressionTests + { + // ---- Device ------------------------------------------------ + + [Test] + public void Device_default_constructor_leaves_identity_fields_null() + { + var device = new Device(); + Assert.Multiple(() => + { + Assert.That(device.Id, Is.Null, "Device.Id"); + Assert.That(device.Name, Is.Null, "Device.Name"); + Assert.That(device.Uuid, Is.Null, "Device.Uuid"); + }); + } + + [Test] + public void Agent_default_constructor_leaves_identity_fields_null() + { + var agent = new Agent(); + Assert.Multiple(() => + { + Assert.That(agent.Id, Is.Null, "Agent.Id"); + Assert.That(agent.Name, Is.Null, "Agent.Name"); + Assert.That(agent.Uuid, Is.Null, "Agent.Uuid"); + }); + } + + [Test] + public void Sequential_default_Devices_share_null_Uuid() + { + // The original #136 defect produced a fresh GUID per + // construction. Pinned here because the bug is silent — + // the symptom is identity drift, not a thrown exception. + var first = new Device(); + var second = new Device(); + Assert.That(first.Uuid, Is.Null); + Assert.That(second.Uuid, Is.Null); + } + + [Test] + public void Object_initializer_continues_to_set_Device_identity() + { + var device = new Device { Id = "id-A", Name = "name-A", Uuid = "uuid-A" }; + Assert.Multiple(() => + { + Assert.That(device.Id, Is.EqualTo("id-A")); + Assert.That(device.Name, Is.EqualTo("name-A")); + Assert.That(device.Uuid, Is.EqualTo("uuid-A")); + }); + } + + // ---- Reflection guard -------------------------------------- + + [Test] + public void No_Device_subclass_default_constructor_back_fills_identity() + { + var failures = new List(); + foreach (var subclass in EnumerateConcreteWithDefaultCtor(typeof(Device))) + { + var instance = (Device)Activator.CreateInstance(subclass)!; + if (instance.Id is not null) + { + failures.Add($"{subclass.FullName} default ctor set Id = '{instance.Id}'."); + } + if (instance.Name is not null) + { + failures.Add($"{subclass.FullName} default ctor set Name = '{instance.Name}'."); + } + if (instance.Uuid is not null) + { + failures.Add($"{subclass.FullName} default ctor set Uuid = '{instance.Uuid}'."); + } + } + + Assert.That(failures, Is.Empty, string.Join(Environment.NewLine, failures)); + } + + [Test] + public void No_Component_subclass_default_constructor_back_fills_Name() + { + var componentType = typeof(Component); + var failures = new List(); + + foreach (var subclass in EnumerateConcreteWithDefaultCtor(componentType)) + { + if (subclass == componentType) + { + // Base class — has no NameId to back-fill from. + continue; + } + + if (NameBackfillRemovalOutOfScope.ComponentTypeNames.Contains(subclass.FullName!)) + { + continue; + } + + var instance = (Component)Activator.CreateInstance(subclass)!; + if (instance.Name is not null) + { + failures.Add($"{subclass.FullName} default ctor set Name = '{instance.Name}'."); + } + } + + Assert.That(failures, Is.Empty, string.Join(Environment.NewLine, failures)); + } + + [Test] + public void Reflection_guard_walks_a_meaningful_set_of_Component_subclasses() + { + // Sanity check on the reflection walker — if the assembly + // ever stops exposing component subclasses (e.g. a + // refactor splits them off), the guard above silently + // passes. This test fails loudly in that case. + var componentSubclasses = EnumerateConcreteWithDefaultCtor(typeof(Component)) + .Where(t => t != typeof(Component) && t.Namespace == "MTConnect.Devices.Components") + .ToList(); + Assert.That(componentSubclasses.Count, Is.GreaterThan(50)); + } + + // ---- Helper ------------------------------------------------ + + private static IEnumerable EnumerateConcreteWithDefaultCtor(Type baseType) + { + return baseType.Assembly.GetTypes() + .Where(t => baseType.IsAssignableFrom(t) + && !t.IsAbstract + && t.GetConstructor(BindingFlags.Public | BindingFlags.Instance, binder: null, types: Type.EmptyTypes, modifiers: null) is not null); + } + } +} diff --git a/tests/MTConnect.NET-Common-Tests/TestHelpers/NameBackfillRemovalOutOfScope.cs b/tests/MTConnect.NET-Common-Tests/TestHelpers/NameBackfillRemovalOutOfScope.cs new file mode 100644 index 000000000..87829d93b --- /dev/null +++ b/tests/MTConnect.NET-Common-Tests/TestHelpers/NameBackfillRemovalOutOfScope.cs @@ -0,0 +1,41 @@ +// Copyright (c) 2026 TrakHound Inc., All Rights Reserved. +// TrakHound Inc. licenses this file to you under the MIT license. + +using System; +using System.Collections.Generic; + +namespace MTConnect.Tests.Common.TestHelpers +{ + /// + /// Shared list of concrete MTConnect.Devices.Components.*Component + /// classes whose Name back-fill is generated from an older regen + /// template and is not removed by the current source tree. A follow-up + /// regen will strip the back-fill from these classes too; until then the + /// type names live here so: + /// - ComponentCtorDefaultsTests and + /// - DeviceComponentDefaultsRegressionTests + /// stay green without losing their enforcement intent on the components + /// whose back-fill has already been removed. + /// + /// Centralizing the set prevents the two fixtures' inline copies from + /// drifting as new generated subclasses are added or as the regen + /// removes them from this list. + /// + internal static class NameBackfillRemovalOutOfScope + { + /// + /// Fully-qualified type names of the out-of-scope component classes. + /// Uses ordinal (case-sensitive) comparison so a generated + /// `cuttingtorchcomponent` snapshot wouldn't accidentally match the + /// canonical `CuttingTorchComponent`. + /// + public static readonly HashSet ComponentTypeNames = + new(StringComparer.Ordinal) + { + "MTConnect.Devices.Components.CuttingTorchComponent", + "MTConnect.Devices.Components.ElectrodeComponent", + "MTConnect.Devices.Components.PinToolComponent", + "MTConnect.Devices.Components.ToolHolderComponent", + }; + } +} diff --git a/tests/MTConnect.NET-Common-Tests/TestHelpers/NameBackfillRemovalOutOfScopeTests.cs b/tests/MTConnect.NET-Common-Tests/TestHelpers/NameBackfillRemovalOutOfScopeTests.cs new file mode 100644 index 000000000..bb2484338 --- /dev/null +++ b/tests/MTConnect.NET-Common-Tests/TestHelpers/NameBackfillRemovalOutOfScopeTests.cs @@ -0,0 +1,63 @@ +// Copyright (c) 2026 TrakHound Inc., All Rights Reserved. +// TrakHound Inc. licenses this file to you under the MIT license. + +using System.Linq; +using MTConnect.Tests.Common.TestHelpers; +using NUnit.Framework; + +namespace MTConnect.Tests.Common.TestHelpers +{ + /// + /// Pins the contract for the shared + /// helper so the + /// out-of-scope set lives in one place and ctor-defaults regression + /// fixtures cannot drift as the regen track lands the back-fill + /// removal on the remaining `*.g.cs` classes. + /// + [TestFixture] + public class NameBackfillRemovalOutOfScopeTests + { + [Test] + public void Helper_class_is_internal_static() + { + var t = typeof(NameBackfillRemovalOutOfScope); + Assert.That(t.IsAbstract && t.IsSealed, Is.True, + "NameBackfillRemovalOutOfScope must be a static class."); + Assert.That(t.IsNotPublic, Is.True, + "NameBackfillRemovalOutOfScope must be internal to the test project."); + } + + [Test] + public void Helper_exposes_expected_out_of_scope_component_types() + { + var expected = new[] + { + "MTConnect.Devices.Components.CuttingTorchComponent", + "MTConnect.Devices.Components.ElectrodeComponent", + "MTConnect.Devices.Components.PinToolComponent", + "MTConnect.Devices.Components.ToolHolderComponent", + }; + + var actual = NameBackfillRemovalOutOfScope.ComponentTypeNames + .OrderBy(s => s, System.StringComparer.Ordinal) + .ToArray(); + + Assert.That(actual, Is.EqualTo(expected.OrderBy(s => s, System.StringComparer.Ordinal).ToArray())); + } + + [Test] + public void Helper_set_uses_ordinal_comparer() + { + // Case-insensitive comparison would mask `cuttingtorchcomponent` + // accidentally landing as a different generated type — pin + // ordinal so consumers cannot regress to a looser comparer. + Assert.That( + NameBackfillRemovalOutOfScope.ComponentTypeNames.Contains("MTConnect.Devices.Components.CuttingTorchComponent"), + Is.True); + Assert.That( + NameBackfillRemovalOutOfScope.ComponentTypeNames.Contains("MTConnect.Devices.Components.cuttingtorchcomponent"), + Is.False, + "Out-of-scope set must use ordinal (case-sensitive) comparison."); + } + } +} diff --git a/tests/MTConnect.NET-XML-Tests/Devices/DeviceCtorDefaultsWireShapeTests.cs b/tests/MTConnect.NET-XML-Tests/Devices/DeviceCtorDefaultsWireShapeTests.cs new file mode 100644 index 000000000..66c0e7fa3 --- /dev/null +++ b/tests/MTConnect.NET-XML-Tests/Devices/DeviceCtorDefaultsWireShapeTests.cs @@ -0,0 +1,73 @@ +// Copyright (c) 2026 TrakHound Inc., All Rights Reserved. +// TrakHound Inc. licenses this file to you under the MIT license. + +using System.Text; +using MTConnect.Devices; +using MTConnect.Devices.Xml; +using NUnit.Framework; + +namespace MTConnect.Tests.XML.Devices +{ + /// + /// Wire-shape smoke for the constructor-defaults removal contract: + /// after the campaign, a freshly-constructed + /// with no explicit fields set produces XML with empty id, + /// name, and uuid attribute values rather than + /// placeholder strings. + /// + /// This is the closest available approximation to the plan's + /// HTTP+MQTT Docker E2E. The full agent E2E surface (probe + /// emission against an XSD validator across an agent restart) is + /// not yet plumbed on upstream/master; once the bootstrap + /// prelude lands the higher-fidelity scenarios can be added. + /// + [TestFixture] + public class DeviceCtorDefaultsWireShapeTests + { + [Test] + public void Default_constructed_Device_emits_empty_identity_attributes() + { + var device = new Device(); + // The campaign deliberately leaves identity unset; serialise + // straight to XML to confirm the wire shape carries empty + // attribute values rather than placeholder strings. + var xml = Encoding.UTF8.GetString(XmlDevice.ToXml(device, indent: false)); + + Assert.That(xml, Does.Contain("id=\"\""), "Expected empty id attribute on default-constructed Device."); + Assert.That(xml, Does.Contain("name=\"\""), "Expected empty name attribute on default-constructed Device."); + Assert.That(xml, Does.Contain("uuid=\"\""), "Expected empty uuid attribute on default-constructed Device."); + Assert.That(xml, Does.Not.Contain("name=\"dev\""), + "Default ctor must not emit the placeholder name 'dev'."); + } + + [Test] + public void Caller_set_identity_round_trips_through_XML() + { + var device = new Device + { + Id = "device-1", + Name = "spindle-A", + Uuid = "uuid-A" + }; + + var xml = Encoding.UTF8.GetString(XmlDevice.ToXml(device, indent: false)); + + Assert.That(xml, Does.Contain("id=\"device-1\"")); + Assert.That(xml, Does.Contain("name=\"spindle-A\"")); + Assert.That(xml, Does.Contain("uuid=\"uuid-A\"")); + } + + [Test] + public void Sequential_default_Devices_emit_identical_empty_uuid_attributes() + { + // The original #136 symptom: GUID drift across constructions. + // Pinned at the wire-shape layer in case a future change + // masks it inside the POCO accessors. + var first = Encoding.UTF8.GetString(XmlDevice.ToXml(new Device(), indent: false)); + var second = Encoding.UTF8.GetString(XmlDevice.ToXml(new Device(), indent: false)); + + Assert.That(first, Does.Contain("uuid=\"\"")); + Assert.That(second, Does.Contain("uuid=\"\"")); + } + } +}