]> git.saurik.com Git - apt.git/blame - apt-pkg/deb/debversion.h
Avoid temporary strings in SubstVar.
[apt.git] / apt-pkg / deb / debversion.h
CommitLineData
b2e465d6
AL
1// -*- mode: cpp; mode: fold -*-
2// Description /*{{{*/
b2e465d6
AL
3/* ######################################################################
4
5 Debian Version - Versioning system for Debian
6
7 This implements the standard Debian versioning system.
8
9 ##################################################################### */
10 /*}}}*/
11#ifndef PKGLIB_DEBVERSION_H
12#define PKGLIB_DEBVERSION_H
13
453b82a3 14#include <apt-pkg/version.h>
13500573 15
453b82a3 16#include <string>
b2e465d6 17
b2e465d6 18class debVersioningSystem : public pkgVersioningSystem
453b82a3 19{
c0a00c82 20 public:
a02db58f 21
b2e465d6 22 static int CmpFragment(const char *A, const char *AEnd, const char *B,
a02db58f
DK
23 const char *BEnd) APT_PURE;
24
b2e465d6
AL
25 // Compare versions..
26 virtual int DoCmpVersion(const char *A,const char *Aend,
6d7122b5
JAK
27 const char *B,const char *Bend) APT_OVERRIDE APT_PURE;
28 virtual bool CheckDep(const char *PkgVer,int Op,const char *DepVer) APT_OVERRIDE APT_PURE;
a02db58f 29 virtual APT_PURE int DoCmpReleaseVer(const char *A,const char *Aend,
3b302846 30 const char *B,const char *Bend) APT_OVERRIDE
b2e465d6
AL
31 {
32 return DoCmpVersion(A,Aend,B,Bend);
a02db58f 33 }
3b302846 34 virtual std::string UpstreamVersion(const char *A) APT_OVERRIDE;
b2e465d6
AL
35
36 debVersioningSystem();
37};
38
39extern debVersioningSystem debVS;
40
b2e465d6 41#endif