@Test public void testLoadFromCP() throws Exception { SolrSchemaUtil solrSchemaUtil = new SolrSchemaUtil(); Document schemaDocument = solrSchemaUtil.getSchemaDocument(SOLR_SCHEMA_XML, loader); assertNotNull(schemaDocument); }
public Document getSchemaDocument(String schemaFile, ClassSubPathResourceLoader classLoader) throws ParserConfigurationException, SAXException, IOException { InputStream resourceAsStream = classLoader.openResource(schemaFile); DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = dbf.newDocumentBuilder(); return db.parse(resourceAsStream); }
SolrSchemaUtil { public Document getSchemaDocument(String schemaFile, ClassSubPathResourceLoader classLoader) throws ParserConfigurationException, SAXException, IOException { InputStream resourceAsStream = classLoader.openResource(schemaFile); DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = dbf.newDocumentBuilder(); return db.parse(resourceAsStream); } }
SolrSchemaUtil { public Document getSchemaDocument(String schemaFile, ClassSubPathResourceLoader classLoader) throws ParserConfigurationException, SAXException, IOException { InputStream resourceAsStream = classLoader.openResource(schemaFile); DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = dbf.newDocumentBuilder(); return db.parse(resourceAsStream); }  }
SolrSchemaUtil { public Document getSchemaDocument(String schemaFile, ClassSubPathResourceLoader classLoader) throws ParserConfigurationException, SAXException, IOException { InputStream resourceAsStream = classLoader.openResource(schemaFile); DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = dbf.newDocumentBuilder(); return db.parse(resourceAsStream); }  Document getSchemaDocument(String schemaFile, ClassSubPathResourceLoader classLoader); FieldType getFieldType(Document doc, String fieldTypeName, String luceneMatch, float schemaVersion, ClassSubPathResourceLoader loader); void load(NodeList nodes, String errRef, List<T> list, Class<T> clazz, String luceneMatch, ResourceLoader loader); T newInstance(String cName, Class<T> expectedType, String[] subPackages, Class[] params, Object[] args); Class<? extends T> findClass(String cname, Class<T> expectedType, String... subpackages); }
SolrSchemaUtil { public Document getSchemaDocument(String schemaFile, ClassSubPathResourceLoader classLoader) throws ParserConfigurationException, SAXException, IOException { InputStream resourceAsStream = classLoader.openResource(schemaFile); DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = dbf.newDocumentBuilder(); return db.parse(resourceAsStream); }  Document getSchemaDocument(String schemaFile, ClassSubPathResourceLoader classLoader); FieldType getFieldType(Document doc, String fieldTypeName, String luceneMatch, float schemaVersion, ClassSubPathResourceLoader loader); void load(NodeList nodes, String errRef, List<T> list, Class<T> clazz, String luceneMatch, ResourceLoader loader); T newInstance(String cName, Class<T> expectedType, String[] subPackages, Class[] params, Object[] args); Class<? extends T> findClass(String cname, Class<T> expectedType, String... subpackages); static final String SCHEMA_XML_ANALYZER_FILTER; static final String SCHEMA_XML_ANALYZER_TOKENIZER; static final String SCHEMA_XML_ANALYZER_CHAR_FILTER; }