com.xpn.xwiki.tool.xar
Class XWikiDocument

java.lang.Object
  extended by com.xpn.xwiki.tool.xar.XWikiDocument

public class XWikiDocument
extends Object

Parse XWiki document from XML.

Version:
$Id$

Constructor Summary
XWikiDocument()
           
 
Method Summary
 void fromXML(File file)
          Parse xml file to extract documents informations.
 String getDefaultLanguage()
           
 String getFullName()
           
static String getFullName(File file)
           
 String getLanguage()
           
 String getName()
           
 String getSpace()
           
 void setDefaultLanguage(String defaultLanguage)
           
 void setLanguage(String language)
           
 void setName(String name)
           
 void setSpace(String space)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XWikiDocument

public XWikiDocument()
Method Detail

fromXML

public void fromXML(File file)
             throws org.dom4j.DocumentException
Parse xml file to extract documents informations.

Parameters:
file - the xml file.
Throws:
org.dom4j.DocumentException - error when parsing XML file.

getName

public String getName()
Returns:
the name of the document.

setName

public void setName(String name)
Parameters:
name - the name of the document.

getSpace

public String getSpace()
Returns:
the space of the document.

setSpace

public void setSpace(String space)
Parameters:
space - the space of the document.

getLanguage

public String getLanguage()
Returns:
the language of the document.

setLanguage

public void setLanguage(String language)
Parameters:
language - the language of the document.

getDefaultLanguage

public String getDefaultLanguage()
Returns:
the default language of the document.

setDefaultLanguage

public void setDefaultLanguage(String defaultLanguage)
Parameters:
defaultLanguage - the default language of the document.

getFullName

public String getFullName()
Returns:
the full name of the document.

getFullName

public static String getFullName(File file)
Parameters:
file - the file containing the document.
Returns:
the full name of the document or null, if the document is invalid


Copyright © 2004-2012 XWiki. All Rights Reserved.