The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.
NAME
    Apache::Module - Interface to Apache C module structures

SYNOPSIS
      use Apache::Module ();

DESCRIPTION
    This module provides an interface to the list of apache modules
    configured with your httpd and their `module *' structures.

METHODS
    top_module
        This method returns a pointer the first module in Apache's internal
        list of modules.

           Example:

           my $top_module = Apache::Module->top_module;

           print "Configured modules: \n";

           for (my $modp = $top_module; $modp; $modp = $modp->next) {
                print $modp->name, "\n";
           }

    find($module_name)
        This method returns a pointer to the module structure if found,
        under otherwise.

          Example:

         for (qw(proxy perl include cgi)) {
             if(my $modp = Apache::Module->find($_)) {
                 print "$_ module is configured\n";
                 print "with enabled commands: \n";

                 for (my $cmd = $modp->cmds; $cmd; $cmd = $cmd->next) {
                     print "   ", $cmd->name, "\n";
                 }
             }
             else {
                 print "$_ module is not configured\n";
             }
         }

    handlers
        Returns a pointer to the module response handler table.

        Example:

            print "module ", $modp->name, " handles:\n";

            for (my $hand = $modp->handlers; $hand; $hand = $hand->next) {
                print $hand->content_type, "\n";
            }

    Other Stuff
        There's more you can do with this module, I will document it later.
        For now, see Apache::ModuleDoc and Apache::ShowRequest for examples.

AUTHOR
    Doug MacEachern

SEE ALSO
    Apache::ModuleDoc(3), Apache::ShowRequest(3), Apache(3), mod_perl(3).