<?xml version="1.0" encoding="Shift_JIS"?>

<!-- 帋尡枾搙應掕傪峴側偆價儖僪僼傽僀儖丅 -->

<project name="" basedir=".." default="count">
	
  <target name="usage">
	<echo message=""/>
	<echo message="帋尡枾搙應掕傪峴側偆價儖僪僼傽僀儖丅"/>
	<echo message="----------------------------------------------------------"/>
  	<echo message="亂娐嫬愝掕亃"/>
	<echo message="僣乕儖乽jensity乿傪巊梡偡傞丅"/>
	<echo message="帋尡枾搙偺應掕偵偼僥僗僩懳徾僋儔僗偺僜乕僗僐乕僪乮.java偲.class乯丄"/>
	<echo message="僥僗僩僋儔僗乮.class)偑昁梫丅"/>
	<echo message="傑偨丄幚峴娐嫬偺僷僗偵jensity.jar丄bcel-5.2.jar丄stepcounter.jar丄"/>
	<echo message="jensity-style.xsl偑昁梫偲側傞丅"/>
  	<echo message="----------------------------------------------------------"/>
  	<echo message="亂幚峴壜擻側僞僗僋亃"/>
  	<echo message="count  --> 帋尡枾搙應掕偺幚峴"/>
  	<echo message="丒弌椡偝傟傞僼傽僀儖:${test.root}/dentityReports/result.html"/>
	<echo message=""/>
  </target>

  <!-- 仠仠仠仠仠 娐嫬愝掕 仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭 -->
  <!-- build僨傿儗僋僩儕 -->
  <property name="build.dir" value="${basedir}/ant" />

  <!-- 仠仠仠仠仠 僾儘僷僥傿僼傽僀儖愝掕 仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭 -->
  <property file="${build.dir}/jensitybuild.properties" />

  <!-- 仠仠仠仠仠 僋儔僗僷僗偺愝掕 仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭 -->
  <!-- 仩${jensity.lib}偺僨傿儗僋僩儕偵jensity.jar丄bcel-5.2.jar丄stepcounter.jar丄-->
  <!--   jensity-style.xsl傪巜掕偡傞昁梫偑偁傝傑偡 -->
  <property name="jensity.classpath"
    value="${jensity.lib}/jensity.jar;
      ${jensity.lib}/bcel-5.2.jar;
      ${jensity.lib}/stepcounter.jar;" />

	
  <!-- 仠仠仠仠仠 帋尡枾搙應掕梡僾儘僷僥傿 仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭 -->
  <!-- 拞娫XML僼傽僀儖偺弌椡愭 -->
  <property name="density.report.xml.dir" value="${result.dir}/xml" />
  
  <!-- 僥僗僩僋儔僗偺僒僼傿僢僋僗 -->
  <property name="density.test.suffix" value="Test[0-9]*" />
  <property name="lower" value="65" />   <!-- 帋尡枾搙偺嫋梕壓尷抣 -->
  <property name="upper" value="350" />  <!-- 帋尡枾搙偺嫋梕忋尷抣 -->
  
  <!-- 仠仠仠仠仠 jensity僞僗僋 仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭 -->
  <taskdef name="density"
	classname="jp.co.nttdata.terasoluna.jensity.DensityTask"
	classpath="${jensity.classpath}}" />
	    
  <!-- 仭仭仭仭仭 帋尡枾搙應掕 幚峴 仭仭仭仭仭 -->
  <target name="count">
    <!-- 僼傽僀儖弌椡愭僨傿儗僋僩儕嶌惉 -->
    <delete dir="${result.dir}" />
    <mkdir dir="${result.dir}" />
    <mkdir dir="${density.report.xml.dir}" />
  	
  	<!-- 僜乕僗僐乕僪(僋儔僗僼傽僀儖乯亄僥僗僩僐乕僪乮僋儔僗僼傽僀儖乯傪儅乕僕偡傞 -->
  	<!-- 乮jensity偱偼僋儔僗僼傽僀儖偺僨傿儗僋僩儕傪侾偮偟偐巜掕偱偒側偄偨傔乯 -->
  	<property name="temp.class.dir" value="${result.dir}/temp/classes" />
  	<mkdir dir="${temp.class.dir}"/>
  	<copy todir="${temp.class.dir}" preservelastmodified="true">
      <fileset dir="${class.dir}">
	    <include name="**/*.class"/>
	  </fileset>
	</copy>
  	<copy todir="${temp.class.dir}" preservelastmodified="true">
      <fileset dir="${testclass.dir}">
	    <include name="**/*.class"/>
	  </fileset>
	</copy>

    <!-- 帋尡枾搙應掕乮XML儗億乕僩弌椡乯 -->
    <!-- classdir   : 僋儔僗僼傽僀儖偺奿擺愭乮侾偮偟偐巜掕偱偒傑偣傫乯
         destdir    : 拞娫XML儗億乕僩偺弌椡
         testsuffix : 僥僗僩僋儔僗偺僒僼傿僢僋僗乮徣棯偟偨応崌偼"Test"乯
         fileset    : 應掕懳徾偺僜乕僗僼傽僀儖 -->
    <density classdir="${temp.class.dir}"
	   destdir="${density.report.xml.dir}" 
	   testsuffix="${density.test.suffix}" >
	  <fileset dir="${src.dir}">
        <include name="jp/terasoluna/fw/**/*.java" />
	  </fileset>
	</density>
		
	<!-- XML儗億乕僩偐傜HTML儗億乕僩傊曄姺 -->
    <style basedir="${density.report.xml.dir}" destdir="${result.dir}" 
           extension=".html" 
    	   style="${jensity.lib}/jensity-style.xsl">
      <param name="lower" expression="${lower}" />
      <param name="upper" expression="${upper}" />
    </style>
  	
  	<!-- 嶌嬈梡僼傽僀儖嶍彍  -->
  	<delete dir="${result.dir}/temp" />
  </target> 

 </project>
 