org.apache.lucene.gdata.gom.core.utils
Class AtomParserUtils

java.lang.Object
  extended by org.apache.lucene.gdata.gom.core.utils.AtomParserUtils

public class AtomParserUtils
extends Object

Author:
Simon Willnauer

Constructor Summary
AtomParserUtils()
           
 
Method Summary
static boolean compareAlternateLinks(GOMLink left, GOMLink right)
          Compares two links with rel attribute "alternate" Checks if href and type are equal
static String escapeXMLCharacter(String aString)
          Replaces all xml character with the corresponding entity.
static String getAbsolutAtomURI(String xmlBase, String atomUri)
           
static AtomMediaType getAtomMediaType(String aMediaType)
           
static boolean isAtomMediaType(String aMediaType)
           
static void main(String[] args)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AtomParserUtils

public AtomParserUtils()
Method Detail

escapeXMLCharacter

public static String escapeXMLCharacter(String aString)
Replaces all xml character with the corresponding entity. see W3C specification

Parameters:
aString - - a string may container xml characters like '<'
Returns:
the input string with escaped xml characters

isAtomMediaType

public static boolean isAtomMediaType(String aMediaType)
Parameters:
aMediaType -
Returns:

getAtomMediaType

public static AtomMediaType getAtomMediaType(String aMediaType)
Parameters:
aMediaType -
Returns:

getAbsolutAtomURI

public static String getAbsolutAtomURI(String xmlBase,
                                       String atomUri)
                                throws URISyntaxException
Parameters:
xmlBase -
atomUri -
Returns:
Throws:
URISyntaxException

compareAlternateLinks

public static boolean compareAlternateLinks(GOMLink left,
                                            GOMLink right)
Compares two links with rel attribute "alternate" Checks if href and type are equal

Parameters:
left - - left link to compare
right - - right link to compare
Returns:
true if and only if href and type are equal, otherwise false

main

public static void main(String[] args)


Copyright © 2000-2008 Apache Software Foundation. All Rights Reserved.