Aktive lesere: 7

Lokale meninger, globale ytringer

Create Array of unique values from another Array

Skrevet av | 0 kommentarer

This code snippet show you how to create an array of unique numbers from another array of numbers. The example is taken from the comment...

Les mer

Get attributes of element during SAX parsing

Skrevet av | 0 kommentarer

This example show you how to get the attributes of elements in an XML file using the SAX parser. package org.brudvik.example.xml; import...

Les mer

Build Object from XML file using SAX

Skrevet av | 0 kommentarer

This example will show you how to parse an XML file using SAX parser and build an object graph from the parsed XML. We will read the...

Les mer

Handle error when parsing an XML file using SAX

Skrevet av | 0 kommentarer

The ErrorHandler interface implemented by the org.xml.sax.helpers.DefaultHandler class provides some methods for error handling mechanism...

Les mer

Parse an XML file using SAX

Skrevet av | 0 kommentarer

This example show you how to read / parse an xml file using the SAX (Simple API for XML) parser. In the main class (SAXDemo) we create the...

Les mer

Create File Object from URL

Skrevet av | 0 kommentarer

The code snippet below use the FileUtils.toFile(URL url) method that can be found in the commons-io library to convert a URL into a File....

Les mer