public class OmicsXMLFile extends Object
| Constructor and Description |
|---|
OmicsXMLFile(File file) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the Reader
|
List<Entry> |
getAllEntries() |
String |
getDatabaseName() |
String |
getDescription() |
Entry |
getEntryById(String id)
This function return the information of an element using the the id in the XML, for example PXD00001
|
Entry |
getEntryByIndex(Integer index)
THis function return an entry using the index element in the file for example first element (index = 0),
second element (index = 1)
|
Integer |
getEntryCount() |
List<String> |
getEntryIds()
Return all the entry Ids from the XML
|
String |
getName() |
String |
getRelease() |
String |
getReleaseDate() |
static boolean |
hasFileHeader(File file) |
static boolean |
isSchemaValid(File xmlFile) |
void |
setDatabaseName(String name) |
static List<Tuple> |
validateSchema(File file)
Return Error as a Tuple with the Code of the Error and the message.
|
static List<Tuple> |
validateSemantic(File file) |
public OmicsXMLFile(File file) throws DDIException
DDIExceptionpublic Entry getEntryById(String id) throws DDIException
id - the id value in the fileDDIExceptionpublic List<Entry> getAllEntries() throws DDIException
DDIExceptionpublic Entry getEntryByIndex(Integer index) throws DDIException
index - the index in the List of file elementsDDIExceptionpublic List<String> getEntryIds()
public static boolean isSchemaValid(File xmlFile)
public static boolean hasFileHeader(File file) throws DDIException
DDIExceptionpublic static List<Tuple> validateSchema(File file)
file - the file to be validatedpublic String getName()
public String getDescription()
public String getRelease()
public String getReleaseDate()
public Integer getEntryCount()
public void setDatabaseName(String name)
public String getDatabaseName()
public void close()
Copyright © 2019. All Rights Reserved.