From: Mathieu Baudier Date: Mon, 13 Feb 2012 11:07:11 +0000 (+0000) Subject: Docuementation X-Git-Tag: argeo-slc-2.1.7~799 X-Git-Url: http://git.argeo.org/?a=commitdiff_plain;h=ff68bb057dae37c01cde18e0fddb27f6a420f658;p=gpl%2Fargeo-slc.git Docuementation git-svn-id: https://svn.argeo.org/slc/trunk@5066 4cfe0d0a-d680-48aa-b62c-e0a02a3f76cc --- diff --git a/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/ExecutionResources.java b/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/ExecutionResources.java index 0c6139811..2313942ec 100644 --- a/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/ExecutionResources.java +++ b/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/ExecutionResources.java @@ -20,6 +20,7 @@ import java.io.File; import org.springframework.core.io.Resource; +/** Provides write access to resources during execution */ public interface ExecutionResources { /** The base directory where this execution can write */ public File getWritableBaseDir(); diff --git a/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/FileExecutionResources.java b/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/FileExecutionResources.java index 646a1c156..3c3f77aeb 100644 --- a/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/FileExecutionResources.java +++ b/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/FileExecutionResources.java @@ -32,6 +32,7 @@ import org.springframework.core.io.FileSystemResource; import org.springframework.core.io.Resource; import org.springframework.util.Assert; +/** Implements write access to resources based on standard Java {@link File} */ public class FileExecutionResources implements ExecutionResources { private final static Log log = LogFactory .getLog(FileExecutionResources.class); @@ -40,8 +41,7 @@ public class FileExecutionResources implements ExecutionResources { .getProperty("java.io.tmpdir") + File.separator + "slc" - + File.separator - + DEFAULT_EXECUTION_RESOURCES_DIRNAME; + + File.separator + DEFAULT_EXECUTION_RESOURCES_DIRNAME; private File baseDir; private ExecutionContext executionContext; @@ -172,10 +172,9 @@ public class FileExecutionResources implements ExecutionResources { Assert.notNull(executionContext, "execution context is null"); String path = baseDir.getPath() + File.separator - + sdf() - .format( - executionContext - .getVariable(ExecutionContext.VAR_EXECUTION_CONTEXT_CREATION_DATE)) + + sdf().format( + executionContext + .getVariable(ExecutionContext.VAR_EXECUTION_CONTEXT_CREATION_DATE)) + executionContext.getUuid(); return new File(path); } else {