Dear Wiki user, You have subscribed to a wiki page or wiki category on "Marmotta Wiki" for change notification.
The "ImportData" page has been changed by JakobFrank: https://wiki.apache.org/marmotta/ImportData?action=diff&rev1=12&rev2=13 Comment: updated java import api == Import data via the client library == - The [[http://marmotta.incubator.apache.org/client-library.html|client library]] could be also used to import data. For example, using Java you would need something like: + The [[http://marmotta.apache.org/client-library.html|client library]] could be also used to import data. For example, using Java you would need something like: {{{ String path = "/path/to/file.rdf"; String context = "http://example.org/context"; ClientConfiguration configuration = new ClientConfiguration("http://host/marmotta/"); + configuration.setMarmottaContext(context); ImportClient importClient = new ImportClient(configuration); InputStream is = new FileInputStream(new File(path)); RDFFormat format = Rio.getParserFormatForFileName(path); - importClient.uploadDataset(is, format.getDefaultMIMEType(), context); + importClient.uploadDataset(is, format.getDefaultMIMEType()); }}} ''(import and so on have been intentionally removed from the snippet)''
