<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.irs.gov/efile" targetNamespace="http://www.irs.gov/efile" elementFormDefault="qualified" attributeFormDefault="unqualified">
	<xsd:annotation>
		<xsd:documentation>
			<Description>IRS e-file Schema - Form 6478</Description>
			<TaxYear>2018</TaxYear>
			<MaturityLevel>Final Release</MaturityLevel>
			<ReleaseDate>October 15, 2019</ReleaseDate>
		</xsd:documentation>
	</xsd:annotation>
	<xsd:include schemaLocation="../../../Common/efileTypes.xsd"/>


	<!-- ================================================================== -->
	<!-- ======================  IRS Form 6478 ============================ -->
	<!-- ================================================================== -->

	<xsd:element name="IRS6478">
		<xsd:annotation>
			<xsd:documentation>IRS Form 6478</xsd:documentation>
		</xsd:annotation>
		<xsd:complexType>
			<xsd:complexContent>
				<xsd:extension base="IRS6478Type">
					<xsd:attributeGroup ref="DocumentAttributes">
						<xsd:annotation>
							<xsd:documentation>Common return document attributes</xsd:documentation>
						</xsd:annotation>
					</xsd:attributeGroup>
					<xsd:attribute name="documentName" type="xsd:string" fixed="IRS6478">
						<xsd:annotation>
							<xsd:documentation>IRS internal use only. To avoid error in the return, do not include the attribute name or value.</xsd:documentation>
						</xsd:annotation>
					</xsd:attribute>
					<xsd:attribute name="referenceDocumentId" type="IdListType"/>
					<xsd:attribute name="referenceDocumentName" type="StringType" fixed="SmallEthanolProducerCreditElection"/>
				</xsd:extension>
			</xsd:complexContent>
		</xsd:complexType>
	</xsd:element>

	<xsd:complexType name="IRS6478Type">
		<xsd:annotation>
			<xsd:documentation>Content model for Form 6478</xsd:documentation>
		</xsd:annotation>
		<xsd:sequence>
			
			<!-- Qualified Second Generation Biofuel Produced for Fuel - Gallons -->
			<xsd:element name="Qlfy2ndBiofuelProdFuelGalsQty" type="Form6478NumGallonsType" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>
						<Description>Qualified second generation biofuel produced for fuel - Gallons</Description>
						<LineNumber>Line 1</LineNumber>
					</xsd:documentation>
				</xsd:annotation>
			</xsd:element>

			<!-- Qualified Second Generation Biofuel Produced for Fuel - Credit -->
			<xsd:element name="Qlfy2ndBiofuelProdFuelCrAmt" type="USAmountType" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>
						<Description>Qualified second generation biofuel produced for fuel - Credit</Description>
						<LineNumber>Line 1</LineNumber>
					</xsd:documentation>
				</xsd:annotation>
			</xsd:element>			

			<!-- Alcohol and Cellulosic Biofuel Fuels Credit Registration Number -->
			<xsd:element name="FuelsCreditRegistrationNum" type="RegistrationNumType" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>
						<Description>Alcohol and cellulosic biofuel fuels credit registration number</Description>
						<LineNumber>Line 2</LineNumber>
					</xsd:documentation>
				</xsd:annotation>
			</xsd:element>			
			
			<!-- Add The Amounts in Column C on Lines 1 Through 6 -->
			<xsd:element name="OtherIncomeAmt" type="USAmountType" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>
						<Description>Add the amounts in column C on lines 1 through 6</Description>
						<LineNumber>Line 2</LineNumber>
					</xsd:documentation>
				</xsd:annotation>
			</xsd:element>

			<!-- Biofuel Producer Credit -->
			<xsd:element name="BiofuelProducerCreditAmt" type="USAmountType" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>
						<Description>Biofuel producer credit</Description>
						<LineNumber>Line 3</LineNumber>
					</xsd:documentation>
				</xsd:annotation>
			</xsd:element>

			<!-- Add lines 7 and 8 -->
			<xsd:element name="EthanolAlcoholOtherCreditAmt" type="USAmountType" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>
						<Description>Add lines 7 and 8</Description>
						<LineNumber>Line 4</LineNumber>
					</xsd:documentation>
				</xsd:annotation>
			</xsd:element>

			<!-- Amount Allocated To Beneficiaries -->
			<xsd:element name="AllocatedToBeneficiariesAmt" type="USAmountType" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>
						<Description>Amount allocated to beneficiaries</Description>
						<LineNumber>Line 5</LineNumber>
					</xsd:documentation>
				</xsd:annotation>
			</xsd:element>

			<!-- Estates And Trusts And Cooperatives -->
			<xsd:element name="EstatesTrustsCooperativesAmt" type="USAmountType" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>
						<Description>Estates and trusts and cooperatives</Description>
						<LineNumber>Line 6</LineNumber>
					</xsd:documentation>
				</xsd:annotation>
			</xsd:element>

		</xsd:sequence>
	</xsd:complexType>

	<!-- Number of Gallons Type Used Throughout Form 6478 -->
	<xsd:simpleType name="Form6478NumGallonsType">
		<xsd:restriction base="IntegerType">
			<xsd:totalDigits value="9"/>
		</xsd:restriction>
	</xsd:simpleType>

</xsd:schema>
