|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.xnap.commons.pkg.PackageInfo
public class PackageInfo
This class serves as a plugin information record.
Field Summary | |
---|---|
static String |
ACTION_INSTALL
|
static String |
DELIMETER
|
static String |
PACKAGE_STATUS_INSTALLED
|
static String |
STATUS_INSTALLED
|
static String |
STATUS_NOT_INSTALLED
|
Constructor Summary | |
---|---|
PackageInfo()
|
|
PackageInfo(Properties props)
Constructs a new plugin information record from p . |
|
PackageInfo(String packageName)
|
Method Summary | |
---|---|
int |
compareTo(Object o)
Lower versions come first. |
int |
compareToVersion(PackageInfo info)
Returns a value > 0 if the version of this package is higher than the version of info. |
int |
compareToVersion(String version)
|
boolean |
containsProperties(Properties p)
|
boolean |
equals(Object o)
|
String |
getAction()
See setAction(String) for possible return values. |
String |
getActionStatus()
Returns "ok". |
String |
getAuthors()
|
String[] |
getClassPath()
Returns an empty array if no dependencies are defined. |
String |
getControlPath()
|
String |
getDepends()
|
String |
getDescription()
|
String |
getDownloadFilename()
|
String[] |
getDownloadURLs()
|
File |
getFile(String filename)
Returns a file that is relative to this packages location. |
String |
getFilename()
|
String |
getLongDescription()
Returns a long description of the package's functionality that may contain html tags. |
String |
getName()
|
String |
getPackage()
|
String |
getPackageStatus()
|
Properties |
getProperties()
|
String |
getProperty(String key)
Returns a property. |
String |
getProperty(String key,
String defaultValue)
Returns a property. |
String[] |
getPropertyList(String key)
Returns a property that is a list of strings. |
String |
getProvides()
|
long |
getReleaseNr()
|
String |
getSection()
|
long |
getSize()
|
String |
getStatus()
|
String |
getStatus(int pos)
|
String |
getVersion()
|
boolean |
isAvailable()
|
boolean |
isBase()
|
boolean |
isCore()
|
boolean |
isInstalled()
|
boolean |
isNew()
|
boolean |
isPatch()
|
boolean |
isPlugin()
|
boolean |
isUpdateAvailable()
|
boolean |
isValid()
|
void |
putAll(Properties p)
|
void |
setAction(String action)
Action can be "deinstall", "hold", "install", "purge" |
void |
setAvailable(boolean available)
|
void |
setClassPath(String[] classPath)
|
void |
setControlPath(String controlPath)
|
void |
setDescription(String description)
|
void |
setDownloadFilename(String filename)
|
void |
setInstalled(boolean installed)
|
void |
setNew(boolean isNew)
|
void |
setPackage(String packageName)
|
void |
setSection(String section)
|
void |
setStatus(String status)
|
void |
setStatus(String action,
String actionStatus,
String packageStatus)
|
void |
setVersion(String version)
|
String |
toString()
Returns the value of getName() . |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final String DELIMETER
public static final String ACTION_INSTALL
public static final String PACKAGE_STATUS_INSTALLED
public static final String STATUS_INSTALLED
public static final String STATUS_NOT_INSTALLED
Constructor Detail |
---|
public PackageInfo(Properties props)
p
.
All keys with prefix
are copied to this info object.
prefix
- the key prefixPackageInfo(String packageName)
PackageInfo()
Method Detail |
---|
public int compareTo(Object o)
compareTo
in interface Comparable
public int compareToVersion(PackageInfo info)
public int compareToVersion(String version)
public boolean containsProperties(Properties p)
public boolean equals(Object o)
equals
in class Object
public String getAction()
setAction(String)
for possible return values.
public String getActionStatus()
public String getAuthors()
public String[] getClassPath()
public String getControlPath()
public String getDepends()
public String getDescription()
public String getDownloadFilename()
public String[] getDownloadURLs()
public File getFile(String filename)
public String getFilename()
public String getLongDescription()
public String getName()
public String getPackage()
public String getPackageStatus()
public Properties getProperties()
public String getProperty(String key, String defaultValue)
public String getProperty(String key)
public String[] getPropertyList(String key)
public String getProvides()
public long getReleaseNr()
public String getSection()
public long getSize()
public String getStatus()
public String getStatus(int pos)
public String getVersion()
public boolean isAvailable()
public boolean isBase()
public boolean isCore()
public boolean isPatch()
public boolean isInstalled()
public boolean isNew()
public boolean isPlugin()
public boolean isUpdateAvailable()
public boolean isValid()
public void putAll(Properties p)
public void setAction(String action)
public void setAvailable(boolean available)
public void setClassPath(String[] classPath)
public void setControlPath(String controlPath)
public void setDescription(String description)
public void setDownloadFilename(String filename)
public void setInstalled(boolean installed)
public void setNew(boolean isNew)
public void setPackage(String packageName)
public void setSection(String section)
public void setStatus(String status)
public void setStatus(String action, String actionStatus, String packageStatus)
public void setVersion(String version)
public String toString()
getName()
.
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |