// ------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool Xbim.CodeGeneration 
//  
//     Changes to this file may cause incorrect behaviour and will be lost if
//     the code is regenerated.
// </auto-generated>
// ------------------------------------------------------------------------------

using Xbim.Ifc4.Interfaces;
using System.Collections.Generic;
using System.Linq;
using Xbim.Common;

// ReSharper disable once CheckNamespace
namespace Xbim.Ifc2x3.HVACDomain
{
	public partial class @IfcPipeFittingType : IIfcPipeFittingType
	{

		[CrossSchemaAttribute(typeof(IIfcPipeFittingType), 10)]
		Ifc4.Interfaces.IfcPipeFittingTypeEnum IIfcPipeFittingType.PredefinedType 
		{ 
			get
			{
				//## Custom code to handle enumeration of PredefinedType
				//##
				switch (PredefinedType)
				{
					case IfcPipeFittingTypeEnum.BEND:
						return Ifc4.Interfaces.IfcPipeFittingTypeEnum.BEND;
					case IfcPipeFittingTypeEnum.CONNECTOR:
						return Ifc4.Interfaces.IfcPipeFittingTypeEnum.CONNECTOR;
					case IfcPipeFittingTypeEnum.ENTRY:
						return Ifc4.Interfaces.IfcPipeFittingTypeEnum.ENTRY;
					case IfcPipeFittingTypeEnum.EXIT:
						return Ifc4.Interfaces.IfcPipeFittingTypeEnum.EXIT;
					case IfcPipeFittingTypeEnum.JUNCTION:
						return Ifc4.Interfaces.IfcPipeFittingTypeEnum.JUNCTION;
					case IfcPipeFittingTypeEnum.OBSTRUCTION:
						return Ifc4.Interfaces.IfcPipeFittingTypeEnum.OBSTRUCTION;
					case IfcPipeFittingTypeEnum.TRANSITION:
						return Ifc4.Interfaces.IfcPipeFittingTypeEnum.TRANSITION;
					case IfcPipeFittingTypeEnum.USERDEFINED:
						//## Optional custom handling of PredefinedType == .USERDEFINED. 
						//##
						return Ifc4.Interfaces.IfcPipeFittingTypeEnum.USERDEFINED;
					case IfcPipeFittingTypeEnum.NOTDEFINED:
						return Ifc4.Interfaces.IfcPipeFittingTypeEnum.NOTDEFINED;
					
					default:
						throw new System.ArgumentOutOfRangeException();
				}
			} 
			set
			{
				//## Custom code to handle setting of enumeration of PredefinedType
				//##
				switch (value)
				{
					case Ifc4.Interfaces.IfcPipeFittingTypeEnum.BEND:
						PredefinedType = IfcPipeFittingTypeEnum.BEND;
						return;
					case Ifc4.Interfaces.IfcPipeFittingTypeEnum.CONNECTOR:
						PredefinedType = IfcPipeFittingTypeEnum.CONNECTOR;
						return;
					case Ifc4.Interfaces.IfcPipeFittingTypeEnum.ENTRY:
						PredefinedType = IfcPipeFittingTypeEnum.ENTRY;
						return;
					case Ifc4.Interfaces.IfcPipeFittingTypeEnum.EXIT:
						PredefinedType = IfcPipeFittingTypeEnum.EXIT;
						return;
					case Ifc4.Interfaces.IfcPipeFittingTypeEnum.JUNCTION:
						PredefinedType = IfcPipeFittingTypeEnum.JUNCTION;
						return;
					case Ifc4.Interfaces.IfcPipeFittingTypeEnum.OBSTRUCTION:
						PredefinedType = IfcPipeFittingTypeEnum.OBSTRUCTION;
						return;
					case Ifc4.Interfaces.IfcPipeFittingTypeEnum.TRANSITION:
						PredefinedType = IfcPipeFittingTypeEnum.TRANSITION;
						return;
					case Ifc4.Interfaces.IfcPipeFittingTypeEnum.USERDEFINED:
						PredefinedType = IfcPipeFittingTypeEnum.USERDEFINED;
						return;
					case Ifc4.Interfaces.IfcPipeFittingTypeEnum.NOTDEFINED:
						PredefinedType = IfcPipeFittingTypeEnum.NOTDEFINED;
						return;
					default:
						throw new System.ArgumentOutOfRangeException();
				}
				
			}
		}
	//## Custom code
	//##
	}
}