(*
Copyright by:
buildingSMART International Limited, 1996-2019

Any technical documentation made available by buildingSMART International Limited
is the copyrighted work of buildingSMART International Limited and is owned by the 
buildingSMART International Limited. It may be photocopied, used in software development, 
or translated into another computer language without prior written consent from 
buildingSMART International Limited provided that full attribution is given. 
Prior written consent is required if changes are made to the technical specification.

This material is delivered to you as is and buildingSMART International Limited makes 
no warranty of any kind with regard to it, including, but not limited to, the implied 
warranties as to its accuracy or fitness for a particular purpose. Any use of the 
technical documentation or the information contained therein is at the risk of the user. 
Documentation may include technical or other inaccuracies or typographical errors. 
buildingSMART International Limited shall not be liable for errors contained therein or 
for incidental consequential damages in connection with the furnishing, performance or use 
of the material. The information contained in this document is subject to change without notice.

Issue date:
Friday, July 26, 2019

*)

SCHEMA IFCELECTRICALDOMAIN;

REFERENCE FROM IFCSHAREDBLDGSERVICEELEMENTS
(
  IfcFlowTerminalType,
  IfcFlowControllerType,
  IfcEnergyConversionDeviceType,
  IfcFlowFittingType,
  IfcFlowStorageDeviceType,
  IfcFlowSegmentType,
  IfcDistributionControlElementType,
  IfcFlowSegment,
  IfcFlowFitting,
  IfcFlowStorageDevice,
  IfcFlowTerminal,
  IfcFlowController,
  IfcEnergyConversionDevice,
  IfcDistributionControlElement
);

REFERENCE FROM IFCPRODUCTEXTENSION
(
);

