biweekly.io.xml
Class XCalNamespaceContext

java.lang.Object
  extended by biweekly.io.xml.XCalNamespaceContext
All Implemented Interfaces:
NamespaceContext

public class XCalNamespaceContext
extends Object
implements NamespaceContext

Used for xCal xpath expressions.

Author:
Michael Angstadt
See Also:
XPath.setNamespaceContext(NamespaceContext)

Field Summary
static String XCAL_NS
          The XML namespace for xCal documents.
 
Constructor Summary
XCalNamespaceContext(String prefix)
          Creates a new namespace context.
 
Method Summary
 String getNamespaceURI(String prefix)
           
 String getPrefix()
          Gets the prefix to use in xpath expressions.
 String getPrefix(String ns)
           
 Iterator<String> getPrefixes(String ns)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

XCAL_NS

public static final String XCAL_NS
The XML namespace for xCal documents.

See Also:
Constant Field Values
Constructor Detail

XCalNamespaceContext

public XCalNamespaceContext(String prefix)
Creates a new namespace context.

Parameters:
prefix - the prefix to use in xpath expressions
Method Detail

getPrefix

public String getPrefix()
Gets the prefix to use in xpath expressions.

Returns:
the xpath prefix

getNamespaceURI

public String getNamespaceURI(String prefix)
Specified by:
getNamespaceURI in interface NamespaceContext

getPrefix

public String getPrefix(String ns)
Specified by:
getPrefix in interface NamespaceContext

getPrefixes

public Iterator<String> getPrefixes(String ns)
Specified by:
getPrefixes in interface NamespaceContext


Copyright © 2013 Michael Angstadt. All Rights Reserved.