title: Spring Batch - FlatFileItemWriter is creating folders when it doesnt exist. How to stop this?
body: <p>FlatFileItemWriter is creating the output folder when it does not exist, but I want it not to create the folder and throw an error instead. Can anybody please suggest how can I achieve this? 
  For example - I don't want the below temp folder to get created when it doesn't exist --</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code> 
  
  &lt;bean id="sampleWriter" class="com.test.writer.SampleWriter"
        scope="step"&gt;
      &lt;property name="shouldDeleteIfExists" value="true"/&gt;
      &lt;property name="resource"
                value="file://C:/temp/SAMPLE.txt"/&gt;
      &lt;property name="lineAggregator"&gt;
          &lt;bean class="org.springframework.batch.item.file.transform.DelimitedLineAggregator"&gt;
              &lt;property name="delimiter" value=","/&gt;
          &lt;/bean&gt;
      &lt;/property&gt;
  &lt;/bean&gt;</code></pre>
  </div>
  </div>
  </p>