TYPE IfcAudioVisualApplianceTypeEnum = ENUMERATION OF
	(AMPLIFIER
	,CAMERA
	,DISPLAY
	,MICROPHONE
	,PLAYER
	,PROJECTOR
	,RECEIVER
	,SPEAKER
	,SWITCHER
	,TELEPHONE
	,TUNER
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcCableCarrierFittingTypeEnum = ENUMERATION OF
	(BEND
	,CROSS
	,REDUCER
	,TEE
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcCableCarrierSegmentTypeEnum = ENUMERATION OF
	(CABLELADDERSEGMENT
	,CABLETRAYSEGMENT
	,CABLETRUNKINGSEGMENT
	,CONDUITSEGMENT
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcCableFittingTypeEnum = ENUMERATION OF
	(CONNECTOR
	,ENTRY
	,EXIT
	,JUNCTION
	,TRANSITION
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcCableSegmentTypeEnum = ENUMERATION OF
	(BUSBARSEGMENT
	,CABLESEGMENT
	,CONDUCTORSEGMENT
	,CORESEGMENT
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcCommunicationsApplianceTypeEnum = ENUMERATION OF
	(ANTENNA
	,COMPUTER
	,FAX
	,GATEWAY
	,MODEM
	,NETWORKAPPLIANCE
	,NETWORKBRIDGE
	,NETWORKHUB
	,PRINTER
	,REPEATER
	,ROUTER
	,SCANNER
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcElectricApplianceTypeEnum = ENUMERATION OF
	(DISHWASHER
	,ELECTRICCOOKER
	,FREESTANDINGELECTRICHEATER
	,FREESTANDINGFAN
	,FREESTANDINGWATERHEATER
	,FREESTANDINGWATERCOOLER
	,FREEZER
	,FRIDGE_FREEZER
	,HANDDRYER
	,KITCHENMACHINE
	,MICROWAVE
	,PHOTOCOPIER
	,REFRIGERATOR
	,TUMBLEDRYER
	,VENDINGMACHINE
	,WASHINGMACHINE
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcElectricDistributionBoardTypeEnum = ENUMERATION OF
	(CONSUMERUNIT
	,DISTRIBUTIONBOARD
	,MOTORCONTROLCENTRE
	,SWITCHBOARD
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcElectricFlowStorageDeviceTypeEnum = ENUMERATION OF
	(BATTERY
	,CAPACITORBANK
	,HARMONICFILTER
	,INDUCTORBANK
	,UPS
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcElectricGeneratorTypeEnum = ENUMERATION OF
	(CHP
	,ENGINEGENERATOR
	,STANDALONE
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcElectricMotorTypeEnum = ENUMERATION OF
	(DC
	,INDUCTION
	,POLYPHASE
	,RELUCTANCESYNCHRONOUS
	,SYNCHRONOUS
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcElectricTimeControlTypeEnum = ENUMERATION OF
	(TIMECLOCK
	,TIMEDELAY
	,RELAY
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcJunctionBoxTypeEnum = ENUMERATION OF
	(DATA
	,POWER
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcLampTypeEnum = ENUMERATION OF
	(COMPACTFLUORESCENT
	,FLUORESCENT
	,HALOGEN
	,HIGHPRESSUREMERCURY
	,HIGHPRESSURESODIUM
	,LED
	,METALHALIDE
	,OLED
	,TUNGSTENFILAMENT
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcLightFixtureTypeEnum = ENUMERATION OF
	(POINTSOURCE
	,DIRECTIONSOURCE
	,SECURITYLIGHTING
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcMotorConnectionTypeEnum = ENUMERATION OF
	(BELTDRIVE
	,COUPLING
	,DIRECTDRIVE
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcOutletTypeEnum = ENUMERATION OF
	(AUDIOVISUALOUTLET
	,COMMUNICATIONSOUTLET
	,POWEROUTLET
	,DATAOUTLET
	,TELEPHONEOUTLET
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcProtectiveDeviceTrippingUnitTypeEnum = ENUMERATION OF
	(ELECTRONIC
	,ELECTROMAGNETIC
	,RESIDUALCURRENT
	,THERMAL
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcProtectiveDeviceTypeEnum = ENUMERATION OF
	(CIRCUITBREAKER
	,EARTHLEAKAGECIRCUITBREAKER
	,EARTHINGSWITCH
	,FUSEDISCONNECTOR
	,RESIDUALCURRENTCIRCUITBREAKER
	,RESIDUALCURRENTSWITCH
	,VARISTOR
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcSolarDeviceTypeEnum = ENUMERATION OF
	(SOLARCOLLECTOR
	,SOLARPANEL
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcSwitchingDeviceTypeEnum = ENUMERATION OF
	(CONTACTOR
	,DIMMERSWITCH
	,EMERGENCYSTOP
	,KEYPAD
	,MOMENTARYSWITCH
	,SELECTORSWITCH
	,STARTER
	,SWITCHDISCONNECTOR
	,TOGGLESWITCH
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

TYPE IfcTransformerTypeEnum = ENUMERATION OF
	(CURRENT
	,FREQUENCY
	,INVERTER
	,RECTIFIER
	,VOLTAGE
	,USERDEFINED
	,NOTDEFINED);
END_TYPE;

ENTITY IfcAudioVisualAppliance
 SUBTYPE OF (IfcFlowTerminal);
	PredefinedType : OPTIONAL IfcAudioVisualApplianceTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcAudioVisualApplianceTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcAudioVisualApplianceTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCAUDIOVISUALAPPLIANCETYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcAudioVisualApplianceType
 SUBTYPE OF (IfcFlowTerminalType);
	PredefinedType : IfcAudioVisualApplianceTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcAudioVisualApplianceTypeEnum.USERDEFINED) OR
((PredefinedType = IfcAudioVisualApplianceTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcCableCarrierFitting
 SUBTYPE OF (IfcFlowFitting);
	PredefinedType : OPTIONAL IfcCableCarrierFittingTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcCableCarrierFittingTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcCableCarrierFittingTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCCABLECARRIERFITTINGTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcCableCarrierFittingType
 SUBTYPE OF (IfcFlowFittingType);
	PredefinedType : IfcCableCarrierFittingTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcCableCarrierFittingTypeEnum.USERDEFINED) OR
((PredefinedType = IfcCableCarrierFittingTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcCableCarrierSegment
 SUBTYPE OF (IfcFlowSegment);
	PredefinedType : OPTIONAL IfcCableCarrierSegmentTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcCableCarrierSegmentTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcCableCarrierSegmentTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCCABLECARRIERSEGMENTTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcCableCarrierSegmentType
 SUBTYPE OF (IfcFlowSegmentType);
	PredefinedType : IfcCableCarrierSegmentTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcCableCarrierSegmentTypeEnum.USERDEFINED) OR
((PredefinedType = IfcCableCarrierSegmentTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcCableFitting
 SUBTYPE OF (IfcFlowFitting);
	PredefinedType : OPTIONAL IfcCableFittingTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcCableFittingTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcCableFittingTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCCABLEFITTINGTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcCableFittingType
 SUBTYPE OF (IfcFlowFittingType);
	PredefinedType : IfcCableFittingTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcCableFittingTypeEnum.USERDEFINED) OR
((PredefinedType = IfcCableFittingTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcCableSegment
 SUBTYPE OF (IfcFlowSegment);
	PredefinedType : OPTIONAL IfcCableSegmentTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcCableSegmentTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcCableSegmentTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCCABLESEGMENTTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcCableSegmentType
 SUBTYPE OF (IfcFlowSegmentType);
	PredefinedType : IfcCableSegmentTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcCableSegmentTypeEnum.USERDEFINED) OR
((PredefinedType = IfcCableSegmentTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcCommunicationsAppliance
 SUBTYPE OF (IfcFlowTerminal);
	PredefinedType : OPTIONAL IfcCommunicationsApplianceTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcCommunicationsApplianceTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcCommunicationsApplianceTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCCOMMUNICATIONSAPPLIANCETYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcCommunicationsApplianceType
 SUBTYPE OF (IfcFlowTerminalType);
	PredefinedType : IfcCommunicationsApplianceTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcCommunicationsApplianceTypeEnum.USERDEFINED) OR
((PredefinedType = IfcCommunicationsApplianceTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcElectricAppliance
 SUBTYPE OF (IfcFlowTerminal);
	PredefinedType : OPTIONAL IfcElectricApplianceTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcElectricApplianceTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcElectricApplianceTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCELECTRICAPPLIANCETYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcElectricApplianceType
 SUBTYPE OF (IfcFlowTerminalType);
	PredefinedType : IfcElectricApplianceTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcElectricApplianceTypeEnum.USERDEFINED) OR
((PredefinedType = IfcElectricApplianceTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcElectricDistributionBoard
 SUBTYPE OF (IfcFlowController);
	PredefinedType : OPTIONAL IfcElectricDistributionBoardTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcElectricDistributionBoardTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcElectricDistributionBoardTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCELECTRICDISTRIBUTIONBOARDTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcElectricDistributionBoardType
 SUBTYPE OF (IfcFlowControllerType);
	PredefinedType : IfcElectricDistributionBoardTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcElectricDistributionBoardTypeEnum.USERDEFINED) OR
((PredefinedType = IfcElectricDistributionBoardTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcElectricFlowStorageDevice
 SUBTYPE OF (IfcFlowStorageDevice);
	PredefinedType : OPTIONAL IfcElectricFlowStorageDeviceTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcElectricFlowStorageDeviceTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcElectricFlowStorageDeviceTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCELECTRICFLOWSTORAGEDEVICETYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcElectricFlowStorageDeviceType
 SUBTYPE OF (IfcFlowStorageDeviceType);
	PredefinedType : IfcElectricFlowStorageDeviceTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcElectricFlowStorageDeviceTypeEnum.USERDEFINED) OR
((PredefinedType = IfcElectricFlowStorageDeviceTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcElectricGenerator
 SUBTYPE OF (IfcEnergyConversionDevice);
	PredefinedType : OPTIONAL IfcElectricGeneratorTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcElectricGeneratorTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcElectricGeneratorTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCELECTRICGENERATORTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcElectricGeneratorType
 SUBTYPE OF (IfcEnergyConversionDeviceType);
	PredefinedType : IfcElectricGeneratorTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcElectricGeneratorTypeEnum.USERDEFINED) OR
((PredefinedType = IfcElectricGeneratorTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcElectricMotor
 SUBTYPE OF (IfcEnergyConversionDevice);
	PredefinedType : OPTIONAL IfcElectricMotorTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcElectricMotorTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcElectricMotorTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCELECTRICMOTORTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcElectricMotorType
 SUBTYPE OF (IfcEnergyConversionDeviceType);
	PredefinedType : IfcElectricMotorTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcElectricMotorTypeEnum.USERDEFINED) OR
((PredefinedType = IfcElectricMotorTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcElectricTimeControl
 SUBTYPE OF (IfcFlowController);
	PredefinedType : OPTIONAL IfcElectricTimeControlTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcElectricTimeControlTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcElectricTimeControlTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCELECTRICTIMECONTROLTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcElectricTimeControlType
 SUBTYPE OF (IfcFlowControllerType);
	PredefinedType : IfcElectricTimeControlTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcElectricTimeControlTypeEnum.USERDEFINED) OR
((PredefinedType = IfcElectricTimeControlTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcJunctionBox
 SUBTYPE OF (IfcFlowFitting);
	PredefinedType : OPTIONAL IfcJunctionBoxTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcJunctionBoxTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcJunctionBoxTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCJUNCTIONBOXTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcJunctionBoxType
 SUBTYPE OF (IfcFlowFittingType);
	PredefinedType : IfcJunctionBoxTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcJunctionBoxTypeEnum.USERDEFINED) OR
((PredefinedType = IfcJunctionBoxTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcLamp
 SUBTYPE OF (IfcFlowTerminal);
	PredefinedType : OPTIONAL IfcLampTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcLampTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcLampTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCLAMPTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcLampType
 SUBTYPE OF (IfcFlowTerminalType);
	PredefinedType : IfcLampTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcLampTypeEnum.USERDEFINED) OR
((PredefinedType = IfcLampTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcLightFixture
 SUBTYPE OF (IfcFlowTerminal);
	PredefinedType : OPTIONAL IfcLightFixtureTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcLightFixtureTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcLightFixtureTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCLIGHTFIXTURETYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcLightFixtureType
 SUBTYPE OF (IfcFlowTerminalType);
	PredefinedType : IfcLightFixtureTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcLightFixtureTypeEnum.USERDEFINED) OR
((PredefinedType = IfcLightFixtureTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcMotorConnection
 SUBTYPE OF (IfcEnergyConversionDevice);
	PredefinedType : OPTIONAL IfcMotorConnectionTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcMotorConnectionTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcMotorConnectionTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCMOTORCONNECTIONTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcMotorConnectionType
 SUBTYPE OF (IfcEnergyConversionDeviceType);
	PredefinedType : IfcMotorConnectionTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcMotorConnectionTypeEnum.USERDEFINED) OR
((PredefinedType = IfcMotorConnectionTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcOutlet
 SUBTYPE OF (IfcFlowTerminal);
	PredefinedType : OPTIONAL IfcOutletTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcOutletTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcOutletTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCOUTLETTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcOutletType
 SUBTYPE OF (IfcFlowTerminalType);
	PredefinedType : IfcOutletTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcOutletTypeEnum.USERDEFINED) OR
((PredefinedType = IfcOutletTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcProtectiveDevice
 SUBTYPE OF (IfcFlowController);
	PredefinedType : OPTIONAL IfcProtectiveDeviceTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcProtectiveDeviceTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcProtectiveDeviceTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCPROTECTIVEDEVICETYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcProtectiveDeviceTrippingUnit
 SUBTYPE OF (IfcDistributionControlElement);
	PredefinedType : OPTIONAL IfcProtectiveDeviceTrippingUnitTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcProtectiveDeviceTrippingUnitTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcProtectiveDeviceTrippingUnitTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCPROTECTIVEDEVICETRIPPINGUNITTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcProtectiveDeviceTrippingUnitType
 SUBTYPE OF (IfcDistributionControlElementType);
	PredefinedType : IfcProtectiveDeviceTrippingUnitTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcProtectiveDeviceTrippingUnitTypeEnum.USERDEFINED) OR
((PredefinedType = IfcProtectiveDeviceTrippingUnitTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcProtectiveDeviceType
 SUBTYPE OF (IfcFlowControllerType);
	PredefinedType : IfcProtectiveDeviceTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcProtectiveDeviceTypeEnum.USERDEFINED) OR
((PredefinedType = IfcProtectiveDeviceTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcSolarDevice
 SUBTYPE OF (IfcEnergyConversionDevice);
	PredefinedType : OPTIONAL IfcSolarDeviceTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcSolarDeviceTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcSolarDeviceTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCSOLARDEVICETYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcSolarDeviceType
 SUBTYPE OF (IfcEnergyConversionDeviceType);
	PredefinedType : IfcSolarDeviceTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcSolarDeviceTypeEnum.USERDEFINED) OR
((PredefinedType = IfcSolarDeviceTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcSwitchingDevice
 SUBTYPE OF (IfcFlowController);
	PredefinedType : OPTIONAL IfcSwitchingDeviceTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcSwitchingDeviceTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcSwitchingDeviceTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCSWITCHINGDEVICETYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcSwitchingDeviceType
 SUBTYPE OF (IfcFlowControllerType);
	PredefinedType : IfcSwitchingDeviceTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcSwitchingDeviceTypeEnum.USERDEFINED) OR
((PredefinedType = IfcSwitchingDeviceTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

ENTITY IfcTransformer
 SUBTYPE OF (IfcEnergyConversionDevice);
	PredefinedType : OPTIONAL IfcTransformerTypeEnum;
 WHERE
	CorrectPredefinedType : NOT(EXISTS(PredefinedType)) OR 
 (PredefinedType <> IfcTransformerTypeEnum.USERDEFINED) OR 
 ((PredefinedType = IfcTransformerTypeEnum.USERDEFINED) AND EXISTS (SELF\IfcObject.ObjectType));
	CorrectTypeAssigned : (SIZEOF(IsTypedBy) = 0) OR 
  ('IFCELECTRICALDOMAIN.IFCTRANFORMERTYPE' IN TYPEOF(SELF\IfcObject.IsTypedBy[1].RelatingType));
END_ENTITY;

ENTITY IfcTransformerType
 SUBTYPE OF (IfcEnergyConversionDeviceType);
	PredefinedType : IfcTransformerTypeEnum;
 WHERE
	CorrectPredefinedType : (PredefinedType <> IfcTransformerTypeEnum.USERDEFINED) OR
((PredefinedType = IfcTransformerTypeEnum.USERDEFINED) AND EXISTS(SELF\IfcElementType.ElementType));
END_ENTITY;

END_SCHEMA;
