|
Scala Library Documentation
|
|
scala/xml/XML.scala]
object
XML
extends AnyRefXML provides constants, and functions to load
and save XML elements. Use this when data binding is not desired, i.e.
when XML is handled using Symbol nodes.| Value Summary | |
val
|
encoding : String |
val
|
lang : String |
val
|
namespace : String |
val
|
preserve : String |
val
|
space : String |
val
|
xml : String |
val
|
xmlns : String |
| Method Summary | |
final def
|
load
(source : InputSource) : Elem
loads XML from a given input source, using XML parser in JDK.
|
final def
|
load
(reader : Reader) : Elem
loads XML from given Reader, using XML parser in JDK.
|
final def
|
load
(is : InputStream) : Elem
loads XML from given InputStream, using XML parser in JDK.
|
final def
|
load
(sysID : String) : Elem
loads XML from given sysID, using XML parser in JDK.
|
final def
|
loadFile
(fileDesc : FileDescriptor) : Elem
loads XML from given file descriptor, using XML parser in JDK.
|
final def
|
loadFile
(fileName : String) : Elem
loads XML from given file, using XML parser in JDK.
|
final def
|
loadFile
(file : File) : Elem
loads XML from given file, using XML parser in JDK.
|
final def
|
loadString
(string : String) : Elem
loads XML from a string, using XML parser in JDK.
|
final def
|
save
(filename : String, node : Node) : Unit
Saves XML to filename with encoding ISO-8859-1 without xml-decl without
doctype. |
final def
|
save
(filename : String, node : Node, enc : String) : Unit
saves XML to filename with given encoding, without xml-decl without
doctype. |
final def
|
saveFull
(filename : String, node : Node, xmlDecl : Boolean, doctype : DocType) : Unit
saves a node to a file with given filename using encoding iso-8859-1
optionally with xmldecl and doctype declaration.
|
final def
|
saveFull
(filename : String, node : Node, enc : String, xmlDecl : Boolean, doctype : DocType) : Unit
Saves a node to a file with given filename using given encoding
optionally with xmldecl and doctype declaration.
|
final def
|
write
(w : Writer, node : Node, enc : String, xmlDecl : Boolean, doctype : DocType) : Unit
Writes the given node using writer, optionally with xml decl and doctype.
It's the caller's responsibility to close the writer.
|
| Methods inherited from AnyRef | |
| getClass, hashCode, equals, clone, toString, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized |
| Methods inherited from Any | |
| ==, !=, isInstanceOf, asInstanceOf |
| Value Details |
val
xml : String
val
xmlns : String
val
namespace : String
val
preserve : String
val
space : String
val
lang : String
val
encoding : String
| Method Details |
final
def
loadFile(fileDesc : FileDescriptor) : Elem
fileDesc - ...final
def
load(is : InputStream) : Elem
final
def
load(source : InputSource) : Elem
source - ...doctype.filename - ...node - ...doctype.filename - ...node - ...enc - ...filename - the filenamenode - the xml node we want to writexmlDecl - if true, write xml declarationdoctype - if not null, write doctype declarationfinal
def
saveFull(filename : String, node : Node, enc : String, xmlDecl : Boolean, doctype : DocType) : Unit
filename - the filenamenode - the xml node we want to writeenc - encoding to usexmlDecl - if true, write xml declarationdoctype - if not null, write doctype declarationw - the writernode - the xml node we want to writeenc - the string to be used in xmlDeclxmlDecl - if true, write xml declarationdoctype - if not null, write doctype declaration|
Scala Library Documentation
|
|