NAME
OODoc::Object - base class for all OODoc classes.
INHERITANCE
OODoc::Object is extended by
OODoc
OODoc::Format
OODoc::Manifest
OODoc::Manual
OODoc::Parser
OODoc::Text
SYNOPSIS
# Never instantiated directly.
DESCRIPTION
Any object used in the OODoc module is derived from this OODoc::Object class. This means that all functionality in this class is provided for all of the other classes.
METHODS
Constructors
- OODoc::Object->new(OPTIONS)
-
Create a new object (instantiation). All objects in OODoc are created the same way: they carry a list of key-value pairs as option. For examples, see the description of this method in the manual page of the specific object.
The validity of the options for
new
is checked, in contrary to the options when used with many other method defined by OODoc.
Inheritance knowledge
- $obj->extends([OBJECT])
-
Close to all elements used within OODoc can have an inheritance relation. The returned object is extended by the current object. Multiple inheritance is not supported here.
Commonly used functions
- $obj->filenameToPackage(FILENAME)
- OODoc::Object->filenameToPackage(FILENAME)
-
example:
print $self->filenameToPackage('Mail/Box.pm'); # prints Mail::Box
- $obj->mkdirhier(DIRECTORY)
- OODoc::Object->mkdirhier(DIRECTORY)
-
Creates this DIRECTORY and all its non-existing parents.
Manual Repository
All manuals can be reached everywhere in the program: it is a global collection.
- $obj->addManual(MANUAL)
-
The MANUAL will be added to the list of known manuals. The same package name can appear in more than one manual. This OBJECT shall be of type OODoc::Manual.
- $obj->mainManual(NAME)
-
Returns the manual of the named package which contains the primar documentation for the code of the package NAME.
- $obj->manual(NAME)
-
Returns the manual with the specified name, or else
undef
. - $obj->manuals()
-
All manuals are returned.
- $obj->manualsForPackage(NAME)
-
Returns a list package objects which are related to the specified NAME. One NAME can appear in more than one file, and therefore a list is returned.
- $obj->packageNames()
-
Returns the names of all defined packages.
DIAGNOSTICS
- Warning: Unknown option $name
-
You have used the option with $name, which is not defined with the instantiation (the
new
method) of this object. - Warning: Unknown options @names
-
You have used more than one option which is not defined to instantiate the object.
- Error: manual definition requires manual object
-
A call to addManual() expects a new manual object (a OODoc::Manual), however an incompatible thing was passed. Usually, intended was a call to manualsForPackage() or mainManual().
SEE ALSO
This module is part of OODoc distribution version 2.00, built on January 11, 2013. Website: http://perl.overmeer.net/oodoc/
LICENSE
Copyrights 2003-2013 by [Mark Overmeer]. For other contributors see ChangeLog.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See http://www.perl.com/perl/misc/Artistic.html