From Code to Community: Sponsoring The Perl and Raku Conference 2025 Learn more

NAME

XML::Compile::RPC - XML-RPC schema handler

INHERITANCE

XML::Compile::RPC
is a XML::Compile::Cache
is a XML::Compile::Schema
is a XML::Compile

SYNOPSIS

# ******
# you should initiate the ::Client
# this module contains the low-level XML implementation
# ******

DESCRIPTION

This class handles the XML-RPC pseudo schema for XML-RPC client or servers. The server-side has not been implemented (yet).

XML-RPC does not have an official schema, however with some craftsmanship, one has been produced. It actually works quite well. Some types, especially the data type, needed some help to fit onto the schema type definitions.

See http://www.xmlrpc.com/spec and http://en.wikipedia.org/wiki/XML-RPC

Supported simple data types:

base64
boolean
dateTime.iso8601
double
i4
int
nil [added with 0.16]
string

To use any of these types, you use "typename => value". For nil, use "nil => {}".

Supported data structures:

array
struct

Extends "DESCRIPTION" in XML::Compile::Cache.

METHODS

Extends "METHODS" in XML::Compile::Cache.

Constructors

Extends "Constructors" in XML::Compile::Cache.

XML::Compile::RPC->new(%options)
-Option --Defined in --Default
allow_undeclared XML::Compile::Cache <false>
any_element XML::Compile::Cache 'ATTEMPT'
block_namespace XML::Compile::Schema []
hook XML::Compile::Schema undef
hooks XML::Compile::Schema []
ignore_unused_tags XML::Compile::Schema <false>
key_rewrite XML::Compile::Schema []
opts_readers []
opts_rw []
opts_writers []
parser_options XML::Compile <many>
prefixes XML::Compile::Cache <smart>
schema_dirs XML::Compile undef
typemap XML::Compile::Cache {}
xsi_type XML::Compile::Cache {}
allow_undeclared => BOOLEAN
any_element => CODE|'TAKE_ALL'|'SKIP_ALL'|'ATTEMPT'|'SLOPPY'
block_namespace => NAMESPACE|TYPE|HASH|CODE|ARRAY
hook => $hook|ARRAY
hooks => ARRAY
ignore_unused_tags => BOOLEAN|REGEXP
key_rewrite => HASH|CODE|ARRAY
opts_readers => ARRAY-OF-PAIRS
opts_rw => ARRAY-OF-PAIRS
opts_writers => ARRAY-OF-PAIRS
parser_options => HASH|ARRAY
prefixes => HASH|ARRAY-of-PAIRS
schema_dirs => $directory|ARRAY-OF-directories
typemap => HASH|ARRAY
xsi_type => HASH|ARRAY

Accessors

Extends "Accessors" in XML::Compile::Cache.

$obj->addHook($hook|LIST|undef)

Inherited, see "Accessors" in XML::Compile::Schema

$obj->addHooks( $hook, [$hook, ...] )

Inherited, see "Accessors" in XML::Compile::Schema

$obj->addKeyRewrite($predef|CODE|HASH, ...)

Inherited, see "Accessors" in XML::Compile::Schema

$obj->addSchemaDirs(@directories|$filename)
XML::Compile::RPC->addSchemaDirs(@directories|$filename)

Inherited, see "Accessors" in XML::Compile

$obj->addSchemas($xml, %options)

Inherited, see "Accessors" in XML::Compile::Schema

$obj->addTypemap(PAIR)

Inherited, see "Accessors" in XML::Compile::Schema

$obj->addTypemaps(PAIRS)

Inherited, see "Accessors" in XML::Compile::Schema

$obj->addXsiType( [HASH|ARRAY|LIST] )

Inherited, see "Accessors" in XML::Compile::Cache

$obj->allowUndeclared( [BOOLEAN] )

Inherited, see "Accessors" in XML::Compile::Cache

$obj->anyElement('ATTEMPT'|'SLOPPY'|'SKIP_ALL'|'TAKE_ALL'|CODE)

Inherited, see "Accessors" in XML::Compile::Cache

$obj->blockNamespace($ns|$type|HASH|CODE|ARRAY)

Inherited, see "Accessors" in XML::Compile::Schema

$obj->hooks( [<'READER'|'WRITER'>] )

