<commit_before><?xml version="1.0"?>

<!--
	Similar to main build file, but using Commons Attributes to deliver
	autoproxying: no need to use TransactionProxyFactoryBean.
-->
<project name="jpetstore-attributes" basedir=".." default="usage">

	<property name="name" value="jpetstore"/>

	<property name="war.dir" value="war"/>
	<property name="src.dir" value="src"/>
	<property name="client.dir" value="client"/>
	<property name="build.dir" value=".classes"/>
	<property name="weblib.dir" value="${war.dir}/WEB-INF/lib"/>
	<property name="dist.dir" value="dist"/>

	<property name="spring.root" value="../.."/>

	<!--
		Set the directory where Java source files generated by Commons Attributes
		will be written.
	-->
	<property name="commons.attributes.tempdir" value=".atts"/>


	<path id="attribute-compiler-classpath">

		<fileset dir="${spring.root}/lib/jakarta-commons">
			<include name="commons-attributes-compiler-SNAPSHOT.jar"/>
			<include name="commons-collections.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/xdoclet">
			<include name="xjavadoc-1.0.jar"/>
		</fileset>

	</path>


	<path id="master-classpath">

		<fileset dir="${spring.root}/lib/aop-alliance">
			<include name="aopalliance.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/axis">
			<include name="axis.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/ibatis">
			<include name="ibatis-db.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/j2ee">
			<include name="jaxrpc.jar"/>
			<include name="jdbc2_0-stdext.jar"/>
			<include name="servlet.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/jakarta-commons">
			<include name="commons-attributes-api*.jar"/>
			<include name="commons-logging.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/struts">
			<include name="struts-1.1.jar"/>
		</fileset>
		<fileset dir="${spring.root}/dist">
			<include name="spring.jar"/>
		</fileset>

	</path>


	<target name="usage">

		<echo message=""/>
		<echo message="Spring JPetStore build file"/>
		<echo message="------------------------------------------------------"/>
		<echo message=""/>
		<echo message="Available targets are:"/>
		<echo message=""/>
		<echo message="clean    --> Clean output dirs"/>
		<echo message="build    --> Compile main Java sources and copy libraries"/>
		<echo message="warfile  --> Build the web application archive"/>
		<echo message="all      --> Clean, build, warfile"/>
		<echo message=""/>

	</target>


	<target name="clean" description="Clean output dirs (build, weblib, dist)">

		<delete dir="${build.dir}"/>
		<delete dir="${weblib.dir}"/>
		<delete dir="${dist.dir}"/>
		<delete dir="${commons.attributes.tempdir}"/>

	</target>


	<!--
		Compile attributes with Jakarta Commons Attributes.
		It will generate source files in the $commons.attributes.tempdir
		directory. These must then be compiled along with the application
		Java sources in the build target below.
	-->
	<target name="compileAttributes" >
	
		<!-- Bring in Jakarta Commons attribute compilation -->
		<taskdef resource="org/apache/commons/attributes/anttasks.properties">
			<classpath refid="attribute-compiler-classpath"/>
		</taskdef>

	 	<!-- Compile to a temp directory: Commons Attributes will place Java Source here. -->
	  <attribute-compiler destdir="${commons.attributes.tempdir}">
			<fileset dir="${src.dir}" includes="**/*.java"/>
		</attribute-compiler>

 	</target>


	<target name="build" depends="compileAttributes"
		description="Compile main source tree java files into class files, generate jar files">

		<mkdir dir="${build.dir}"/>

		<javac destdir="${build.dir}" target="1.3" debug="true"
			deprecation="false" optimize="false" failonerror="true">
			<src path="${src.dir}"/>
			<src path="${commons.attributes.tempdir}"/>
			<classpath refid="master-classpath"/>
		</javac>

		<copy todir="${build.dir}" preservelastmodified="true">
			<fileset dir="${src.dir}">
				<include name="**/*.xml"/>
			</fileset>
		</copy>

		<mkdir dir="${weblib.dir}"/>

		<jar jarfile="${weblib.dir}/${name}.jar" compress="true" basedir="${build.dir}"/>

		<copy todir="${weblib.dir}" preservelastmodified="true">
			<fileset dir="${spring.root}/lib/aop-alliance">
				<include name="aopalliance.jar"/>
			</fileset>
			<fileset dir="${spring.root}/lib/axis">
				<include name="axis.jar"/>
				<include name="saaj.jar"/>
				<include name="wsdl4j.jar"/>
			</fileset>
			<fileset dir="${spring.root}/lib/caucho">
				<include name="burlap*.jar"/>
				<include name="hessian*.jar"/>
			</fileset>
			<fileset dir="${spring.root}/lib/hsqldb">
				<include name="hsqldb.jar"/>
			</fileset>
			<fileset dir="${spring.root}/lib/ibatis">
				<include name="ibatis-db.jar"/>
			</fileset>
			<fileset dir="${spring.root}/lib/j2ee">
				<include name="jaxrpc.jar"/>
				<include name="jstl.jar"/>
			</fileset><commit_msg>include ibatis-common and ibatis-sqlmap instead of ibatis-db<commit_after><?xml version="1.0"?>

<!--
	Similar to main build file, but using Commons Attributes to deliver
	autoproxying: no need to use TransactionProxyFactoryBean.
