// ------------------------------------------------------------------------------
// <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.PresentationAppearanceResource
{
	public partial class @IfcSurfaceStyle : IIfcSurfaceStyle
	{

		[CrossSchemaAttribute(typeof(IIfcSurfaceStyle), 2)]
		Ifc4.Interfaces.IfcSurfaceSide IIfcSurfaceStyle.Side 
		{ 
			get
			{
				//## Custom code to handle enumeration of Side
				//##
				switch (Side)
				{
					case IfcSurfaceSide.BOTH:
						return Ifc4.Interfaces.IfcSurfaceSide.BOTH;
					case IfcSurfaceSide.NEGATIVE:
						return Ifc4.Interfaces.IfcSurfaceSide.NEGATIVE;
					case IfcSurfaceSide.POSITIVE:
						return Ifc4.Interfaces.IfcSurfaceSide.POSITIVE;
					
					default:
						throw new System.ArgumentOutOfRangeException();
				}
			} 
			set
			{
				//## Custom code to handle setting of enumeration of Side
				//##
				switch (value)
				{
					case Ifc4.Interfaces.IfcSurfaceSide.POSITIVE:
						Side = IfcSurfaceSide.POSITIVE;
						return;
					case Ifc4.Interfaces.IfcSurfaceSide.NEGATIVE:
						Side = IfcSurfaceSide.NEGATIVE;
						return;
					case Ifc4.Interfaces.IfcSurfaceSide.BOTH:
						Side = IfcSurfaceSide.BOTH;
						return;
					default:
						throw new System.ArgumentOutOfRangeException();
				}
				
			}
		}

		[CrossSchemaAttribute(typeof(IIfcSurfaceStyle), 3)]
		IItemSet<IIfcSurfaceStyleElementSelect> IIfcSurfaceStyle.Styles 
		{ 
			get
			{
			
				return new Common.Collections.ProxyItemSet<IfcSurfaceStyleElementSelect, IIfcSurfaceStyleElementSelect>(Styles);
			} 
		}
	//## Custom code
	//##
	}
}