<?xml version="1.0"?>
<xsl:stylesheet version="1.0"
	xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml" indent="yes" encoding="iso-8859-1"/>

<xsl:template match="/">
<iso_10303_28>
	<xsl:apply-templates/>
</iso_10303_28>
</xsl:template>

<xsl:template match="iso_10303_28_header">
	<xsl:copy>
	<xsl:apply-templates/>
	</xsl:copy>
</xsl:template>

<xsl:template match="iso_10303_28_header//*">
	<xsl:copy>
	<xsl:apply-templates/>
	</xsl:copy>
</xsl:template>

<xsl:template match="external_refid">
	<xsl:copy>
	<xsl:apply-templates/>
	</xsl:copy>
</xsl:template>

<xsl:template match="external_refid//*">
	<xsl:copy>
	<xsl:apply-templates/>
	</xsl:copy>
</xsl:template>

<xsl:template match="express_data">
	<xsl:copy>
	<xsl:apply-templates/>
	</xsl:copy>
</xsl:template>

<xsl:template match="data_section_header">
    <xsl:copy>
	<xsl:apply-templates/>
    </xsl:copy>
</xsl:template>

<xsl:template match="data_section_header//*">
	<xsl:copy>
	<xsl:apply-templates/>
	</xsl:copy>
</xsl:template>

<xsl:template match="*[@late-bound-element='schema_instance']">
	<schema_instance>
		<xsl:copy-of select='@express_schema_name'/>
		<xsl:copy-of select='@id'/>
	<xsl:apply-templates/>
	</schema_instance>
</xsl:template>

<xsl:template match="*[@late-bound-element='entity_instance']">
	<entity_instance>
		<xsl:copy-of select='@express_entity_name'/>
		<xsl:copy-of select='@id'/>
		<xsl:copy-of select='@express_schema_name'/>
	<xsl:apply-templates/>
	</entity_instance>
</xsl:template>

<xsl:template match="*[@late-bound-element='attribute_instance']">
	<attribute_instance>
		<xsl:copy-of select='@express_attribute_name'/>
		<xsl:apply-templates/>
	</attribute_instance>
</xsl:template>

<xsl:template match="*[@late-bound-element='entity_instance_as_group']">
	<entity_instance_as_group>
		<xsl:copy-of select='@id'/>
	<xsl:apply-templates/>
	</entity_instance_as_group>
</xsl:template>
<xsl:template match="*[@late-bound-element='partial_entity_instance']">
	<partial_entity_instance>
		<xsl:copy-of select='@express_entity_name'/>
		<xsl:copy-of select='@id'/>
	<xsl:apply-templates/>
	</partial_entity_instance>
</xsl:template>

<xsl:template match="*[contains(local-name(.),'-ref')]">
	<entity_instance_ref>
		<xsl:copy-of select='@refid'/>
	</entity_instance_ref>
</xsl:template>

<xsl:template match="*[@late-bound-element='set_literal']">
	<set_literal>
	<xsl:apply-templates/>
	</set_literal>
</xsl:template>

<xsl:template match="*[@late-bound-element='bag_literal']">
	<bag_literal>
	<xsl:apply-templates/>
	</bag_literal>
</xsl:template>

<xsl:template match="*[@late-bound-element='list_literal']">
	<list_literal>
	<xsl:apply-templates/>
	</list_literal>
</xsl:template>

<xsl:template match="*[@late-bound-element='array_literal']">
	<array_literal>
	<xsl:apply-templates/>
	</array_literal>
</xsl:template>


<xsl:template match="*[@late-bound-element='type_literal']">
	<type_literal>
		<xsl:copy-of select='@express_type_name'/>
	<xsl:apply-templates/>
	</type_literal>
</xsl:template>

<xsl:template match="string">
	<string_literal>
		<xsl:value-of select="."/>
	</string_literal>
</xsl:template>

<xsl:template match="real">
	<real_literal>
		<xsl:value-of select="."/>
	</real_literal>
</xsl:template>

<xsl:template match="integer">
	<integer_literal>
		<xsl:value-of select="."/>
	</integer_literal>
</xsl:template>

<xsl:template match="boolean">
	<boolean_literal>
		<xsl:value-of select="."/>
	</boolean_literal>
</xsl:template>

<xsl:template match="logical">
	<logical_literal>
		<xsl:value-of select="."/>
	</logical_literal>
</xsl:template>

<xsl:template match="true">
	<xsl:copy/>
</xsl:template>

<xsl:template match="false">
	<xsl:copy/>
</xsl:template>

<xsl:template match="unset">
	<xsl:copy/>
</xsl:template>

</xsl:stylesheet>