internal package
Foswiki::Store::Rcs::RcsLiteHandler
internal package
Foswiki::Store::Rcs::RcsLiteHandler is a
Foswiki::Store::Rcs::Handler
This class implements the pure methods of the
Foswiki::Store::Rcs::Handler
superclass. See the superclass for detailed documentation of the methods.
For readers who are familiar with Foswiki version 1.0, this class
is analagous to the old
Foswiki::Store::RcsLite
.
Simple pure perl replacement for RCS. Doesn't support:
This module doesn't know anything about the content of the topic
There is one of these objects for each file stored under Rcs Lite.
This class is PACKAGE PRIVATE to Store, and should NEVER be
used from anywhere else.
rcstext ::= admin {delta}* desc {deltatext}*
admin ::= head {num};
{ branch {num}; }
access {id}*;
symbols {sym : num}*;
locks {id : num}*; {strict ;}
{ comment {string}; }
{ expand {string}; }
{ newphrase }*
delta ::= num
date num;
author id;
state {id};
branches {num}*;
next {num};
{ newphrase }*
desc ::= desc string
deltatext ::= num
log string
{ newphrase }*
text string
num ::= {digit | .}+
digit ::= 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
id ::= {num} idchar {idchar | num }*
sym ::= {digit}* idchar {idchar | digit }*
idchar ::= any visible graphic character except special
special ::= $ | , | . | : | ; | @
string ::= @{any character, with @ doubled}*@
newphrase ::= id word* ;
word ::= id | num | string | :
Identifiers are case sensitive. Keywords are in lower case only. The
sets of keywords and identifiers can overlap. In most environments RCS
uses the ISO 8859/1 encoding: visible graphic characters are codes
041-176 and 240-377, and white space characters are codes 010-015 and
040.
Dates, which appear after the date keyword, are of the form
Y.mm.dd.hh.mm.ss, where Y is the year, mm the month (01-12), dd the
day (01-31), hh the hour (00-23), mm the minute (00-59), and ss the
second (00-60). Y contains just the last two digits of the year for
years from 1900 through 1999, and all the digits of years
thereafter. Dates use the Gregorian calendar; times use UTC.
The newphrase productions in the grammar are reserved for future
extensions to the format of RCS files. No newphrase will begin with
any keyword already in use.
The head of the revisions array contains the plain text of the file in
it's most recent incarnation.
Earlier revisions consist of a sequence of 'a' and 'd' edits that need
to be applied to rev N+1 to get rev N. Each edit has an offset (number
of lines from start) and length (number of lines). For 'a', the edit
is followed by length lines (the lines to be inserted in the
text). For example:
d1 3 means "delete three lines starting with line 1
a4 2 means "insert two lines at line 4'
xxxxxx is the new line 4
yyyyyy is the new line 5
Edits are applied sequentially i.e. edits are relative to the text as
it exists after the previous edit has been applied.