<xsd:schema id="slicerConfig" version="1.0" xml:lang="en"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:slicer="http://indus.projects.cis.ksu.edu/slicer"
    targetNamespace="http://indus.projects.cis.ksu.edu/slicer"
    elementFormDefault="qualified"
    attributeFormDefault="qualified"
    blockDefault="restriction"
    finalDefault="restriction">

	<xsd:element id="criteria" name="criteria">
		<xsd:annotation>
			<xsd:appinfo>
	          Collection of Criterion
    	    </xsd:appinfo>
	        <xsd:documentation>
    	      This is a set of criterion specifications.
        	</xsd:documentation>
      </xsd:annotation>
      <xsd:complexType>
        <xsd:sequence>
          <xsd:element name="criterion" type="slicer:criterion" minOccurs="1" maxOccurs="unbounded"/>
        </xsd:sequence>
      </xsd:complexType>
	</xsd:element>

	<xsd:attribute name="index" type="xsd:nonNegativeInteger"/>			

	<xsd:complexType name="expr">
		<xsd:attribute ref="slicer:index" use="required">
			<xsd:annotation>
		        <xsd:documentation>
    		      This is 0-offset index of the expression in the list of use-def boxes of the enclosing statement.
        		</xsd:documentation>
	     	</xsd:annotation>
		</xsd:attribute>
	</xsd:complexType>

	<xsd:complexType name="stmt">
		<xsd:attribute ref="slicer:index" use="required">
			<xsd:annotation>
		        <xsd:documentation>
    		      This is 0-offset index of the statement in the statement list of the enclosing method.
        		</xsd:documentation>
	      </xsd:annotation>
		</xsd:attribute>
		<xsd:attribute name="considerEntireStmt" type="xsd:boolean" use="required"/>
	</xsd:complexType>

	<xsd:complexType id="criterion" name="criterion">
		<xsd:annotation>
	        <xsd:documentation>
    	      This is the criterion.
      		</xsd:documentation>
	   	</xsd:annotation>		
		<xsd:sequence>
			<xsd:element name="className" type="xsd:string"/>
			<xsd:element name="method" type="slicer:method"/>
			<xsd:element name="stmt" type="slicer:stmt" minOccurs="0" maxOccurs="1"/>
			<xsd:element name="expr" type="slicer:expr" minOccurs="0" maxOccurs="1"/>
		</xsd:sequence>
		<xsd:attribute name="considerExecution" type="xsd:boolean" use="optional"/>
	</xsd:complexType>

	<xsd:complexType id="method" name="method">
		<xsd:annotation>
			<xsd:documentation>
			As for specifying types, provide the fully-qualified names of the types as specified in the class file.  So, the name of 
			java.lang.String array type would written as "java.lang.String[".
			</xsd:documentation>
		</xsd:annotation>
		<xsd:sequence>
			<xsd:element name="methodName" type="xsd:string"/>
			<xsd:element name="returnTypeName" type="xsd:string"/>
			<xsd:element name="parameters">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element name="parameterTypeName" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
		</xsd:sequence>
	</xsd:complexType>

</xsd:schema>