package com.jxml.quick.util.qjml2qiml;
import com.jxml.quick.model.qjml.*;
import com.jxml.quick.*;
import org.xml.sax.*;
import java.util.*;
import com.jxml.quick.ocm.*;
import java.io.*;

/**
 * Extracts QJML data.
 */
public class QCAbstract extends OCMpeerSupport
{
	public boolean beenHere=false;

	/**
	 * User-provided code to perform the conversion.
	 */
	public void cvt(Object param) 
		throws SAXException, IOException
	{
		QMAbstract dm=(QMAbstract)dataModel;

		if (beenHere)
		{
			addStringAttribute("href","#"+dm.getLabel());
			//addStringAttribute("schema","http://www.jxml.com/qiml.qiml");
			emptyElement("link");
			return;
		}
		beenHere=true;

		addStringAttribute("tagName","abstract "+dm.getLabel());
		addStringAttribute("ID",dm.getLabel());

		startElement("elementDefinition");

		doCvt(dm.remList,null);
		doCvt(dm.targetClass,null);
		doCvt(dm.extensions,null);
		doCvt(dm.implementations,null);
		doCvt(dm.attributes,null);

		endElement("elementDefinition");
	}
}
