| Package | Description |
|---|---|
| org.expath.pkg.repo | |
| org.expath.pkg.repo.deps | |
| org.expath.pkg.repo.parser | |
| org.expath.pkg.repo.tools | |
| org.expath.pkg.repo.tui |
| Modifier and Type | Class and Description |
|---|---|
static class |
Repository.AlreadyInstalledException
Exception raised when trying to install a package already installed.
|
static class |
Repository.HttpException
Exception raised when receiving 404 when trying to read a package on the web.
|
static class |
Repository.NotFoundException
Exception raised when receiving 404 when trying to read a package on the web.
|
static class |
Repository.OnlineException
Exception raised when receiving an error when trying to read a package on the web.
|
| Modifier and Type | Method and Description |
|---|---|
java.util.List<PackageException> |
Repository.init()
Initialise the repository.
|
java.util.List<PackageException> |
Repository.reload()
Reload the repository configuration, so parse again the package descriptors.
|
| Modifier and Type | Method and Description |
|---|---|
void |
Package.addInfo(java.lang.String name,
PackageInfo info)
Set the info object for the given name.
|
void |
Package.addPackageDep(java.lang.String pkg,
java.lang.String versions,
java.lang.String semver,
java.lang.String min,
java.lang.String max)
Add a dependency on a package.
|
void |
Package.addPublicUri(URISpace space,
java.lang.String href,
java.lang.String relative) |
boolean |
UserInteractionStrategy.ask(java.lang.String prompt,
boolean dflt)
Ask something to the user (the response must be a
boolean.) |
java.lang.String |
UserInteractionStrategy.ask(java.lang.String prompt,
java.lang.String dflt)
Ask something to the user (the response must be a
String.) |
void |
FileSystemStorage.beforeInstall(boolean force,
UserInteractionStrategy interact) |
void |
ClasspathStorage.beforeInstall(boolean force,
UserInteractionStrategy interact) |
abstract void |
Storage.beforeInstall(boolean force,
UserInteractionStrategy interact)
The opportunity to do anything before the install of a package.
|
static Repository |
Repository.createRepository(java.nio.file.Path dir)
Create a repository.
|
static void |
FileHelper.ensureDir(java.nio.file.Path dir)
Create a directory if it does not exist yet.
|
java.net.URI |
ClasspathStorage.ClasspathResolver.getContentDirBaseURI() |
abstract java.net.URI |
Storage.PackageResolver.getContentDirBaseURI()
The base URI of the package "content directory".
|
void |
Extension.init(Repository repo,
java.util.Map<java.lang.String,Packages> packages)
Deprecated.
|
void |
DescriptorExtension.init(Repository repo,
Package pkg) |
abstract void |
Extension.init(Repository repo,
Package pkg)
Initialize a package for a specific extension.
|
abstract void |
Extension.install(Repository repo,
Package pkg)
Additional installation actions needed by a specific extension.
|
Package |
Repository.installPackage(java.net.URI pkg,
boolean force,
UserInteractionStrategy interact)
Install a XAR package into this repository, from a URI location.
|
Package |
Repository.installPackage(XarSource xarSource,
boolean force,
UserInteractionStrategy interact)
Install a XAR package into this repository.
|
java.util.Set<java.lang.String> |
FileSystemStorage.listPackageDirectories() |
java.util.Set<java.lang.String> |
ClasspathStorage.listPackageDirectories() |
abstract java.util.Set<java.lang.String> |
Storage.listPackageDirectories()
Return the list of installed packages.
|
void |
UserInteractionStrategy.logInfo(java.lang.String msg)
A log message, "info" level.
|
static Repository |
Repository.makeDefaultRepo()
Shortcut for
makeDefaultRepo(null). |
static Repository |
Repository.makeDefaultRepo(java.lang.String dir)
Return a repository instantiated from default location.
|
Storage.PackageResolver |
FileSystemStorage.makePackageResolver(java.lang.String rsrc_name,
java.lang.String abbrev) |
Storage.PackageResolver |
ClasspathStorage.makePackageResolver(java.lang.String rsrc_name,
java.lang.String abbrev) |
abstract Storage.PackageResolver |
Storage.makePackageResolver(java.lang.String rsrc_name,
java.lang.String abbrev)
Return a resolver for a specific package.
|
java.nio.file.Path |
FileSystemStorage.makeTempDir(java.lang.String prefix) |
java.nio.file.Path |
ClasspathStorage.makeTempDir(java.lang.String prefix) |
abstract java.nio.file.Path |
Storage.makeTempDir(java.lang.String prefix)
Create a temporary directory.
|
static java.nio.file.Path |
FileHelper.makeTempDir(java.lang.String prefix,
java.nio.file.Path parent)
Create a new directory within
parent. |
void |
UserInteractionStrategy.messageError(java.lang.String msg)
A message to display to the user, "error" level.
|
void |
UserInteractionStrategy.messageInfo(java.lang.String msg)
A message to display to the user, "info" level.
|
boolean |
FileSystemStorage.packageKeyExists(java.lang.String key) |
boolean |
ClasspathStorage.packageKeyExists(java.lang.String key) |
abstract boolean |
Storage.packageKeyExists(java.lang.String key)
Each package in a repository can be identified by a unique key.
|
protected abstract void |
DescriptorExtension.parseDescriptor(javax.xml.stream.XMLStreamReader parser,
Package pkg) |
void |
Repository.registerExtension(Extension ext)
Register an extension.
|
void |
FileSystemStorage.remove(Package pkg) |
void |
ClasspathStorage.remove(Package pkg) |
abstract void |
Storage.remove(Package pkg)
Remove a package.
|
boolean |
Repository.removePackage(java.lang.String pkg,
boolean force,
UserInteractionStrategy interact)
Remove a package from the repository, by name.
|
boolean |
Repository.removePackage(java.lang.String pkg,
java.lang.String version,
boolean force,
UserInteractionStrategy interact)
Remove a package from the repository, by name and version.
|
static void |
FileHelper.renameTmpDir(java.nio.file.Path from,
java.nio.file.Path to) |
javax.xml.transform.Source |
Universe.resolve(java.lang.String href,
URISpace space)
Resolve a specific URI, in a specific space, into a stream source.
|
javax.xml.transform.Source |
Package.resolve(java.lang.String href,
URISpace space) |
javax.xml.transform.Source |
Repository.resolve(java.lang.String href,
URISpace space)
Resolve a URI in this repository, in the specified space, return a File.
|
javax.xml.transform.Source |
Packages.resolve(java.lang.String href,
URISpace space) |
javax.xml.transform.Source |
CompositeUniverse.resolve(java.lang.String href,
URISpace space) |
abstract javax.xml.transform.Source |
PackageInfo.resolve(java.lang.String href,
URISpace space) |
javax.xml.transform.Source |
Universe.resolve(java.lang.String href,
URISpace space,
boolean transitive)
Resolve a specific URI, in a specific space, into a stream source.
|
javax.xml.transform.Source |
Package.resolve(java.lang.String href,
URISpace space,
boolean transitive) |
javax.xml.transform.Source |
Repository.resolve(java.lang.String href,
URISpace space,
boolean transitive) |
javax.xml.transform.Source |
Packages.resolve(java.lang.String href,
URISpace space,
boolean transitive) |
javax.xml.transform.Source |
CompositeUniverse.resolve(java.lang.String href,
URISpace space,
boolean transitive) |
javax.xml.transform.stream.StreamSource |
FileSystemStorage.FileSystemResolver.resolveComponent(java.lang.String path) |
javax.xml.transform.stream.StreamSource |
ClasspathStorage.ClasspathResolver.resolveComponent(java.lang.String path) |
abstract javax.xml.transform.Source |
Storage.PackageResolver.resolveComponent(java.lang.String path)
Resolve a resource within the package "content directory".
|
javax.xml.transform.stream.StreamSource |
FileSystemStorage.FileSystemResolver.resolveResource(java.lang.String path) |
javax.xml.transform.stream.StreamSource |
ClasspathStorage.ClasspathResolver.resolveResource(java.lang.String path) |
abstract javax.xml.transform.Source |
Storage.PackageResolver.resolveResource(java.lang.String path)
Resolve a resource within the "package directory".
|
void |
FileSystemStorage.storeInstallDir(java.nio.file.Path dir,
java.lang.String key,
Package pkg) |
void |
ClasspathStorage.storeInstallDir(java.nio.file.Path dir,
java.lang.String key,
Package pkg) |
abstract void |
Storage.storeInstallDir(java.nio.file.Path dir,
java.lang.String key,
Package pkg)
Actually store the package in the storage.
|
void |
FileSystemStorage.updatePackageLists(Package pkg) |
void |
ClasspathStorage.updatePackageLists(Package pkg) |
abstract void |
Storage.updatePackageLists(Package pkg)
The package has just been install, record the information if needed.
|
| Constructor and Description |
|---|
ClasspathResolver(java.lang.String pkg_root,
java.lang.String abbrev,
java.lang.String rsrc_name) |
FileSystemResolver(java.nio.file.Path pkg_dir,
java.lang.String abbrev,
java.lang.String rsrc_name) |
FileSystemStorage(java.nio.file.Path root) |
| Modifier and Type | Method and Description |
|---|---|
abstract boolean |
DependencyVersion.isCompatible(java.lang.String version) |
static DependencyVersion |
DependencyVersion.makeVersion(java.lang.String versions,
java.lang.String semver,
java.lang.String min,
java.lang.String max) |
boolean |
Semver.matches(Semver rhs)
Does
rhs (a SemVer version) match this SemVer template? |
boolean |
Semver.matchesMax(Semver rhs)
Does
rhs (a SemVer version) match this SemVer template as a maximum? |
boolean |
Semver.matchesMin(Semver rhs)
Does
rhs (a SemVer version) match this SemVer template as a minimum? |
static Semver |
Semver.parse(java.lang.String semver) |
| Modifier and Type | Method and Description |
|---|---|
void |
XMLStreamHelper.ensureDocument(javax.xml.stream.XMLStreamReader parser) |
void |
XMLStreamHelper.ensureElement(javax.xml.stream.XMLStreamReader parser,
java.lang.String local_name) |
void |
XMLStreamHelper.ensureNextElement(javax.xml.stream.XMLStreamReader parser,
java.lang.String local_name) |
java.lang.String |
XMLStreamHelper.getAttributeValue(javax.xml.stream.XMLStreamReader parser,
java.lang.String name) |
java.lang.String |
XMLStreamHelper.getElementValue(javax.xml.stream.XMLStreamReader parser) |
java.lang.String |
XMLStreamHelper.getEventName(int event) |
void |
PkgComponentHandler.handleDescription(javax.xml.stream.XMLStreamReader parser,
Package pkg,
XMLStreamHelper helper)
Handle an element in the package descriptor.
|
void |
XMLStreamHelper.ignoreElement(javax.xml.stream.XMLStreamReader parser)
The parser's current event must be START_ELEMENT.
|
boolean |
XMLStreamHelper.isElement(javax.xml.stream.XMLStreamReader parser,
java.lang.String local_name) |
boolean |
XMLStreamHelper.isNextElement(javax.xml.stream.XMLStreamReader parser,
java.lang.String local_name) |
javax.xml.stream.XMLStreamReader |
XMLStreamHelper.makeParser(javax.xml.transform.Source desc) |
Package |
DescriptorParser.parse(javax.xml.transform.Source desc,
java.lang.String rsrc_name,
Storage storage,
Repository repo)
Parse a package descriptor and build the corresponding
Package object. |
boolean |
XMLStreamHelper.stateError(java.lang.String msg,
int event) |
| Modifier and Type | Method and Description |
|---|---|
void |
PackagesXmlFile.addPackage(Package pkg,
java.lang.String dir)
Add a package to packages.xml.
|
void |
PackagesTxtFile.addPackage(Package pkg,
java.lang.String pkg_dir) |
protected javax.xml.transform.Transformer |
UpdatableXmlFile.compile(java.lang.String rsrc_name)
Compile a stylesheet.
|
java.util.Set<java.lang.String> |
PackagesTxtFile.parseDirectories()
Return the names of all the package directories, as a set.
|
static java.util.Set<java.lang.String> |
PackagesTxtFile.parseDirectories(java.io.InputStream stream)
Return the names of all the package directories, as a set.
|
void |
PackagesXmlFile.removePackageByDir(java.lang.String dir)
Remove a package from packages.xml.
|
void |
PackagesTxtFile.removePackageByDir(java.lang.String dir) |
protected void |
UpdatableXmlFile.transform(javax.xml.transform.Transformer trans)
Transform the file with the transformer.
|
protected void |
UpdatableFile.update(java.io.StringWriter content)
Replace the actual file with
content. |
| Constructor and Description |
|---|
PackagesTxtFile(java.nio.file.Path file) |
PackagesXmlFile(java.nio.file.Path file)
Create a new instance.
|
UpdatableFile(java.nio.file.Path file) |
UpdatableXmlFile(java.nio.file.Path file)
Create a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
TextUserInteraction.ask(java.lang.String prompt,
boolean dflt) |
boolean |
BatchUserInteraction.ask(java.lang.String prompt,
boolean dflt) |
java.lang.String |
TextUserInteraction.ask(java.lang.String prompt,
java.lang.String dflt) |
java.lang.String |
BatchUserInteraction.ask(java.lang.String prompt,
java.lang.String dflt) |
void |
TextUserInteraction.logInfo(java.lang.String msg) |
void |
BatchUserInteraction.logInfo(java.lang.String msg) |
void |
TextUserInteraction.messageError(java.lang.String msg) |
void |
BatchUserInteraction.messageError(java.lang.String msg) |
void |
TextUserInteraction.messageInfo(java.lang.String msg) |
void |
BatchUserInteraction.messageInfo(java.lang.String msg) |
Copyright © 2015-2023 EXPath. All Rights Reserved