org.dspace.app.sfx
Class SFXFileReader

java.lang.Object
  extended by org.dspace.app.sfx.SFXFileReader

public class SFXFileReader
extends Object


Constructor Summary
SFXFileReader()
           
 
Method Summary
static String doNodes(Node node, Item item)
          Process the item.
static String getAttribute(Node e, String name)
          Returns the value of the node's attribute named
static Node getElement(Node node)
          Returns element node
static String getValue(Node node)
          Returns the value found in the Text node (if any) in the node list that's passed in.
static boolean isEmptyTextNode(Node nd)
          Is Empty text Node
static String loadSFXFile(String fileName, Item item)
          Loads the SFX configuraiton file
static Document parseFile(String fileName)
          Parses XML file and returns XML document.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SFXFileReader

public SFXFileReader()
Method Detail

loadSFXFile

public static String loadSFXFile(String fileName,
                                 Item item)
                          throws IOException
Loads the SFX configuraiton file

Parameters:
fileName - The name of the SFX configuration file
item - The item to process
Returns:
the SFX string
Throws:
IOException

parseFile

public static Document parseFile(String fileName)
Parses XML file and returns XML document.

Parameters:
fileName - XML file to parse
Returns:
XML document or null if error occured

doNodes

public static String doNodes(Node node,
                             Item item)
                      throws IOException
Process the item.

Parameters:
node -
item -
Returns:
processed fields.
Throws:
IOException

getElement

public static Node getElement(Node node)
Returns element node

Parameters:
node - element (it is XML tag)
Returns:
Element node otherwise null

isEmptyTextNode

public static boolean isEmptyTextNode(Node nd)
Is Empty text Node


getAttribute

public static String getAttribute(Node e,
                                  String name)
Returns the value of the node's attribute named


getValue

public static String getValue(Node node)
Returns the value found in the Text node (if any) in the node list that's passed in.



Copyright © 2012 DuraSpace. All Rights Reserved.