// ------------------------------------------------------------------------------
// <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;

//## Custom using statements
//##

// ReSharper disable once CheckNamespace
namespace Xbim.Ifc4x3.SharedBldgElements
{
	public partial class @IfcRoofType : IIfcRoofType
	{

		[CrossSchemaAttribute(typeof(IIfcRoofType), 10)]
		Ifc4.Interfaces.IfcRoofTypeEnum IIfcRoofType.PredefinedType 
		{ 
			get
			{
				//## Custom code to handle enumeration of PredefinedType
				//##
				switch (PredefinedType)
				{
					case IfcRoofTypeEnum.BARREL_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.BARREL_ROOF;
					case IfcRoofTypeEnum.BUTTERFLY_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.BUTTERFLY_ROOF;
					case IfcRoofTypeEnum.DOME_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.DOME_ROOF;
					case IfcRoofTypeEnum.FLAT_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.FLAT_ROOF;
					case IfcRoofTypeEnum.FREEFORM:
						return Ifc4.Interfaces.IfcRoofTypeEnum.FREEFORM;
					case IfcRoofTypeEnum.GABLE_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.GABLE_ROOF;
					case IfcRoofTypeEnum.GAMBREL_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.GAMBREL_ROOF;
					case IfcRoofTypeEnum.HIPPED_GABLE_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.HIPPED_GABLE_ROOF;
					case IfcRoofTypeEnum.HIP_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.HIP_ROOF;
					case IfcRoofTypeEnum.MANSARD_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.MANSARD_ROOF;
					case IfcRoofTypeEnum.PAVILION_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.PAVILION_ROOF;
					case IfcRoofTypeEnum.RAINBOW_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.RAINBOW_ROOF;
					case IfcRoofTypeEnum.SHED_ROOF:
						return Ifc4.Interfaces.IfcRoofTypeEnum.SHED_ROOF;
					case IfcRoofTypeEnum.USERDEFINED:
						//## Optional custom handling of PredefinedType == .USERDEFINED. 
						//##
						return Ifc4.Interfaces.IfcRoofTypeEnum.USERDEFINED;
					case IfcRoofTypeEnum.NOTDEFINED:
						return Ifc4.Interfaces.IfcRoofTypeEnum.NOTDEFINED;
					
					default:
						throw new System.ArgumentOutOfRangeException();
				}
			} 
			set
			{
				//## Custom code to handle setting of enumeration of PredefinedType
				//##
				switch (value)
				{
					case Ifc4.Interfaces.IfcRoofTypeEnum.FLAT_ROOF:
						PredefinedType = IfcRoofTypeEnum.FLAT_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.SHED_ROOF:
						PredefinedType = IfcRoofTypeEnum.SHED_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.GABLE_ROOF:
						PredefinedType = IfcRoofTypeEnum.GABLE_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.HIP_ROOF:
						PredefinedType = IfcRoofTypeEnum.HIP_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.HIPPED_GABLE_ROOF:
						PredefinedType = IfcRoofTypeEnum.HIPPED_GABLE_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.GAMBREL_ROOF:
						PredefinedType = IfcRoofTypeEnum.GAMBREL_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.MANSARD_ROOF:
						PredefinedType = IfcRoofTypeEnum.MANSARD_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.BARREL_ROOF:
						PredefinedType = IfcRoofTypeEnum.BARREL_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.RAINBOW_ROOF:
						PredefinedType = IfcRoofTypeEnum.RAINBOW_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.BUTTERFLY_ROOF:
						PredefinedType = IfcRoofTypeEnum.BUTTERFLY_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.PAVILION_ROOF:
						PredefinedType = IfcRoofTypeEnum.PAVILION_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.DOME_ROOF:
						PredefinedType = IfcRoofTypeEnum.DOME_ROOF;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.FREEFORM:
						PredefinedType = IfcRoofTypeEnum.FREEFORM;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.USERDEFINED:
						PredefinedType = IfcRoofTypeEnum.USERDEFINED;
						return;
					case Ifc4.Interfaces.IfcRoofTypeEnum.NOTDEFINED:
						PredefinedType = IfcRoofTypeEnum.NOTDEFINED;
						return;
					default:
						throw new System.ArgumentOutOfRangeException();
				}
				
			}
		}
	//## Custom code
	//##
	}
}