Sun Oct 26 11:44:48 2003

Configuration Quickref

This is a quick reference sheet to the configuration, not a tutorial that will walk you through all the steps required to understand AxKit configuration.

Please note that the order and the partitionning into sections is presently arbitrary. It will probably evolve over time.

Processor Directives

AxAddProcessor

  • Syntax: AxAddProcessor mime/type processor-stylesheet
  • Version: ???

Adds a step to the processing pipeline which will feed the processor-stylesheet file to the processor mapped to handle that mime/type by an "AxAddStyleMap" directive and use that to process the requested file.

AxAddDocTypeProcessor

  • Syntax: AxAddDocTypeProcessor mime/type processor-stylesheet PUBLIC_ID
  • Version: ???

Adds a step to the processing pipeline which will feed the processor-stylesheet file to the processor mapped to handle that mime/type by an "AxAddStyleMap" directive and use that to process the requested file if it happens to have a DOCTYPE pointing to the specified PUBLIC_ID.

AxAddDTDProcessor

  • Syntax: AxAddDTDProcessor mime/type processor-stylesheet SYSTEM_ID
  • Version: ???

Adds a step to the processing pipeline which will feed the processor-stylesheet file to the processor mapped to handle that mime/type by an "AxAddStyleMap" directive and use that to process the requested file if it happens to have a DOCTYPE pointing to the specified SYSTEM_ID.

AxAddDynamicProcessor

  • Syntax: AxAddDynamicProcessor Perl::Package
  • Version: 1.5

Will call the handler() in the given Perl::Package before processing takes place. The handler() must set up the list of processors to be used, manipulating them with the AxKit::reset_stylesheets() (which empties the processor list), AxKit::insert_next_stylesheet($type,$path) which adds a stylesheet to the front of the list, and AxKit::insert_last_stylesheet($type,$path) which adds a stylesheet to the end of the list.

AxAddRootProcessor

  • Syntax: AxAddRootProcessor mime/type processor-stylesheet root-element
  • Version: ???

Adds a step to the processing pipeline which will feed the processor-stylesheet file to the processor mapped to handle that mime/type by an "AxAddStyleMap" directive and use that to process the requested file if it happens to have a root element that matches the given root-element.

Note that root-element is expressed in JClark notation, that is if your element has a namespace it is written {ns}lname.

AxAddURIProcessor

  • Syntax: AxAddURIProcessor mime/type processor-stylesheet regexp
  • Version: ???

Adds a step to the processing pipeline which will feed the processor-stylesheet file to the processor mapped to handle that mime/type by an "AxAddStyleMap" directive and use that to process the requested file if it happens to have a URI that matches the given regexp.

AxResetProcessors

  • Syntax: AxResetProcessors
  • Version: ???

Removes all previously configured processors in the pipeline.

Plugin Directives

AxAddPlugin

  • Syntax: AxAddPlugin Perl::Package
  • Version: 1.5

Will add a Plugin to the list of plugins that will be run before the processing beings. A plugin may modify all sorts of request parametres and notes in order to influence the behaviour of the processor.

The handler() in the given Perl::Package will be called with $r, as if it were a normal modperl handler (except that it is not expected to do anything fancy there, or to return something).

AxResetPlugins

  • Syntax: AxResetPlugins
  • Version: 1.5

Removes all previously configured plugins.

Media Directives

<AxMediaType>

  • Syntax: ???
  • Version: ???

???

AxMedia

  • Syntax: ???
  • Version: ???

???

Style Directives

<AxStyleName>

  • Syntax: ???
  • Version: ???

???

AxAddStyleMap

  • Syntax: AxAddStyleMap mime/type Perl::Module
  • Version: ???

Adds a type to the StyleMap, to be used by Processors so that they know which module you use. The benefit of this is that you only define that mapping once. For instance, if you were processing XSLT with Apache::AxKit::Language::FooXSLT and you suddenly want to change to using Apache::AxKit::Language::BarXSLT, all you'll have to do to switch is to change the AxAddStyleMap mapping for text/xsl from the former to the latter, and all Processors using text/xsl will switch automatically.

AxResetStyleMap

  • Syntax: AxResetStyleMap
  • Version: ???

Removes all previously configured StyleMaps.

AxStyleProvider

  • Syntax: AxStyleProvider Perl::Module
  • Version: 1.6

