public static org.ibeans.api.DataType convertMuleToIBeans(DataType muleDT) throws MimeTypeParseException
{
//Both Mule and iBeans have DataType implementations, need to wrap the Mule DataType to work with iBeans
if(muleDT instanceof CollectionDataType)
{
CollectionDataType dt = (CollectionDataType)muleDT;
return org.ibeans.impl.support.datatype.DataTypeFactory.create(dt.getType(), dt.getItemType(), new MimeType(dt.getMimeType()));
}
else
{
return org.ibeans.impl.support.datatype.DataTypeFactory.create(muleDT.getType(), new MimeType(muleDT.getMimeType()));
}