public class DocumentPathsImpl extends Object implements DocumentPaths, DebianPackageConstants
A DocumentPaths
implementation.
CONFFILES_ENTRY, CONFIG_ENTRY, CONTROL_ENTRY, CONTROL_NAME, CONTROL_TAR_PREFIX, DATA_NAME, DATA_TAR_PREFIX, DEBIAN_BINARY, DIRECTORY_MODE, DOC_BASE_PATH, FILE_MODE, MD5SUMS_ENTRY, POSTINST_ENTRY, POSTRM_ENTRY, PREINST_ENTRY, PRERM_ENTRY, ROOT_GROUP_ID, ROOT_GROUP_NAME, ROOT_USER_ID, ROOT_USER_NAME, SCRIPT_MODE, SHLIBS_ENTRY, SYMBOLS_ENTRY, TAR_BZIP2_SUFFIX, TAR_GZIP_SUFFIX, TAR_XZ_SUFFIX, TEMPLATES_ENTRY, TRIGGERS_ENTRY, USR_PATH, USR_SHARE_PATH
UTF_8, UTF_8_CHARSET
Constructor and Description |
---|
DocumentPathsImpl(PackageName name)
Creates the paths.
|
Modifier and Type | Method and Description |
---|---|
String |
getChangeLogGzipPath()
Returns the path of the GZIP compressed change log file.
|
String |
getChangeLogHtmlGzipPath()
Returns the path of the GZIP compressed HTML formatted change log file.
|
String |
getChangeLogHtmlPath()
Returns the path of the HTML formatted change log file.
|
String |
getChangeLogPath()
Returns the path of the change log file.
|
String |
getCopyrightPath()
Returns the path of the copyright file.
|
String |
getDocumentBasePath()
Returns the base path of the document folder.
|
String |
getDocumentPath()
Returns the path of the document folder of the Debian package.
|
boolean |
isChangeLogDebianPath(String path)
Returns the flag if the specified path is the path of the Debian change
log file.
|
boolean |
isChangeLogGzipPath(String path)
Returns the flag if the specified path is the path of a GZIP compressed
change log file.
|
boolean |
isChangeLogHtmlPath(String path)
Returns the flag if the specified path is the path of a HTML formatted
change log file.
|
boolean |
isChangeLogPath(String path)
Returns the flag if the specified path is the path of the change log
file.
|
boolean |
isCopyrightPath(String path)
Returns the flag if the specified path is the path of the copyright file.
|
public DocumentPathsImpl(PackageName name)
Creates the paths.
name
- The name of the package.IllegalArgumentException
- If the name is null
.public String getDocumentBasePath()
DocumentPaths
Returns the base path of the document folder.
Normally this should be:
/usr/share/doc/
getDocumentBasePath
in interface DocumentPaths
public String getDocumentPath()
DocumentPaths
Returns the path of the document folder of the Debian package.
Normally this should be:
/usr/share/doc/[package-name]/
getDocumentPath
in interface DocumentPaths
public boolean isCopyrightPath(String path)
DocumentPaths
Returns the flag if the specified path is the path of the copyright file.
isCopyrightPath
in interface DocumentPaths
path
- The path.true
, if the path is the path of the
copyright file, false
otherwise.public String getCopyrightPath()
DocumentPaths
Returns the path of the copyright file.
Normally this should be:
/usr/share/doc/[package-name]/copyright
getCopyrightPath
in interface DocumentPaths
public boolean isChangeLogPath(String path)
DocumentPaths
Returns the flag if the specified path is the path of the change log file.
The method doesn't determine the format and/or compression of the change log file.
isChangeLogPath
in interface DocumentPaths
path
- The path.true
, if the path is the path of the
change log file, false
otherwise.DocumentPaths.isChangeLogGzipPath(String)
,
DocumentPaths.isChangeLogHtmlPath(String)
public boolean isChangeLogDebianPath(String path)
DocumentPaths
Returns the flag if the specified path is the path of the Debian change log file.
The filename of the Debian change log starts with "changelog.Debian.*". It often exists parallel to the "changelog.*" file which in this case has its own, non-standard format. If both files exists the Debian change log should always be used.
isChangeLogDebianPath
in interface DocumentPaths
path
- The path.true
, if the path is the path of the
Debian change log file, false
otherwise.public boolean isChangeLogGzipPath(String path)
DocumentPaths
Returns the flag if the specified path is the path of a GZIP compressed change log file.
The method doesn't determine the format of the change log file.
isChangeLogGzipPath
in interface DocumentPaths
path
- The path.true
, if the path is the path of a GZIP
compressed change log file, false
otherwise.DocumentPaths.isChangeLogHtmlPath(String)
public boolean isChangeLogHtmlPath(String path)
DocumentPaths
Returns the flag if the specified path is the path of a HTML formatted change log file.
The method doesn't determine the compression of the change log file.
isChangeLogHtmlPath
in interface DocumentPaths
path
- The path.true
, if the path is the path of a HTML
formatted change log file, false
otherwise.DocumentPaths.isChangeLogGzipPath(String)
public String getChangeLogPath()
DocumentPaths
Returns the path of the change log file.
Normally this should be:
/usr/share/doc/[package-name]/changelog
getChangeLogPath
in interface DocumentPaths
public String getChangeLogGzipPath()
DocumentPaths
Returns the path of the GZIP compressed change log file.
Normally this should be:
/usr/share/doc/[package-name]/changelog.gz
getChangeLogGzipPath
in interface DocumentPaths
public String getChangeLogHtmlPath()
DocumentPaths
Returns the path of the HTML formatted change log file.
Normally this should be:
/usr/share/doc/[package-name]/changelog.html
getChangeLogHtmlPath
in interface DocumentPaths
public String getChangeLogHtmlGzipPath()
DocumentPaths
Returns the path of the GZIP compressed HTML formatted change log file.
Normally this should be:
/usr/share/doc/[package-name]/changelog.html.gz
getChangeLogHtmlGzipPath
in interface DocumentPaths
Copyright © 2015–2019. All rights reserved.