public class TemplateUtilities
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
TemplateUtilities.ConfigInfo |
Constructor and Description |
---|
TemplateUtilities() |
Modifier and Type | Method and Description |
---|---|
static TemplateUtilities.ConfigInfo |
getConfigInfo(java.io.File f) |
static java.io.File |
getTemplateFile(WorkDirectory wd)
Get the path to the template associated with the work dir.
|
static java.lang.String |
getTemplateFromWd(java.io.File dir)
Using a lightweight method,, find out if and which template is associated
with a work dir.
|
static java.lang.String |
getTemplatePath(WorkDirectory wd)
Get the path to the template associated with the work dir.
|
static boolean |
isTemplate(java.io.File f) |
static void |
setTemplateFile(WorkDirectory wd,
java.io.File t,
boolean changeable)
Associate a template file with a work directory.
|
public static java.io.File getTemplateFile(WorkDirectory wd)
wd
- The work directory to query.public static java.lang.String getTemplatePath(WorkDirectory wd)
wd
- The work directory to query.public static void setTemplateFile(WorkDirectory wd, java.io.File t, boolean changeable) throws java.io.IOException
wd
- Work dir to operate on.t
- Template file to associate the work directory with.changeable
- Can the workdir be later associated with a
different template? Not currently used.java.io.IOException
- If the complete path to the template file
cannot be resolve, or if there is an error writing to
the work dir.public static java.lang.String getTemplateFromWd(java.io.File dir) throws java.io.IOException
java.io.IOException
- If there are problems getting the template information,
which usually means there is a problem reading the workdir.public static boolean isTemplate(java.io.File f) throws java.io.IOException
java.io.IOException
public static TemplateUtilities.ConfigInfo getConfigInfo(java.io.File f) throws java.io.IOException
java.io.IOException
Copyright (c) 1996, 2011, Oracle and/or its affiliates. All rights reserved.