NAME
VcsTools::Version - Perl class to manage VCS revision.
SYNOPSIS
No synopsis given. This object is better used with the History module.
DESCRIPTION
This class represents one version of a VCS file. It holds all the information relevant to this version including the parent revision, child revision, branches revisions and do on.
Its main function is to provides the functionnality to manage versions (inluding branches and merges) of a Vcs file:
Find the common ancestor of 2 revisions (but this does not yet take merges into account)
Find the oldest parent of a revision
Find all children of a revision (taking merges into account)
All these information can be stored in a database. See Puppet::Body for more details.
CONVENTION
The following words may be non ambiguous for native english speakers, but it is not so with us french people. So I prefer clarify these words:
Log: Refers to the information stored with one version.
History: Refers to a collection of all logs of all versions stored in the VCS base.
Constructor
new(...)
Parameters are :
All parameter of "Constructor" in Puppet::Body
revision : revision number of this version
manager: the ref of the history object.
Methods
update(...)
Parameters are:
info: hash ref of log informations
This methods takes a hash reference containing all informations extracted from the VCS log of this version. Then all other complementary informations (such as upper revision, branches revisions, revision that were eventually merged in this one) are computed and stored in the database.
getRevision()
Returns the revision number of this object.
getUpperRev()
Returns the revision number of the "parent" of this object.
hasParent()
Returns true if this version has a "parent" object.
findAncestor(other_revision_number)
Returns the ancestor number of this revision and the other.
Returns undef in case of problems.
findOldest()
Returns the version number of the oldest parent in the revision tree that it can find.
getLog()
Returns the log of this version object.
AUTHOR
Dominique Dumont, Dominique_Dumont@grenoble.hp.com
Copyright (c) 1998-1999 Dominique Dumont. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
SEE ALSO
perl(1), Puppet:Body:(3), VcsTools::History(3)