net.dpml.station.builder
Class RegistryBuilder

java.lang.Object
  extended bynet.dpml.station.builder.RegistryBuilder
All Implemented Interfaces:
Decoder

public final class RegistryBuilder
extends Object
implements Decoder

Test example application sources.

Version:
1.0.1
Author:
Digital Product Meta Library

Constructor Summary
RegistryBuilder()
           
 
Method Summary
 Object build(URI uri)
          Build a registry descriptior from a uri.
protected  ValueDirective buildValueDirective(Element element)
          Construct a single value directive.
protected  ValueDirective[] buildValueDirectives(Element[] elements)
          Construct a value directive array.
 Object decode(Element element, Resolver resolver)
          Decode a registry descriptior from a DOM element.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RegistryBuilder

public RegistryBuilder()
Method Detail

build

public Object build(URI uri)
             throws DecodingException,
                    IOException
Build a registry descriptior from a uri.

Parameters:
uri - the uri to the descriptor XML document
Returns:
the registry descriptor
Throws:
DecodingException - if a decoding error occurs
IOException - if a IO error occurs

decode

public Object decode(Element element,
                     Resolver resolver)
              throws DecodingException
Decode a registry descriptior from a DOM element.

Specified by:
decode in interface Decoder
Parameters:
element - the element representing the root registry
resolver - build-time uri resolver
Returns:
the registry descriptor
Throws:
DecodingException - if a decoding error occurs

buildValueDirectives

protected ValueDirective[] buildValueDirectives(Element[] elements)
Construct a value directive array.

Parameters:
elements - the array of DOM elements representing value directive assertions
Returns:
the array of value directives

buildValueDirective

protected ValueDirective buildValueDirective(Element element)
Construct a single value directive.

Parameters:
element - the DOM element representing the value directive assertions
Returns:
the value directive