1 /* 2 * SPDX-FileCopyrightText: Copyright (c) 2012-2025 Yegor Bugayenko 3 * SPDX-License-Identifier: MIT 4 */ 5 package com.jcabi.xml; 6 7 import java.util.Collection; 8 import javax.xml.transform.Source; 9 import org.xml.sax.SAXParseException; 10 11 /** 12 * XSD schema. 13 * 14 * <p>Implementation of this interface must be immutable and thread-safe. 15 * 16 * @see XSDDocument 17 * @since 0.5 18 * @deprecated This class is deprecated since 0.31.0. Instead, you can 19 * use {@link StrictXML} with a schema provided in the constructor. Otherwise, 20 * you can use {@link XMLDocument} and validate the XML against the schema 21 * via the {@link XMLDocument#validate(XML)} method. 22 * @checkstyle AbbreviationAsWordInNameCheck (5 lines) 23 */ 24 @Deprecated 25 public interface XSD { 26 27 /** 28 * Validate XML. 29 * 30 * @param xml Source XML document 31 * @return Collection of problems found (empty if no problems) 32 */ 33 Collection<SAXParseException> validate(Source xml); 34 35 }