/* this file was generated by the MCOP idl compiler - DO NOT EDIT */

#include "artsmodulescommon.h"

// Implementation
Arts::Environment::Context_base *Arts::Environment::Context_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::Environment::Context_base *castedObject = (Arts::Environment::Context_base *)skel->_cast(Arts::Environment::Context_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::Environment::Context_base *Arts::Environment::Context_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::Environment::Context_base::_fromReference(r,true);
	return 0;
}

Arts::Environment::Context_base *Arts::Environment::Context_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::Environment::Context_base *castedObject = (Arts::Environment::Context_base *)object._base()->_cast(Arts::Environment::Context_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::Environment::Context_base *Arts::Environment::Context_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::Environment::Context_base *result;
	result = (Arts::Environment::Context_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::Environment::Context");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::Environment::Context_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::Environment::Context")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::Environment::Context_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::Environment::Context_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::Environment::Context_base::_cast(unsigned long iid)
{
	if(iid == Arts::Environment::Context_base::_IID) return (Arts::Environment::Context_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::Environment::Context_stub::Context_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::Environment::Context_stub::Context_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

void Arts::Environment::Context_stub::addEntry(const std::string& name, Arts::Object obj)
{
	long methodID = _lookupMethodFast("method:00000009616464456e7472790000000005766f696400000000020000000200000007737472696e6700000000056e616d650000000000000000076f626a65637400000000046f626a000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(name);
	Arts::writeObject(*request,obj._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::Environment::Context_stub::lookupEntry(Arts::Object obj)
{
	long methodID = _lookupMethodFast("method:0000000c6c6f6f6b7570456e7472790000000007737472696e67000000000200000001000000076f626a65637400000000046f626a000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,obj._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return""; // error occurred
	std::string returnCode;
	result->readString(returnCode);
	delete result;
	return returnCode;
}

void Arts::Environment::Context_stub::removeEntry(Arts::Object obj)
{
	long methodID = _lookupMethodFast("method:0000000c72656d6f7665456e7472790000000005766f6964000000000200000001000000076f626a65637400000000046f626a000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,obj._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::Environment::Context_skel::_interfaceName()
{
	return "Arts::Environment::Context";
}

bool Arts::Environment::Context_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::Environment::Context") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::Environment::Context_skel::_interfaceNameSkel()
{
	return "Arts::Environment::Context";
}

// addEntry
static void _dispatch_Arts__Environment_Context_00(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::string name;
	request->readString(name);
	Arts::Object_base* _temp_obj;
	Arts::readObject(*request,_temp_obj);
	Arts::Object obj = Arts::Object::_from_base(_temp_obj);
	((Arts::Environment::Context_skel *)object)->addEntry(name,obj);
}

// lookupEntry
static void _dispatch_Arts__Environment_Context_01(void *object, Arts::Buffer *request, Arts::Buffer *result)
{
	Arts::Object_base* _temp_obj;
	Arts::readObject(*request,_temp_obj);
	Arts::Object obj = Arts::Object::_from_base(_temp_obj);
	result->writeString(((Arts::Environment::Context_skel *)object)->lookupEntry(obj));
}

// removeEntry
static void _dispatch_Arts__Environment_Context_02(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	Arts::Object_base* _temp_obj;
	Arts::readObject(*request,_temp_obj);
	Arts::Object obj = Arts::Object::_from_base(_temp_obj);
	((Arts::Environment::Context_skel *)object)->removeEntry(obj);
}

void Arts::Environment::Context_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:00000009616464456e7472790000000005766f6964000000000200"
        "00000200000007737472696e6700000000056e616d650000000000000000076f62"
        "6a65637400000000046f626a0000000000000000000000000c6c6f6f6b7570456e"
        "7472790000000007737472696e67000000000200000001000000076f626a656374"
        "00000000046f626a0000000000000000000000000c72656d6f7665456e74727900"
        "00000005766f6964000000000200000001000000076f626a65637400000000046f"
        "626a000000000000000000",
		"MethodTable"
	);
	_addMethod(_dispatch_Arts__Environment_Context_00,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Context_01,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Context_02,this,Arts::MethodDef(m));
}

Arts::Environment::Context_skel::Context_skel()
{
}

Arts::Object_base* Arts::Environment::Context::_Creator() {
	return Arts::Environment::Context_base::_create();
}

unsigned long Arts::Environment::Context_base::_IID = Arts::MCOPUtils::makeIID("Arts::Environment::Context");

Arts::Environment::Container_base *Arts::Environment::Container_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::Environment::Container_base *castedObject = (Arts::Environment::Container_base *)skel->_cast(Arts::Environment::Container_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::Environment::Container_base *Arts::Environment::Container_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::Environment::Container_base::_fromReference(r,true);
	return 0;
}

Arts::Environment::Container_base *Arts::Environment::Container_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::Environment::Container_base *castedObject = (Arts::Environment::Container_base *)object._base()->_cast(Arts::Environment::Container_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::Environment::Container_base *Arts::Environment::Container_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::Environment::Container_base *result;
	result = (Arts::Environment::Container_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::Environment::Container");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::Environment::Container_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::Environment::Container")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::Environment::Container_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::Environment::Container_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::Environment::Container_base::_cast(unsigned long iid)
{
	if(iid == Arts::Environment::Container_base::_IID) return (Arts::Environment::Container_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::Environment::Container_stub::Container_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::Environment::Container_stub::Container_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

std::vector<std::string> * Arts::Environment::Container_stub::saveToList()
{
	long methodID = _lookupMethodFast("method:0000000b73617665546f4c69737400000000082a737472696e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	std::vector<std::string> *_returnCode = new std::vector<std::string>;
	if(!result) return _returnCode; // error occurred
	result->readStringSeq(*_returnCode);
	delete result;
	return _returnCode;
}

void Arts::Environment::Container_stub::loadFromList(const std::vector<std::string>& strlist)
{
	long methodID = _lookupMethodFast("method:0000000d6c6f616446726f6d4c6973740000000005766f6964000000000200000001000000082a737472696e6700000000087374726c697374000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeStringSeq(strlist);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

void Arts::Environment::Container_stub::addItem(Arts::Environment::Item item)
{
	long methodID = _lookupMethodFast("method:000000086164644974656d0000000005766f696400000000020000000100000018417274733a3a456e7669726f6e6d656e743a3a4974656d00000000056974656d000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,item._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

Arts::Environment::Item Arts::Environment::Container_stub::createItem(const std::string& name)
{
	long methodID = _lookupMethodFast("method:0000000b6372656174654974656d0000000018417274733a3a456e7669726f6e6d656e743a3a4974656d00000000020000000100000007737472696e6700000000056e616d65000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(name);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if (!result) return Arts::Environment::Item::null();
	Arts::Environment::Item_base* returnCode;
	Arts::readObject(*result,returnCode);
	delete result;
	return Arts::Environment::Item::_from_base(returnCode);
}

void Arts::Environment::Container_stub::removeItem(Arts::Environment::Item item)
{
	long methodID = _lookupMethodFast("method:0000000b72656d6f76654974656d0000000005766f696400000000020000000100000018417274733a3a456e7669726f6e6d656e743a3a4974656d00000000056974656d000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,item._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::Environment::Container_stub::dataDirectory()
{
	long methodID = _lookupMethodFast("method:000000135f6765745f646174614469726563746f72790000000007737472696e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return""; // error occurred
	std::string returnCode;
	result->readString(returnCode);
	delete result;
	return returnCode;
}

void Arts::Environment::Container_stub::dataDirectory(const std::string& newValue)
{
	long methodID = _lookupMethodFast("method:000000135f7365745f646174614469726563746f72790000000005766f696400000000020000000100000007737472696e6700000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

Arts::Environment::Context Arts::Environment::Container_stub::context()
{
	long methodID = _lookupMethodFast("method:0000000d5f6765745f636f6e74657874000000001b417274733a3a456e7669726f6e6d656e743a3a436f6e7465787400000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if (!result) return Arts::Environment::Context::null();
	Arts::Environment::Context_base* returnCode;
	Arts::readObject(*result,returnCode);
	delete result;
	return Arts::Environment::Context::_from_base(returnCode);
}

void Arts::Environment::Container_stub::context(Arts::Environment::Context newValue)
{
	long methodID = _lookupMethodFast("method:0000000d5f7365745f636f6e746578740000000005766f69640000000002000000010000001b417274733a3a456e7669726f6e6d656e743a3a436f6e7465787400000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,newValue._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::vector<Arts::Environment::Item> * Arts::Environment::Container_stub::items()
{
	long methodID = _lookupMethodFast("method:0000000b5f6765745f6974656d7300000000192a417274733a3a456e7669726f6e6d656e743a3a4974656d00000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	std::vector<Arts::Environment::Item> *_returnCode = new std::vector<Arts::Environment::Item>;
	if(!result) return _returnCode; // error occurred
	Arts::readObjectSeq(*result,*_returnCode);
	delete result;
	return _returnCode;
}

std::string Arts::Environment::Container_skel::_interfaceName()
{
	return "Arts::Environment::Container";
}

bool Arts::Environment::Container_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::Environment::Container") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::Environment::Container_skel::_interfaceNameSkel()
{
	return "Arts::Environment::Container";
}

// saveToList
static void _dispatch_Arts__Environment_Container_00(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	std::vector<std::string> *_returnCode = ((Arts::Environment::Container_skel *)object)->saveToList();
	result->writeStringSeq(*_returnCode);
	delete _returnCode;
}

// loadFromList
static void _dispatch_Arts__Environment_Container_01(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::vector<std::string> strlist;
	request->readStringSeq(strlist);
	((Arts::Environment::Container_skel *)object)->loadFromList(strlist);
}

// addItem
static void _dispatch_Arts__Environment_Container_02(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	Arts::Environment::Item_base* _temp_item;
	Arts::readObject(*request,_temp_item);
	Arts::Environment::Item item = Arts::Environment::Item::_from_base(_temp_item);
	((Arts::Environment::Container_skel *)object)->addItem(item);
}

// createItem
static void _dispatch_Arts__Environment_Container_03(void *object, Arts::Buffer *request, Arts::Buffer *result)
{
	std::string name;
	request->readString(name);
	Arts::Environment::Item returnCode = ((Arts::Environment::Container_skel *)object)->createItem(name);
	Arts::writeObject(*result,returnCode._base());
}

// removeItem
static void _dispatch_Arts__Environment_Container_04(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	Arts::Environment::Item_base* _temp_item;
	Arts::readObject(*request,_temp_item);
	Arts::Environment::Item item = Arts::Environment::Item::_from_base(_temp_item);
	((Arts::Environment::Container_skel *)object)->removeItem(item);
}

// _get_dataDirectory
static void _dispatch_Arts__Environment_Container_05(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeString(((Arts::Environment::Container_skel *)object)->dataDirectory());
}

// _set_dataDirectory
static void _dispatch_Arts__Environment_Container_06(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::string newValue;
	request->readString(newValue);
	((Arts::Environment::Container_skel *)object)->dataDirectory(newValue);
}

// _get_context
static void _dispatch_Arts__Environment_Container_07(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	Arts::Environment::Context returnCode = ((Arts::Environment::Container_skel *)object)->context();
	Arts::writeObject(*result,returnCode._base());
}

// _set_context
static void _dispatch_Arts__Environment_Container_08(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	Arts::Environment::Context_base* _temp_newValue;
	Arts::readObject(*request,_temp_newValue);
	Arts::Environment::Context newValue = Arts::Environment::Context::_from_base(_temp_newValue);
	((Arts::Environment::Container_skel *)object)->context(newValue);
}

// _get_items
static void _dispatch_Arts__Environment_Container_09(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	std::vector<Arts::Environment::Item> *_returnCode = ((Arts::Environment::Container_skel *)object)->items();
	Arts::writeObjectSeq(*result,*_returnCode);
	delete _returnCode;
}

void Arts::Environment::Container_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:0000000b73617665546f4c69737400000000082a737472696e6700"
        "0000000200000000000000000000000d6c6f616446726f6d4c6973740000000005"
        "766f6964000000000200000001000000082a737472696e6700000000087374726c"
        "697374000000000000000000000000086164644974656d0000000005766f696400"
        "000000020000000100000018417274733a3a456e7669726f6e6d656e743a3a4974"
        "656d00000000056974656d0000000000000000000000000b637265617465497465"
        "6d0000000018417274733a3a456e7669726f6e6d656e743a3a4974656d00000000"
        "020000000100000007737472696e6700000000056e616d65000000000000000000"
        "0000000b72656d6f76654974656d0000000005766f696400000000020000000100"
        "000018417274733a3a456e7669726f6e6d656e743a3a4974656d00000000056974"
        "656d000000000000000000000000135f6765745f646174614469726563746f7279"
        "0000000007737472696e6700000000020000000000000000000000135f7365745f"
        "646174614469726563746f72790000000005766f69640000000002000000010000"
        "0007737472696e6700000000096e657756616c7565000000000000000000000000"
        "0d5f6765745f636f6e74657874000000001b417274733a3a456e7669726f6e6d65"
        "6e743a3a436f6e74657874000000000200000000000000000000000d5f7365745f"
        "636f6e746578740000000005766f69640000000002000000010000001b41727473"
        "3a3a456e7669726f6e6d656e743a3a436f6e7465787400000000096e657756616c"
        "75650000000000000000000000000b5f6765745f6974656d7300000000192a4172"
        "74733a3a456e7669726f6e6d656e743a3a4974656d000000000200000000000000"
        "00",
		"MethodTable"
	);
	_addMethod(_dispatch_Arts__Environment_Container_00,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Container_01,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Container_02,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Container_03,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Container_04,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Container_05,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Container_06,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Container_07,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Container_08,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Container_09,this,Arts::MethodDef(m));
}

Arts::Environment::Container_skel::Container_skel()
{
}

Arts::Object_base* Arts::Environment::Container::_Creator() {
	return Arts::Environment::Container_base::_create();
}

unsigned long Arts::Environment::Container_base::_IID = Arts::MCOPUtils::makeIID("Arts::Environment::Container");

Arts::Environment::Item_base *Arts::Environment::Item_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::Environment::Item_base *castedObject = (Arts::Environment::Item_base *)skel->_cast(Arts::Environment::Item_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::Environment::Item_base *Arts::Environment::Item_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::Environment::Item_base::_fromReference(r,true);
	return 0;
}

Arts::Environment::Item_base *Arts::Environment::Item_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::Environment::Item_base *castedObject = (Arts::Environment::Item_base *)object._base()->_cast(Arts::Environment::Item_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::Environment::Item_base *Arts::Environment::Item_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::Environment::Item_base *result;
	result = (Arts::Environment::Item_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::Environment::Item");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::Environment::Item_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::Environment::Item")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::Environment::Item_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::Environment::Item_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::Environment::Item_base::_cast(unsigned long iid)
{
	if(iid == Arts::Environment::Item_base::_IID) return (Arts::Environment::Item_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::Environment::Item_stub::Item_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::Environment::Item_stub::Item_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

void Arts::Environment::Item_stub::setContainer(Arts::Environment::Container container)
{
	long methodID = _lookupMethodFast("method:0000000d736574436f6e7461696e65720000000005766f69640000000002000000010000001d417274733a3a456e7669726f6e6d656e743a3a436f6e7461696e6572000000000a636f6e7461696e6572000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,container._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::vector<std::string> * Arts::Environment::Item_stub::saveToList()
{
	long methodID = _lookupMethodFast("method:0000000b73617665546f4c69737400000000082a737472696e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	std::vector<std::string> *_returnCode = new std::vector<std::string>;
	if(!result) return _returnCode; // error occurred
	result->readStringSeq(*_returnCode);
	delete result;
	return _returnCode;
}

void Arts::Environment::Item_stub::loadFromList(const std::vector<std::string>& strlist)
{
	long methodID = _lookupMethodFast("method:0000000d6c6f616446726f6d4c6973740000000005766f6964000000000200000001000000082a737472696e6700000000087374726c697374000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeStringSeq(strlist);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

bool Arts::Environment::Item_stub::active()
{
	long methodID = _lookupMethodFast("method:0000000c5f6765745f6163746976650000000008626f6f6c65616e00000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return false; // error occurred
	bool returnCode = result->readBool();
	delete result;
	return returnCode;
}

Arts::Environment::Container Arts::Environment::Item_stub::parent()
{
	long methodID = _lookupMethodFast("method:0000000c5f6765745f706172656e74000000001d417274733a3a456e7669726f6e6d656e743a3a436f6e7461696e657200000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if (!result) return Arts::Environment::Container::null();
	Arts::Environment::Container_base* returnCode;
	Arts::readObject(*result,returnCode);
	delete result;
	return Arts::Environment::Container::_from_base(returnCode);
}

std::string Arts::Environment::Item_skel::_interfaceName()
{
	return "Arts::Environment::Item";
}

bool Arts::Environment::Item_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::Environment::Item") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::Environment::Item_skel::_interfaceNameSkel()
{
	return "Arts::Environment::Item";
}

// setContainer
static void _dispatch_Arts__Environment_Item_00(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	Arts::Environment::Container_base* _temp_container;
	Arts::readObject(*request,_temp_container);
	Arts::Environment::Container container = Arts::Environment::Container::_from_base(_temp_container);
	((Arts::Environment::Item_skel *)object)->setContainer(container);
}

// saveToList
static void _dispatch_Arts__Environment_Item_01(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	std::vector<std::string> *_returnCode = ((Arts::Environment::Item_skel *)object)->saveToList();
	result->writeStringSeq(*_returnCode);
	delete _returnCode;
}

// loadFromList
static void _dispatch_Arts__Environment_Item_02(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::vector<std::string> strlist;
	request->readStringSeq(strlist);
	((Arts::Environment::Item_skel *)object)->loadFromList(strlist);
}

// _get_active
static void _dispatch_Arts__Environment_Item_03(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeBool(((Arts::Environment::Item_skel *)object)->active());
}

// _get_parent
static void _dispatch_Arts__Environment_Item_04(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	Arts::Environment::Container returnCode = ((Arts::Environment::Item_skel *)object)->parent();
	Arts::writeObject(*result,returnCode._base());
}

void Arts::Environment::Item_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:0000000d736574436f6e7461696e65720000000005766f69640000"
        "000002000000010000001d417274733a3a456e7669726f6e6d656e743a3a436f6e"
        "7461696e6572000000000a636f6e7461696e65720000000000000000000000000b"
        "73617665546f4c69737400000000082a737472696e670000000002000000000000"
        "00000000000d6c6f616446726f6d4c6973740000000005766f6964000000000200"
        "000001000000082a737472696e6700000000087374726c69737400000000000000"
        "00000000000c5f6765745f6163746976650000000008626f6f6c65616e00000000"
        "0200000000000000000000000c5f6765745f706172656e74000000001d41727473"
        "3a3a456e7669726f6e6d656e743a3a436f6e7461696e6572000000000200000000"
        "00000000",
		"MethodTable"
	);
	_addMethod(_dispatch_Arts__Environment_Item_00,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Item_01,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Item_02,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Item_03,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_Item_04,this,Arts::MethodDef(m));
}

Arts::Environment::Item_skel::Item_skel()
{
}

Arts::Object_base* Arts::Environment::Item::_Creator() {
	return Arts::Environment::Item_base::_create();
}

unsigned long Arts::Environment::Item_base::_IID = Arts::MCOPUtils::makeIID("Arts::Environment::Item");

Arts::Environment::InstrumentItem_base *Arts::Environment::InstrumentItem_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::Environment::InstrumentItem_base *castedObject = (Arts::Environment::InstrumentItem_base *)skel->_cast(Arts::Environment::InstrumentItem_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::Environment::InstrumentItem_base *Arts::Environment::InstrumentItem_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::Environment::InstrumentItem_base::_fromReference(r,true);
	return 0;
}

Arts::Environment::InstrumentItem_base *Arts::Environment::InstrumentItem_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::Environment::InstrumentItem_base *castedObject = (Arts::Environment::InstrumentItem_base *)object._base()->_cast(Arts::Environment::InstrumentItem_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::Environment::InstrumentItem_base *Arts::Environment::InstrumentItem_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::Environment::InstrumentItem_base *result;
	result = (Arts::Environment::InstrumentItem_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::Environment::InstrumentItem");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::Environment::InstrumentItem_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::Environment::InstrumentItem")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::Environment::InstrumentItem_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::Environment::InstrumentItem_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::Environment::InstrumentItem_base::_cast(unsigned long iid)
{
	if(iid == Arts::Environment::InstrumentItem_base::_IID) return (Arts::Environment::InstrumentItem_base *)this;
	if(iid == Arts::Environment::Item_base::_IID) return (Arts::Environment::Item_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::Environment::InstrumentItem_stub::InstrumentItem_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::Environment::InstrumentItem_stub::InstrumentItem_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

Arts::MidiPort Arts::Environment::InstrumentItem_stub::port()
{
	long methodID = _lookupMethodFast("method:0000000a5f6765745f706f7274000000000f417274733a3a4d696469506f727400000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if (!result) return Arts::MidiPort::null();
	Arts::MidiPort_base* returnCode;
	Arts::readObject(*result,returnCode);
	delete result;
	return Arts::MidiPort::_from_base(returnCode);
}

std::string Arts::Environment::InstrumentItem_stub::filename()
{
	long methodID = _lookupMethodFast("method:0000000e5f6765745f66696c656e616d650000000007737472696e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return""; // error occurred
	std::string returnCode;
	result->readString(returnCode);
	delete result;
	return returnCode;
}

void Arts::Environment::InstrumentItem_stub::filename(const std::string& newValue)
{
	long methodID = _lookupMethodFast("method:0000000e5f7365745f66696c656e616d650000000005766f696400000000020000000100000007737472696e6700000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::Environment::InstrumentItem_stub::busname()
{
	long methodID = _lookupMethodFast("method:0000000d5f6765745f6275736e616d650000000007737472696e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return""; // error occurred
	std::string returnCode;
	result->readString(returnCode);
	delete result;
	return returnCode;
}

void Arts::Environment::InstrumentItem_stub::busname(const std::string& newValue)
{
	long methodID = _lookupMethodFast("method:0000000d5f7365745f6275736e616d650000000005766f696400000000020000000100000007737472696e6700000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::Environment::InstrumentItem_skel::_interfaceName()
{
	return "Arts::Environment::InstrumentItem";
}

bool Arts::Environment::InstrumentItem_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::Environment::InstrumentItem") return true;
	if (interfacename == "Arts::Environment::Item") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::Environment::InstrumentItem_skel::_interfaceNameSkel()
{
	return "Arts::Environment::InstrumentItem";
}

// _get_port
static void _dispatch_Arts__Environment_InstrumentItem_00(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	Arts::MidiPort returnCode = ((Arts::Environment::InstrumentItem_skel *)object)->port();
	Arts::writeObject(*result,returnCode._base());
}

// _get_filename
static void _dispatch_Arts__Environment_InstrumentItem_01(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeString(((Arts::Environment::InstrumentItem_skel *)object)->filename());
}

// _set_filename
static void _dispatch_Arts__Environment_InstrumentItem_02(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::string newValue;
	request->readString(newValue);
	((Arts::Environment::InstrumentItem_skel *)object)->filename(newValue);
}

// _get_busname
static void _dispatch_Arts__Environment_InstrumentItem_03(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeString(((Arts::Environment::InstrumentItem_skel *)object)->busname());
}

// _set_busname
static void _dispatch_Arts__Environment_InstrumentItem_04(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::string newValue;
	request->readString(newValue);
	((Arts::Environment::InstrumentItem_skel *)object)->busname(newValue);
}

void Arts::Environment::InstrumentItem_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:0000000a5f6765745f706f7274000000000f417274733a3a4d6964"
        "69506f7274000000000200000000000000000000000e5f6765745f66696c656e61"
        "6d650000000007737472696e67000000000200000000000000000000000e5f7365"
        "745f66696c656e616d650000000005766f69640000000002000000010000000773"
        "7472696e6700000000096e657756616c75650000000000000000000000000d5f67"
        "65745f6275736e616d650000000007737472696e67000000000200000000000000"
        "000000000d5f7365745f6275736e616d650000000005766f696400000000020000"
        "000100000007737472696e6700000000096e657756616c75650000000000000000"
        "00",
		"MethodTable"
	);
	_addMethod(_dispatch_Arts__Environment_InstrumentItem_00,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_InstrumentItem_01,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_InstrumentItem_02,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_InstrumentItem_03,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_InstrumentItem_04,this,Arts::MethodDef(m));
	Arts::Environment::Item_skel::_buildMethodTable();
}

Arts::Environment::InstrumentItem_skel::InstrumentItem_skel()
{
}

Arts::Object_base* Arts::Environment::InstrumentItem::_Creator() {
	return Arts::Environment::InstrumentItem_base::_create();
}

unsigned long Arts::Environment::InstrumentItem_base::_IID = Arts::MCOPUtils::makeIID("Arts::Environment::InstrumentItem");

Arts::Environment::InstrumentItemGuiFactory_base *Arts::Environment::InstrumentItemGuiFactory_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::Environment::InstrumentItemGuiFactory_base *castedObject = (Arts::Environment::InstrumentItemGuiFactory_base *)skel->_cast(Arts::Environment::InstrumentItemGuiFactory_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::Environment::InstrumentItemGuiFactory_base *Arts::Environment::InstrumentItemGuiFactory_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::Environment::InstrumentItemGuiFactory_base::_fromReference(r,true);
	return 0;
}

Arts::Environment::InstrumentItemGuiFactory_base *Arts::Environment::InstrumentItemGuiFactory_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::Environment::InstrumentItemGuiFactory_base *castedObject = (Arts::Environment::InstrumentItemGuiFactory_base *)object._base()->_cast(Arts::Environment::InstrumentItemGuiFactory_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::Environment::InstrumentItemGuiFactory_base *Arts::Environment::InstrumentItemGuiFactory_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::Environment::InstrumentItemGuiFactory_base *result;
	result = (Arts::Environment::InstrumentItemGuiFactory_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::Environment::InstrumentItemGuiFactory");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::Environment::InstrumentItemGuiFactory_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::Environment::InstrumentItemGuiFactory")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::Environment::InstrumentItemGuiFactory_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::Environment::InstrumentItemGuiFactory_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::Environment::InstrumentItemGuiFactory_base::_cast(unsigned long iid)
{
	if(iid == Arts::Environment::InstrumentItemGuiFactory_base::_IID) return (Arts::Environment::InstrumentItemGuiFactory_base *)this;
	if(iid == Arts::GuiFactory_base::_IID) return (Arts::GuiFactory_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::Environment::InstrumentItemGuiFactory_stub::InstrumentItemGuiFactory_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::Environment::InstrumentItemGuiFactory_stub::InstrumentItemGuiFactory_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

std::string Arts::Environment::InstrumentItemGuiFactory_skel::_interfaceName()
{
	return "Arts::Environment::InstrumentItemGuiFactory";
}

bool Arts::Environment::InstrumentItemGuiFactory_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::Environment::InstrumentItemGuiFactory") return true;
	if (interfacename == "Arts::GuiFactory") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::Environment::InstrumentItemGuiFactory_skel::_interfaceNameSkel()
{
	return "Arts::Environment::InstrumentItemGuiFactory";
}

void Arts::Environment::InstrumentItemGuiFactory_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:",
		"MethodTable"
	);
	Arts::GuiFactory_skel::_buildMethodTable();
}

Arts::Environment::InstrumentItemGuiFactory_skel::InstrumentItemGuiFactory_skel()
{
}

Arts::Object_base* Arts::Environment::InstrumentItemGuiFactory::_Creator() {
	return Arts::Environment::InstrumentItemGuiFactory_base::_create();
}

unsigned long Arts::Environment::InstrumentItemGuiFactory_base::_IID = Arts::MCOPUtils::makeIID("Arts::Environment::InstrumentItemGuiFactory");

Arts::Environment::StereoEffectItem_base *Arts::Environment::StereoEffectItem_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::Environment::StereoEffectItem_base *castedObject = (Arts::Environment::StereoEffectItem_base *)skel->_cast(Arts::Environment::StereoEffectItem_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::Environment::StereoEffectItem_base *Arts::Environment::StereoEffectItem_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::Environment::StereoEffectItem_base::_fromReference(r,true);
	return 0;
}

Arts::Environment::StereoEffectItem_base *Arts::Environment::StereoEffectItem_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::Environment::StereoEffectItem_base *castedObject = (Arts::Environment::StereoEffectItem_base *)object._base()->_cast(Arts::Environment::StereoEffectItem_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::Environment::StereoEffectItem_base *Arts::Environment::StereoEffectItem_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::Environment::StereoEffectItem_base *result;
	result = (Arts::Environment::StereoEffectItem_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::Environment::StereoEffectItem");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::Environment::StereoEffectItem_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::Environment::StereoEffectItem")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::Environment::StereoEffectItem_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::Environment::StereoEffectItem_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::Environment::StereoEffectItem_base::_cast(unsigned long iid)
{
	if(iid == Arts::Environment::StereoEffectItem_base::_IID) return (Arts::Environment::StereoEffectItem_base *)this;
	if(iid == Arts::Environment::Item_base::_IID) return (Arts::Environment::Item_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::Environment::StereoEffectItem_stub::StereoEffectItem_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::Environment::StereoEffectItem_stub::StereoEffectItem_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

Arts::SynthModule Arts::Environment::StereoEffectItem_stub::effect()
{
	long methodID = _lookupMethodFast("method:0000000c5f6765745f6566666563740000000012417274733a3a53796e74684d6f64756c6500000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if (!result) return Arts::SynthModule::null();
	Arts::SynthModule_base* returnCode;
	Arts::readObject(*result,returnCode);
	delete result;
	return Arts::SynthModule::_from_base(returnCode);
}

void Arts::Environment::StereoEffectItem_stub::effect(Arts::SynthModule newValue)
{
	long methodID = _lookupMethodFast("method:0000000c5f7365745f6566666563740000000005766f696400000000020000000100000012417274733a3a53796e74684d6f64756c6500000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,newValue._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

Arts::StereoEffectStack Arts::Environment::StereoEffectItem_stub::stack()
{
	long methodID = _lookupMethodFast("method:0000000b5f6765745f737461636b0000000018417274733a3a53746572656f456666656374537461636b00000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if (!result) return Arts::StereoEffectStack::null();
	Arts::StereoEffectStack_base* returnCode;
	Arts::readObject(*result,returnCode);
	delete result;
	return Arts::StereoEffectStack::_from_base(returnCode);
}

void Arts::Environment::StereoEffectItem_stub::stack(Arts::StereoEffectStack newValue)
{
	long methodID = _lookupMethodFast("method:0000000b5f7365745f737461636b0000000005766f696400000000020000000100000018417274733a3a53746572656f456666656374537461636b00000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,newValue._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::Environment::StereoEffectItem_skel::_interfaceName()
{
	return "Arts::Environment::StereoEffectItem";
}

bool Arts::Environment::StereoEffectItem_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::Environment::StereoEffectItem") return true;
	if (interfacename == "Arts::Environment::Item") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::Environment::StereoEffectItem_skel::_interfaceNameSkel()
{
	return "Arts::Environment::StereoEffectItem";
}

// _get_effect
static void _dispatch_Arts__Environment_StereoEffectItem_00(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	Arts::SynthModule returnCode = ((Arts::Environment::StereoEffectItem_skel *)object)->effect();
	Arts::writeObject(*result,returnCode._base());
}

// _set_effect
static void _dispatch_Arts__Environment_StereoEffectItem_01(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	Arts::SynthModule_base* _temp_newValue;
	Arts::readObject(*request,_temp_newValue);
	Arts::SynthModule newValue = Arts::SynthModule::_from_base(_temp_newValue);
	((Arts::Environment::StereoEffectItem_skel *)object)->effect(newValue);
}

// _get_stack
static void _dispatch_Arts__Environment_StereoEffectItem_02(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	Arts::StereoEffectStack returnCode = ((Arts::Environment::StereoEffectItem_skel *)object)->stack();
	Arts::writeObject(*result,returnCode._base());
}

// _set_stack
static void _dispatch_Arts__Environment_StereoEffectItem_03(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	Arts::StereoEffectStack_base* _temp_newValue;
	Arts::readObject(*request,_temp_newValue);
	Arts::StereoEffectStack newValue = Arts::StereoEffectStack::_from_base(_temp_newValue);
	((Arts::Environment::StereoEffectItem_skel *)object)->stack(newValue);
}

void Arts::Environment::StereoEffectItem_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:0000000c5f6765745f6566666563740000000012417274733a3a53"
        "796e74684d6f64756c65000000000200000000000000000000000c5f7365745f65"
        "66666563740000000005766f696400000000020000000100000012417274733a3a"
        "53796e74684d6f64756c6500000000096e657756616c7565000000000000000000"
        "0000000b5f6765745f737461636b0000000018417274733a3a53746572656f4566"
        "66656374537461636b000000000200000000000000000000000b5f7365745f7374"
        "61636b0000000005766f696400000000020000000100000018417274733a3a5374"
        "6572656f456666656374537461636b00000000096e657756616c75650000000000"
        "00000000",
		"MethodTable"
	);
	_addMethod(_dispatch_Arts__Environment_StereoEffectItem_00,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_StereoEffectItem_01,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_StereoEffectItem_02,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_StereoEffectItem_03,this,Arts::MethodDef(m));
	Arts::Environment::Item_skel::_buildMethodTable();
}

Arts::Environment::StereoEffectItem_skel::StereoEffectItem_skel()
{
}

Arts::Object_base* Arts::Environment::StereoEffectItem::_Creator() {
	return Arts::Environment::StereoEffectItem_base::_create();
}

unsigned long Arts::Environment::StereoEffectItem_base::_IID = Arts::MCOPUtils::makeIID("Arts::Environment::StereoEffectItem");

Arts::Environment::MixerChannel_base *Arts::Environment::MixerChannel_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::Environment::MixerChannel_base *castedObject = (Arts::Environment::MixerChannel_base *)skel->_cast(Arts::Environment::MixerChannel_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::Environment::MixerChannel_base *Arts::Environment::MixerChannel_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::Environment::MixerChannel_base::_fromReference(r,true);
	return 0;
}

Arts::Environment::MixerChannel_base *Arts::Environment::MixerChannel_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::Environment::MixerChannel_base *castedObject = (Arts::Environment::MixerChannel_base *)object._base()->_cast(Arts::Environment::MixerChannel_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::Environment::MixerChannel_base *Arts::Environment::MixerChannel_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::Environment::MixerChannel_base *result;
	result = (Arts::Environment::MixerChannel_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::Environment::MixerChannel");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::Environment::MixerChannel_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::Environment::MixerChannel")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::Environment::MixerChannel_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	ret.push_back("inleft");
	ret.push_back("inright");
	return ret;
}
std::vector<std::string> Arts::Environment::MixerChannel_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	ret.push_back("outleft");
	ret.push_back("outright");
	return ret;
}

void *Arts::Environment::MixerChannel_base::_cast(unsigned long iid)
{
	if(iid == Arts::Environment::MixerChannel_base::_IID) return (Arts::Environment::MixerChannel_base *)this;
	if(iid == Arts::StereoEffect_base::_IID) return (Arts::StereoEffect_base *)this;
	if(iid == Arts::SynthModule_base::_IID) return (Arts::SynthModule_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::Environment::MixerChannel_stub::MixerChannel_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::Environment::MixerChannel_stub::MixerChannel_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

std::string Arts::Environment::MixerChannel_stub::name()
{
	long methodID = _lookupMethodFast("method:0000000a5f6765745f6e616d650000000007737472696e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return""; // error occurred
	std::string returnCode;
	result->readString(returnCode);
	delete result;
	return returnCode;
}

void Arts::Environment::MixerChannel_stub::name(const std::string& newValue)
{
	long methodID = _lookupMethodFast("method:0000000a5f7365745f6e616d650000000005766f696400000000020000000100000007737472696e6700000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::Environment::MixerChannel_skel::_interfaceName()
{
	return "Arts::Environment::MixerChannel";
}

bool Arts::Environment::MixerChannel_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::Environment::MixerChannel") return true;
	if (interfacename == "Arts::StereoEffect") return true;
	if (interfacename == "Arts::SynthModule") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::Environment::MixerChannel_skel::_interfaceNameSkel()
{
	return "Arts::Environment::MixerChannel";
}

// _get_name
static void _dispatch_Arts__Environment_MixerChannel_00(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeString(((Arts::Environment::MixerChannel_skel *)object)->name());
}

// _set_name
static void _dispatch_Arts__Environment_MixerChannel_01(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::string newValue;
	request->readString(newValue);
	((Arts::Environment::MixerChannel_skel *)object)->name(newValue);
}

void Arts::Environment::MixerChannel_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:0000000a5f6765745f6e616d650000000007737472696e67000000"
        "000200000000000000000000000a5f7365745f6e616d650000000005766f696400"
        "000000020000000100000007737472696e6700000000096e657756616c75650000"
        "00000000000000",
		"MethodTable"
	);
	_addMethod(_dispatch_Arts__Environment_MixerChannel_00,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_MixerChannel_01,this,Arts::MethodDef(m));
	Arts::StereoEffect_skel::_buildMethodTable();
}

Arts::Environment::MixerChannel_skel::MixerChannel_skel()
{
}

Arts::Object_base* Arts::Environment::MixerChannel::_Creator() {
	return Arts::Environment::MixerChannel_base::_create();
}

unsigned long Arts::Environment::MixerChannel_base::_IID = Arts::MCOPUtils::makeIID("Arts::Environment::MixerChannel");

Arts::Environment::MixerItem_base *Arts::Environment::MixerItem_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::Environment::MixerItem_base *castedObject = (Arts::Environment::MixerItem_base *)skel->_cast(Arts::Environment::MixerItem_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::Environment::MixerItem_base *Arts::Environment::MixerItem_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::Environment::MixerItem_base::_fromReference(r,true);
	return 0;
}

Arts::Environment::MixerItem_base *Arts::Environment::MixerItem_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::Environment::MixerItem_base *castedObject = (Arts::Environment::MixerItem_base *)object._base()->_cast(Arts::Environment::MixerItem_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::Environment::MixerItem_base *Arts::Environment::MixerItem_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::Environment::MixerItem_base *result;
	result = (Arts::Environment::MixerItem_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::Environment::MixerItem");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::Environment::MixerItem_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::Environment::MixerItem")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::Environment::MixerItem_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::Environment::MixerItem_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::Environment::MixerItem_base::_cast(unsigned long iid)
{
	if(iid == Arts::Environment::MixerItem_base::_IID) return (Arts::Environment::MixerItem_base *)this;
	if(iid == Arts::Environment::Item_base::_IID) return (Arts::Environment::Item_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::Environment::MixerItem_stub::MixerItem_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::Environment::MixerItem_stub::MixerItem_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

std::vector<Arts::Environment::MixerChannel> * Arts::Environment::MixerItem_stub::channels()
{
	long methodID = _lookupMethodFast("method:0000000e5f6765745f6368616e6e656c7300000000212a417274733a3a456e7669726f6e6d656e743a3a4d697865724368616e6e656c00000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	std::vector<Arts::Environment::MixerChannel> *_returnCode = new std::vector<Arts::Environment::MixerChannel>;
	if(!result) return _returnCode; // error occurred
	Arts::readObjectSeq(*result,*_returnCode);
	delete result;
	return _returnCode;
}

long Arts::Environment::MixerItem_stub::channelCount()
{
	long methodID = _lookupMethodFast("method:000000125f6765745f6368616e6e656c436f756e7400000000056c6f6e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return 0; // error occurred
	long returnCode = result->readLong();
	delete result;
	return returnCode;
}

void Arts::Environment::MixerItem_stub::channelCount(long newValue)
{
	long methodID = _lookupMethodFast("method:000000125f7365745f6368616e6e656c436f756e740000000005766f6964000000000200000001000000056c6f6e6700000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeLong(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::Environment::MixerItem_stub::name()
{
	long methodID = _lookupMethodFast("method:0000000a5f6765745f6e616d650000000007737472696e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return""; // error occurred
	std::string returnCode;
	result->readString(returnCode);
	delete result;
	return returnCode;
}

void Arts::Environment::MixerItem_stub::name(const std::string& newValue)
{
	long methodID = _lookupMethodFast("method:0000000a5f7365745f6e616d650000000005766f696400000000020000000100000007737472696e6700000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::Environment::MixerItem_stub::type()
{
	long methodID = _lookupMethodFast("method:0000000a5f6765745f747970650000000007737472696e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return""; // error occurred
	std::string returnCode;
	result->readString(returnCode);
	delete result;
	return returnCode;
}

void Arts::Environment::MixerItem_stub::type(const std::string& newValue)
{
	long methodID = _lookupMethodFast("method:0000000a5f7365745f747970650000000005766f696400000000020000000100000007737472696e6700000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::Environment::MixerItem_skel::_interfaceName()
{
	return "Arts::Environment::MixerItem";
}

bool Arts::Environment::MixerItem_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::Environment::MixerItem") return true;
	if (interfacename == "Arts::Environment::Item") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::Environment::MixerItem_skel::_interfaceNameSkel()
{
	return "Arts::Environment::MixerItem";
}

// _get_channels
static void _dispatch_Arts__Environment_MixerItem_00(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	std::vector<Arts::Environment::MixerChannel> *_returnCode = ((Arts::Environment::MixerItem_skel *)object)->channels();
	Arts::writeObjectSeq(*result,*_returnCode);
	delete _returnCode;
}

// _get_channelCount
static void _dispatch_Arts__Environment_MixerItem_01(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeLong(((Arts::Environment::MixerItem_skel *)object)->channelCount());
}

// _set_channelCount
static void _dispatch_Arts__Environment_MixerItem_02(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	long newValue = request->readLong();
	((Arts::Environment::MixerItem_skel *)object)->channelCount(newValue);
}

// _get_name
static void _dispatch_Arts__Environment_MixerItem_03(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeString(((Arts::Environment::MixerItem_skel *)object)->name());
}

// _set_name
static void _dispatch_Arts__Environment_MixerItem_04(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::string newValue;
	request->readString(newValue);
	((Arts::Environment::MixerItem_skel *)object)->name(newValue);
}

// _get_type
static void _dispatch_Arts__Environment_MixerItem_05(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeString(((Arts::Environment::MixerItem_skel *)object)->type());
}

// _set_type
static void _dispatch_Arts__Environment_MixerItem_06(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::string newValue;
	request->readString(newValue);
	((Arts::Environment::MixerItem_skel *)object)->type(newValue);
}

void Arts::Environment::MixerItem_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:0000000e5f6765745f6368616e6e656c7300000000212a41727473"
        "3a3a456e7669726f6e6d656e743a3a4d697865724368616e6e656c000000000200"
        "00000000000000000000125f6765745f6368616e6e656c436f756e740000000005"
        "6c6f6e6700000000020000000000000000000000125f7365745f6368616e6e656c"
        "436f756e740000000005766f6964000000000200000001000000056c6f6e670000"
        "0000096e657756616c75650000000000000000000000000a5f6765745f6e616d65"
        "0000000007737472696e67000000000200000000000000000000000a5f7365745f"
        "6e616d650000000005766f696400000000020000000100000007737472696e6700"
        "000000096e657756616c75650000000000000000000000000a5f6765745f747970"
        "650000000007737472696e67000000000200000000000000000000000a5f736574"
        "5f747970650000000005766f696400000000020000000100000007737472696e67"
        "00000000096e657756616c7565000000000000000000",
		"MethodTable"
	);
	_addMethod(_dispatch_Arts__Environment_MixerItem_00,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_MixerItem_01,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_MixerItem_02,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_MixerItem_03,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_MixerItem_04,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_MixerItem_05,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_MixerItem_06,this,Arts::MethodDef(m));
	Arts::Environment::Item_skel::_buildMethodTable();
}

Arts::Environment::MixerItem_skel::MixerItem_skel()
{
}

Arts::Object_base* Arts::Environment::MixerItem::_Creator() {
	return Arts::Environment::MixerItem_base::_create();
}

unsigned long Arts::Environment::MixerItem_base::_IID = Arts::MCOPUtils::makeIID("Arts::Environment::MixerItem");

Arts::Environment::EffectRackItem_base *Arts::Environment::EffectRackItem_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::Environment::EffectRackItem_base *castedObject = (Arts::Environment::EffectRackItem_base *)skel->_cast(Arts::Environment::EffectRackItem_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::Environment::EffectRackItem_base *Arts::Environment::EffectRackItem_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::Environment::EffectRackItem_base::_fromReference(r,true);
	return 0;
}

Arts::Environment::EffectRackItem_base *Arts::Environment::EffectRackItem_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::Environment::EffectRackItem_base *castedObject = (Arts::Environment::EffectRackItem_base *)object._base()->_cast(Arts::Environment::EffectRackItem_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::Environment::EffectRackItem_base *Arts::Environment::EffectRackItem_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::Environment::EffectRackItem_base *result;
	result = (Arts::Environment::EffectRackItem_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::Environment::EffectRackItem");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::Environment::EffectRackItem_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::Environment::EffectRackItem")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::Environment::EffectRackItem_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::Environment::EffectRackItem_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::Environment::EffectRackItem_base::_cast(unsigned long iid)
{
	if(iid == Arts::Environment::EffectRackItem_base::_IID) return (Arts::Environment::EffectRackItem_base *)this;
	if(iid == Arts::Environment::Item_base::_IID) return (Arts::Environment::Item_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::Environment::EffectRackItem_stub::EffectRackItem_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::Environment::EffectRackItem_stub::EffectRackItem_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

Arts::StereoEffect Arts::Environment::EffectRackItem_stub::createEffect(const std::string& type, const std::string& name)
{
	long methodID = _lookupMethodFast("method:0000000d6372656174654566666563740000000013417274733a3a53746572656f45666665637400000000020000000200000007737472696e67000000000574797065000000000000000007737472696e6700000000056e616d65000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(type);
	request->writeString(name);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if (!result) return Arts::StereoEffect::null();
	Arts::StereoEffect_base* returnCode;
	Arts::readObject(*result,returnCode);
	delete result;
	return Arts::StereoEffect::_from_base(returnCode);
}

void Arts::Environment::EffectRackItem_stub::delEffect(long pos)
{
	long methodID = _lookupMethodFast("method:0000000a64656c4566666563740000000005766f6964000000000200000001000000056c6f6e670000000004706f73000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeLong(pos);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

void Arts::Environment::EffectRackItem_stub::routeToMaster(long pos, bool tomaster)
{
	long methodID = _lookupMethodFast("method:0000000e726f757465546f4d61737465720000000005766f6964000000000200000002000000056c6f6e670000000004706f73000000000000000008626f6f6c65616e0000000009746f6d6173746572000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeLong(pos);
	request->writeBool(tomaster);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::vector<Arts::StereoEffect> * Arts::Environment::EffectRackItem_stub::effects()
{
	long methodID = _lookupMethodFast("method:0000000d5f6765745f6566666563747300000000142a417274733a3a53746572656f45666665637400000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	std::vector<Arts::StereoEffect> *_returnCode = new std::vector<Arts::StereoEffect>;
	if(!result) return _returnCode; // error occurred
	Arts::readObjectSeq(*result,*_returnCode);
	delete result;
	return _returnCode;
}

long Arts::Environment::EffectRackItem_stub::effectCount()
{
	long methodID = _lookupMethodFast("method:000000115f6765745f656666656374436f756e7400000000056c6f6e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return 0; // error occurred
	long returnCode = result->readLong();
	delete result;
	return returnCode;
}

std::string Arts::Environment::EffectRackItem_stub::name()
{
	long methodID = _lookupMethodFast("method:0000000a5f6765745f6e616d650000000007737472696e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return""; // error occurred
	std::string returnCode;
	result->readString(returnCode);
	delete result;
	return returnCode;
}

void Arts::Environment::EffectRackItem_stub::name(const std::string& newValue)
{
	long methodID = _lookupMethodFast("method:0000000a5f7365745f6e616d650000000005766f696400000000020000000100000007737472696e6700000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::Environment::EffectRackItem_skel::_interfaceName()
{
	return "Arts::Environment::EffectRackItem";
}

bool Arts::Environment::EffectRackItem_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::Environment::EffectRackItem") return true;
	if (interfacename == "Arts::Environment::Item") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::Environment::EffectRackItem_skel::_interfaceNameSkel()
{
	return "Arts::Environment::EffectRackItem";
}

// createEffect
static void _dispatch_Arts__Environment_EffectRackItem_00(void *object, Arts::Buffer *request, Arts::Buffer *result)
{
	std::string type;
	request->readString(type);
	std::string name;
	request->readString(name);
	Arts::StereoEffect returnCode = ((Arts::Environment::EffectRackItem_skel *)object)->createEffect(type,name);
	Arts::writeObject(*result,returnCode._base());
}

// delEffect
static void _dispatch_Arts__Environment_EffectRackItem_01(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	long pos = request->readLong();
	((Arts::Environment::EffectRackItem_skel *)object)->delEffect(pos);
}

// routeToMaster
static void _dispatch_Arts__Environment_EffectRackItem_02(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	long pos = request->readLong();
	bool tomaster = request->readBool();
	((Arts::Environment::EffectRackItem_skel *)object)->routeToMaster(pos,tomaster);
}

// _get_effects
static void _dispatch_Arts__Environment_EffectRackItem_03(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	std::vector<Arts::StereoEffect> *_returnCode = ((Arts::Environment::EffectRackItem_skel *)object)->effects();
	Arts::writeObjectSeq(*result,*_returnCode);
	delete _returnCode;
}

// _get_effectCount
static void _dispatch_Arts__Environment_EffectRackItem_04(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeLong(((Arts::Environment::EffectRackItem_skel *)object)->effectCount());
}

// _get_name
static void _dispatch_Arts__Environment_EffectRackItem_05(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeString(((Arts::Environment::EffectRackItem_skel *)object)->name());
}

// _set_name
static void _dispatch_Arts__Environment_EffectRackItem_06(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::string newValue;
	request->readString(newValue);
	((Arts::Environment::EffectRackItem_skel *)object)->name(newValue);
}

void Arts::Environment::EffectRackItem_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:0000000d6372656174654566666563740000000013417274733a3a"
        "53746572656f45666665637400000000020000000200000007737472696e670000"
        "00000574797065000000000000000007737472696e6700000000056e616d650000"
        "000000000000000000000a64656c4566666563740000000005766f696400000000"
        "0200000001000000056c6f6e670000000004706f73000000000000000000000000"
        "0e726f757465546f4d61737465720000000005766f696400000000020000000200"
        "0000056c6f6e670000000004706f73000000000000000008626f6f6c65616e0000"
        "000009746f6d61737465720000000000000000000000000d5f6765745f65666665"
        "63747300000000142a417274733a3a53746572656f456666656374000000000200"
        "00000000000000000000115f6765745f656666656374436f756e7400000000056c"
        "6f6e67000000000200000000000000000000000a5f6765745f6e616d6500000000"
        "07737472696e67000000000200000000000000000000000a5f7365745f6e616d65"
        "0000000005766f696400000000020000000100000007737472696e670000000009"
        "6e657756616c7565000000000000000000",
		"MethodTable"
	);
	_addMethod(_dispatch_Arts__Environment_EffectRackItem_00,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_EffectRackItem_01,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_EffectRackItem_02,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_EffectRackItem_03,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_EffectRackItem_04,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_EffectRackItem_05,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts__Environment_EffectRackItem_06,this,Arts::MethodDef(m));
	Arts::Environment::Item_skel::_buildMethodTable();
}

Arts::Environment::EffectRackItem_skel::EffectRackItem_skel()
{
}

Arts::Object_base* Arts::Environment::EffectRackItem::_Creator() {
	return Arts::Environment::EffectRackItem_base::_create();
}

unsigned long Arts::Environment::EffectRackItem_base::_IID = Arts::MCOPUtils::makeIID("Arts::Environment::EffectRackItem");

Arts::MixerItemGui_base *Arts::MixerItemGui_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::MixerItemGui_base *castedObject = (Arts::MixerItemGui_base *)skel->_cast(Arts::MixerItemGui_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::MixerItemGui_base *Arts::MixerItemGui_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::MixerItemGui_base::_fromReference(r,true);
	return 0;
}

Arts::MixerItemGui_base *Arts::MixerItemGui_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::MixerItemGui_base *castedObject = (Arts::MixerItemGui_base *)object._base()->_cast(Arts::MixerItemGui_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::MixerItemGui_base *Arts::MixerItemGui_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::MixerItemGui_base *result;
	result = (Arts::MixerItemGui_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::MixerItemGui");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::MixerItemGui_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::MixerItemGui")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::MixerItemGui_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::MixerItemGui_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::MixerItemGui_base::_cast(unsigned long iid)
{
	if(iid == Arts::MixerItemGui_base::_IID) return (Arts::MixerItemGui_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::MixerItemGui_stub::MixerItemGui_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::MixerItemGui_stub::MixerItemGui_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

Arts::Widget Arts::MixerItemGui_stub::initialize(Arts::Environment::MixerItem item)
{
	long methodID = _lookupMethodFast("method:0000000b696e697469616c697a65000000000d417274733a3a5769646765740000000002000000010000001d417274733a3a456e7669726f6e6d656e743a3a4d697865724974656d00000000056974656d000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,item._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if (!result) return Arts::Widget::null();
	Arts::Widget_base* returnCode;
	Arts::readObject(*result,returnCode);
	delete result;
	return Arts::Widget::_from_base(returnCode);
}

bool Arts::MixerItemGui_stub::active()
{
	long methodID = _lookupMethodFast("method:0000000c5f6765745f6163746976650000000008626f6f6c65616e00000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return false; // error occurred
	bool returnCode = result->readBool();
	delete result;
	return returnCode;
}

void Arts::MixerItemGui_stub::active(bool newValue)
{
	long methodID = _lookupMethodFast("method:0000000c5f7365745f6163746976650000000005766f696400000000020000000100000008626f6f6c65616e00000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeBool(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

long Arts::MixerItemGui_stub::channelCount()
{
	long methodID = _lookupMethodFast("method:000000125f6765745f6368616e6e656c436f756e7400000000056c6f6e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return 0; // error occurred
	long returnCode = result->readLong();
	delete result;
	return returnCode;
}

void Arts::MixerItemGui_stub::channelCount(long newValue)
{
	long methodID = _lookupMethodFast("method:000000125f7365745f6368616e6e656c436f756e740000000005766f6964000000000200000001000000056c6f6e6700000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeLong(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::MixerItemGui_stub::type()
{
	long methodID = _lookupMethodFast("method:0000000a5f6765745f747970650000000007737472696e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return""; // error occurred
	std::string returnCode;
	result->readString(returnCode);
	delete result;
	return returnCode;
}

void Arts::MixerItemGui_stub::type(const std::string& newValue)
{
	long methodID = _lookupMethodFast("method:0000000a5f7365745f747970650000000005766f696400000000020000000100000007737472696e6700000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::MixerItemGui_skel::_interfaceName()
{
	return "Arts::MixerItemGui";
}

bool Arts::MixerItemGui_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::MixerItemGui") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::MixerItemGui_skel::_interfaceNameSkel()
{
	return "Arts::MixerItemGui";
}

// initialize
static void _dispatch_Arts_MixerItemGui_00(void *object, Arts::Buffer *request, Arts::Buffer *result)
{
	Arts::Environment::MixerItem_base* _temp_item;
	Arts::readObject(*request,_temp_item);
	Arts::Environment::MixerItem item = Arts::Environment::MixerItem::_from_base(_temp_item);
	Arts::Widget returnCode = ((Arts::MixerItemGui_skel *)object)->initialize(item);
	Arts::writeObject(*result,returnCode._base());
}

// _get_active
static void _dispatch_Arts_MixerItemGui_01(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeBool(((Arts::MixerItemGui_skel *)object)->active());
}

// _set_active
static void _dispatch_Arts_MixerItemGui_02(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	bool newValue = request->readBool();
	((Arts::MixerItemGui_skel *)object)->active(newValue);
}

// _get_channelCount
static void _dispatch_Arts_MixerItemGui_03(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeLong(((Arts::MixerItemGui_skel *)object)->channelCount());
}

// _set_channelCount
static void _dispatch_Arts_MixerItemGui_04(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	long newValue = request->readLong();
	((Arts::MixerItemGui_skel *)object)->channelCount(newValue);
}

// _get_type
static void _dispatch_Arts_MixerItemGui_05(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeString(((Arts::MixerItemGui_skel *)object)->type());
}

// _set_type
static void _dispatch_Arts_MixerItemGui_06(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::string newValue;
	request->readString(newValue);
	((Arts::MixerItemGui_skel *)object)->type(newValue);
}

void Arts::MixerItemGui_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:0000000b696e697469616c697a65000000000d417274733a3a5769"
        "646765740000000002000000010000001d417274733a3a456e7669726f6e6d656e"
        "743a3a4d697865724974656d00000000056974656d000000000000000000000000"
        "0c5f6765745f6163746976650000000008626f6f6c65616e000000000200000000"
        "000000000000000c5f7365745f6163746976650000000005766f69640000000002"
        "0000000100000008626f6f6c65616e00000000096e657756616c75650000000000"
        "00000000000000125f6765745f6368616e6e656c436f756e7400000000056c6f6e"
        "6700000000020000000000000000000000125f7365745f6368616e6e656c436f75"
        "6e740000000005766f6964000000000200000001000000056c6f6e670000000009"
        "6e657756616c75650000000000000000000000000a5f6765745f74797065000000"
        "0007737472696e67000000000200000000000000000000000a5f7365745f747970"
        "650000000005766f696400000000020000000100000007737472696e6700000000"
        "096e657756616c7565000000000000000000",
		"MethodTable"
	);
	_addMethod(_dispatch_Arts_MixerItemGui_00,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_MixerItemGui_01,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_MixerItemGui_02,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_MixerItemGui_03,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_MixerItemGui_04,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_MixerItemGui_05,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_MixerItemGui_06,this,Arts::MethodDef(m));
}

Arts::MixerItemGui_skel::MixerItemGui_skel()
{
}

Arts::Object_base* Arts::MixerItemGui::_Creator() {
	return Arts::MixerItemGui_base::_create();
}

unsigned long Arts::MixerItemGui_base::_IID = Arts::MCOPUtils::makeIID("Arts::MixerItemGui");

Arts::EffectRackItemGui_base *Arts::EffectRackItemGui_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::EffectRackItemGui_base *castedObject = (Arts::EffectRackItemGui_base *)skel->_cast(Arts::EffectRackItemGui_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::EffectRackItemGui_base *Arts::EffectRackItemGui_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::EffectRackItemGui_base::_fromReference(r,true);
	return 0;
}

Arts::EffectRackItemGui_base *Arts::EffectRackItemGui_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::EffectRackItemGui_base *castedObject = (Arts::EffectRackItemGui_base *)object._base()->_cast(Arts::EffectRackItemGui_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::EffectRackItemGui_base *Arts::EffectRackItemGui_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::EffectRackItemGui_base *result;
	result = (Arts::EffectRackItemGui_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::EffectRackItemGui");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::EffectRackItemGui_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::EffectRackItemGui")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::EffectRackItemGui_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::EffectRackItemGui_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::EffectRackItemGui_base::_cast(unsigned long iid)
{
	if(iid == Arts::EffectRackItemGui_base::_IID) return (Arts::EffectRackItemGui_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::EffectRackItemGui_stub::EffectRackItemGui_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::EffectRackItemGui_stub::EffectRackItemGui_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

void Arts::EffectRackItemGui_stub::removeSlot(Arts::EffectRackSlot slot)
{
	long methodID = _lookupMethodFast("method:0000000b72656d6f7665536c6f740000000005766f696400000000020000000100000015417274733a3a4566666563745261636b536c6f740000000005736c6f74000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,slot._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

void Arts::EffectRackItemGui_stub::routeToMaster(Arts::EffectRackSlot slot, bool tomaster)
{
	long methodID = _lookupMethodFast("method:0000000e726f757465546f4d61737465720000000005766f696400000000020000000200000015417274733a3a4566666563745261636b536c6f740000000005736c6f74000000000000000008626f6f6c65616e0000000009746f6d6173746572000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,slot._base());
	request->writeBool(tomaster);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

Arts::Widget Arts::EffectRackItemGui_stub::initialize(Arts::Environment::EffectRackItem item)
{
	long methodID = _lookupMethodFast("method:0000000b696e697469616c697a65000000000d417274733a3a57696467657400000000020000000100000022417274733a3a456e7669726f6e6d656e743a3a4566666563745261636b4974656d00000000056974656d000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,item._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if (!result) return Arts::Widget::null();
	Arts::Widget_base* returnCode;
	Arts::readObject(*result,returnCode);
	delete result;
	return Arts::Widget::_from_base(returnCode);
}

bool Arts::EffectRackItemGui_stub::active()
{
	long methodID = _lookupMethodFast("method:0000000c5f6765745f6163746976650000000008626f6f6c65616e00000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return false; // error occurred
	bool returnCode = result->readBool();
	delete result;
	return returnCode;
}

void Arts::EffectRackItemGui_stub::active(bool newValue)
{
	long methodID = _lookupMethodFast("method:0000000c5f7365745f6163746976650000000005766f696400000000020000000100000008626f6f6c65616e00000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeBool(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::EffectRackItemGui_stub::type()
{
	long methodID = _lookupMethodFast("method:0000000a5f6765745f747970650000000007737472696e6700000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return""; // error occurred
	std::string returnCode;
	result->readString(returnCode);
	delete result;
	return returnCode;
}

void Arts::EffectRackItemGui_stub::type(const std::string& newValue)
{
	long methodID = _lookupMethodFast("method:0000000a5f7365745f747970650000000005766f696400000000020000000100000007737472696e6700000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeString(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

bool Arts::EffectRackItemGui_stub::addeffect()
{
	long methodID = _lookupMethodFast("method:0000000f5f6765745f6164646566666563740000000008626f6f6c65616e00000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return false; // error occurred
	bool returnCode = result->readBool();
	delete result;
	return returnCode;
}

void Arts::EffectRackItemGui_stub::addeffect(bool newValue)
{
	long methodID = _lookupMethodFast("method:0000000f5f7365745f6164646566666563740000000005766f696400000000020000000100000008626f6f6c65616e00000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeBool(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::EffectRackItemGui_skel::_interfaceName()
{
	return "Arts::EffectRackItemGui";
}

bool Arts::EffectRackItemGui_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::EffectRackItemGui") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::EffectRackItemGui_skel::_interfaceNameSkel()
{
	return "Arts::EffectRackItemGui";
}

// removeSlot
static void _dispatch_Arts_EffectRackItemGui_00(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	Arts::EffectRackSlot_base* _temp_slot;
	Arts::readObject(*request,_temp_slot);
	Arts::EffectRackSlot slot = Arts::EffectRackSlot::_from_base(_temp_slot);
	((Arts::EffectRackItemGui_skel *)object)->removeSlot(slot);
}

// routeToMaster
static void _dispatch_Arts_EffectRackItemGui_01(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	Arts::EffectRackSlot_base* _temp_slot;
	Arts::readObject(*request,_temp_slot);
	Arts::EffectRackSlot slot = Arts::EffectRackSlot::_from_base(_temp_slot);
	bool tomaster = request->readBool();
	((Arts::EffectRackItemGui_skel *)object)->routeToMaster(slot,tomaster);
}

// initialize
static void _dispatch_Arts_EffectRackItemGui_02(void *object, Arts::Buffer *request, Arts::Buffer *result)
{
	Arts::Environment::EffectRackItem_base* _temp_item;
	Arts::readObject(*request,_temp_item);
	Arts::Environment::EffectRackItem item = Arts::Environment::EffectRackItem::_from_base(_temp_item);
	Arts::Widget returnCode = ((Arts::EffectRackItemGui_skel *)object)->initialize(item);
	Arts::writeObject(*result,returnCode._base());
}

// _get_active
static void _dispatch_Arts_EffectRackItemGui_03(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeBool(((Arts::EffectRackItemGui_skel *)object)->active());
}

// _set_active
static void _dispatch_Arts_EffectRackItemGui_04(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	bool newValue = request->readBool();
	((Arts::EffectRackItemGui_skel *)object)->active(newValue);
}

// _get_type
static void _dispatch_Arts_EffectRackItemGui_05(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeString(((Arts::EffectRackItemGui_skel *)object)->type());
}

// _set_type
static void _dispatch_Arts_EffectRackItemGui_06(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	std::string newValue;
	request->readString(newValue);
	((Arts::EffectRackItemGui_skel *)object)->type(newValue);
}

// _get_addeffect
static void _dispatch_Arts_EffectRackItemGui_07(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeBool(((Arts::EffectRackItemGui_skel *)object)->addeffect());
}

// _set_addeffect
static void _dispatch_Arts_EffectRackItemGui_08(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	bool newValue = request->readBool();
	((Arts::EffectRackItemGui_skel *)object)->addeffect(newValue);
}

void Arts::EffectRackItemGui_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:0000000b72656d6f7665536c6f740000000005766f696400000000"
        "020000000100000015417274733a3a4566666563745261636b536c6f7400000000"
        "05736c6f740000000000000000000000000e726f757465546f4d61737465720000"
        "000005766f696400000000020000000200000015417274733a3a45666665637452"
        "61636b536c6f740000000005736c6f74000000000000000008626f6f6c65616e00"
        "00000009746f6d61737465720000000000000000000000000b696e697469616c69"
        "7a65000000000d417274733a3a5769646765740000000002000000010000002241"
        "7274733a3a456e7669726f6e6d656e743a3a4566666563745261636b4974656d00"
        "000000056974656d0000000000000000000000000c5f6765745f61637469766500"
        "00000008626f6f6c65616e000000000200000000000000000000000c5f7365745f"
        "6163746976650000000005766f696400000000020000000100000008626f6f6c65"
        "616e00000000096e657756616c75650000000000000000000000000a5f6765745f"
        "747970650000000007737472696e67000000000200000000000000000000000a5f"
        "7365745f747970650000000005766f696400000000020000000100000007737472"
        "696e6700000000096e657756616c75650000000000000000000000000f5f676574"
        "5f6164646566666563740000000008626f6f6c65616e0000000002000000000000"
        "00000000000f5f7365745f6164646566666563740000000005766f696400000000"
        "020000000100000008626f6f6c65616e00000000096e657756616c756500000000"
        "0000000000",
		"MethodTable"
	);
	_addMethod(_dispatch_Arts_EffectRackItemGui_00,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackItemGui_01,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackItemGui_02,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackItemGui_03,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackItemGui_04,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackItemGui_05,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackItemGui_06,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackItemGui_07,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackItemGui_08,this,Arts::MethodDef(m));
}

Arts::EffectRackItemGui_skel::EffectRackItemGui_skel()
{
}

Arts::Object_base* Arts::EffectRackItemGui::_Creator() {
	return Arts::EffectRackItemGui_base::_create();
}

unsigned long Arts::EffectRackItemGui_base::_IID = Arts::MCOPUtils::makeIID("Arts::EffectRackItemGui");

Arts::EffectRackSlot_base *Arts::EffectRackSlot_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::EffectRackSlot_base *castedObject = (Arts::EffectRackSlot_base *)skel->_cast(Arts::EffectRackSlot_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::EffectRackSlot_base *Arts::EffectRackSlot_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::EffectRackSlot_base::_fromReference(r,true);
	return 0;
}

Arts::EffectRackSlot_base *Arts::EffectRackSlot_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::EffectRackSlot_base *castedObject = (Arts::EffectRackSlot_base *)object._base()->_cast(Arts::EffectRackSlot_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::EffectRackSlot_base *Arts::EffectRackSlot_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::EffectRackSlot_base *result;
	result = (Arts::EffectRackSlot_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::EffectRackSlot");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::EffectRackSlot_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::EffectRackSlot")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::EffectRackSlot_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::EffectRackSlot_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::EffectRackSlot_base::_cast(unsigned long iid)
{
	if(iid == Arts::EffectRackSlot_base::_IID) return (Arts::EffectRackSlot_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::EffectRackSlot_stub::EffectRackSlot_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::EffectRackSlot_stub::EffectRackSlot_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

void Arts::EffectRackSlot_stub::constructor(Arts::Widget parent, Arts::Widget effect, Arts::EffectRackItemGui effectrackgui)
{
	long methodID = _lookupMethodFast("method:0000000c636f6e7374727563746f720000000005766f69640000000002000000030000000d417274733a3a5769646765740000000007706172656e7400000000000000000d417274733a3a5769646765740000000007656666656374000000000000000018417274733a3a4566666563745261636b4974656d477569000000000e6566666563747261636b677569000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	Arts::writeObject(*request,parent._base());
	Arts::writeObject(*request,effect._base());
	Arts::writeObject(*request,effectrackgui._base());
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

bool Arts::EffectRackSlot_stub::removeslot()
{
	long methodID = _lookupMethodFast("method:000000105f6765745f72656d6f7665736c6f740000000008626f6f6c65616e00000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return false; // error occurred
	bool returnCode = result->readBool();
	delete result;
	return returnCode;
}

void Arts::EffectRackSlot_stub::removeslot(bool newValue)
{
	long methodID = _lookupMethodFast("method:000000105f7365745f72656d6f7665736c6f740000000005766f696400000000020000000100000008626f6f6c65616e00000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeBool(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

bool Arts::EffectRackSlot_stub::tomaster()
{
	long methodID = _lookupMethodFast("method:0000000e5f6765745f746f6d61737465720000000008626f6f6c65616e00000000020000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(!result) return false; // error occurred
	bool returnCode = result->readBool();
	delete result;
	return returnCode;
}

void Arts::EffectRackSlot_stub::tomaster(bool newValue)
{
	long methodID = _lookupMethodFast("method:0000000e5f7365745f746f6d61737465720000000005766f696400000000020000000100000008626f6f6c65616e00000000096e657756616c7565000000000000000000");
	long requestID;
	Arts::Buffer *request, *result;
	request = Arts::Dispatcher::the()->createRequest(requestID,_objectID,methodID);
	request->writeBool(newValue);
	request->patchLength();
	_connection->qSendBuffer(request);

	result = Arts::Dispatcher::the()->waitForResult(requestID,_connection);
	if(result) delete result;
}

std::string Arts::EffectRackSlot_skel::_interfaceName()
{
	return "Arts::EffectRackSlot";
}

bool Arts::EffectRackSlot_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::EffectRackSlot") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::EffectRackSlot_skel::_interfaceNameSkel()
{
	return "Arts::EffectRackSlot";
}

// constructor
static void _dispatch_Arts_EffectRackSlot_00(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	Arts::Widget_base* _temp_parent;
	Arts::readObject(*request,_temp_parent);
	Arts::Widget parent = Arts::Widget::_from_base(_temp_parent);
	Arts::Widget_base* _temp_effect;
	Arts::readObject(*request,_temp_effect);
	Arts::Widget effect = Arts::Widget::_from_base(_temp_effect);
	Arts::EffectRackItemGui_base* _temp_effectrackgui;
	Arts::readObject(*request,_temp_effectrackgui);
	Arts::EffectRackItemGui effectrackgui = Arts::EffectRackItemGui::_from_base(_temp_effectrackgui);
	((Arts::EffectRackSlot_skel *)object)->constructor(parent,effect,effectrackgui);
}

// _get_removeslot
static void _dispatch_Arts_EffectRackSlot_01(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeBool(((Arts::EffectRackSlot_skel *)object)->removeslot());
}

// _set_removeslot
static void _dispatch_Arts_EffectRackSlot_02(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	bool newValue = request->readBool();
	((Arts::EffectRackSlot_skel *)object)->removeslot(newValue);
}

// _get_tomaster
static void _dispatch_Arts_EffectRackSlot_03(void *object, Arts::Buffer *, Arts::Buffer *result)
{
	result->writeBool(((Arts::EffectRackSlot_skel *)object)->tomaster());
}

// _set_tomaster
static void _dispatch_Arts_EffectRackSlot_04(void *object, Arts::Buffer *request, Arts::Buffer *)
{
	bool newValue = request->readBool();
	((Arts::EffectRackSlot_skel *)object)->tomaster(newValue);
}

void Arts::EffectRackSlot_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:0000000c636f6e7374727563746f720000000005766f6964000000"
        "0002000000030000000d417274733a3a5769646765740000000007706172656e74"
        "00000000000000000d417274733a3a576964676574000000000765666665637400"
        "0000000000000018417274733a3a4566666563745261636b4974656d4775690000"
        "00000e6566666563747261636b677569000000000000000000000000105f676574"
        "5f72656d6f7665736c6f740000000008626f6f6c65616e00000000020000000000"
        "000000000000105f7365745f72656d6f7665736c6f740000000005766f69640000"
        "0000020000000100000008626f6f6c65616e00000000096e657756616c75650000"
        "000000000000000000000e5f6765745f746f6d61737465720000000008626f6f6c"
        "65616e000000000200000000000000000000000e5f7365745f746f6d6173746572"
        "0000000005766f696400000000020000000100000008626f6f6c65616e00000000"
        "096e657756616c7565000000000000000000",
		"MethodTable"
	);
	_addMethod(_dispatch_Arts_EffectRackSlot_00,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackSlot_01,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackSlot_02,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackSlot_03,this,Arts::MethodDef(m));
	_addMethod(_dispatch_Arts_EffectRackSlot_04,this,Arts::MethodDef(m));
}

Arts::EffectRackSlot_skel::EffectRackSlot_skel()
{
}

Arts::Object_base* Arts::EffectRackSlot::_Creator() {
	return Arts::EffectRackSlot_base::_create();
}

unsigned long Arts::EffectRackSlot_base::_IID = Arts::MCOPUtils::makeIID("Arts::EffectRackSlot");

Arts::MixerGuiFactory_base *Arts::MixerGuiFactory_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::MixerGuiFactory_base *castedObject = (Arts::MixerGuiFactory_base *)skel->_cast(Arts::MixerGuiFactory_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::MixerGuiFactory_base *Arts::MixerGuiFactory_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::MixerGuiFactory_base::_fromReference(r,true);
	return 0;
}

Arts::MixerGuiFactory_base *Arts::MixerGuiFactory_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::MixerGuiFactory_base *castedObject = (Arts::MixerGuiFactory_base *)object._base()->_cast(Arts::MixerGuiFactory_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::MixerGuiFactory_base *Arts::MixerGuiFactory_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::MixerGuiFactory_base *result;
	result = (Arts::MixerGuiFactory_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::MixerGuiFactory");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::MixerGuiFactory_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::MixerGuiFactory")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::MixerGuiFactory_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::MixerGuiFactory_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::MixerGuiFactory_base::_cast(unsigned long iid)
{
	if(iid == Arts::MixerGuiFactory_base::_IID) return (Arts::MixerGuiFactory_base *)this;
	if(iid == Arts::GuiFactory_base::_IID) return (Arts::GuiFactory_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::MixerGuiFactory_stub::MixerGuiFactory_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::MixerGuiFactory_stub::MixerGuiFactory_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

std::string Arts::MixerGuiFactory_skel::_interfaceName()
{
	return "Arts::MixerGuiFactory";
}

bool Arts::MixerGuiFactory_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::MixerGuiFactory") return true;
	if (interfacename == "Arts::GuiFactory") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::MixerGuiFactory_skel::_interfaceNameSkel()
{
	return "Arts::MixerGuiFactory";
}

void Arts::MixerGuiFactory_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:",
		"MethodTable"
	);
	Arts::GuiFactory_skel::_buildMethodTable();
}

Arts::MixerGuiFactory_skel::MixerGuiFactory_skel()
{
}

Arts::Object_base* Arts::MixerGuiFactory::_Creator() {
	return Arts::MixerGuiFactory_base::_create();
}

unsigned long Arts::MixerGuiFactory_base::_IID = Arts::MCOPUtils::makeIID("Arts::MixerGuiFactory");

Arts::EffectRackGuiFactory_base *Arts::EffectRackGuiFactory_base::_create(const std::string& subClass)
{
	Arts::Object_skel *skel = Arts::ObjectManager::the()->create(subClass);
	assert(skel);
	Arts::EffectRackGuiFactory_base *castedObject = (Arts::EffectRackGuiFactory_base *)skel->_cast(Arts::EffectRackGuiFactory_base::_IID);
	assert(castedObject);
	return castedObject;
}

Arts::EffectRackGuiFactory_base *Arts::EffectRackGuiFactory_base::_fromString(const std::string& objectref)
{
	Arts::ObjectReference r;

	if(Arts::Dispatcher::the()->stringToObjectReference(r,objectref))
		return Arts::EffectRackGuiFactory_base::_fromReference(r,true);
	return 0;
}

Arts::EffectRackGuiFactory_base *Arts::EffectRackGuiFactory_base::_fromDynamicCast(const Arts::Object& object)
{
	if(object.isNull()) return 0;

	Arts::EffectRackGuiFactory_base *castedObject = (Arts::EffectRackGuiFactory_base *)object._base()->_cast(Arts::EffectRackGuiFactory_base::_IID);
	if(castedObject) return castedObject->_copy();

	return _fromString(object._toString());
}

Arts::EffectRackGuiFactory_base *Arts::EffectRackGuiFactory_base::_fromReference(Arts::ObjectReference r, bool needcopy)
{
	Arts::EffectRackGuiFactory_base *result;
	result = (Arts::EffectRackGuiFactory_base *)Arts::Dispatcher::the()->connectObjectLocal(r,"Arts::EffectRackGuiFactory");
	if(result)
	{
		if(!needcopy)
			result->_cancelCopyRemote();
	}
	else
	{
		Arts::Connection *conn = Arts::Dispatcher::the()->connectObjectRemote(r);
		if(conn)
		{
			result = new Arts::EffectRackGuiFactory_stub(conn,r.objectID);
			if(needcopy) result->_copyRemote();
			result->_useRemote();
			if (!result->_isCompatibleWith("Arts::EffectRackGuiFactory")) {
				result->_release();
				return 0;
			}
		}
	}
	return result;
}

std::vector<std::string> Arts::EffectRackGuiFactory_base::_defaultPortsIn() const {
	std::vector<std::string> ret;
	return ret;
}
std::vector<std::string> Arts::EffectRackGuiFactory_base::_defaultPortsOut() const {
	std::vector<std::string> ret;
	return ret;
}

void *Arts::EffectRackGuiFactory_base::_cast(unsigned long iid)
{
	if(iid == Arts::EffectRackGuiFactory_base::_IID) return (Arts::EffectRackGuiFactory_base *)this;
	if(iid == Arts::GuiFactory_base::_IID) return (Arts::GuiFactory_base *)this;
	if(iid == Arts::Object_base::_IID) return (Arts::Object_base *)this;
	return 0;
}

Arts::EffectRackGuiFactory_stub::EffectRackGuiFactory_stub()
{
	// constructor for subclasses (don't use directly)
}

Arts::EffectRackGuiFactory_stub::EffectRackGuiFactory_stub(Arts::Connection *connection, long objectID)
	: Arts::Object_stub(connection, objectID)
{
	// constructor to create a stub for an object
}

std::string Arts::EffectRackGuiFactory_skel::_interfaceName()
{
	return "Arts::EffectRackGuiFactory";
}

bool Arts::EffectRackGuiFactory_skel::_isCompatibleWith(const std::string& interfacename)
{
	if (interfacename == "Arts::EffectRackGuiFactory") return true;
	if (interfacename == "Arts::GuiFactory") return true;
	if (interfacename == "Arts::Object") return true;
	return false;
}

std::string Arts::EffectRackGuiFactory_skel::_interfaceNameSkel()
{
	return "Arts::EffectRackGuiFactory";
}

void Arts::EffectRackGuiFactory_skel::_buildMethodTable()
{
	Arts::Buffer m;
	m.fromString(
        "MethodTable:",
		"MethodTable"
	);
	Arts::GuiFactory_skel::_buildMethodTable();
}

Arts::EffectRackGuiFactory_skel::EffectRackGuiFactory_skel()
{
}

Arts::Object_base* Arts::EffectRackGuiFactory::_Creator() {
	return Arts::EffectRackGuiFactory_base::_create();
}

unsigned long Arts::EffectRackGuiFactory_base::_IID = Arts::MCOPUtils::makeIID("Arts::EffectRackGuiFactory");

static Arts::IDLFileReg IDLFileReg_artsmodulescommon("artsmodulescommon",
    "IDLFile:000000010000000000000000000000000e0000001b417274733a3a456e7669"
    "726f6e6d656e743a3a436f6e7465787400000000000000000300000009616464456e74"
    "72790000000005766f696400000000020000000200000007737472696e670000000005"
    "6e616d650000000000000000076f626a65637400000000046f626a0000000000000000"
    "000000000c6c6f6f6b7570456e7472790000000007737472696e670000000002000000"
    "01000000076f626a65637400000000046f626a0000000000000000000000000c72656d"
    "6f7665456e7472790000000005766f6964000000000200000001000000076f626a6563"
    "7400000000046f626a0000000000000000000000000000000000000000000000001d41"
    "7274733a3a456e7669726f6e6d656e743a3a436f6e7461696e65720000000000000000"
    "050000000b73617665546f4c69737400000000082a737472696e670000000002000000"
    "00000000000000000d6c6f616446726f6d4c6973740000000005766f69640000000002"
    "00000001000000082a737472696e6700000000087374726c6973740000000000000000"
    "00000000086164644974656d0000000005766f69640000000002000000010000001841"
    "7274733a3a456e7669726f6e6d656e743a3a4974656d00000000056974656d00000000"
    "00000000000000000b6372656174654974656d0000000018417274733a3a456e766972"
    "6f6e6d656e743a3a4974656d00000000020000000100000007737472696e6700000000"
    "056e616d650000000000000000000000000b72656d6f76654974656d0000000005766f"
    "696400000000020000000100000018417274733a3a456e7669726f6e6d656e743a3a49"
    "74656d00000000056974656d000000000000000000000000030000000e646174614469"
    "726563746f72790000000007737472696e6700000000130000000000000008636f6e74"
    "657874000000001b417274733a3a456e7669726f6e6d656e743a3a436f6e7465787400"
    "0000001300000000000000066974656d7300000000192a417274733a3a456e7669726f"
    "6e6d656e743a3a4974656d000000001200000000000000000000000000000018417274"
    "733a3a456e7669726f6e6d656e743a3a4974656d0000000000000000030000000d7365"
    "74436f6e7461696e65720000000005766f69640000000002000000010000001d417274"
    "733a3a456e7669726f6e6d656e743a3a436f6e7461696e6572000000000a636f6e7461"
    "696e65720000000000000000000000000b73617665546f4c69737400000000082a7374"
    "72696e67000000000200000000000000000000000d6c6f616446726f6d4c6973740000"
    "000005766f6964000000000200000001000000082a737472696e670000000008737472"
    "6c69737400000000000000000000000002000000076163746976650000000008626f6f"
    "6c65616e00000000120000000000000007706172656e74000000001d417274733a3a45"
    "6e7669726f6e6d656e743a3a436f6e7461696e65720000000012000000000000000000"
    "00000000000022417274733a3a456e7669726f6e6d656e743a3a496e737472756d656e"
    "744974656d000000000100000018417274733a3a456e7669726f6e6d656e743a3a4974"
    "656d00000000000000000300000005706f7274000000000f417274733a3a4d69646950"
    "6f72740000000012000000000000000966696c656e616d650000000007737472696e67"
    "000000001300000000000000086275736e616d650000000007737472696e6700000000"
    "130000000000000000000000000000002c417274733a3a456e7669726f6e6d656e743a"
    "3a496e737472756d656e744974656d477569466163746f727900000000010000001141"
    "7274733a3a477569466163746f72790000000000000000000000000000000000000000"
    "24417274733a3a456e7669726f6e6d656e743a3a53746572656f456666656374497465"
    "6d000000000100000018417274733a3a456e7669726f6e6d656e743a3a4974656d0000"
    "00000000000002000000076566666563740000000012417274733a3a53796e74684d6f"
    "64756c6500000000130000000000000006737461636b0000000018417274733a3a5374"
    "6572656f456666656374537461636b0000000013000000000000000000000000000000"
    "20417274733a3a456e7669726f6e6d656e743a3a4d697865724368616e6e656c000000"
    "000100000013417274733a3a53746572656f4566666563740000000000000000010000"
    "00056e616d650000000007737472696e67000000001300000000000000000000000000"
    "00001d417274733a3a456e7669726f6e6d656e743a3a4d697865724974656d00000000"
    "0100000018417274733a3a456e7669726f6e6d656e743a3a4974656d00000000000000"
    "0004000000096368616e6e656c7300000000212a417274733a3a456e7669726f6e6d65"
    "6e743a3a4d697865724368616e6e656c0000000012000000000000000d6368616e6e65"
    "6c436f756e7400000000056c6f6e67000000001300000000000000056e616d65000000"
    "0007737472696e6700000000130000000000000005747970650000000007737472696e"
    "67000000001300000000000000000000000000000022417274733a3a456e7669726f6e"
    "6d656e743a3a4566666563745261636b4974656d000000000100000018417274733a3a"
    "456e7669726f6e6d656e743a3a4974656d00000000030000000d637265617465456666"
    "6563740000000013417274733a3a53746572656f456666656374000000000200000002"
    "00000007737472696e67000000000574797065000000000000000007737472696e6700"
    "000000056e616d650000000000000000000000000a64656c4566666563740000000005"
    "766f6964000000000200000001000000056c6f6e670000000004706f73000000000000"
    "0000000000000e726f757465546f4d61737465720000000005766f6964000000000200"
    "000002000000056c6f6e670000000004706f73000000000000000008626f6f6c65616e"
    "0000000009746f6d617374657200000000000000000000000003000000086566666563"
    "747300000000142a417274733a3a53746572656f456666656374000000001200000000"
    "0000000c656666656374436f756e7400000000056c6f6e670000000012000000000000"
    "00056e616d650000000007737472696e67000000001300000000000000000000000000"
    "000013417274733a3a4d697865724974656d4775690000000000000000010000000b69"
    "6e697469616c697a65000000000d417274733a3a576964676574000000000200000001"
    "0000001d417274733a3a456e7669726f6e6d656e743a3a4d697865724974656d000000"
    "00056974656d0000000000000000000000000300000007616374697665000000000862"
    "6f6f6c65616e0000000013000000000000000d6368616e6e656c436f756e7400000000"
    "056c6f6e6700000000130000000000000005747970650000000007737472696e670000"
    "00001300000000000000000000000000000018417274733a3a4566666563745261636b"
    "4974656d4775690000000000000000030000000b72656d6f7665536c6f740000000005"
    "766f696400000000020000000100000015417274733a3a4566666563745261636b536c"
    "6f740000000005736c6f740000000000000000000000000e726f757465546f4d617374"
    "65720000000005766f696400000000020000000200000015417274733a3a4566666563"
    "745261636b536c6f740000000005736c6f74000000000000000008626f6f6c65616e00"
    "00000009746f6d61737465720000000000000000000000000b696e697469616c697a65"
    "000000000d417274733a3a57696467657400000000020000000100000022417274733a"
    "3a456e7669726f6e6d656e743a3a4566666563745261636b4974656d00000000056974"
    "656d00000000000000000000000003000000076163746976650000000008626f6f6c65"
    "616e00000000130000000000000005747970650000000007737472696e670000000013"
    "000000000000000a6164646566666563740000000008626f6f6c65616e000000001300"
    "000000000000000000000000000015417274733a3a4566666563745261636b536c6f74"
    "0000000000000000010000000c636f6e7374727563746f720000000005766f69640000"
    "000002000000030000000d417274733a3a5769646765740000000007706172656e7400"
    "000000000000000d417274733a3a576964676574000000000765666665637400000000"
    "0000000018417274733a3a4566666563745261636b4974656d477569000000000e6566"
    "666563747261636b677569000000000000000000000000020000000b72656d6f766573"
    "6c6f740000000008626f6f6c65616e00000000130000000000000009746f6d61737465"
    "720000000008626f6f6c65616e00000000130000000000000000000000000000001641"
    "7274733a3a4d69786572477569466163746f7279000000000100000011417274733a3a"
    "477569466163746f727900000000000000000000000000000000000000001b41727473"
    "3a3a4566666563745261636b477569466163746f727900000000010000001141727473"
    "3a3a477569466163746f7279000000000000000000000000000000000000000000"
);
