ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/SCRAM/src/ActiveDoc/ActiveDoc.pm
(Generate patch)

Comparing COMP/SCRAM/src/ActiveDoc/ActiveDoc.pm (file contents):
Revision 1.21 by williamc, Mon Feb 21 14:30:16 2000 UTC vs.
Revision 1.23 by williamc, Wed Feb 23 14:53:28 2000 UTC

# Line 21 | Line 21
21   #                                       hashref from a tag call
22   # includeparse(local_parsename, objparsename, activedoc) : copy the parse from
23   #                                                       one object to another
24 + # currentparser() : return the current parser object
25   # currentparsename([name]) : get/set current parse name
26   # getfile(url)  : get a processedfile object given a url
27   # activatedoc(url) : Return the object ref for a doc described by the given url
# Line 41 | Line 42
42   # parseerror(string)  : Report an error during parsing a file
43   # line()              : Return the current line number of the document
44   #                       and the ProcessedFileObj it is in
45 + #
46 + # -- support for inheriting classes
47 + # _saveactivedoc(filehandle)
48 + # _restoreactivedoc(filehandle)
49  
50   package ActiveDoc::ActiveDoc;
51   require 5.004;
# Line 128 | Line 133 | sub currentparsename {
133            :$self->{currentparsename};
134   }
135  
136 + sub currentparser {
137 +        my $self=shift;
138 +        return $self->{currentparser};
139 + }
140 +
141 +
142   sub newparse {
143          my $self=shift;
144          my $parselabel=shift;
# Line 259 | Line 270 | sub askuser {
270          return $self->userinterface()->askuser(@_);
271   }
272  
273 < sub getfile() {
273 > sub getfile {
274          my $self=shift;
275          my $origurl=shift;
276  
# Line 457 | Line 468 | sub userinterface {
468          @_?$self->{userinterface}=shift
469            :$self->{userinterface}
470   }
471 +
472 + sub _saveactivedoc {
473 +        my $self=shift;
474 +        my $fh=shift;
475 +        print "Storing $self\n";
476 +        print $fh $self->url()."\n";
477 + }
478 +
479 + sub _restoreactivedoc {
480 +        my $self=shift;
481 +        my $fh=shift;
482 +
483 +        my $url=<$fh>;
484 +        chomp $url;
485 +        $self->url($url);
486 + }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines