thinkmap.xmlconfig.tags
Class Include

java.lang.Object
  extended by thinkmap.xmlconfig.tags.Include
All Implemented Interfaces:
IConfigTag

public class Include
extends Object
implements IConfigTag

Include brings another xml config file into the current file. It is similar in concept to a C, JSP, and Apache Server-Side Includes. Elements that are given ids in the included file may be given ids in the local file with the 'ref' element.


Nested Class Summary
 class Include.Ref
          Reference an object in the imported document, and give it a local id.
 
Constructor Summary
Include()
           
 
Method Summary
 void addRef(Include.Ref r)
           
 XObject build(Assembler assembler, ConfigElement thisElement, ConfigElement parent, XObject object, XObject parentObject)
           
 Include.Ref createParam()
           
 Include.Ref createRef()
           
 URL getHref()
          Get the url of the file to include.
 String getId()
          Returns the id that the property handler the included config will be stored as.
 String getLocalId()
          Get the local id.
 Include.Ref[] getRefs()
           
 void setHref(URL url)
          Set the url of the file to be included.
 void setId(String handlerid)
          Sets the id that the property handler the included config will be stored as.
 void setLocalId(String s)
          Set the local id.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Include

public Include()
Method Detail

setHref

public void setHref(URL url)
Set the url of the file to be included.

Parameters:
url - url of the file to be included

setLocalId

public void setLocalId(String s)
Set the local id. This id will be given to the root object of the imported xml.

Parameters:
s - local id

getLocalId

public String getLocalId()
Get the local id.

Returns:
local id

getHref

public URL getHref()
Get the url of the file to include.

Returns:
url to include

getId

public String getId()
Returns the id that the property handler the included config will be stored as.

Returns:
Returns the id that the property handler the included config will be stored as.

setId

public void setId(String handlerid)
Sets the id that the property handler the included config will be stored as.

Parameters:
Sets - the id that the property handler the included config will be stored as.

createRef

public Include.Ref createRef()

createParam

public Include.Ref createParam()

addRef

public void addRef(Include.Ref r)

getRefs

public Include.Ref[] getRefs()

build

public XObject build(Assembler assembler,
                     ConfigElement thisElement,
                     ConfigElement parent,
                     XObject object,
                     XObject parentObject)
              throws XMLException
Specified by:
build in interface IConfigTag
Throws:
XMLException


Copyright © 2013 Thinkmap, Inc. All Rights Reserved.