public class WinMsiBundler extends AbstractBundler
Modifier and Type | Class and Description |
---|---|
(package private) static class |
WinMsiBundler.VersionExtractor |
Modifier and Type | Field and Description |
---|---|
static BundlerParamInfo<WinAppBundler> |
APP_BUNDLER |
private static java.lang.String |
AUTODETECT_DIRS |
static BundlerParamInfo<java.lang.Boolean> |
CAN_USE_WIX36 |
private int |
compId |
static BundlerParamInfo<java.io.File> |
CONFIG_ROOT |
private static java.util.ResourceBundle |
I18N |
private int |
id |
private static java.lang.String |
LAUNCHER_ID |
private static java.lang.String |
LAUNCHER_SVC_ID |
static BundlerParamInfo<java.io.File> |
MSI_IMAGE_DIR |
private static java.lang.String |
MSI_PROJECT_CONTENT_FILE |
private static java.lang.String |
MSI_PROJECT_TEMPLATE |
static StandardBundlerParam<java.lang.Boolean> |
MSI_SYSTEM_WIDE |
static StandardBundlerParam<java.lang.String> |
PRODUCT_VERSION |
static BundlerParamInfo<WinServiceBundler> |
SERVICE_BUNDLER |
private static java.lang.String |
TOOL_CANDLE |
static BundlerParamInfo<java.lang.String> |
TOOL_CANDLE_EXECUTABLE |
private static java.lang.String |
TOOL_LIGHT |
static BundlerParamInfo<java.lang.String> |
TOOL_LIGHT_EXECUTABLE |
private static java.lang.String |
TWEAK_FOR_EXCLUDING_LICENSE
Overrides the dialog sequence in built-in dialog set "WixUI_InstallDir"
to exclude license dialog
|
static BundlerParamInfo<java.util.UUID> |
UPGRADE_UUID |
static BundlerParamInfo<java.io.File> |
WIN_APP_IMAGE |
baseResourceLoader, BUNDLER_PREFIX, IMAGES_ROOT
Constructor and Description |
---|
WinMsiBundler() |
Modifier and Type | Method and Description |
---|---|
private java.io.File |
buildMSI(java.util.Map<java.lang.String,? super java.lang.Object> params,
java.io.File outdir) |
java.io.File |
bundle(java.util.Map<java.lang.String,? super java.lang.Object> p,
java.io.File outdir) |
protected void |
cleanupConfigFiles(java.util.Map<java.lang.String,? super java.lang.Object> params) |
static void |
ensureByMutationFileIsRTF(java.io.File f) |
java.io.File |
execute(java.util.Map<java.lang.String,? super java.lang.Object> params,
java.io.File outputParentDir)
Creates a bundle from existing content.
|
private static double |
findToolVersion(java.lang.String toolName) |
private java.lang.String |
getAppCDSBlock(java.util.Map<java.lang.String,? super java.lang.Object> params) |
java.util.Collection<BundlerParamInfo<?>> |
getBundleParameters()
The parameters that this bundler uses to generate it's bundle.
|
java.lang.String |
getBundleType() |
private java.io.File |
getConfig_ProjectFile(java.util.Map<java.lang.String,? super java.lang.Object> params) |
private java.io.File |
getConfig_Script(java.util.Map<java.lang.String,? super java.lang.Object> params) |
java.lang.String |
getDescription() |
java.lang.String |
getID() |
private java.lang.String |
getLicenseFile(java.util.Map<java.lang.String,? super java.lang.Object> params) |
static java.util.Collection<BundlerParamInfo<?>> |
getMsiBundleParameters() |
java.lang.String |
getName() |
(package private) java.lang.String |
getRegistryRoot(java.util.Map<java.lang.String,? super java.lang.Object> params) |
private java.lang.String |
getUIBlock(java.util.Map<java.lang.String,? super java.lang.Object> params)
Creates UI element using WiX built-in dialog sets - WixUI_InstallDir/WixUI_Minimal.
|
(package private) static boolean |
isVersionStringValid(java.lang.String v) |
private boolean |
prepareBasicProjectConfig(java.util.Map<java.lang.String,? super java.lang.Object> params) |
(package private) boolean |
prepareContentList(java.util.Map<java.lang.String,? super java.lang.Object> params) |
(package private) boolean |
prepareMainProjectFile(java.util.Map<java.lang.String,? super java.lang.Object> params) |
private boolean |
prepareProto(java.util.Map<java.lang.String,? super java.lang.Object> p) |
private boolean |
prepareWiXConfig(java.util.Map<java.lang.String,? super java.lang.Object> params) |
private java.lang.String |
relativePath(java.io.File basedir,
java.io.File file) |
boolean |
validate(java.util.Map<java.lang.String,? super java.lang.Object> p)
Determines if this bundler will execute with the given parameters.
|
private void |
walkFileTree(java.util.Map<java.lang.String,? super java.lang.Object> params,
java.io.File root,
java.io.PrintStream out,
java.lang.String prefix) |
fetchResource, fetchResource, preprocessTextResource, toString
private static final java.util.ResourceBundle I18N
public static final BundlerParamInfo<WinAppBundler> APP_BUNDLER
public static final BundlerParamInfo<WinServiceBundler> SERVICE_BUNDLER
public static final BundlerParamInfo<java.lang.Boolean> CAN_USE_WIX36
public static final BundlerParamInfo<java.io.File> CONFIG_ROOT
public static final BundlerParamInfo<java.io.File> MSI_IMAGE_DIR
public static final BundlerParamInfo<java.io.File> WIN_APP_IMAGE
public static final StandardBundlerParam<java.lang.Boolean> MSI_SYSTEM_WIDE
public static final StandardBundlerParam<java.lang.String> PRODUCT_VERSION
public static final BundlerParamInfo<java.util.UUID> UPGRADE_UUID
private static final java.lang.String TOOL_CANDLE
private static final java.lang.String TOOL_LIGHT
private static final java.lang.String AUTODETECT_DIRS
public static final BundlerParamInfo<java.lang.String> TOOL_CANDLE_EXECUTABLE
public static final BundlerParamInfo<java.lang.String> TOOL_LIGHT_EXECUTABLE
private int id
private int compId
private static final java.lang.String LAUNCHER_ID
private static final java.lang.String LAUNCHER_SVC_ID
private static final java.lang.String TWEAK_FOR_EXCLUDING_LICENSE
private static final java.lang.String MSI_PROJECT_TEMPLATE
private static final java.lang.String MSI_PROJECT_CONTENT_FILE
public java.lang.String getName()
public java.lang.String getDescription()
public java.lang.String getID()
public java.lang.String getBundleType()
public java.util.Collection<BundlerParamInfo<?>> getBundleParameters()
Bundler
public static java.util.Collection<BundlerParamInfo<?>> getMsiBundleParameters()
public java.io.File execute(java.util.Map<java.lang.String,? super java.lang.Object> params, java.io.File outputParentDir)
Bundler
Bundler.validate(java.util.Map)
date} returns true with the
parameters map, then you can expect a valid output. However if an exception
was thrown out of validate or it returned false then you should not
expect sensible results from this call. It may or may not return a value,
and it may or may not throw an exception. But any output should not
be considered valid or sane.params
- The parameters as specified by getBundleParameters.
Keyed by the id from the ParamInfo. Execution may
modify the map, so if you are going to be using the
same map across multiple bundlers you should pass
in a deep copy.outputParentDir
- The parent dir that the returned bundle will be placed in.private static double findToolVersion(java.lang.String toolName)
public boolean validate(java.util.Map<java.lang.String,? super java.lang.Object> p) throws UnsupportedPlatformException, ConfigException
Bundler
p
- The parameters to be validate. Validation may modify
the map, so if you are going to be using the same map
across multiple bundlers you should pass in a deep copy.UnsupportedPlatformException
- If the bundler cannot run on this
platform (i.e. creating mac apps on windows)ConfigException
- If the configuration params are incorrect. The
exception may contain advice on how to modify the params map
to make it valid.static boolean isVersionStringValid(java.lang.String v)
private boolean prepareProto(java.util.Map<java.lang.String,? super java.lang.Object> p) throws java.io.IOException
java.io.IOException
public java.io.File bundle(java.util.Map<java.lang.String,? super java.lang.Object> p, java.io.File outdir)
protected void cleanupConfigFiles(java.util.Map<java.lang.String,? super java.lang.Object> params)
private java.io.File getConfig_Script(java.util.Map<java.lang.String,? super java.lang.Object> params)
private boolean prepareBasicProjectConfig(java.util.Map<java.lang.String,? super java.lang.Object> params) throws java.io.IOException
java.io.IOException
private java.lang.String relativePath(java.io.File basedir, java.io.File file)
boolean prepareMainProjectFile(java.util.Map<java.lang.String,? super java.lang.Object> params) throws java.io.IOException
java.io.IOException
private java.lang.String getUIBlock(java.util.Map<java.lang.String,? super java.lang.Object> params)
private java.lang.String getAppCDSBlock(java.util.Map<java.lang.String,? super java.lang.Object> params)
private void walkFileTree(java.util.Map<java.lang.String,? super java.lang.Object> params, java.io.File root, java.io.PrintStream out, java.lang.String prefix)
java.lang.String getRegistryRoot(java.util.Map<java.lang.String,? super java.lang.Object> params)
boolean prepareContentList(java.util.Map<java.lang.String,? super java.lang.Object> params) throws java.io.FileNotFoundException
java.io.FileNotFoundException
private java.io.File getConfig_ProjectFile(java.util.Map<java.lang.String,? super java.lang.Object> params)
private java.lang.String getLicenseFile(java.util.Map<java.lang.String,? super java.lang.Object> params)
private boolean prepareWiXConfig(java.util.Map<java.lang.String,? super java.lang.Object> params) throws java.io.IOException
java.io.IOException
private java.io.File buildMSI(java.util.Map<java.lang.String,? super java.lang.Object> params, java.io.File outdir) throws java.io.IOException
java.io.IOException
public static void ensureByMutationFileIsRTF(java.io.File f)