
extern "C" 
{

//------------------------------------------------------------------------------------
// irr::io::IXMLReaderUTF8 wrappers
// be sure to call the del function when done
//------------------------------------------------------------------------------------

void IrrIO_IXMLReaderUTF8_del(IXMLReaderUTF8* f)
{
	if (f)
		f->drop();
}

s32 IrrIO_IXMLReaderUTF8_getAttributeCount(IXMLReaderUTF8* f)
{
	if (f)
		return f->getAttributeCount();
	else
		return 0;
}

const c8* IrrIO_IXMLReaderUTF8_getAttributeName(IXMLReaderUTF8* f,s32 idx)
{
	if (f)
		return f->getAttributeName(idx);
	else
		return "";
}

const c8* IrrIO_IXMLReaderUTF8_getAttributeValue(IXMLReaderUTF8* f,const c8* name)
{
	if (f)
		return f->getAttributeValue(name);
	else
		return "";
}

const c8* IrrIO_IXMLReaderUTF8_getAttributeValueByIdx(IXMLReaderUTF8* f,s32 idx)
{
	if (f)
		return f->getAttributeValue(idx);
	else
		return "";
}

f32 IrrIO_IXMLReaderUTF8_getAttributeValueAsFloat(IXMLReaderUTF8* f,const c8* name)
{
	if (f)
		return f->getAttributeValueAsFloat(name);
	else
		return 0.0f;
}

f32 IrrIO_IXMLReaderUTF8_getAttributeValueAsFloatByIdx(IXMLReaderUTF8* f,s32 idx)
{
	if (f)
		return f->getAttributeValueAsFloat(idx);
	else	return 0.0f;
}

s32 IrrIO_IXMLReaderUTF8_getAttributeValueAsInt(IXMLReaderUTF8* f,const c8* name)
{
	if (f)
		return f->getAttributeValueAsInt(name);
	else
		return 0;
}

s32 IrrIO_IXMLReaderUTF8_getAttributeValueAsIntByIdx(IXMLReaderUTF8* f,s32 idx)
{
	if (f)
		return f->getAttributeValueAsInt(idx);
	else return 0;
}

const c8* IrrIO_IXMLReaderUTF8_getAttributeValueSafe(IXMLReaderUTF8* f,const c8* name)
{
	if (f)
		return f->getAttributeValueSafe(name);
	else
		return "";
}

const c8* IrrIO_IXMLReaderUTF8_getNodeData(IXMLReaderUTF8* f)
{
	if (f)
		return f->getNodeData();
	else
		return "";
}

const c8* IrrIO_IXMLReaderUTF8_getNodeName(IXMLReaderUTF8* f)
{
	if (f)
		return f->getNodeName();
	else
		return "";
}

s32 IrrIO_IXMLReaderUTF8_getNodeType(IXMLReaderUTF8* f)
{
	if (f)
		return f->getNodeType();
	else
		return -1;
}

bool IrrIO_IXMLReaderUTF8_isEmptyElement(IXMLReaderUTF8* f)
{
	if (f)
		return f->isEmptyElement();
	else
		return false;
}

bool IrrIO_IXMLReaderUTF8_read(IXMLReaderUTF8* f)
{
	if (f)
		return f->read();
	else
		return false;
}

bool IrrIO_IXMLReaderUTF8_drop(IXMLReaderUTF8* unk)
{
	if (unk)
		return unk->drop();
	else return 0;
}

const c8* IrrIO_IXMLReaderUTF8_getDebugName(IXMLReaderUTF8* unk)
{
	if (unk)
		return unk->getDebugName();
	else return "";
}

void IrrIO_IXMLReaderUTF8_grab(IXMLReaderUTF8* unk)
{
	if (unk)
		unk->grab();
}

}