-->
<project name="jpetstore-attributes" basedir=".." default="usage">

	<property name="name" value="jpetstore"/>

	<property name="war.dir" value="war"/>
	<property name="src.dir" value="src"/>
	<property name="client.dir" value="client"/>
	<property name="build.dir" value=".classes"/>
	<property name="weblib.dir" value="${war.dir}/WEB-INF/lib"/>
	<property name="dist.dir" value="dist"/>

	<property name="spring.root" value="../.."/>

	<!--
		Set the directory where Java source files generated by Commons Attributes
		will be written.
	-->
	<property name="commons.attributes.tempdir" value=".atts"/>


	<path id="attribute-compiler-classpath">

		<fileset dir="${spring.root}/lib/jakarta-commons">
			<include name="commons-attributes-compiler-SNAPSHOT.jar"/>
			<include name="commons-collections.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/xdoclet">
			<include name="xjavadoc-1.0.jar"/>
		</fileset>

	</path>


	<path id="master-classpath">

		<fileset dir="${spring.root}/lib/aop-alliance">
			<include name="aopalliance.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/axis">
			<include name="axis.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/ibatis">
			<include name="ibatis-db.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/j2ee">
			<include name="jaxrpc.jar"/>
			<include name="jdbc2_0-stdext.jar"/>
			<include name="servlet.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/jakarta-commons">
			<include name="commons-attributes-api*.jar"/>
			<include name="commons-logging.jar"/>
		</fileset>
		<fileset dir="${spring.root}/lib/struts">
			<include name="struts-1.1.jar"/>
		</fileset>
		<fileset dir="${spring.root}/dist">
			<include name="spring.jar"/>
		</fileset>

	</path>


	<target name="usage">

		<echo message=""/>
		<echo message="Spring JPetStore build file"/>
		<echo message="------------------------------------------------------"/>
		<echo message=""/>
		<echo message="Available targets are:"/>
		<echo message=""/>
		<echo message="clean    --> Clean output dirs"/>
		<echo message="build    --> Compile main Java sources and copy libraries"/>
		<echo message="warfile  --> Build the web application archive"/>
		<echo message="all      --> Clean, build, warfile"/>
		<echo message=""/>

	</target>


	<target name="clean" description="Clean output dirs (build, weblib, dist)">

		<delete dir="${build.dir}"/>
		<delete dir="${weblib.dir}"/>
		<delete dir="${dist.dir}"/>
		<delete dir="${commons.attributes.tempdir}"/>

	</target>


	<!--
		Compile attributes with Jakarta Commons Attributes.
		It will generate source files in the $commons.attributes.tempdir
		directory. These must then be compiled along with the application
		Java sources in the build target below.
	-->
	<target name="compileAttributes" >
	
		<!-- Bring in Jakarta Commons attribute compilation -->
		<taskdef resource="org/apache/commons/attributes/anttasks.properties">
			<classpath refid="attribute-compiler-classpath"/>
		</taskdef>

	 	<!-- Compile to a temp directory: Commons Attributes will place Java Source here. -->
	  <attribute-compiler destdir="${commons.attributes.tempdir}">
			<fileset dir="${src.dir}" includes="**/*.java"/>
		</attribute-compiler>

 	</target>


	<target name="build" depends="compileAttributes"
		description="Compile main source tree java files into class files, generate jar files">

		<mkdir dir="${build.dir}"/>

		<javac destdir="${build.dir}" target="1.3" debug="true"
			deprecation="false" optimize="false" failonerror="true">
			<src path="${src.dir}"/>
			<src path="${commons.attributes.tempdir}"/>
			<classpath refid="master-classpath"/>
		</javac>

		<copy todir="${build.dir}" preservelastmodified="true">
			<fileset dir="${src.dir}">
				<include name="**/*.xml"/>
			</fileset>
		</copy>

		<mkdir dir="${weblib.dir}"/>

		<jar jarfile="${weblib.dir}/${name}.jar" compress="true" basedir="${build.dir}"/>

		<copy todir="${weblib.dir}" preservelastmodified="true">
			<fileset dir="${spring.root}/lib/aop-alliance">
				<include name="aopalliance.jar"/>
			</fileset>
			<fileset dir="${spring.root}/lib/axis">
				<include name="axis.jar"/>
				<include name="saaj.jar"/>
				<include name="wsdl4j.jar"/>
			</fileset>
			<fileset dir="${spring.root}/lib/caucho">
				<include name="burlap*.jar"/>
				<include name="hessian*.jar"/>
			</fileset>
			<fileset dir="${spring.root}/lib/hsqldb">
				<include name="hsqldb.jar"/>
			</fileset>
			<fileset dir="${spring.root}/lib/ibatis">
				<include name="ibatis-common.jar"/>
				<include name="ibatis-sqlmap.jar"/>
			</fileset>
			<fileset dir="${spring.root}/lib/j2ee">
				<include name="jaxrpc.jar"/>
				<include name="jstl.jar"/>
			</fileset>
{'fraction_non_alphanumeric': 0.20739303584192792, 'fraction_numerical': 0.0026549576227917903, 'mean_word_length': 3.860545905707196, 'pattern_counts': {'":': 0, '<': 234, '<?xml version=': 2, '>': 242, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 4}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6330151', 'n_tokens_mistral': 3533, 'n_tokens_neox': 3141, 'n_words': 683}