Document::NotesFile - NotesFile file manager.


Document documentation  | view source Contained in the Document distribution.

Index


NAME

Top

 Document::NotesFile - NotesFile file manager.

SYNOPSIS

Top

 use Document::NotesFile;
 $obj  = Document::NotesFile->new ($filespecobj);
 $obj  = Document::NotesFile->new ($filename)
 $okay = $obj->note               ($note,$user);

Inheritance

Top

 UNIVERSAL

Description

Top

This Class manages .note files contained within a Document directory. Notes are special historical or other information about the document added by the user of a program.

Examples

Top

 use Document::NotesFile;
 my $baz       = Document::NotesFile->new ($filespecobj);
 my $baz       = Document::NotesFile->new ($pathname);
 my $waslogged = $baz->note ("Washington slept in this file", "BenF" );

Class Variables

Top

 None.

Instance Variables

Top

 None.

Class Methods

Top

$obj = Document::NotesFile->new ($filespecobj)
$obj = Document::NotesFile->new ($filename)

Create an object to allow communications with a notes file object of a Document directory defined by $filename or $filespecobj. If there is currently no file in it named .note, create one and emit a log creation message about it.

Objects of this Class may be used as inputs to the Fault::Logger class.

All of the path information comes either from a preparsed filename in $filespecobj, a File::Spec::DatedPage object, or a string containing a pathname to the target Document directory.

[Can we get by with a File::Spec::Dated object?]

Instance Methods

Top

$okay = $obj->log ($note, $user)

Write a time-stamped message into the .note file of the form:

       $note\n
       [$user 20021207223010]\n

and return true if we succeeded in doing so.

Private Class Methods

Top

 None.

Private Instance Methods

Top

 None.

KNOWN BUGS

Top

 See TODO.

SEE ALSO

Top

Fault::ErrorHandler, DMA::ISODate, File::Spec::DatedPage

AUTHOR

Top

Dale Amon <amon@vnl.com>


Document documentation  | view source Contained in the Document distribution.