Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

import java.io.IOException;

import javax.xml.transform.dom.DOMSource;

import javax.xml.validation.Schema;

import org.w3c.dom.Document;

import org.xml.sax.SAXException;

public class Main {
    public static void validate(Schema schema, Document document) throws SAXException, IOException {
        schema.newValidator().validate(new DOMSource(document));
    }
}