Alternative module to use for reading the stylesheet.

AxStyle

  • Syntax: ???
  • Version: ???

???

Cache Directives

AxCacheDir

  • Syntax: AxCacheDir cache-dir
  • Version: ???

Specifies the directory in which the cache is maintained, as opposed to using .axcache in the current directory. It is recommended that this be set to a non web-accessible directory.

AxCacheModule

  • Syntax: AxCacheModule Perl::Module
  • Version: ???

Specifies an alternative module to use in order to implement caching. That module must implement the same API as is found in Apache::AxKit::Cache, and probably ought to subclass it to avoid future breakage should that API evolve.

AxNoCache

  • Syntax: AxNoCache On | Off
  • Version: ???

Whether results should be cached (default) or not.

AxDependencyChecks

  • Syntax: AxDependencyChecks On | Off
  • Version: 1.5

Whether dependencies (eg external entities) should be checked (default) or not. Turning this off can be a major performance boost if you know what you're doing.

Output Directives

AxAddOutputTransformer

  • Syntax: AxAddOutputTransformer Perl::sub
  • Version: ???

Adds an OutputTransformer subroutine. That subroutine will receive the content to modify in @_ and must modify it in place. It is run right after cache which makes it the ideal place to perform small per request modifications while still benefitting from the caching of the other operations.

AxResetOutputTransformers

  • Syntax: AxResetOutputTransformers
  • Version: ???

Removes all previously configured OutputTransformers.

AxOutputCharset

  • Syntax: AxOutputCharset charset
  • Version: ???

Requests that the output be translated to the given charset before it is sent.

AxGzipOutput

  • Syntax: AxGzipOutput On | Off
  • Version: ???

Whether the output should be gzipped or not (default).

AxTranslateOutput

  • Syntax: AxTranslateOutput On | Off
  • Version: ???

Whether the output should have automatic charset conversion on or not (default). [and that kicks in when???]

Logging Directives

AxDebugLevel

  • Syntax: AxDebugLevel level
  • Version: ???

Sets the debugging level. 0 is no debugging and higher numbers mean more of it. The max should normally be 10.

AxLogDeclines

  • Syntax: AxLogDeclines On | Off
  • Version: ???

Whether the requests that AxKit declines to handle should be logged or not or not (default).

AxStackTrace

  • Syntax: AxStackTrace On | Off
  • Version: ???

Whether the a stack trace of AxKit exceptions should be maintained or not (default).

AxTraceIntermediate

  • Syntax: ???
  • Version: ???

Makes AxKit save to a file every intermediate stage of processing, so you no longer need to remove parts of your pipeline when debugging.

Miscellaneous Directives

AxConfigReader

  • Syntax: AxConfigReader Perl::Module
  • Version: ???

Specifies an alternative module to use in order to implement configuration. That module must implement the same API as is found in Apache::AxKit::ConfigReader, and probably ought to subclass it to avoid future breakage should that API evolve.

AxProvider

  • Syntax: AxProvider Perl::Module
  • Version: ???

Specifies an alternative module to use in order to implement providing of files to AxKit. That module must implement the same API as is found in Apache::AxKit::Provider, and probably ought to subclass it to avoid future breakage should that API evolve.

AxErrorStylesheet

  • Syntax: AxErrorStylesheet mime/type stylesheet
  • Version: ???

Defines the stylesheet to use for error documents when errors occur. It's syntax is comparable to that of "AxAddProcessor". The error document looks something like:

<error>
	<file>filename</file>
	<msg>error message</msg>
	<stack_trace>
		<bt level="0">
			<file>filename</file>
			<line>line number</line>
		</bt>
		<bt level="2">
		<!--etc-->
		</bt>
	</stack_trace>
</error>

AxAddXSPTaglib

  • Syntax: AxAddXSPTaglib Perl::Module
  • Version: ???

Adds an XSP handling module. This is required in order to use taglibs as it gives them a chance to register their namespaces with the XSP dispatcher. Without this, taglib code in XSP will not function properly.

Revision

0.02 - 2002-06-21, switched to Pod with the Wiki move
0.01 - 2001-11-09, initial draft

Copyright

Copyright (c) 2001 The AxKit Documentation Project, and individual contributors. All rights reserved. This text is free documentation; you can redistribute it and/or modify it under the same terms as AxKit itself.


Edit This Page / Show Page History /