net.sourceforge.javadpkg.control.PackageVersion Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of dpkg Show documentation
Show all versions of dpkg Show documentation
The library for reading and writing Debian Packages.
/*
* dpkg - Debian Package library and the Debian Package Maven plugin
* (c) Copyright 2015 Gerrit Hohl
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
package net.sourceforge.javadpkg.control;
/**
*
* The version number of a package.
*
*
* See
* 5.6.12 Version for further information.
*
*
* @author Gerrit Hohl ([email protected])
* @version 1.0, 31.12.2015 by Gerrit Hohl
*/
public interface PackageVersion {
/**
*
* Returns the epoch of the version.
*
*
* This is a single (generally small) unsigned integer. It may be omitted,
* in which case zero is assumed. If it is omitted then the
* upstream_version may not contain any colons.
*
*
* @return The epoch or null
, if the version doesn't have any
* epoch.
*/
String getEpoch();
/**
*
* Returns the upstream version which is the main part of the version
* number.
*
*
* It is usually the version number of the original ("upstream") package
* from which the Debian package file has been made, if this is applicable.
*
*
* @return The upstream version.
*/
String getUpstreamVersion();
/**
*
* Returns the version of the Debian package based on the upstream version.
*
*
* @return The Debian revision or null
, if the version doesn't
* have any Debian revision.
*/
String getDebianRevision();
/**
*
* Returns the version as text.
*
* This method returns a textual representation of the version. This
* includes the epoch, the upstream version and the Debian revision.
*
*
* @return The name.
*/
String getText();
}