|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.schmant.tpm.TaskPackage
public class TaskPackage
This object contains information on a task package. It is managed by the
TaskPackageManager
.
Through this object, task packages can access their files.
TaskPackageManager
Method Summary | |
---|---|
void |
enable()
Enable this task package. |
TaskPackageClassLoader |
getClassLoader()
Get the class loader used for loading classes in this task package. |
String |
getClassLoaderName()
Get the name of the class loader that this task package will use. |
Set<String> |
getJavaPackageNames()
Get the names of the Java packages that should be automatically imported when this task package is enabled. |
String |
getName()
Get the task package's name. |
Directory |
getRootDirectory()
Get the task package's root directory. |
boolean |
isEnabled()
Is this task package enabled? |
EFile |
makeFileBacked(EFile f)
Make the file support the FCFileBacked
capability. |
EFile |
makeRandomlyAccessible(EFile f)
Make the file support the FCRandomAccess
capability. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public String getName()
org.schmant.task.base
.public Directory getRootDirectory()
public Set<String> getJavaPackageNames()
public String getClassLoaderName()
public TaskPackageClassLoader getClassLoader()
getClassLoaderName()
public boolean isEnabled()
true
if this task package is enabled.public void enable()
Enabling a task package makes all its classes available to the named
class loader used by it. By default the class loader name is the same as
the task package name, but this may be overridden by the task package
configuration if the task package wants to collaborate with classes from
another task package. See getClassLoaderName()
.
public EFile makeRandomlyAccessible(EFile f)
FCRandomAccess
capability.
If the file does not already do so (if the file is stored in a Zip file, for instance), it is copied to an in-memory file system that is specific for this task package.
f
- The file to make randomly accessible. The file must be somewhere
in this task package, i.e. somewhere under the directory returned by
getRootDirectory()
.
makeFileBacked(EFile)
public EFile makeFileBacked(EFile f)
FCFileBacked
capability. In other words: make sure that the file is backed by a
java.io.File
object.
If the file does not already is so (if the file is stored in a Zip file, for instance), it is copied to a temporary directory that is specific for this task package. The temporary file is deleted when the build script terminates.
f
- The file to make File
-backed. The file must be somewhere
in this task package, i.e. somewhere under the directory returned by
getRootDirectory()
.
File
object backing the file entity can be retrieved using the
ECFileResolvableUtil.getFileObject(org.entityfs.EntityView)
method.makeRandomlyAccessible(EFile)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |