public class DownloadLatestZipFromRepo extends Object
Constructor and Description |
---|
DownloadLatestZipFromRepo() |
Modifier and Type | Method and Description |
---|---|
static void |
downloadLatestZipFromRepo(URL jarPath)
Downloads the latest deploy from the genesis maven repository of the
artifact of the jarPath, starts it without arguments and removes the old
jar if there was an update.
|
static void |
downloadLatestZipFromRepo(URL jarPath,
boolean deleteOldFiles,
boolean startDownloadedVersion)
Downloads the latest deploy from the genesis maven repository of the
artifact and starts it without arguments.
|
static void |
downloadLatestZipFromRepo(URL jarPath,
boolean deleteOldFiles,
String[] args,
boolean startDownloadedVersion)
Downloads the latest zip archive of the jar in the url from the genesis
maven repo.
|
static void |
downloadLatestZipFromRepo(URL jarPath,
boolean deleteOldFiles,
String[] args,
URL jarRepository)
Downloads the latest zip archive of the jar in the url from a given
jarRepository.
|
static void |
downloadLatestZipFromRepo(URL jarPath,
boolean deleteOldFiles,
String iconName,
String[] args,
URL jarRepository,
boolean startDownloadedVersion)
Retrieves the latest version of a maven jar file from a maven repository,
also checks if the environment is headless or not.
|
static void |
downloadLatestZipFromRepo(URL jarPath,
boolean deleteOldFiles,
String iconName,
String[] args,
URL jarRepository,
boolean startDownloadedVersion,
FileDAO fileDAO)
Retrieves the latest version of a maven jar file from a maven repository.
|
public static void downloadLatestZipFromRepo(URL jarPath) throws IOException, XMLStreamException, URISyntaxException
jarPath
- the path to the jarfileIOException
- should there be problems with reading or writing
files during the updatingXMLStreamException
- if there was a problem reading the meta data
from the remote maven repositoryURISyntaxException
public static void downloadLatestZipFromRepo(URL jarPath, boolean deleteOldFiles, boolean startDownloadedVersion) throws IOException, XMLStreamException, URISyntaxException
jarPath
- the path to the jarfiledeleteOldFiles
- if the jar who starts the update should be deletedstartDownloadedVersion
- if the newly downloaded jar should be
started after downloadIOException
- should there be problems with reading or writing
files during the updatingXMLStreamException
- if there was a problem reading the meta data
from the remote maven repositoryURISyntaxException
public static void downloadLatestZipFromRepo(URL jarPath, boolean deleteOldFiles, String[] args, boolean startDownloadedVersion) throws IOException, XMLStreamException, URISyntaxException
jarPath
- the path to the jarfile to updatedeleteOldFiles
- if the original jar file should be deletedargs
- the args for the newly downloaded jar when it startsstartDownloadedVersion
- if true, the downloaded version will be
started when the download completesIOException
- should there be problems with reading or writing
files during the updatingXMLStreamException
- if there was a problem reading the meta data
from the remote maven repositoryURISyntaxException
public static void downloadLatestZipFromRepo(URL jarPath, boolean deleteOldFiles, String[] args, URL jarRepository) throws IOException, XMLStreamException, URISyntaxException
jarPath
- the path to the jarfile to update, cannot be null
deleteOldFiles
- if the original jar folder should be deleted,
cannot be null
args
- the args for the newly downloaded jar when it startsjarRepository
- the repository to look for the latest deploy of the
jar file, cannot be null
IOException
- should there be problems with reading or writing
files during the updatingXMLStreamException
- if there was a problem reading the meta data
from the remote maven repositoryURISyntaxException
public static void downloadLatestZipFromRepo(URL jarPath, boolean deleteOldFiles, String iconName, String[] args, URL jarRepository, boolean startDownloadedVersion) throws IOException, XMLStreamException, URISyntaxException
jarPath
- the URL of the location of the jar that needs to be
updated on the file system. cannot be null
deleteOldFiles
- should the old installation be removed or not
cannot be null
iconName
- name of the shortcut image should one be createdargs
- the args that will be passed to the newly downloaded program
when started, cannot be null
jarRepository
- the maven repository to go look in, cannot be
null
startDownloadedVersion
- if the newly downloaded version should be
started automatically or notIOException
- should there be problems with reading or writing
files during the updatingXMLStreamException
- if there was a problem reading the meta data
from the remote maven repositoryURISyntaxException
public static void downloadLatestZipFromRepo(URL jarPath, boolean deleteOldFiles, String iconName, String[] args, URL jarRepository, boolean startDownloadedVersion, FileDAO fileDAO) throws IOException, XMLStreamException, URISyntaxException
jarPath
- the URL of the location of the jar that needs to be
updated on the file system. cannot be null
deleteOldFiles
- should the old installation be removed or not
cannot be null
iconName
- name of the shortcut image should one be createdargs
- the args that will be passed to the newly downloaded program
when started, cannot be null
jarRepository
- the maven repository to go look in, cannot be
null
startDownloadedVersion
- if the newly downloaded version should be
started automatically or notfileDAO
- what implementation of FileDAO should be used in the
updatingIOException
- should there be problems with reading or writing
files during the updatingXMLStreamException
- if there was a problem reading the meta data
from the remote maven repositoryURISyntaxException
Copyright © 2013. All Rights Reserved.