/* Code generated by IfcQuery EXPRESS generator, www.ifcquery.com */

#include <sstream>
#include <limits>
#include <map>
#include "ifcpp/reader/ReaderUtil.h"
#include "ifcpp/writer/WriterUtil.h"
#include "ifcpp/model/BasicTypes.h"
#include "ifcpp/model/BuildingException.h"
#include "ifcpp/IFC4/include/IfcCompressorTypeEnum.h"

// TYPE IfcCompressorTypeEnum = ENUMERATION OF	(DYNAMIC	,RECIPROCATING	,ROTARY	,SCROLL	,TROCHOIDAL	,SINGLESTAGE	,BOOSTER	,OPENTYPE	,HERMETIC	,SEMIHERMETIC	,WELDEDSHELLHERMETIC	,ROLLINGPISTON	,ROTARYVANE	,SINGLESCREW	,TWINSCREW	,USERDEFINED	,NOTDEFINED);
IfcCompressorTypeEnum::~IfcCompressorTypeEnum() {}
shared_ptr<BuildingObject> IfcCompressorTypeEnum::getDeepCopy( BuildingCopyOptions& options )
{
	shared_ptr<IfcCompressorTypeEnum> copy_self( new IfcCompressorTypeEnum() );
	copy_self->m_enum = m_enum;
	return copy_self;
}
void IfcCompressorTypeEnum::getStepParameter( std::stringstream& stream, bool is_select_type ) const
{
	if( is_select_type ) { stream << "IFCCOMPRESSORTYPEENUM("; }
	switch( m_enum )
	{
		case ENUM_DYNAMIC:	stream << ".DYNAMIC."; break;
		case ENUM_RECIPROCATING:	stream << ".RECIPROCATING."; break;
		case ENUM_ROTARY:	stream << ".ROTARY."; break;
		case ENUM_SCROLL:	stream << ".SCROLL."; break;
		case ENUM_TROCHOIDAL:	stream << ".TROCHOIDAL."; break;
		case ENUM_SINGLESTAGE:	stream << ".SINGLESTAGE."; break;
		case ENUM_BOOSTER:	stream << ".BOOSTER."; break;
		case ENUM_OPENTYPE:	stream << ".OPENTYPE."; break;
		case ENUM_HERMETIC:	stream << ".HERMETIC."; break;
		case ENUM_SEMIHERMETIC:	stream << ".SEMIHERMETIC."; break;
		case ENUM_WELDEDSHELLHERMETIC:	stream << ".WELDEDSHELLHERMETIC."; break;
		case ENUM_ROLLINGPISTON:	stream << ".ROLLINGPISTON."; break;
		case ENUM_ROTARYVANE:	stream << ".ROTARYVANE."; break;
		case ENUM_SINGLESCREW:	stream << ".SINGLESCREW."; break;
		case ENUM_TWINSCREW:	stream << ".TWINSCREW."; break;
		case ENUM_USERDEFINED:	stream << ".USERDEFINED."; break;
		case ENUM_NOTDEFINED:	stream << ".NOTDEFINED."; break;
	}
	if( is_select_type ) { stream << ")"; }
}
const std::wstring IfcCompressorTypeEnum::toString() const
{
	switch( m_enum ) 
	{
		case ENUM_DYNAMIC:	return L"DYNAMIC";
		case ENUM_RECIPROCATING:	return L"RECIPROCATING";
		case ENUM_ROTARY:	return L"ROTARY";
		case ENUM_SCROLL:	return L"SCROLL";
		case ENUM_TROCHOIDAL:	return L"TROCHOIDAL";
		case ENUM_SINGLESTAGE:	return L"SINGLESTAGE";
		case ENUM_BOOSTER:	return L"BOOSTER";
		case ENUM_OPENTYPE:	return L"OPENTYPE";
		case ENUM_HERMETIC:	return L"HERMETIC";
		case ENUM_SEMIHERMETIC:	return L"SEMIHERMETIC";
		case ENUM_WELDEDSHELLHERMETIC:	return L"WELDEDSHELLHERMETIC";
		case ENUM_ROLLINGPISTON:	return L"ROLLINGPISTON";
		case ENUM_ROTARYVANE:	return L"ROTARYVANE";
		case ENUM_SINGLESCREW:	return L"SINGLESCREW";
		case ENUM_TWINSCREW:	return L"TWINSCREW";
		case ENUM_USERDEFINED:	return L"USERDEFINED";
		case ENUM_NOTDEFINED:	return L"NOTDEFINED";
	}
	return L"";
}
shared_ptr<IfcCompressorTypeEnum> IfcCompressorTypeEnum::createObjectFromSTEP( const std::wstring& arg, const std::map<int,shared_ptr<BuildingEntity> >& map )
{
	if( arg.compare( L"$" ) == 0 ) { return shared_ptr<IfcCompressorTypeEnum>(); }
	if( arg.compare( L"*" ) == 0 ) { return shared_ptr<IfcCompressorTypeEnum>(); }
	shared_ptr<IfcCompressorTypeEnum> type_object( new IfcCompressorTypeEnum() );
	if( boost::iequals( arg, L".DYNAMIC." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_DYNAMIC;
	}
	else if( boost::iequals( arg, L".RECIPROCATING." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_RECIPROCATING;
	}
	else if( boost::iequals( arg, L".ROTARY." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_ROTARY;
	}
	else if( boost::iequals( arg, L".SCROLL." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_SCROLL;
	}
	else if( boost::iequals( arg, L".TROCHOIDAL." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_TROCHOIDAL;
	}
	else if( boost::iequals( arg, L".SINGLESTAGE." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_SINGLESTAGE;
	}
	else if( boost::iequals( arg, L".BOOSTER." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_BOOSTER;
	}
	else if( boost::iequals( arg, L".OPENTYPE." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_OPENTYPE;
	}
	else if( boost::iequals( arg, L".HERMETIC." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_HERMETIC;
	}
	else if( boost::iequals( arg, L".SEMIHERMETIC." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_SEMIHERMETIC;
	}
	else if( boost::iequals( arg, L".WELDEDSHELLHERMETIC." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_WELDEDSHELLHERMETIC;
	}
	else if( boost::iequals( arg, L".ROLLINGPISTON." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_ROLLINGPISTON;
	}
	else if( boost::iequals( arg, L".ROTARYVANE." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_ROTARYVANE;
	}
	else if( boost::iequals( arg, L".SINGLESCREW." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_SINGLESCREW;
	}
	else if( boost::iequals( arg, L".TWINSCREW." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_TWINSCREW;
	}
	else if( boost::iequals( arg, L".USERDEFINED." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_USERDEFINED;
	}
	else if( boost::iequals( arg, L".NOTDEFINED." ) )
	{
		type_object->m_enum = IfcCompressorTypeEnum::ENUM_NOTDEFINED;
	}
	return type_object;
}