Inherited, see "Accessors" in XML::Compile::Schema

$obj->typemap( [HASH|ARRAY|PAIRS] )

Inherited, see "Accessors" in XML::Compile::Cache

$obj->useSchema( $schema, [$schema, ...] )

Inherited, see "Accessors" in XML::Compile::Schema

Prefix management

Extends "Prefix management" in XML::Compile::Cache.

$obj->addNicePrefix(BASE, NAMESPACE)

Inherited, see "Prefix management" in XML::Compile::Cache

$obj->addPrefixes( [PAIRS|ARRAY|HASH] )

Inherited, see "Prefix management" in XML::Compile::Cache

$obj->learnPrefixes($node)

Inherited, see "Prefix management" in XML::Compile::Cache

$obj->prefix($prefix)

Inherited, see "Prefix management" in XML::Compile::Cache

$obj->prefixFor($uri)

Inherited, see "Prefix management" in XML::Compile::Cache

$obj->prefixed( $type|<$ns,$local> )

Inherited, see "Prefix management" in XML::Compile::Cache

$obj->prefixes( [$params] )

Inherited, see "Prefix management" in XML::Compile::Cache

Compilers

Extends "Compilers" in XML::Compile::Cache.

$obj->addCompileOptions( ['READERS'|'WRITERS'|'RW'], %options )

Inherited, see "Compilers" in XML::Compile::Cache

$obj->compile( <'READER'|'WRITER'>, $type, %options )

Inherited, see "Compilers" in XML::Compile::Schema

$obj->compileAll( ['READERS'|'WRITERS'|'RW', [$ns]] )

Inherited, see "Compilers" in XML::Compile::Cache

$obj->compileType( <'READER'|'WRITER'>, $type, %options )

Inherited, see "Compilers" in XML::Compile::Schema

$obj->dataToXML($node|REF-XML|XML-STRING|$filename|$fh|$known)
XML::Compile::RPC->dataToXML($node|REF-XML|XML-STRING|$filename|$fh|$known)

Inherited, see "Compilers" in XML::Compile

$obj->initParser(%options)
XML::Compile::RPC->initParser(%options)

Inherited, see "Compilers" in XML::Compile

$obj->reader($type|$name, %options)

Inherited, see "Compilers" in XML::Compile::Cache

$obj->template( <'XML'|'PERL'|'TREE'>, $element, %options )

Inherited, see "Compilers" in XML::Compile::Schema

$obj->writer($type|$name)

Inherited, see "Compilers" in XML::Compile::Cache

Administration

Extends "Administration" in XML::Compile::Cache.

$obj->declare( <'READER'|'WRITER'|'RW'>, <$type|ARRAY>, %options )

Inherited, see "Administration" in XML::Compile::Cache

$obj->doesExtend($exttype, $basetype)

Inherited, see "Administration" in XML::Compile::Schema

$obj->elements()

Inherited, see "Administration" in XML::Compile::Schema

$obj->findName($name)

Inherited, see "Administration" in XML::Compile::Cache

$obj->findSchemaFile($filename)
XML::Compile::RPC->findSchemaFile($filename)

Inherited, see "Administration" in XML::Compile

$obj->importDefinitions($xmldata, %options)

Inherited, see "Administration" in XML::Compile::Schema

$obj->knownNamespace($ns|PAIRS)
XML::Compile::RPC->knownNamespace($ns|PAIRS)

Inherited, see "Administration" in XML::Compile

$obj->namespaces()

Inherited, see "Administration" in XML::Compile::Schema

$obj->printIndex( [$fh], %options )

Inherited, see "Administration" in XML::Compile::Cache

$obj->types()

Inherited, see "Administration" in XML::Compile::Schema

$obj->walkTree($node, CODE)

Inherited, see "Administration" in XML::Compile

DETAILS

Extends "DETAILS" in XML::Compile::Cache.

DESCRIPTIONS

Extends "DESCRIPTIONS" in XML::Compile::Cache.

SEE ALSO

This module is part of XML-Compile-RPC distribution version 0.20, built on January 15, 2020. Website: http://perl.overmeer.net/xml-compile/

LICENSE

Copyrights 2009-2020 by [Mark Overmeer <markov@cpan.org>]. 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://dev.perl.org/licenses/