diff --git a/biodata-formats/pom.xml b/biodata-formats/pom.xml index c84192db6..7079cda8c 100644 --- a/biodata-formats/pom.xml +++ b/biodata-formats/pom.xml @@ -42,6 +42,10 @@ org.opencb.commons commons-lib + + org.opencb.commons + commons-datastore-core + jakarta.xml.bind @@ -97,6 +101,16 @@ jackson-mapper-asl test --> + + + org.apache.poi + poi + + + org.apache.poi + poi-ooxml + + junit junit diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerDbParserCallback.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerDbParserCallback.java new file mode 100644 index 000000000..6fe1a321d --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerDbParserCallback.java @@ -0,0 +1,25 @@ +/* + * + * + */ + +package org.opencb.biodata.formats.feature.chimerdb; + + +public interface ChimerDbParserCallback { + boolean processChimerDbObject(T object); +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerKbParser.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerKbParser.java new file mode 100644 index 000000000..5c5e098b8 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerKbParser.java @@ -0,0 +1,279 @@ +/* + * + * + */ + +package org.opencb.biodata.formats.feature.chimerdb; + +import org.apache.poi.ss.usermodel.Row; +import org.apache.poi.ss.usermodel.Sheet; +import org.apache.poi.ss.usermodel.Workbook; +import org.apache.poi.xssf.usermodel.XSSFWorkbook; +import org.opencb.biodata.models.core.chimerdb.ChimerKb; +import org.opencb.biodata.models.core.chimerdb.ChimerKbGeneBreakpoint; +import org.opencb.commons.utils.FileUtils; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.io.FileInputStream; +import java.io.IOException; +import java.nio.file.Path; +import java.util.Arrays; +import java.util.Iterator; +import java.util.stream.Collectors; + +import static org.opencb.biodata.formats.feature.chimerdb.ChimerPubParser.getIntCellValue; +import static org.opencb.biodata.formats.feature.chimerdb.ChimerPubParser.getStringCellValue; + +public class ChimerKbParser { + + private static Logger logger = LoggerFactory.getLogger(ChimerKbParser.class); + + public static void parse(Path xlsxPath, ChimerDbParserCallback callback) throws IOException { + logger.info("Parsing ChimerKB file: {}", xlsxPath); + FileUtils.checkFile(xlsxPath); + + try (FileInputStream excelFile = new FileInputStream(xlsxPath.toFile()); + Workbook workbook = new XSSFWorkbook(excelFile)) { + // Get the first sheet from the workbook + Sheet sheet = workbook.getSheetAt(0); + + // Iterate over rows + Iterator rowIterator = sheet.iterator(); + while (rowIterator.hasNext()) { + Row row = rowIterator.next(); + + // Skip header row if needed (e.g., if first row is header) + if (row.getRowNum() == 0) { + continue; + } + + String strValue; + Integer intValue; + + ChimerKb chimerKb = new ChimerKb(); + + // 0 1 2 3 4 5 6 7 8 9 10 + // id ChimerDB_Type Source webSource Fusion_pair 5Gene_Junction 3Gene_Junction H_gene H_chr H_position H_strand + // 11 12 13 14 15 16 17 18 + // T_gene T_chr T_position T_strand Genomic_breakpoint Exonic_breakpoint Breakpoint_Type Genome_Build_Version + // 19 20 21 22 23 24 25 26 27 28 + // PMID Disease Validation Frame Chr_info Kinase Oncogene Tumor_suppressor Receptor Transcription_Factor + // 29 30 31 + // ChimerPub ChimerSeq ChimerSeq+ + + // ID + chimerKb.setId(String.valueOf((int) row.getCell(0).getNumericCellValue())); + + // ChimerDB Type + strValue = getStringCellValue(row, 1); + if (strValue != null) { + chimerKb.setChimerDbType(strValue); + } + + // Source (different from source provided by user) + strValue = getStringCellValue(row, 2); + if (strValue != null) { + chimerKb.setChimerSource(strValue); + } + + // Web source + strValue = getStringCellValue(row, 3); + if (strValue != null) { + chimerKb.setWebSource(strValue); + } + + // Fusion pair + strValue = getStringCellValue(row, 4); + if (strValue != null) { + chimerKb.setFusionPair(strValue); + } + + // Gene junctions (5 and 3) + strValue = getStringCellValue(row, 5); + if (strValue != null) { + chimerKb.setFiveGeneJunction(strValue); + } + strValue = getStringCellValue(row, 6); + if (strValue != null) { + chimerKb.setThreeGeneJunction(strValue); + } + + // Head gene breakpoint + ChimerKbGeneBreakpoint head = new ChimerKbGeneBreakpoint(); + strValue = getStringCellValue(row, 7); + if (strValue != null) { + head.setGeneName(strValue); + } + strValue = getStringCellValue(row, 8); + if (strValue != null) { + if (strValue.startsWith("chr") || strValue.startsWith("Chr") || strValue.startsWith("CHR")) { + // Remove 'chr' prefix if present + strValue = strValue.substring(3); + } + head.setChromosome(strValue); + } + intValue = getIntCellValue(row, 9); + if (intValue != null) { + head.setPosition(intValue); + } + strValue = getStringCellValue(row, 10); + if (strValue != null) { + head.setStrand(strValue); + } + chimerKb.setHeadGene(head); + + // Tail gene breakpoint + ChimerKbGeneBreakpoint tail = new ChimerKbGeneBreakpoint(); + strValue = getStringCellValue(row, 11); + if (strValue != null) { + tail.setGeneName(strValue); + } + strValue = getStringCellValue(row, 12); + if (strValue != null) { + if (strValue.startsWith("chr") || strValue.startsWith("Chr") || strValue.startsWith("CHR")) { + // Remove 'chr' prefix if present + strValue = strValue.substring(3); + } + tail.setChromosome(strValue); + } + intValue = getIntCellValue(row, 13); + if (intValue != null) { + tail.setPosition(intValue); + } + strValue = getStringCellValue(row, 14); + if (strValue != null) { + tail.setStrand(strValue); + } + chimerKb.setTailGene(tail); + + // Genomic breakpoint + intValue = getIntCellValue(row, 15); + if (intValue != null) { + chimerKb.setGenomicBreakpoint(intValue == 1); + } + + // Exonic breakpoint + intValue = getIntCellValue(row, 16); + if (intValue != null) { + chimerKb.setExonicBreakpoint(intValue == 1); + } + + // Breakpoint type + strValue = getStringCellValue(row, 17); + if (strValue != null) { + chimerKb.setBreakpointType(strValue); + } + + // Genome build version + strValue = getStringCellValue(row, 18); + if (strValue != null) { + chimerKb.setGenomeBuildVersion(strValue); + } + + // Publications + strValue = getStringCellValue(row, 19); + if (strValue != null) { + chimerKb.setPmid(Arrays.stream(strValue.split(",")).map(String::trim).collect(Collectors.toList())); + } else { + intValue = getIntCellValue(row, 19); + if (intValue != null && intValue > 0) { + chimerKb.setPmid(Arrays.asList(String.valueOf(intValue))); + } + } + + // Diseases + strValue = getStringCellValue(row, 20); + if (strValue != null) { + chimerKb.setDiseases(Arrays.stream(strValue.split(",")).map(String::trim).collect(Collectors.toList())); + } + + // Validations + strValue = getStringCellValue(row, 21); + if (strValue != null) { + chimerKb.setValidations(Arrays.stream(strValue.split(",")).map(String::trim).collect(Collectors.toList())); + } + + // Frame + strValue = getStringCellValue(row, 22); + if (strValue != null) { + chimerKb.setFrame(strValue); + } + + // Chromosome info + strValue = getStringCellValue(row, 23); + if (strValue != null) { + chimerKb.setChrInfo(strValue); + } + + // Kinase + strValue = getStringCellValue(row, 24); + if (strValue != null) { + chimerKb.setKinase(strValue.equalsIgnoreCase("kinase")); + } + + // Oncogene + strValue = getStringCellValue(row, 25); + if (strValue != null) { + chimerKb.setOncogene(strValue.equalsIgnoreCase("oncogene")); + } + + // Tumor suppressor + strValue = getStringCellValue(row, 26); + if (strValue != null) { + chimerKb.setTumorSuppressor(strValue.equalsIgnoreCase("Tumor suppressor gene")); + } + + // Receptor + strValue = getStringCellValue(row, 27); + if (strValue != null) { + chimerKb.setReceptor(strValue.equalsIgnoreCase("Receptor")); + } + + // Transcription factor + strValue = getStringCellValue(row, 28); + if (strValue != null) { + chimerKb.setTranscriptionFactor(strValue.equalsIgnoreCase("Transcription factor")); + } + + // ChimerPub + strValue = getStringCellValue(row, 29); + if (strValue != null) { + chimerKb.setChimerPub(strValue.equalsIgnoreCase("Pub")); + } + + // ChimerSeq + strValue = getStringCellValue(row, 30); + if (strValue != null) { + chimerKb.setChimerSeq(strValue.equalsIgnoreCase("Seq")); + } + + // ChimerSeq+ + strValue = getStringCellValue(row, 31); + if (strValue != null) { + chimerKb.setChimerSeqPlus(strValue.equalsIgnoreCase("Seq+")); + } + + // Callback to process the gene fusion + callback.processChimerDbObject(chimerKb); + } + } catch (IOException e) { + throw new IOException("Error reading the ChimerKB file: " + e.getMessage(), e); + } + logger.info("ChimerKB file parsed successfully: {}", xlsxPath); + } +} \ No newline at end of file diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerPubParser.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerPubParser.java new file mode 100644 index 000000000..6ca5e7348 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerPubParser.java @@ -0,0 +1,258 @@ +/* + * + * + */ + +package org.opencb.biodata.formats.feature.chimerdb; + +import org.apache.commons.lang3.StringUtils; +import org.apache.poi.ss.usermodel.CellType; +import org.apache.poi.ss.usermodel.Row; +import org.apache.poi.ss.usermodel.Sheet; +import org.apache.poi.ss.usermodel.Workbook; +import org.apache.poi.xssf.usermodel.XSSFWorkbook; +import org.opencb.biodata.models.core.chimerdb.ChimerPub; +import org.opencb.biodata.models.core.chimerdb.ChimerPubGeneBreakpoint; +import org.opencb.commons.utils.FileUtils; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.io.FileInputStream; +import java.io.IOException; +import java.nio.file.Path; +import java.util.Arrays; +import java.util.Iterator; +import java.util.stream.Collectors; + +public class ChimerPubParser { + + private static Logger logger = LoggerFactory.getLogger(ChimerPubParser.class); + + public static void parse(Path xlsxPath, ChimerDbParserCallback callback) throws IOException { + logger.info("Parsing ChimerPub file: {}", xlsxPath); + FileUtils.checkFile(xlsxPath); + + try (FileInputStream excelFile = new FileInputStream(xlsxPath.toFile()); + Workbook workbook = new XSSFWorkbook(excelFile)) { + // Get the first sheet from the workbook + Sheet sheet = workbook.getSheetAt(0); + + // Iterate over rows + Iterator rowIterator = sheet.iterator(); + while (rowIterator.hasNext()) { + Row row = rowIterator.next(); + + // Skip header row if needed (e.g., if first row is header) + if (row.getRowNum() == 0) { + continue; + } + + String strValue; + Integer intValue; + Double doubleValue; + + ChimerPub chimerPub = new ChimerPub(); + + // 0 1 2 3 4 5 6 7 8 9 10 11 + // id Fusion_pair Translocation H_gene T_gene PMID Score Disease Validation Kinase Oncogene Tumor_suppressor + // 12 13 14 15 16 17 18 + // Receptor Transcription_Factor ChimerKB ChimerSeq ChimerSeq+ Sentence_highlight H_gene_highlight + // 19 20 21 + // T_gene_highlight Disease_highlight Validation_highlight + + // ID + chimerPub.setId(String.valueOf((int) row.getCell(0).getNumericCellValue())); + + // Fusion pair + strValue = getStringCellValue(row, 1); + if (strValue != null) { + chimerPub.setFusionPair(strValue); + } + + // Translocation + strValue = getStringCellValue(row, 2); + if (strValue != null) { + chimerPub.setTranslocation(strValue); + } + + // Head gene breakpoint + ChimerPubGeneBreakpoint head = new ChimerPubGeneBreakpoint(); + strValue = getStringCellValue(row, 3); + if (strValue != null) { + head.setGeneName(strValue); + } + strValue = getStringCellValue(row, 18); + if (strValue != null) { + head.setHighlight(strValue); + } + chimerPub.setHeadGene(head); + + // Tail gene breakpoint + ChimerPubGeneBreakpoint tail = new ChimerPubGeneBreakpoint(); + strValue = getStringCellValue(row, 4); + if (strValue != null) { + tail.setGeneName(strValue); + } + strValue = getStringCellValue(row, 19); + if (strValue != null) { + tail.setHighlight(strValue); + } + chimerPub.setTailGene(tail); + + // Publications + strValue = getStringCellValue(row, 5); + if (strValue != null) { + chimerPub.setPmid(Arrays.stream(strValue.split(",")).map(String::trim).collect(Collectors.toList())); + } else { + intValue = getIntCellValue(row, 5); + if (intValue != null && intValue > 0) { + chimerPub.setPmid(Arrays.asList(String.valueOf(intValue))); + } + } + + // Score + doubleValue = getDoubleCellValue(row, 6); + if (doubleValue != null) { + chimerPub.setScore(doubleValue); + } + + // Diseases + strValue = getStringCellValue(row, 7); + if (strValue != null) { + chimerPub.setDiseases(Arrays.stream(strValue.split(",")).map(String::trim).collect(Collectors.toList())); + } + + // Validations + strValue = getStringCellValue(row, 8); + if (strValue != null) { + chimerPub.setValidations(Arrays.stream(strValue.split(",")).map(String::trim).collect(Collectors.toList())); + } + + // Kinase + strValue = getStringCellValue(row, 9); + if (strValue != null) { + chimerPub.setKinase(strValue.equalsIgnoreCase("kinase")); + } + + // Oncogene + strValue = getStringCellValue(row, 10); + if (strValue != null) { + chimerPub.setOncogene(strValue.equalsIgnoreCase("oncogene")); + } + + // Tumor suppressor + strValue = getStringCellValue(row, 11); + if (strValue != null) { + chimerPub.setTumorSuppressor(strValue.equalsIgnoreCase("Tumor suppressor gene")); + } + + // Receptor + strValue = getStringCellValue(row, 12); + if (strValue != null) { + chimerPub.setReceptor(strValue.equalsIgnoreCase("Receptor")); + } + + // Transcription factor + strValue = getStringCellValue(row, 13); + if (strValue != null) { + chimerPub.setTranscriptionFactor(strValue.equalsIgnoreCase("Transcription factor")); + } + + // ChimerKb + strValue = getStringCellValue(row, 14); + if (strValue != null) { + chimerPub.setChimerKb(strValue.equalsIgnoreCase("KB")); + } + + // ChimerSeq + strValue = getStringCellValue(row, 15); + if (strValue != null) { + chimerPub.setChimerSeq(strValue.equalsIgnoreCase("Seq")); + } + + // ChimerSeq+ + strValue = getStringCellValue(row, 16); + if (strValue != null) { + chimerPub.setChimerSeqPlus(strValue.equalsIgnoreCase("Seq+")); + } + + // Sentence highlight + strValue = getStringCellValue(row, 17); + if (strValue != null) { + chimerPub.setSenteceHighlight(strValue); + } + + // Disease highlight + strValue = getStringCellValue(row, 20); + if (strValue != null) { + chimerPub.setDiseaseHighlight(strValue); + } + + // Validation highlight + strValue = getStringCellValue(row, 21); + if (strValue != null) { + chimerPub.setValidationHighlight(strValue); + } + + // Callback to process the gene fusion + callback.processChimerDbObject(chimerPub); + } + } catch (IOException e) { + throw new IOException("Error reading the ChimerPub file: " + e.getMessage(), e); + } + logger.info("ChimerPub file parsed successfully: {}", xlsxPath); + } + + public static Integer getIntCellValue(Row row, int index) { + if (row.getCell(index) == null) { + return null; + } + if (row.getCell(index).getCellType() != CellType.NUMERIC) { + logger.warn("Error in cell {} of row {}, expected NUMERIC but found {}", index, row.getRowNum(), + row.getCell(index).getCellType()); + return null; + } + return (int) row.getCell(index).getNumericCellValue(); + } + + public static Double getDoubleCellValue(Row row, int index) { + if (row.getCell(index) == null) { + return null; + } + if (row.getCell(index).getCellType() != CellType.NUMERIC) { + logger.warn("Error in cell {} of row {}, expected NUMERIC but found {}", index, row.getRowNum(), + row.getCell(index).getCellType()); + return null; + } + return row.getCell(index).getNumericCellValue(); + } + + public static String getStringCellValue(Row row, int index) { + if (row.getCell(index) == null) { + return null; + } + if (row.getCell(index).getCellType() != CellType.STRING) { + logger.warn("Error in cell {} of row {}, expected STRING but found {}", index, row.getRowNum(), + row.getCell(index).getCellType()); + return null; + } + if (StringUtils.isNotEmpty(row.getCell(index).getStringCellValue())) { + return row.getCell(index).getStringCellValue(); + } + return null; + } +} \ No newline at end of file diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerSeqParser.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerSeqParser.java new file mode 100644 index 000000000..a0c0783c5 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/chimerdb/ChimerSeqParser.java @@ -0,0 +1,282 @@ +/* + * + * + */ + +package org.opencb.biodata.formats.feature.chimerdb; + +import org.apache.poi.ss.usermodel.Row; +import org.apache.poi.ss.usermodel.Sheet; +import org.apache.poi.ss.usermodel.Workbook; +import org.apache.poi.xssf.usermodel.XSSFWorkbook; +import org.opencb.biodata.models.core.chimerdb.ChimerSeq; +import org.opencb.biodata.models.core.chimerdb.ChimerSeqGeneBreakpoint; +import org.opencb.commons.utils.FileUtils; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.io.FileInputStream; +import java.io.IOException; +import java.nio.file.Path; +import java.util.Iterator; + +import static org.opencb.biodata.formats.feature.chimerdb.ChimerPubParser.getIntCellValue; +import static org.opencb.biodata.formats.feature.chimerdb.ChimerPubParser.getStringCellValue; + +public class ChimerSeqParser { + + private static Logger logger = LoggerFactory.getLogger(ChimerSeqParser.class); + + public static void parse(Path xlsxPath, ChimerDbParserCallback callback) throws IOException { + logger.info("Parsing ChimerSeq file: {}", xlsxPath); + FileUtils.checkFile(xlsxPath); + + try (FileInputStream excelFile = new FileInputStream(xlsxPath.toFile()); + Workbook workbook = new XSSFWorkbook(excelFile)) { + // Get the first sheet from the workbook + Sheet sheet = workbook.getSheetAt(0); + + // Iterate over rows + Iterator rowIterator = sheet.iterator(); + while (rowIterator.hasNext()) { + Row row = rowIterator.next(); + + // Skip header row if needed (e.g., if first row is header) + if (row.getRowNum() == 0) { + continue; + } + + String strValue; + Integer intValue; + + ChimerSeq chimerSeq = new ChimerSeq(); + + // 0 1 2 3 4 5 6 7 8 9 10 11 + // id ChimerDB_Type Source webSource Fusion_pair H_gene H_chr H_position H_strand T_gene T_chr T_position + // 12 13 14 15 16 17 18 + // T_strand Genomic_breakpoint Genome_Build_Version Cancertype BarcodeID Seed_reads_num Spanning_pairs_num + // 19 20 21 22 23 24 25 26 + // Junction_reads_num Frame Chr_info H_locus H_kinase H_oncogene H_tumor_suppressor H_receptor + // 27 28 29 30 + // H_transcription_factor T_locus T_kinase T_oncogene + // 31 32 33 34 35 36 + // T_tumor_suppressor T_receptor T_transcription_factor ChimerKB ChimerPub Highly_Reliable_Seq + + // ID + chimerSeq.setId(String.valueOf((int) row.getCell(0).getNumericCellValue())); + + // ChimerDB Type + strValue = getStringCellValue(row, 1); + if (strValue != null) { + chimerSeq.setChimerDbType(strValue); + } + + // Source (different from source provided by user) + strValue = getStringCellValue(row, 2); + if (strValue != null) { + chimerSeq.setChimerSource(strValue); + } + + // Web source + strValue = getStringCellValue(row, 3); + if (strValue != null) { + chimerSeq.setWebSource(strValue); + } + + // Fusion pair + strValue = getStringCellValue(row, 4); + if (strValue != null) { + chimerSeq.setFusionPair(strValue); + } + + // Head gene breakpoint + ChimerSeqGeneBreakpoint head = new ChimerSeqGeneBreakpoint(); + strValue = getStringCellValue(row, 5); + if (strValue != null) { + head.setGeneName(strValue); + } + strValue = getStringCellValue(row, 6); + if (strValue != null) { + if (strValue.startsWith("chr") || strValue.startsWith("Chr") || strValue.startsWith("CHR")) { + // Remove 'chr' prefix if present + strValue = strValue.substring(3); + } + head.setChromosome(strValue); + } + intValue = getIntCellValue(row, 7); + if (intValue != null) { + head.setPosition(intValue); + } + strValue = getStringCellValue(row, 8); + if (strValue != null) { + head.setStrand(strValue); + } + strValue = getStringCellValue(row, 22); + if (strValue != null) { + head.setLocus(strValue); + } + strValue = getStringCellValue(row, 23); + if (strValue != null) { + head.setKinase(strValue.equalsIgnoreCase("kinase")); + } + strValue = getStringCellValue(row, 24); + if (strValue != null) { + head.setOncogene(strValue.equalsIgnoreCase("oncogene")); + } + strValue = getStringCellValue(row, 25); + if (strValue != null) { + head.setTumorSuppressor(strValue.equalsIgnoreCase("Tumor suppressor gene")); + } + strValue = getStringCellValue(row, 26); + if (strValue != null) { + head.setReceptor(strValue.equalsIgnoreCase("Receptor")); + } + strValue = getStringCellValue(row, 27); + if (strValue != null) { + head.setTranscriptionFactor(strValue.equalsIgnoreCase("Transcription factor")); + } + chimerSeq.setHeadGene(head); + + // Tail gene breakpoint + ChimerSeqGeneBreakpoint tail = new ChimerSeqGeneBreakpoint(); + strValue = getStringCellValue(row, 9); + if (strValue != null) { + tail.setGeneName(strValue); + } + strValue = getStringCellValue(row, 10); + if (strValue != null) { + if (strValue.startsWith("chr") || strValue.startsWith("Chr") || strValue.startsWith("CHR")) { + // Remove 'chr' prefix if present + strValue = strValue.substring(3); + } + tail.setChromosome(strValue); + } + intValue = getIntCellValue(row, 11); + if (intValue != null) { + tail.setPosition(intValue); + } + strValue = getStringCellValue(row, 12); + if (strValue != null) { + tail.setStrand(strValue); + } + strValue = getStringCellValue(row, 28); + if (strValue != null) { + tail.setLocus(strValue); + } + strValue = getStringCellValue(row, 29); + if (strValue != null) { + tail.setKinase(strValue.equalsIgnoreCase("kinase")); + } + strValue = getStringCellValue(row, 30); + if (strValue != null) { + tail.setOncogene(strValue.equalsIgnoreCase("oncogene")); + } + strValue = getStringCellValue(row, 31); + if (strValue != null) { + tail.setTumorSuppressor(strValue.equalsIgnoreCase("Tumor suppressor gene")); + } + strValue = getStringCellValue(row, 32); + if (strValue != null) { + tail.setReceptor(strValue.equalsIgnoreCase("Receptor")); + } + strValue = getStringCellValue(row, 33); + if (strValue != null) { + tail.setTranscriptionFactor(strValue.equalsIgnoreCase("Transcription factor")); + } + chimerSeq.setTailGene(tail); + + // Genomic breakpoint + strValue = getStringCellValue(row, 13); + if (intValue != null) { + chimerSeq.setGenomicBreakpoint(strValue); + } + + // Genome build version + strValue = getStringCellValue(row, 14); + if (strValue != null) { + chimerSeq.setGenomeBuildVersion(strValue); + } + + // Cancer type + strValue = getStringCellValue(row, 15); + if (intValue != null) { + chimerSeq.setCancerType(strValue); + } + + // Barcode ID + strValue = getStringCellValue(row, 16); + if (strValue != null) { + chimerSeq.setBarcodeId(strValue); + } + + // Seed reads number + intValue = getIntCellValue(row, 17); + if (intValue != null) { + chimerSeq.setSeedReadsNum(intValue); + } + + // Spanning pairs number + intValue = getIntCellValue(row, 18); + if (intValue != null) { + chimerSeq.setSpanningPairsNum(intValue); + } + + // Junction reads number + intValue = getIntCellValue(row, 19); + if (intValue != null) { + chimerSeq.setJunctionReadsNum(intValue); + } + + // Frame + strValue = getStringCellValue(row, 20); + if (strValue != null) { + chimerSeq.setFrame(strValue); + } + + // Chromosome info + strValue = getStringCellValue(row, 21); + if (strValue != null) { + chimerSeq.setChrInfo(strValue); + } + + // ChimerKb + strValue = getStringCellValue(row, 34); + if (strValue != null) { + chimerSeq.setChimerKb(strValue.equalsIgnoreCase("KB")); + } + + // ChimerPub + strValue = getStringCellValue(row, 35); + if (strValue != null) { + chimerSeq.setChimerPub(strValue.equalsIgnoreCase("Pub")); + } + + // Highly reliable sequence + strValue = getStringCellValue(row, 36); + if (strValue != null) { + chimerSeq.setHighlyReliableSeq(strValue.equalsIgnoreCase("Seq+")); + } + + // Callback to process the gene fusion + callback.processChimerDbObject(chimerSeq); + } + } catch (IOException e) { + throw new IOException("Error reading the ChimerKB file: " + e.getMessage(), e); + } + logger.info("ChimerKB file parsed successfully: {}", xlsxPath); + } +} \ No newline at end of file diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/mirbase/MirBaseParser.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/mirbase/MirBaseParser.java new file mode 100644 index 000000000..e360f9789 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/mirbase/MirBaseParser.java @@ -0,0 +1,118 @@ +package org.opencb.biodata.formats.feature.mirbase; + +import org.opencb.biodata.models.core.MiRnaGene; +import org.opencb.biodata.models.core.MiRnaMature; +import org.opencb.commons.utils.FileUtils; + +import java.io.BufferedReader; +import java.io.IOException; +import java.io.InputStreamReader; +import java.nio.file.Path; + +public class MirBaseParser { + + private static final String ID_LABEL = "ID"; + private static final String AC_LABEL = "AC"; + private static final String DE_LABEL = "DE"; + private static final String FT_LABEL = "FT"; + private static final String SQ_LABEL = "SQ"; + private static final String END_OF_ITEM_LABEL = "XX"; + private static final String END_OF_RECORD_LABEL = "//"; + + private static final String MIRNA_LABEL = "miRNA"; + + private MirBaseParser() { + throw new IllegalStateException("Utility class"); + } + + public static void parse(Path miRnaDatFile, String species, MirBaseParserCallback callback) throws IOException { + try (BufferedReader datReader = new BufferedReader(new InputStreamReader(FileUtils.newInputStream(miRnaDatFile)))) { + String miRBaseAccession = null; + String miRBaseID = null; + MiRnaGene miRnaGene = null; + String line; + while ((line = datReader.readLine()) != null) { + String[] split = line.split("\\s+"); + switch (split[0]) { + case ID_LABEL: { + miRBaseID = split[1]; + break; + } + case AC_LABEL: { + miRBaseAccession = split[1].split(";")[0]; + break; + } + case DE_LABEL: { + if (line.contains(species)) { + miRnaGene = new MiRnaGene(); + miRnaGene.setId(miRBaseID) + .setAccession(miRBaseAccession); + } + break; + } + case FT_LABEL: { + if (miRnaGene != null && MIRNA_LABEL.equalsIgnoreCase(split[1])) { + processMiRnaMature(line, miRnaGene, datReader); + } + break; + } + case SQ_LABEL: { + if (miRnaGene != null) { + StringBuilder seq = new StringBuilder(); + // Read until END_OF_RECORD_LABEL + while (!(line = datReader.readLine()).equals(END_OF_RECORD_LABEL)) { + split = line.split("\\s+"); + for (int i = 1; i < split.length - 1; i++) { + seq.append(split[i]); + } + } + miRnaGene.setSequence(seq.toString()); + + // Update mature sequences + for (MiRnaMature mature : miRnaGene.getMatures()) { + if (mature.getStart() > 0 && mature.getEnd() > 0) { + mature.setSequence(miRnaGene.getSequence().substring(mature.getStart() - 1, mature.getEnd())); + } + } + + // Callback + callback.processMiRnaGene(miRnaGene); + miRnaGene = null; + } + break; + } + default: { + // Do nothing + break; + } + } + } + } + } + + private static void processMiRnaMature(String headerLine, MiRnaGene miRnaGene, BufferedReader datReader) throws IOException { + // Create MiRNA mature from header line, + // e.g: FT miRNA 6..27 + MiRnaMature miRnaMature = new MiRnaMature(); + String[] split = headerLine.split("\\s+"); + String[] pos = split[2].split("\\.\\."); + miRnaMature.setStart(Integer.parseInt(pos[0])); + miRnaMature.setEnd(Integer.parseInt(pos[1])); + + String line; + while (!(line = datReader.readLine()).equals(END_OF_ITEM_LABEL)) { + split = line.split("\\s+"); + if (split[0].equalsIgnoreCase(FT_LABEL) && split[1].equalsIgnoreCase(MIRNA_LABEL)) { + processMiRnaMature(line, miRnaGene, datReader); + break; + } else { + if (line.contains("accession=")) { + miRnaMature.setAccession(line.split("accession=")[1].replace("\"", "")); + } else if (line.contains("product=")) { + miRnaMature.setId(line.split("product=")[1].replace("\"", "")); + } + } + } + miRnaGene.getMatures().add(miRnaMature); + } +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/mirbase/MirBaseParserCallback.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/mirbase/MirBaseParserCallback.java new file mode 100644 index 000000000..3909d0075 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/feature/mirbase/MirBaseParserCallback.java @@ -0,0 +1,7 @@ +package org.opencb.biodata.formats.feature.mirbase; + +import org.opencb.biodata.models.core.MiRnaGene; + +public interface MirBaseParserCallback { + boolean processMiRnaGene(MiRnaGene miRnaGene); +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/UniProtParser.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/UniProtParser.java index 33bd105b2..09f8046c3 100644 --- a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/UniProtParser.java +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/UniProtParser.java @@ -29,40 +29,29 @@ */ public class UniProtParser { - public final static String UNIPROT_CONTEXT = "org.opencb.biodata.formats.protein.uniprot.v202003jaxb"; + public final static String UNIPROT_202003_CONTEXT = "org.opencb.biodata.formats.protein.uniprot.v202003jaxb"; + public final static String UNIPROT_202502_CONTEXT = "org.opencb.biodata.formats.protein.uniprot.v202502jaxb"; + public final static String UNIPROT_LATEST_CONTEXT = UNIPROT_202502_CONTEXT; + @Deprecated public static void saveXMLInfo(Object obj, String filename) throws FileNotFoundException, JAXBException { + saveXMLInfo(obj, UNIPROT_LATEST_CONTEXT, filename); + } + + public static void saveXMLInfo(Object obj, String uniprotContext, String filename) throws FileNotFoundException, JAXBException { JAXBContext jaxbContext; - jaxbContext = JAXBContext.newInstance(UNIPROT_CONTEXT); + jaxbContext = JAXBContext.newInstance(uniprotContext); Marshaller marshaller = jaxbContext.createMarshaller(); marshaller.marshal(obj, new FileOutputStream(filename)); } - /** - * Checks if XML info path exists and loads it - * - * @throws javax.xml.bind.JAXBException - * @throws java.io.IOException - */ public static Object loadXMLInfo(String filename) throws JAXBException { - Object obj = null; - JAXBContext jaxbContext = JAXBContext.newInstance(UNIPROT_CONTEXT); - Unmarshaller unmarshaller = jaxbContext.createUnmarshaller(); - obj = unmarshaller.unmarshal(new File(filename)); - return obj; + return loadXMLInfo(filename, UNIPROT_LATEST_CONTEXT); } - /** - * Checks if XML info path exists and loads it - * - * @throws javax.xml.bind.JAXBException - * @throws java.io.IOException - */ - public static Object loadXMLInfo(String filename, String uniprotVersion) throws JAXBException { - Object obj = null; - JAXBContext jaxbContext = JAXBContext.newInstance(uniprotVersion); + public static Object loadXMLInfo(String filename, String uniprotContext) throws JAXBException { + JAXBContext jaxbContext = JAXBContext.newInstance(uniprotContext); Unmarshaller unmarshaller = jaxbContext.createUnmarshaller(); - obj = unmarshaller.unmarshal(new File(filename)); - return obj; + return unmarshaller.unmarshal(new File(filename)); } } diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/CitationType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/CitationType.java new file mode 100644 index 000000000..0e9f2a110 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/CitationType.java @@ -0,0 +1,527 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes different types of citations. + * Equivalent to the flat file RX-, RG-, RA-, RT- and RL-lines. + * + *

Java class for citationType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="citationType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="title" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ *         <element name="editorList" type="{https://uniprot.org/uniprot}nameListType" minOccurs="0"/>
+ *         <element name="authorList" type="{https://uniprot.org/uniprot}nameListType" minOccurs="0"/>
+ *         <element name="locator" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ *         <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType" maxOccurs="unbounded" minOccurs="0"/>
+ *       </sequence>
+ *       <attribute name="type" use="required">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="book"/>
+ *             <enumeration value="journal article"/>
+ *             <enumeration value="online journal article"/>
+ *             <enumeration value="patent"/>
+ *             <enumeration value="submission"/>
+ *             <enumeration value="thesis"/>
+ *             <enumeration value="unpublished observations"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *       <attribute name="date">
+ *         <simpleType>
+ *           <union memberTypes=" {http://www.w3.org/2001/XMLSchema}date {http://www.w3.org/2001/XMLSchema}gYearMonth {http://www.w3.org/2001/XMLSchema}gYear">
+ *           </union>
+ *         </simpleType>
+ *       </attribute>
+ *       <attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="volume" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="first" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="last" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="publisher" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="city" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="db" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="number" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="institute" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="country" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "citationType", propOrder = { + "title", + "editorList", + "authorList", + "locator", + "dbReference" +}) +public class CitationType { + + protected String title; + protected NameListType editorList; + protected NameListType authorList; + protected String locator; + protected List dbReference; + @XmlAttribute(name = "type", required = true) + protected String type; + @XmlAttribute(name = "date") + protected String date; + @XmlAttribute(name = "name") + protected String name; + @XmlAttribute(name = "volume") + protected String volume; + @XmlAttribute(name = "first") + protected String first; + @XmlAttribute(name = "last") + protected String last; + @XmlAttribute(name = "publisher") + protected String publisher; + @XmlAttribute(name = "city") + protected String city; + @XmlAttribute(name = "db") + protected String db; + @XmlAttribute(name = "number") + protected String number; + @XmlAttribute(name = "institute") + protected String institute; + @XmlAttribute(name = "country") + protected String country; + + /** + * Gets the value of the title property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getTitle() { + return title; + } + + /** + * Sets the value of the title property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setTitle(String value) { + this.title = value; + } + + /** + * Gets the value of the editorList property. + * + * @return + * possible object is + * {@link NameListType } + * + */ + public NameListType getEditorList() { + return editorList; + } + + /** + * Sets the value of the editorList property. + * + * @param value + * allowed object is + * {@link NameListType } + * + */ + public void setEditorList(NameListType value) { + this.editorList = value; + } + + /** + * Gets the value of the authorList property. + * + * @return + * possible object is + * {@link NameListType } + * + */ + public NameListType getAuthorList() { + return authorList; + } + + /** + * Sets the value of the authorList property. + * + * @param value + * allowed object is + * {@link NameListType } + * + */ + public void setAuthorList(NameListType value) { + this.authorList = value; + } + + /** + * Gets the value of the locator property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getLocator() { + return locator; + } + + /** + * Sets the value of the locator property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setLocator(String value) { + this.locator = value; + } + + /** + * Gets the value of the dbReference property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the dbReference property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getDbReference().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link DbReferenceType } + * + * + */ + public List getDbReference() { + if (dbReference == null) { + dbReference = new ArrayList(); + } + return this.dbReference; + } + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + + /** + * Gets the value of the date property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getDate() { + return date; + } + + /** + * Sets the value of the date property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setDate(String value) { + this.date = value; + } + + /** + * Gets the value of the name property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getName() { + return name; + } + + /** + * Sets the value of the name property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setName(String value) { + this.name = value; + } + + /** + * Gets the value of the volume property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getVolume() { + return volume; + } + + /** + * Sets the value of the volume property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setVolume(String value) { + this.volume = value; + } + + /** + * Gets the value of the first property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getFirst() { + return first; + } + + /** + * Sets the value of the first property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setFirst(String value) { + this.first = value; + } + + /** + * Gets the value of the last property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getLast() { + return last; + } + + /** + * Sets the value of the last property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setLast(String value) { + this.last = value; + } + + /** + * Gets the value of the publisher property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getPublisher() { + return publisher; + } + + /** + * Sets the value of the publisher property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setPublisher(String value) { + this.publisher = value; + } + + /** + * Gets the value of the city property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getCity() { + return city; + } + + /** + * Sets the value of the city property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setCity(String value) { + this.city = value; + } + + /** + * Gets the value of the db property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getDb() { + return db; + } + + /** + * Sets the value of the db property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setDb(String value) { + this.db = value; + } + + /** + * Gets the value of the number property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getNumber() { + return number; + } + + /** + * Sets the value of the number property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setNumber(String value) { + this.number = value; + } + + /** + * Gets the value of the institute property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getInstitute() { + return institute; + } + + /** + * Sets the value of the institute property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setInstitute(String value) { + this.institute = value; + } + + /** + * Gets the value of the country property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getCountry() { + return country; + } + + /** + * Sets the value of the country property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setCountry(String value) { + this.country = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/CofactorType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/CofactorType.java new file mode 100644 index 000000000..66c7d8c3b --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/CofactorType.java @@ -0,0 +1,134 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes a cofactor. + * + *

Java class for cofactorType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="cofactorType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="name" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ *         <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType"/>
+ *       </sequence>
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "cofactorType", propOrder = { + "name", + "dbReference" +}) +public class CofactorType { + + @XmlElement(required = true) + protected String name; + @XmlElement(required = true) + protected DbReferenceType dbReference; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the name property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getName() { + return name; + } + + /** + * Sets the value of the name property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setName(String value) { + this.name = value; + } + + /** + * Gets the value of the dbReference property. + * + * @return + * possible object is + * {@link DbReferenceType } + * + */ + public DbReferenceType getDbReference() { + return dbReference; + } + + /** + * Sets the value of the dbReference property. + * + * @param value + * allowed object is + * {@link DbReferenceType } + * + */ + public void setDbReference(DbReferenceType value) { + this.dbReference = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/CommentType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/CommentType.java new file mode 100644 index 000000000..1343c2ffc --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/CommentType.java @@ -0,0 +1,1791 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlSchemaType; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes different types of general annotations. + * Equivalent to the flat file CC-line. + * + *

Java class for commentType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="commentType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="molecule" type="{https://uniprot.org/uniprot}moleculeType" minOccurs="0"/>
+ *         <choice minOccurs="0">
+ *           <group ref="{https://uniprot.org/uniprot}bpcCommentGroup"/>
+ *           <sequence>
+ *             <element name="reaction" type="{https://uniprot.org/uniprot}reactionType"/>
+ *             <element name="physiologicalReaction" type="{https://uniprot.org/uniprot}physiologicalReactionType" maxOccurs="2" minOccurs="0"/>
+ *           </sequence>
+ *           <sequence>
+ *             <element name="cofactor" type="{https://uniprot.org/uniprot}cofactorType" maxOccurs="unbounded"/>
+ *           </sequence>
+ *           <sequence>
+ *             <element name="subcellularLocation" type="{https://uniprot.org/uniprot}subcellularLocationType" maxOccurs="unbounded"/>
+ *           </sequence>
+ *           <element name="conflict">
+ *             <complexType>
+ *               <complexContent>
+ *                 <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *                   <sequence>
+ *                     <element name="sequence" minOccurs="0">
+ *                       <complexType>
+ *                         <complexContent>
+ *                           <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *                             <attribute name="resource" use="required">
+ *                               <simpleType>
+ *                                 <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *                                   <enumeration value="EMBL-CDS"/>
+ *                                   <enumeration value="EMBL"/>
+ *                                 </restriction>
+ *                               </simpleType>
+ *                             </attribute>
+ *                             <attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *                             <attribute name="version" type="{http://www.w3.org/2001/XMLSchema}int" />
+ *                           </restriction>
+ *                         </complexContent>
+ *                       </complexType>
+ *                     </element>
+ *                   </sequence>
+ *                   <attribute name="type" use="required">
+ *                     <simpleType>
+ *                       <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *                         <enumeration value="frameshift"/>
+ *                         <enumeration value="erroneous initiation"/>
+ *                         <enumeration value="erroneous termination"/>
+ *                         <enumeration value="erroneous gene model prediction"/>
+ *                         <enumeration value="erroneous translation"/>
+ *                         <enumeration value="miscellaneous discrepancy"/>
+ *                       </restriction>
+ *                     </simpleType>
+ *                   </attribute>
+ *                   <attribute name="ref" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *                 </restriction>
+ *               </complexContent>
+ *             </complexType>
+ *           </element>
+ *           <sequence>
+ *             <element name="link" maxOccurs="unbounded" minOccurs="0">
+ *               <complexType>
+ *                 <complexContent>
+ *                   <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *                     <attribute name="uri" use="required" type="{http://www.w3.org/2001/XMLSchema}anyURI" />
+ *                   </restriction>
+ *                 </complexContent>
+ *               </complexType>
+ *             </element>
+ *           </sequence>
+ *           <sequence>
+ *             <element name="event" type="{https://uniprot.org/uniprot}eventType" maxOccurs="4"/>
+ *             <element name="isoform" type="{https://uniprot.org/uniprot}isoformType" maxOccurs="unbounded" minOccurs="0"/>
+ *           </sequence>
+ *           <sequence>
+ *             <element name="interactant" type="{https://uniprot.org/uniprot}interactantType" maxOccurs="2" minOccurs="2"/>
+ *             <element name="organismsDiffer" type="{http://www.w3.org/2001/XMLSchema}boolean"/>
+ *             <element name="experiments" type="{http://www.w3.org/2001/XMLSchema}int"/>
+ *           </sequence>
+ *           <element name="disease">
+ *             <complexType>
+ *               <complexContent>
+ *                 <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *                   <sequence>
+ *                     <element name="name" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ *                     <element name="acronym" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ *                     <element name="description" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ *                     <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType"/>
+ *                   </sequence>
+ *                   <attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *                 </restriction>
+ *               </complexContent>
+ *             </complexType>
+ *           </element>
+ *         </choice>
+ *         <element name="location" type="{https://uniprot.org/uniprot}locationType" maxOccurs="unbounded" minOccurs="0"/>
+ *         <element name="text" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+ *       </sequence>
+ *       <attribute name="type" use="required">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="allergen"/>
+ *             <enumeration value="alternative products"/>
+ *             <enumeration value="biotechnology"/>
+ *             <enumeration value="biophysicochemical properties"/>
+ *             <enumeration value="catalytic activity"/>
+ *             <enumeration value="caution"/>
+ *             <enumeration value="cofactor"/>
+ *             <enumeration value="developmental stage"/>
+ *             <enumeration value="disease"/>
+ *             <enumeration value="domain"/>
+ *             <enumeration value="disruption phenotype"/>
+ *             <enumeration value="activity regulation"/>
+ *             <enumeration value="function"/>
+ *             <enumeration value="induction"/>
+ *             <enumeration value="miscellaneous"/>
+ *             <enumeration value="pathway"/>
+ *             <enumeration value="pharmaceutical"/>
+ *             <enumeration value="polymorphism"/>
+ *             <enumeration value="PTM"/>
+ *             <enumeration value="RNA editing"/>
+ *             <enumeration value="similarity"/>
+ *             <enumeration value="subcellular location"/>
+ *             <enumeration value="sequence caution"/>
+ *             <enumeration value="subunit"/>
+ *             <enumeration value="tissue specificity"/>
+ *             <enumeration value="toxic dose"/>
+ *             <enumeration value="online information"/>
+ *             <enumeration value="mass spectrometry"/>
+ *             <enumeration value="interaction"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *       <attribute name="locationType" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="mass" type="{http://www.w3.org/2001/XMLSchema}float" />
+ *       <attribute name="error" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="method" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "commentType", propOrder = { + "molecule", + "absorption", + "kinetics", + "phDependence", + "redoxPotential", + "temperatureDependence", + "reaction", + "physiologicalReaction", + "cofactor", + "subcellularLocation", + "conflict", + "link", + "event", + "isoform", + "interactant", + "organismsDiffer", + "experiments", + "disease", + "location", + "text" +}) +public class CommentType { + + protected MoleculeType molecule; + protected CommentType.Absorption absorption; + protected CommentType.Kinetics kinetics; + protected CommentType.PhDependence phDependence; + protected CommentType.RedoxPotential redoxPotential; + protected CommentType.TemperatureDependence temperatureDependence; + protected ReactionType reaction; + protected List physiologicalReaction; + protected List cofactor; + protected List subcellularLocation; + protected CommentType.Conflict conflict; + protected List link; + protected List event; + protected List isoform; + protected List interactant; + @XmlElement(defaultValue = "false") + protected Boolean organismsDiffer; + protected Integer experiments; + protected CommentType.Disease disease; + protected List location; + protected List text; + @XmlAttribute(name = "type", required = true) + protected String type; + @XmlAttribute(name = "locationType") + protected String locationType; + @XmlAttribute(name = "name") + protected String name; + @XmlAttribute(name = "mass") + protected Float mass; + @XmlAttribute(name = "error") + protected String error; + @XmlAttribute(name = "method") + protected String method; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the molecule property. + * + * @return + * possible object is + * {@link MoleculeType } + * + */ + public MoleculeType getMolecule() { + return molecule; + } + + /** + * Sets the value of the molecule property. + * + * @param value + * allowed object is + * {@link MoleculeType } + * + */ + public void setMolecule(MoleculeType value) { + this.molecule = value; + } + + /** + * Gets the value of the absorption property. + * + * @return + * possible object is + * {@link CommentType.Absorption } + * + */ + public CommentType.Absorption getAbsorption() { + return absorption; + } + + /** + * Sets the value of the absorption property. + * + * @param value + * allowed object is + * {@link CommentType.Absorption } + * + */ + public void setAbsorption(CommentType.Absorption value) { + this.absorption = value; + } + + /** + * Gets the value of the kinetics property. + * + * @return + * possible object is + * {@link CommentType.Kinetics } + * + */ + public CommentType.Kinetics getKinetics() { + return kinetics; + } + + /** + * Sets the value of the kinetics property. + * + * @param value + * allowed object is + * {@link CommentType.Kinetics } + * + */ + public void setKinetics(CommentType.Kinetics value) { + this.kinetics = value; + } + + /** + * Gets the value of the phDependence property. + * + * @return + * possible object is + * {@link CommentType.PhDependence } + * + */ + public CommentType.PhDependence getPhDependence() { + return phDependence; + } + + /** + * Sets the value of the phDependence property. + * + * @param value + * allowed object is + * {@link CommentType.PhDependence } + * + */ + public void setPhDependence(CommentType.PhDependence value) { + this.phDependence = value; + } + + /** + * Gets the value of the redoxPotential property. + * + * @return + * possible object is + * {@link CommentType.RedoxPotential } + * + */ + public CommentType.RedoxPotential getRedoxPotential() { + return redoxPotential; + } + + /** + * Sets the value of the redoxPotential property. + * + * @param value + * allowed object is + * {@link CommentType.RedoxPotential } + * + */ + public void setRedoxPotential(CommentType.RedoxPotential value) { + this.redoxPotential = value; + } + + /** + * Gets the value of the temperatureDependence property. + * + * @return + * possible object is + * {@link CommentType.TemperatureDependence } + * + */ + public CommentType.TemperatureDependence getTemperatureDependence() { + return temperatureDependence; + } + + /** + * Sets the value of the temperatureDependence property. + * + * @param value + * allowed object is + * {@link CommentType.TemperatureDependence } + * + */ + public void setTemperatureDependence(CommentType.TemperatureDependence value) { + this.temperatureDependence = value; + } + + /** + * Gets the value of the reaction property. + * + * @return + * possible object is + * {@link ReactionType } + * + */ + public ReactionType getReaction() { + return reaction; + } + + /** + * Sets the value of the reaction property. + * + * @param value + * allowed object is + * {@link ReactionType } + * + */ + public void setReaction(ReactionType value) { + this.reaction = value; + } + + /** + * Gets the value of the physiologicalReaction property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the physiologicalReaction property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getPhysiologicalReaction().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link PhysiologicalReactionType } + * + * + */ + public List getPhysiologicalReaction() { + if (physiologicalReaction == null) { + physiologicalReaction = new ArrayList(); + } + return this.physiologicalReaction; + } + + /** + * Gets the value of the cofactor property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the cofactor property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getCofactor().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link CofactorType } + * + * + */ + public List getCofactor() { + if (cofactor == null) { + cofactor = new ArrayList(); + } + return this.cofactor; + } + + /** + * Gets the value of the subcellularLocation property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the subcellularLocation property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getSubcellularLocation().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link SubcellularLocationType } + * + * + */ + public List getSubcellularLocation() { + if (subcellularLocation == null) { + subcellularLocation = new ArrayList(); + } + return this.subcellularLocation; + } + + /** + * Gets the value of the conflict property. + * + * @return + * possible object is + * {@link CommentType.Conflict } + * + */ + public CommentType.Conflict getConflict() { + return conflict; + } + + /** + * Sets the value of the conflict property. + * + * @param value + * allowed object is + * {@link CommentType.Conflict } + * + */ + public void setConflict(CommentType.Conflict value) { + this.conflict = value; + } + + /** + * Gets the value of the link property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the link property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getLink().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link CommentType.Link } + * + * + */ + public List getLink() { + if (link == null) { + link = new ArrayList(); + } + return this.link; + } + + /** + * Gets the value of the event property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the event property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvent().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EventType } + * + * + */ + public List getEvent() { + if (event == null) { + event = new ArrayList(); + } + return this.event; + } + + /** + * Gets the value of the isoform property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the isoform property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getIsoform().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link IsoformType } + * + * + */ + public List getIsoform() { + if (isoform == null) { + isoform = new ArrayList(); + } + return this.isoform; + } + + /** + * Gets the value of the interactant property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the interactant property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getInteractant().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link InteractantType } + * + * + */ + public List getInteractant() { + if (interactant == null) { + interactant = new ArrayList(); + } + return this.interactant; + } + + /** + * Gets the value of the organismsDiffer property. + * + * @return + * possible object is + * {@link Boolean } + * + */ + public Boolean isOrganismsDiffer() { + return organismsDiffer; + } + + /** + * Sets the value of the organismsDiffer property. + * + * @param value + * allowed object is + * {@link Boolean } + * + */ + public void setOrganismsDiffer(Boolean value) { + this.organismsDiffer = value; + } + + /** + * Gets the value of the experiments property. + * + * @return + * possible object is + * {@link Integer } + * + */ + public Integer getExperiments() { + return experiments; + } + + /** + * Sets the value of the experiments property. + * + * @param value + * allowed object is + * {@link Integer } + * + */ + public void setExperiments(Integer value) { + this.experiments = value; + } + + /** + * Gets the value of the disease property. + * + * @return + * possible object is + * {@link CommentType.Disease } + * + */ + public CommentType.Disease getDisease() { + return disease; + } + + /** + * Sets the value of the disease property. + * + * @param value + * allowed object is + * {@link CommentType.Disease } + * + */ + public void setDisease(CommentType.Disease value) { + this.disease = value; + } + + /** + * Gets the value of the location property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the location property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getLocation().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link LocationType } + * + * + */ + public List getLocation() { + if (location == null) { + location = new ArrayList(); + } + return this.location; + } + + /** + * Gets the value of the text property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the text property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getText().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getText() { + if (text == null) { + text = new ArrayList(); + } + return this.text; + } + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + + /** + * Gets the value of the locationType property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getLocationType() { + return locationType; + } + + /** + * Sets the value of the locationType property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setLocationType(String value) { + this.locationType = value; + } + + /** + * Gets the value of the name property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getName() { + return name; + } + + /** + * Sets the value of the name property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setName(String value) { + this.name = value; + } + + /** + * Gets the value of the mass property. + * + * @return + * possible object is + * {@link Float } + * + */ + public Float getMass() { + return mass; + } + + /** + * Sets the value of the mass property. + * + * @param value + * allowed object is + * {@link Float } + * + */ + public void setMass(Float value) { + this.mass = value; + } + + /** + * Gets the value of the error property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getError() { + return error; + } + + /** + * Sets the value of the error property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setError(String value) { + this.error = value; + } + + /** + * Gets the value of the method property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getMethod() { + return method; + } + + /** + * Sets the value of the method property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setMethod(String value) { + this.method = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <sequence>
+     *         <element name="max" type="{https://uniprot.org/uniprot}evidencedStringType" minOccurs="0"/>
+     *         <element name="text" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+     *       </sequence>
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "max", + "text" + }) + public static class Absorption { + + protected EvidencedStringType max; + protected List text; + + /** + * Gets the value of the max property. + * + * @return + * possible object is + * {@link EvidencedStringType } + * + */ + public EvidencedStringType getMax() { + return max; + } + + /** + * Sets the value of the max property. + * + * @param value + * allowed object is + * {@link EvidencedStringType } + * + */ + public void setMax(EvidencedStringType value) { + this.max = value; + } + + /** + * Gets the value of the text property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the text property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getText().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getText() { + if (text == null) { + text = new ArrayList(); + } + return this.text; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <sequence>
+     *         <element name="sequence" minOccurs="0">
+     *           <complexType>
+     *             <complexContent>
+     *               <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *                 <attribute name="resource" use="required">
+     *                   <simpleType>
+     *                     <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+     *                       <enumeration value="EMBL-CDS"/>
+     *                       <enumeration value="EMBL"/>
+     *                     </restriction>
+     *                   </simpleType>
+     *                 </attribute>
+     *                 <attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+     *                 <attribute name="version" type="{http://www.w3.org/2001/XMLSchema}int" />
+     *               </restriction>
+     *             </complexContent>
+     *           </complexType>
+     *         </element>
+     *       </sequence>
+     *       <attribute name="type" use="required">
+     *         <simpleType>
+     *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+     *             <enumeration value="frameshift"/>
+     *             <enumeration value="erroneous initiation"/>
+     *             <enumeration value="erroneous termination"/>
+     *             <enumeration value="erroneous gene model prediction"/>
+     *             <enumeration value="erroneous translation"/>
+     *             <enumeration value="miscellaneous discrepancy"/>
+     *           </restriction>
+     *         </simpleType>
+     *       </attribute>
+     *       <attribute name="ref" type="{http://www.w3.org/2001/XMLSchema}string" />
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "sequence" + }) + public static class Conflict { + + protected CommentType.Conflict.Sequence sequence; + @XmlAttribute(name = "type", required = true) + protected String type; + @XmlAttribute(name = "ref") + protected String ref; + + /** + * Gets the value of the sequence property. + * + * @return + * possible object is + * {@link CommentType.Conflict.Sequence } + * + */ + public CommentType.Conflict.Sequence getSequence() { + return sequence; + } + + /** + * Sets the value of the sequence property. + * + * @param value + * allowed object is + * {@link CommentType.Conflict.Sequence } + * + */ + public void setSequence(CommentType.Conflict.Sequence value) { + this.sequence = value; + } + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + + /** + * Gets the value of the ref property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getRef() { + return ref; + } + + /** + * Sets the value of the ref property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setRef(String value) { + this.ref = value; + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+         * <complexType>
+         *   <complexContent>
+         *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+         *       <attribute name="resource" use="required">
+         *         <simpleType>
+         *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+         *             <enumeration value="EMBL-CDS"/>
+         *             <enumeration value="EMBL"/>
+         *           </restriction>
+         *         </simpleType>
+         *       </attribute>
+         *       <attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+         *       <attribute name="version" type="{http://www.w3.org/2001/XMLSchema}int" />
+         *     </restriction>
+         *   </complexContent>
+         * </complexType>
+         * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "") + public static class Sequence { + + @XmlAttribute(name = "resource", required = true) + protected String resource; + @XmlAttribute(name = "id", required = true) + protected String id; + @XmlAttribute(name = "version") + protected Integer version; + + /** + * Gets the value of the resource property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getResource() { + return resource; + } + + /** + * Sets the value of the resource property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setResource(String value) { + this.resource = value; + } + + /** + * Gets the value of the id property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getId() { + return id; + } + + /** + * Sets the value of the id property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setId(String value) { + this.id = value; + } + + /** + * Gets the value of the version property. + * + * @return + * possible object is + * {@link Integer } + * + */ + public Integer getVersion() { + return version; + } + + /** + * Sets the value of the version property. + * + * @param value + * allowed object is + * {@link Integer } + * + */ + public void setVersion(Integer value) { + this.version = value; + } + + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <sequence>
+     *         <element name="name" type="{http://www.w3.org/2001/XMLSchema}string"/>
+     *         <element name="acronym" type="{http://www.w3.org/2001/XMLSchema}string"/>
+     *         <element name="description" type="{http://www.w3.org/2001/XMLSchema}string"/>
+     *         <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType"/>
+     *       </sequence>
+     *       <attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "name", + "acronym", + "description", + "dbReference" + }) + public static class Disease { + + @XmlElement(required = true) + protected String name; + @XmlElement(required = true) + protected String acronym; + @XmlElement(required = true) + protected String description; + @XmlElement(required = true) + protected DbReferenceType dbReference; + @XmlAttribute(name = "id", required = true) + protected String id; + + /** + * Gets the value of the name property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getName() { + return name; + } + + /** + * Sets the value of the name property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setName(String value) { + this.name = value; + } + + /** + * Gets the value of the acronym property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getAcronym() { + return acronym; + } + + /** + * Sets the value of the acronym property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setAcronym(String value) { + this.acronym = value; + } + + /** + * Gets the value of the description property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getDescription() { + return description; + } + + /** + * Sets the value of the description property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setDescription(String value) { + this.description = value; + } + + /** + * Gets the value of the dbReference property. + * + * @return + * possible object is + * {@link DbReferenceType } + * + */ + public DbReferenceType getDbReference() { + return dbReference; + } + + /** + * Sets the value of the dbReference property. + * + * @param value + * allowed object is + * {@link DbReferenceType } + * + */ + public void setDbReference(DbReferenceType value) { + this.dbReference = value; + } + + /** + * Gets the value of the id property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getId() { + return id; + } + + /** + * Sets the value of the id property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setId(String value) { + this.id = value; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <sequence>
+     *         <element name="KM" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+     *         <element name="Vmax" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+     *         <element name="text" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+     *       </sequence>
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "km", + "vmax", + "text" + }) + public static class Kinetics { + + @XmlElement(name = "KM") + protected List km; + @XmlElement(name = "Vmax") + protected List vmax; + protected List text; + + /** + * Gets the value of the km property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the km property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getKM().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getKM() { + if (km == null) { + km = new ArrayList(); + } + return this.km; + } + + /** + * Gets the value of the vmax property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the vmax property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getVmax().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getVmax() { + if (vmax == null) { + vmax = new ArrayList(); + } + return this.vmax; + } + + /** + * Gets the value of the text property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the text property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getText().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getText() { + if (text == null) { + text = new ArrayList(); + } + return this.text; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <attribute name="uri" use="required" type="{http://www.w3.org/2001/XMLSchema}anyURI" />
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "") + public static class Link { + + @XmlAttribute(name = "uri", required = true) + @XmlSchemaType(name = "anyURI") + protected String uri; + + /** + * Gets the value of the uri property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getUri() { + return uri; + } + + /** + * Sets the value of the uri property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setUri(String value) { + this.uri = value; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <sequence>
+     *         <element name="text" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded"/>
+     *       </sequence>
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "text" + }) + public static class PhDependence { + + @XmlElement(required = true) + protected List text; + + /** + * Gets the value of the text property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the text property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getText().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getText() { + if (text == null) { + text = new ArrayList(); + } + return this.text; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <sequence>
+     *         <element name="text" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded"/>
+     *       </sequence>
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "text" + }) + public static class RedoxPotential { + + @XmlElement(required = true) + protected List text; + + /** + * Gets the value of the text property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the text property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getText().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getText() { + if (text == null) { + text = new ArrayList(); + } + return this.text; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <sequence>
+     *         <element name="text" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded"/>
+     *       </sequence>
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "text" + }) + public static class TemperatureDependence { + + @XmlElement(required = true) + protected List text; + + /** + * Gets the value of the text property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the text property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getText().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getText() { + if (text == null) { + text = new ArrayList(); + } + return this.text; + } + + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ConsortiumType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ConsortiumType.java new file mode 100644 index 000000000..35ecd0263 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ConsortiumType.java @@ -0,0 +1,68 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes the authors of a citation when these are represented by a consortium. + * Equivalent to the flat file RG-line. + * + *

Java class for consortiumType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="consortiumType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "consortiumType") +public class ConsortiumType { + + @XmlAttribute(name = "name", required = true) + protected String name; + + /** + * Gets the value of the name property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getName() { + return name; + } + + /** + * Sets the value of the name property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setName(String value) { + this.name = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/DbReferenceType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/DbReferenceType.java new file mode 100644 index 000000000..1e3af9f21 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/DbReferenceType.java @@ -0,0 +1,192 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes a database cross-reference. + * Equivalent to the flat file DR-line. + * + * + *

Java class for dbReferenceType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="dbReferenceType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="molecule" type="{https://uniprot.org/uniprot}moleculeType" minOccurs="0"/>
+ *         <element name="property" type="{https://uniprot.org/uniprot}propertyType" maxOccurs="unbounded" minOccurs="0"/>
+ *       </sequence>
+ *       <attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "dbReferenceType", propOrder = { + "molecule", + "property" +}) +public class DbReferenceType { + + protected MoleculeType molecule; + protected List property; + @XmlAttribute(name = "type", required = true) + protected String type; + @XmlAttribute(name = "id", required = true) + protected String id; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the molecule property. + * + * @return + * possible object is + * {@link MoleculeType } + * + */ + public MoleculeType getMolecule() { + return molecule; + } + + /** + * Sets the value of the molecule property. + * + * @param value + * allowed object is + * {@link MoleculeType } + * + */ + public void setMolecule(MoleculeType value) { + this.molecule = value; + } + + /** + * Gets the value of the property property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the property property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getProperty().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link PropertyType } + * + * + */ + public List getProperty() { + if (property == null) { + property = new ArrayList(); + } + return this.property; + } + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + + /** + * Gets the value of the id property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getId() { + return id; + } + + /** + * Sets the value of the id property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setId(String value) { + this.id = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/Entry.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/Entry.java new file mode 100644 index 000000000..c23368b2c --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/Entry.java @@ -0,0 +1,625 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlSchemaType; +import javax.xml.bind.annotation.XmlType; +import javax.xml.datatype.XMLGregorianCalendar; + + +/** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType>
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="accession" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded"/>
+ *         <element name="name" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded"/>
+ *         <element name="protein" type="{https://uniprot.org/uniprot}proteinType"/>
+ *         <element name="gene" type="{https://uniprot.org/uniprot}geneType" maxOccurs="unbounded" minOccurs="0"/>
+ *         <element name="organism" type="{https://uniprot.org/uniprot}organismType"/>
+ *         <element name="organismHost" type="{https://uniprot.org/uniprot}organismType" maxOccurs="unbounded" minOccurs="0"/>
+ *         <element name="geneLocation" type="{https://uniprot.org/uniprot}geneLocationType" maxOccurs="unbounded" minOccurs="0"/>
+ *         <element name="reference" type="{https://uniprot.org/uniprot}referenceType" maxOccurs="unbounded"/>
+ *         <element name="comment" type="{https://uniprot.org/uniprot}commentType" maxOccurs="unbounded" minOccurs="0"/>
+ *         <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType" maxOccurs="unbounded" minOccurs="0"/>
+ *         <element name="proteinExistence" type="{https://uniprot.org/uniprot}proteinExistenceType"/>
+ *         <element name="keyword" type="{https://uniprot.org/uniprot}keywordType" maxOccurs="unbounded" minOccurs="0"/>
+ *         <element name="feature" type="{https://uniprot.org/uniprot}featureType" maxOccurs="unbounded" minOccurs="0"/>
+ *         <element name="evidence" type="{https://uniprot.org/uniprot}evidenceType" maxOccurs="unbounded" minOccurs="0"/>
+ *         <element name="sequence" type="{https://uniprot.org/uniprot}sequenceType"/>
+ *       </sequence>
+ *       <attribute name="dataset" use="required">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="Swiss-Prot"/>
+ *             <enumeration value="TrEMBL"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *       <attribute name="created" use="required" type="{http://www.w3.org/2001/XMLSchema}date" />
+ *       <attribute name="modified" use="required" type="{http://www.w3.org/2001/XMLSchema}date" />
+ *       <attribute name="version" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "", propOrder = { + "accession", + "name", + "protein", + "gene", + "organism", + "organismHost", + "geneLocation", + "reference", + "comment", + "dbReference", + "proteinExistence", + "keyword", + "feature", + "evidence", + "sequence" +}) +@XmlRootElement(name = "entry") +public class Entry { + + @XmlElement(required = true) + protected List accession; + @XmlElement(required = true) + protected List name; + @XmlElement(required = true) + protected ProteinType protein; + protected List gene; + @XmlElement(required = true) + protected OrganismType organism; + protected List organismHost; + protected List geneLocation; + @XmlElement(required = true) + protected List reference; + @XmlElement(nillable = true) + protected List comment; + protected List dbReference; + @XmlElement(required = true) + protected ProteinExistenceType proteinExistence; + protected List keyword; + protected List feature; + protected List evidence; + @XmlElement(required = true) + protected SequenceType sequence; + @XmlAttribute(name = "dataset", required = true) + protected String dataset; + @XmlAttribute(name = "created", required = true) + @XmlSchemaType(name = "date") + protected XMLGregorianCalendar created; + @XmlAttribute(name = "modified", required = true) + @XmlSchemaType(name = "date") + protected XMLGregorianCalendar modified; + @XmlAttribute(name = "version", required = true) + protected int version; + + /** + * Gets the value of the accession property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the accession property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getAccession().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link String } + * + * + */ + public List getAccession() { + if (accession == null) { + accession = new ArrayList(); + } + return this.accession; + } + + /** + * Gets the value of the name property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the name property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getName().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link String } + * + * + */ + public List getName() { + if (name == null) { + name = new ArrayList(); + } + return this.name; + } + + /** + * Gets the value of the protein property. + * + * @return + * possible object is + * {@link ProteinType } + * + */ + public ProteinType getProtein() { + return protein; + } + + /** + * Sets the value of the protein property. + * + * @param value + * allowed object is + * {@link ProteinType } + * + */ + public void setProtein(ProteinType value) { + this.protein = value; + } + + /** + * Gets the value of the gene property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the gene property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getGene().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link GeneType } + * + * + */ + public List getGene() { + if (gene == null) { + gene = new ArrayList(); + } + return this.gene; + } + + /** + * Gets the value of the organism property. + * + * @return + * possible object is + * {@link OrganismType } + * + */ + public OrganismType getOrganism() { + return organism; + } + + /** + * Sets the value of the organism property. + * + * @param value + * allowed object is + * {@link OrganismType } + * + */ + public void setOrganism(OrganismType value) { + this.organism = value; + } + + /** + * Gets the value of the organismHost property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the organismHost property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getOrganismHost().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link OrganismType } + * + * + */ + public List getOrganismHost() { + if (organismHost == null) { + organismHost = new ArrayList(); + } + return this.organismHost; + } + + /** + * Gets the value of the geneLocation property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the geneLocation property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getGeneLocation().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link GeneLocationType } + * + * + */ + public List getGeneLocation() { + if (geneLocation == null) { + geneLocation = new ArrayList(); + } + return this.geneLocation; + } + + /** + * Gets the value of the reference property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the reference property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getReference().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link ReferenceType } + * + * + */ + public List getReference() { + if (reference == null) { + reference = new ArrayList(); + } + return this.reference; + } + + /** + * Gets the value of the comment property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the comment property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getComment().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link CommentType } + * + * + */ + public List getComment() { + if (comment == null) { + comment = new ArrayList(); + } + return this.comment; + } + + /** + * Gets the value of the dbReference property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the dbReference property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getDbReference().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link DbReferenceType } + * + * + */ + public List getDbReference() { + if (dbReference == null) { + dbReference = new ArrayList(); + } + return this.dbReference; + } + + /** + * Gets the value of the proteinExistence property. + * + * @return + * possible object is + * {@link ProteinExistenceType } + * + */ + public ProteinExistenceType getProteinExistence() { + return proteinExistence; + } + + /** + * Sets the value of the proteinExistence property. + * + * @param value + * allowed object is + * {@link ProteinExistenceType } + * + */ + public void setProteinExistence(ProteinExistenceType value) { + this.proteinExistence = value; + } + + /** + * Gets the value of the keyword property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the keyword property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getKeyword().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link KeywordType } + * + * + */ + public List getKeyword() { + if (keyword == null) { + keyword = new ArrayList(); + } + return this.keyword; + } + + /** + * Gets the value of the feature property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the feature property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getFeature().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link FeatureType } + * + * + */ + public List getFeature() { + if (feature == null) { + feature = new ArrayList(); + } + return this.feature; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidenceType } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + /** + * Gets the value of the sequence property. + * + * @return + * possible object is + * {@link SequenceType } + * + */ + public SequenceType getSequence() { + return sequence; + } + + /** + * Sets the value of the sequence property. + * + * @param value + * allowed object is + * {@link SequenceType } + * + */ + public void setSequence(SequenceType value) { + this.sequence = value; + } + + /** + * Gets the value of the dataset property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getDataset() { + return dataset; + } + + /** + * Sets the value of the dataset property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setDataset(String value) { + this.dataset = value; + } + + /** + * Gets the value of the created property. + * + * @return + * possible object is + * {@link XMLGregorianCalendar } + * + */ + public XMLGregorianCalendar getCreated() { + return created; + } + + /** + * Sets the value of the created property. + * + * @param value + * allowed object is + * {@link XMLGregorianCalendar } + * + */ + public void setCreated(XMLGregorianCalendar value) { + this.created = value; + } + + /** + * Gets the value of the modified property. + * + * @return + * possible object is + * {@link XMLGregorianCalendar } + * + */ + public XMLGregorianCalendar getModified() { + return modified; + } + + /** + * Sets the value of the modified property. + * + * @param value + * allowed object is + * {@link XMLGregorianCalendar } + * + */ + public void setModified(XMLGregorianCalendar value) { + this.modified = value; + } + + /** + * Gets the value of the version property. + * + */ + public int getVersion() { + return version; + } + + /** + * Sets the value of the version property. + * + */ + public void setVersion(int value) { + this.version = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/EventType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/EventType.java new file mode 100644 index 000000000..6fd460d76 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/EventType.java @@ -0,0 +1,76 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes the type of events that cause alternative products. + * + *

Java class for eventType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="eventType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <attribute name="type" use="required">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="alternative splicing"/>
+ *             <enumeration value="alternative initiation"/>
+ *             <enumeration value="alternative promoter"/>
+ *             <enumeration value="ribosomal frameshifting"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "eventType") +public class EventType { + + @XmlAttribute(name = "type", required = true) + protected String type; + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/EvidenceType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/EvidenceType.java new file mode 100644 index 000000000..1ab652408 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/EvidenceType.java @@ -0,0 +1,153 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.math.BigInteger; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes the evidence for an annotation. + * No flat file equivalent. + * + *

Java class for evidenceType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="evidenceType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="source" type="{https://uniprot.org/uniprot}sourceType" minOccurs="0"/>
+ *         <element name="importedFrom" type="{https://uniprot.org/uniprot}importedFromType" minOccurs="0"/>
+ *       </sequence>
+ *       <attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="key" use="required" type="{http://www.w3.org/2001/XMLSchema}integer" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "evidenceType", propOrder = { + "source", + "importedFrom" +}) +public class EvidenceType { + + protected SourceType source; + protected ImportedFromType importedFrom; + @XmlAttribute(name = "type", required = true) + protected String type; + @XmlAttribute(name = "key", required = true) + protected BigInteger key; + + /** + * Gets the value of the source property. + * + * @return + * possible object is + * {@link SourceType } + * + */ + public SourceType getSource() { + return source; + } + + /** + * Sets the value of the source property. + * + * @param value + * allowed object is + * {@link SourceType } + * + */ + public void setSource(SourceType value) { + this.source = value; + } + + /** + * Gets the value of the importedFrom property. + * + * @return + * possible object is + * {@link ImportedFromType } + * + */ + public ImportedFromType getImportedFrom() { + return importedFrom; + } + + /** + * Sets the value of the importedFrom property. + * + * @param value + * allowed object is + * {@link ImportedFromType } + * + */ + public void setImportedFrom(ImportedFromType value) { + this.importedFrom = value; + } + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + + /** + * Gets the value of the key property. + * + * @return + * possible object is + * {@link BigInteger } + * + */ + public BigInteger getKey() { + return key; + } + + /** + * Sets the value of the key property. + * + * @param value + * allowed object is + * {@link BigInteger } + * + */ + public void setKey(BigInteger value) { + this.key = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/EvidencedStringType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/EvidencedStringType.java new file mode 100644 index 000000000..17f372bbe --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/EvidencedStringType.java @@ -0,0 +1,101 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; +import javax.xml.bind.annotation.XmlValue; + + +/** + *

Java class for evidencedStringType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="evidencedStringType">
+ *   <simpleContent>
+ *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *     </extension>
+ *   </simpleContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "evidencedStringType", propOrder = { + "value" +}) +public class EvidencedStringType { + + @XmlValue + protected String value; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/FeatureType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/FeatureType.java new file mode 100644 index 000000000..75572a6ec --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/FeatureType.java @@ -0,0 +1,369 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes different types of sequence annotations. + * Equivalent to the flat file FT-line. + * + *

Java class for featureType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="featureType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="original" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ *         <element name="variation" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/>
+ *         <element name="location" type="{https://uniprot.org/uniprot}locationType"/>
+ *         <element name="ligand" type="{https://uniprot.org/uniprot}ligandType" minOccurs="0"/>
+ *         <element name="ligandPart" type="{https://uniprot.org/uniprot}ligandPartType" minOccurs="0"/>
+ *       </sequence>
+ *       <attribute name="type" use="required">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="active site"/>
+ *             <enumeration value="binding site"/>
+ *             <enumeration value="chain"/>
+ *             <enumeration value="coiled-coil region"/>
+ *             <enumeration value="compositionally biased region"/>
+ *             <enumeration value="cross-link"/>
+ *             <enumeration value="disulfide bond"/>
+ *             <enumeration value="DNA-binding region"/>
+ *             <enumeration value="domain"/>
+ *             <enumeration value="glycosylation site"/>
+ *             <enumeration value="helix"/>
+ *             <enumeration value="initiator methionine"/>
+ *             <enumeration value="lipid moiety-binding region"/>
+ *             <enumeration value="modified residue"/>
+ *             <enumeration value="mutagenesis site"/>
+ *             <enumeration value="non-consecutive residues"/>
+ *             <enumeration value="non-terminal residue"/>
+ *             <enumeration value="peptide"/>
+ *             <enumeration value="propeptide"/>
+ *             <enumeration value="region of interest"/>
+ *             <enumeration value="repeat"/>
+ *             <enumeration value="non-standard amino acid"/>
+ *             <enumeration value="sequence conflict"/>
+ *             <enumeration value="sequence variant"/>
+ *             <enumeration value="short sequence motif"/>
+ *             <enumeration value="signal peptide"/>
+ *             <enumeration value="site"/>
+ *             <enumeration value="splice variant"/>
+ *             <enumeration value="strand"/>
+ *             <enumeration value="topological domain"/>
+ *             <enumeration value="transit peptide"/>
+ *             <enumeration value="transmembrane region"/>
+ *             <enumeration value="turn"/>
+ *             <enumeration value="unsure residue"/>
+ *             <enumeration value="zinc finger region"/>
+ *             <enumeration value="intramembrane region"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *       <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *       <attribute name="ref" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "featureType", propOrder = { + "original", + "variation", + "location", + "ligand", + "ligandPart" +}) +public class FeatureType { + + protected String original; + protected List variation; + @XmlElement(required = true) + protected LocationType location; + protected LigandType ligand; + protected LigandPartType ligandPart; + @XmlAttribute(name = "type", required = true) + protected String type; + @XmlAttribute(name = "id") + protected String id; + @XmlAttribute(name = "description") + protected String description; + @XmlAttribute(name = "evidence") + protected List evidence; + @XmlAttribute(name = "ref") + protected String ref; + + /** + * Gets the value of the original property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getOriginal() { + return original; + } + + /** + * Sets the value of the original property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setOriginal(String value) { + this.original = value; + } + + /** + * Gets the value of the variation property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the variation property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getVariation().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link String } + * + * + */ + public List getVariation() { + if (variation == null) { + variation = new ArrayList(); + } + return this.variation; + } + + /** + * Gets the value of the location property. + * + * @return + * possible object is + * {@link LocationType } + * + */ + public LocationType getLocation() { + return location; + } + + /** + * Sets the value of the location property. + * + * @param value + * allowed object is + * {@link LocationType } + * + */ + public void setLocation(LocationType value) { + this.location = value; + } + + /** + * Gets the value of the ligand property. + * + * @return + * possible object is + * {@link LigandType } + * + */ + public LigandType getLigand() { + return ligand; + } + + /** + * Sets the value of the ligand property. + * + * @param value + * allowed object is + * {@link LigandType } + * + */ + public void setLigand(LigandType value) { + this.ligand = value; + } + + /** + * Gets the value of the ligandPart property. + * + * @return + * possible object is + * {@link LigandPartType } + * + */ + public LigandPartType getLigandPart() { + return ligandPart; + } + + /** + * Sets the value of the ligandPart property. + * + * @param value + * allowed object is + * {@link LigandPartType } + * + */ + public void setLigandPart(LigandPartType value) { + this.ligandPart = value; + } + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + + /** + * Gets the value of the id property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getId() { + return id; + } + + /** + * Sets the value of the id property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setId(String value) { + this.id = value; + } + + /** + * Gets the value of the description property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getDescription() { + return description; + } + + /** + * Sets the value of the description property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setDescription(String value) { + this.description = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + /** + * Gets the value of the ref property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getRef() { + return ref; + } + + /** + * Sets the value of the ref property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setRef(String value) { + this.ref = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/GeneLocationType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/GeneLocationType.java new file mode 100644 index 000000000..5d0f4cc62 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/GeneLocationType.java @@ -0,0 +1,152 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes non-nuclear gene locations (organelles and plasmids). + * Equivalent to the flat file OG-line. + * + *

Java class for geneLocationType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="geneLocationType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="name" type="{https://uniprot.org/uniprot}statusType" maxOccurs="unbounded" minOccurs="0"/>
+ *       </sequence>
+ *       <attribute name="type" use="required">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="apicoplast"/>
+ *             <enumeration value="chloroplast"/>
+ *             <enumeration value="organellar chromatophore"/>
+ *             <enumeration value="cyanelle"/>
+ *             <enumeration value="hydrogenosome"/>
+ *             <enumeration value="mitochondrion"/>
+ *             <enumeration value="non-photosynthetic plastid"/>
+ *             <enumeration value="nucleomorph"/>
+ *             <enumeration value="plasmid"/>
+ *             <enumeration value="plastid"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "geneLocationType", propOrder = { + "name" +}) +public class GeneLocationType { + + protected List name; + @XmlAttribute(name = "type", required = true) + protected String type; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the name property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the name property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getName().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link StatusType } + * + * + */ + public List getName() { + if (name == null) { + name = new ArrayList(); + } + return this.name; + } + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/GeneNameType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/GeneNameType.java new file mode 100644 index 000000000..6a93d9e72 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/GeneNameType.java @@ -0,0 +1,140 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; +import javax.xml.bind.annotation.XmlValue; + + +/** + * Describes different types of gene designations. + * Equivalent to the flat file GN-line. + * + *

Java class for geneNameType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="geneNameType">
+ *   <simpleContent>
+ *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *       <attribute name="type" use="required">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="primary"/>
+ *             <enumeration value="synonym"/>
+ *             <enumeration value="ordered locus"/>
+ *             <enumeration value="ORF"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *     </extension>
+ *   </simpleContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "geneNameType", propOrder = { + "value" +}) +public class GeneNameType { + + @XmlValue + protected String value; + @XmlAttribute(name = "evidence") + protected List evidence; + @XmlAttribute(name = "type", required = true) + protected String type; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/GeneType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/GeneType.java new file mode 100644 index 000000000..da9c58d46 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/GeneType.java @@ -0,0 +1,79 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes a gene. + * Equivalent to the flat file GN-line. + * + *

Java class for geneType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="geneType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="name" type="{https://uniprot.org/uniprot}geneNameType" maxOccurs="unbounded"/>
+ *       </sequence>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "geneType", propOrder = { + "name" +}) +public class GeneType { + + @XmlElement(required = true) + protected List name; + + /** + * Gets the value of the name property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the name property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getName().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link GeneNameType } + * + * + */ + public List getName() { + if (name == null) { + name = new ArrayList(); + } + return this.name; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ImportedFromType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ImportedFromType.java new file mode 100644 index 000000000..4fc9b1eff --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ImportedFromType.java @@ -0,0 +1,71 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes the source of the evidence, when it is not assigned by UniProt, but imported from an external database. + * + *

Java class for importedFromType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="importedFromType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType"/>
+ *       </sequence>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "importedFromType", propOrder = { + "dbReference" +}) +public class ImportedFromType { + + @XmlElement(required = true) + protected DbReferenceType dbReference; + + /** + * Gets the value of the dbReference property. + * + * @return + * possible object is + * {@link DbReferenceType } + * + */ + public DbReferenceType getDbReference() { + return dbReference; + } + + /** + * Sets the value of the dbReference property. + * + * @param value + * allowed object is + * {@link DbReferenceType } + * + */ + public void setDbReference(DbReferenceType value) { + this.dbReference = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/InteractantType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/InteractantType.java new file mode 100644 index 000000000..8cbcb12dd --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/InteractantType.java @@ -0,0 +1,145 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + *

Java class for interactantType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="interactantType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <group ref="{https://uniprot.org/uniprot}interactantGroup" minOccurs="0"/>
+ *       <attribute name="intactId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "interactantType", propOrder = { + "id", + "label", + "dbReference" +}) +public class InteractantType { + + protected String id; + protected String label; + protected DbReferenceType dbReference; + @XmlAttribute(name = "intactId", required = true) + protected String intactId; + + /** + * Gets the value of the id property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getId() { + return id; + } + + /** + * Sets the value of the id property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setId(String value) { + this.id = value; + } + + /** + * Gets the value of the label property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getLabel() { + return label; + } + + /** + * Sets the value of the label property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setLabel(String value) { + this.label = value; + } + + /** + * Gets the value of the dbReference property. + * + * @return + * possible object is + * {@link DbReferenceType } + * + */ + public DbReferenceType getDbReference() { + return dbReference; + } + + /** + * Sets the value of the dbReference property. + * + * @param value + * allowed object is + * {@link DbReferenceType } + * + */ + public void setDbReference(DbReferenceType value) { + this.dbReference = value; + } + + /** + * Gets the value of the intactId property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getIntactId() { + return intactId; + } + + /** + * Sets the value of the intactId property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setIntactId(String value) { + this.intactId = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/IsoformType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/IsoformType.java new file mode 100644 index 000000000..cae4da7b6 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/IsoformType.java @@ -0,0 +1,370 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; +import javax.xml.bind.annotation.XmlValue; + + +/** + * Describes isoforms in 'alternative products' annotations. + * + *

Java class for isoformType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="isoformType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="id" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded"/>
+ *         <element name="name" maxOccurs="unbounded">
+ *           <complexType>
+ *             <simpleContent>
+ *               <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *                 <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *               </extension>
+ *             </simpleContent>
+ *           </complexType>
+ *         </element>
+ *         <element name="sequence">
+ *           <complexType>
+ *             <complexContent>
+ *               <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *                 <attribute name="type" use="required">
+ *                   <simpleType>
+ *                     <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *                       <enumeration value="not described"/>
+ *                       <enumeration value="described"/>
+ *                       <enumeration value="displayed"/>
+ *                       <enumeration value="external"/>
+ *                     </restriction>
+ *                   </simpleType>
+ *                 </attribute>
+ *                 <attribute name="ref" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *               </restriction>
+ *             </complexContent>
+ *           </complexType>
+ *         </element>
+ *         <element name="text" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+ *       </sequence>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "isoformType", propOrder = { + "id", + "name", + "sequence", + "text" +}) +public class IsoformType { + + @XmlElement(required = true) + protected List id; + @XmlElement(required = true) + protected List name; + @XmlElement(required = true) + protected IsoformType.Sequence sequence; + protected List text; + + /** + * Gets the value of the id property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the id property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getId().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link String } + * + * + */ + public List getId() { + if (id == null) { + id = new ArrayList(); + } + return this.id; + } + + /** + * Gets the value of the name property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the name property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getName().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link IsoformType.Name } + * + * + */ + public List getName() { + if (name == null) { + name = new ArrayList(); + } + return this.name; + } + + /** + * Gets the value of the sequence property. + * + * @return + * possible object is + * {@link IsoformType.Sequence } + * + */ + public IsoformType.Sequence getSequence() { + return sequence; + } + + /** + * Sets the value of the sequence property. + * + * @param value + * allowed object is + * {@link IsoformType.Sequence } + * + */ + public void setSequence(IsoformType.Sequence value) { + this.sequence = value; + } + + /** + * Gets the value of the text property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the text property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getText().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getText() { + if (text == null) { + text = new ArrayList(); + } + return this.text; + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <simpleContent>
+     *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+     *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+     *     </extension>
+     *   </simpleContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "value" + }) + public static class Name { + + @XmlValue + protected String value; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getEvidence().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <attribute name="type" use="required">
+     *         <simpleType>
+     *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+     *             <enumeration value="not described"/>
+     *             <enumeration value="described"/>
+     *             <enumeration value="displayed"/>
+     *             <enumeration value="external"/>
+     *           </restriction>
+     *         </simpleType>
+     *       </attribute>
+     *       <attribute name="ref" type="{http://www.w3.org/2001/XMLSchema}string" />
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "") + public static class Sequence { + + @XmlAttribute(name = "type", required = true) + protected String type; + @XmlAttribute(name = "ref") + protected String ref; + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + + /** + * Gets the value of the ref property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getRef() { + return ref; + } + + /** + * Sets the value of the ref property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setRef(String value) { + this.ref = value; + } + + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/KeywordType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/KeywordType.java new file mode 100644 index 000000000..d2b47f9d8 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/KeywordType.java @@ -0,0 +1,128 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; +import javax.xml.bind.annotation.XmlValue; + + +/** + *

Java class for keywordType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="keywordType">
+ *   <simpleContent>
+ *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *       <attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     </extension>
+ *   </simpleContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "keywordType", propOrder = { + "value" +}) +public class KeywordType { + + @XmlValue + protected String value; + @XmlAttribute(name = "evidence") + protected List evidence; + @XmlAttribute(name = "id", required = true) + protected String id; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + /** + * Gets the value of the id property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getId() { + return id; + } + + /** + * Sets the value of the id property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setId(String value) { + this.id = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/LigandPartType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/LigandPartType.java new file mode 100644 index 000000000..21b9a7180 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/LigandPartType.java @@ -0,0 +1,152 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes a ligand part. + * + *

Java class for ligandPartType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="ligandPartType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="name" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ *         <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType" minOccurs="0"/>
+ *         <element name="label" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ *         <element name="note" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ *       </sequence>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "ligandPartType", propOrder = { + "name", + "dbReference", + "label", + "note" +}) +public class LigandPartType { + + @XmlElement(required = true) + protected String name; + protected DbReferenceType dbReference; + protected String label; + protected String note; + + /** + * Gets the value of the name property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getName() { + return name; + } + + /** + * Sets the value of the name property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setName(String value) { + this.name = value; + } + + /** + * Gets the value of the dbReference property. + * + * @return + * possible object is + * {@link DbReferenceType } + * + */ + public DbReferenceType getDbReference() { + return dbReference; + } + + /** + * Sets the value of the dbReference property. + * + * @param value + * allowed object is + * {@link DbReferenceType } + * + */ + public void setDbReference(DbReferenceType value) { + this.dbReference = value; + } + + /** + * Gets the value of the label property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getLabel() { + return label; + } + + /** + * Sets the value of the label property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setLabel(String value) { + this.label = value; + } + + /** + * Gets the value of the note property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getNote() { + return note; + } + + /** + * Sets the value of the note property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setNote(String value) { + this.note = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/LigandType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/LigandType.java new file mode 100644 index 000000000..22e17ee97 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/LigandType.java @@ -0,0 +1,152 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes a ligand. + * + *

Java class for ligandType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="ligandType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="name" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ *         <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType" minOccurs="0"/>
+ *         <element name="label" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ *         <element name="note" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ *       </sequence>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "ligandType", propOrder = { + "name", + "dbReference", + "label", + "note" +}) +public class LigandType { + + @XmlElement(required = true) + protected String name; + protected DbReferenceType dbReference; + protected String label; + protected String note; + + /** + * Gets the value of the name property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getName() { + return name; + } + + /** + * Sets the value of the name property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setName(String value) { + this.name = value; + } + + /** + * Gets the value of the dbReference property. + * + * @return + * possible object is + * {@link DbReferenceType } + * + */ + public DbReferenceType getDbReference() { + return dbReference; + } + + /** + * Sets the value of the dbReference property. + * + * @param value + * allowed object is + * {@link DbReferenceType } + * + */ + public void setDbReference(DbReferenceType value) { + this.dbReference = value; + } + + /** + * Gets the value of the label property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getLabel() { + return label; + } + + /** + * Sets the value of the label property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setLabel(String value) { + this.label = value; + } + + /** + * Gets the value of the note property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getNote() { + return note; + } + + /** + * Sets the value of the note property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setNote(String value) { + this.note = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/LocationType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/LocationType.java new file mode 100644 index 000000000..6530635ce --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/LocationType.java @@ -0,0 +1,153 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes a sequence location as either a range with a begin and end or as a position. The 'sequence' attribute is only used when the location is not on the canonical sequence displayed in the current entry. + * + *

Java class for locationType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="locationType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <choice>
+ *         <sequence>
+ *           <element name="begin" type="{https://uniprot.org/uniprot}positionType"/>
+ *           <element name="end" type="{https://uniprot.org/uniprot}positionType"/>
+ *         </sequence>
+ *         <element name="position" type="{https://uniprot.org/uniprot}positionType"/>
+ *       </choice>
+ *       <attribute name="sequence" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "locationType", propOrder = { + "begin", + "end", + "position" +}) +public class LocationType { + + protected PositionType begin; + protected PositionType end; + protected PositionType position; + @XmlAttribute(name = "sequence") + protected String sequence; + + /** + * Gets the value of the begin property. + * + * @return + * possible object is + * {@link PositionType } + * + */ + public PositionType getBegin() { + return begin; + } + + /** + * Sets the value of the begin property. + * + * @param value + * allowed object is + * {@link PositionType } + * + */ + public void setBegin(PositionType value) { + this.begin = value; + } + + /** + * Gets the value of the end property. + * + * @return + * possible object is + * {@link PositionType } + * + */ + public PositionType getEnd() { + return end; + } + + /** + * Sets the value of the end property. + * + * @param value + * allowed object is + * {@link PositionType } + * + */ + public void setEnd(PositionType value) { + this.end = value; + } + + /** + * Gets the value of the position property. + * + * @return + * possible object is + * {@link PositionType } + * + */ + public PositionType getPosition() { + return position; + } + + /** + * Sets the value of the position property. + * + * @param value + * allowed object is + * {@link PositionType } + * + */ + public void setPosition(PositionType value) { + this.position = value; + } + + /** + * Gets the value of the sequence property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getSequence() { + return sequence; + } + + /** + * Sets the value of the sequence property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setSequence(String value) { + this.sequence = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/MoleculeType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/MoleculeType.java new file mode 100644 index 000000000..4575c6333 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/MoleculeType.java @@ -0,0 +1,96 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; +import javax.xml.bind.annotation.XmlValue; + + +/** + * Describes a molecule by name or unique identifier. + * + *

Java class for moleculeType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="moleculeType">
+ *   <simpleContent>
+ *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *       <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     </extension>
+ *   </simpleContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "moleculeType", propOrder = { + "value" +}) +public class MoleculeType { + + @XmlValue + protected String value; + @XmlAttribute(name = "id") + protected String id; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the id property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getId() { + return id; + } + + /** + * Sets the value of the id property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setId(String value) { + this.id = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/NameListType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/NameListType.java new file mode 100644 index 000000000..3f9a87714 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/NameListType.java @@ -0,0 +1,82 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlElements; +import javax.xml.bind.annotation.XmlType; + + +/** + *

Java class for nameListType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="nameListType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <choice maxOccurs="unbounded">
+ *         <element name="consortium" type="{https://uniprot.org/uniprot}consortiumType"/>
+ *         <element name="person" type="{https://uniprot.org/uniprot}personType"/>
+ *       </choice>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "nameListType", propOrder = { + "consortiumOrPerson" +}) +public class NameListType { + + @XmlElements({ + @XmlElement(name = "consortium", type = ConsortiumType.class), + @XmlElement(name = "person", type = PersonType.class) + }) + protected List consortiumOrPerson; + + /** + * Gets the value of the consortiumOrPerson property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the consortiumOrPerson property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getConsortiumOrPerson().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link ConsortiumType } + * {@link PersonType } + * + * + */ + public List getConsortiumOrPerson() { + if (consortiumOrPerson == null) { + consortiumOrPerson = new ArrayList(); + } + return this.consortiumOrPerson; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ObjectFactory.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ObjectFactory.java new file mode 100644 index 000000000..110ee58de --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ObjectFactory.java @@ -0,0 +1,524 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.JAXBElement; +import javax.xml.bind.annotation.XmlElementDecl; +import javax.xml.bind.annotation.XmlRegistry; +import javax.xml.namespace.QName; + + +/** + * This object contains factory methods for each + * Java content interface and Java element interface + * generated in the org.opencb.biodata.formats.protein.uniprot.v202502jaxb package. + *

An ObjectFactory allows you to programatically + * construct new instances of the Java representation + * for XML content. The Java representation of XML + * content can consist of schema derived interfaces + * and classes representing the binding of schema + * type definitions, element declarations and model + * groups. Factory methods for each of these are + * provided in this class. + * + */ +@XmlRegistry +public class ObjectFactory { + + private final static QName _Copyright_QNAME = new QName("https://uniprot.org/uniprot", "copyright"); + + /** + * Create a new ObjectFactory that can be used to create new instances of schema derived classes for package: org.opencb.biodata.formats.protein.uniprot.v202502jaxb + * + */ + public ObjectFactory() { + } + + /** + * Create an instance of {@link SourceDataType } + * + */ + public SourceDataType createSourceDataType() { + return new SourceDataType(); + } + + /** + * Create an instance of {@link IsoformType } + * + */ + public IsoformType createIsoformType() { + return new IsoformType(); + } + + /** + * Create an instance of {@link CommentType } + * + */ + public CommentType createCommentType() { + return new CommentType(); + } + + /** + * Create an instance of {@link CommentType.Conflict } + * + */ + public CommentType.Conflict createCommentTypeConflict() { + return new CommentType.Conflict(); + } + + /** + * Create an instance of {@link OrganismType } + * + */ + public OrganismType createOrganismType() { + return new OrganismType(); + } + + /** + * Create an instance of {@link ProteinType } + * + */ + public ProteinType createProteinType() { + return new ProteinType(); + } + + /** + * Create an instance of {@link Entry } + * + */ + public Entry createEntry() { + return new Entry(); + } + + /** + * Create an instance of {@link GeneType } + * + */ + public GeneType createGeneType() { + return new GeneType(); + } + + /** + * Create an instance of {@link GeneLocationType } + * + */ + public GeneLocationType createGeneLocationType() { + return new GeneLocationType(); + } + + /** + * Create an instance of {@link ReferenceType } + * + */ + public ReferenceType createReferenceType() { + return new ReferenceType(); + } + + /** + * Create an instance of {@link DbReferenceType } + * + */ + public DbReferenceType createDbReferenceType() { + return new DbReferenceType(); + } + + /** + * Create an instance of {@link ProteinExistenceType } + * + */ + public ProteinExistenceType createProteinExistenceType() { + return new ProteinExistenceType(); + } + + /** + * Create an instance of {@link KeywordType } + * + */ + public KeywordType createKeywordType() { + return new KeywordType(); + } + + /** + * Create an instance of {@link FeatureType } + * + */ + public FeatureType createFeatureType() { + return new FeatureType(); + } + + /** + * Create an instance of {@link EvidenceType } + * + */ + public EvidenceType createEvidenceType() { + return new EvidenceType(); + } + + /** + * Create an instance of {@link SequenceType } + * + */ + public SequenceType createSequenceType() { + return new SequenceType(); + } + + /** + * Create an instance of {@link Uniprot } + * + */ + public Uniprot createUniprot() { + return new Uniprot(); + } + + /** + * Create an instance of {@link StatusType } + * + */ + public StatusType createStatusType() { + return new StatusType(); + } + + /** + * Create an instance of {@link PositionType } + * + */ + public PositionType createPositionType() { + return new PositionType(); + } + + /** + * Create an instance of {@link ConsortiumType } + * + */ + public ConsortiumType createConsortiumType() { + return new ConsortiumType(); + } + + /** + * Create an instance of {@link GeneNameType } + * + */ + public GeneNameType createGeneNameType() { + return new GeneNameType(); + } + + /** + * Create an instance of {@link LocationType } + * + */ + public LocationType createLocationType() { + return new LocationType(); + } + + /** + * Create an instance of {@link CitationType } + * + */ + public CitationType createCitationType() { + return new CitationType(); + } + + /** + * Create an instance of {@link PropertyType } + * + */ + public PropertyType createPropertyType() { + return new PropertyType(); + } + + /** + * Create an instance of {@link PhysiologicalReactionType } + * + */ + public PhysiologicalReactionType createPhysiologicalReactionType() { + return new PhysiologicalReactionType(); + } + + /** + * Create an instance of {@link CofactorType } + * + */ + public CofactorType createCofactorType() { + return new CofactorType(); + } + + /** + * Create an instance of {@link EvidencedStringType } + * + */ + public EvidencedStringType createEvidencedStringType() { + return new EvidencedStringType(); + } + + /** + * Create an instance of {@link PersonType } + * + */ + public PersonType createPersonType() { + return new PersonType(); + } + + /** + * Create an instance of {@link ImportedFromType } + * + */ + public ImportedFromType createImportedFromType() { + return new ImportedFromType(); + } + + /** + * Create an instance of {@link LigandPartType } + * + */ + public LigandPartType createLigandPartType() { + return new LigandPartType(); + } + + /** + * Create an instance of {@link LigandType } + * + */ + public LigandType createLigandType() { + return new LigandType(); + } + + /** + * Create an instance of {@link EventType } + * + */ + public EventType createEventType() { + return new EventType(); + } + + /** + * Create an instance of {@link InteractantType } + * + */ + public InteractantType createInteractantType() { + return new InteractantType(); + } + + /** + * Create an instance of {@link NameListType } + * + */ + public NameListType createNameListType() { + return new NameListType(); + } + + /** + * Create an instance of {@link ReactionType } + * + */ + public ReactionType createReactionType() { + return new ReactionType(); + } + + /** + * Create an instance of {@link SourceType } + * + */ + public SourceType createSourceType() { + return new SourceType(); + } + + /** + * Create an instance of {@link MoleculeType } + * + */ + public MoleculeType createMoleculeType() { + return new MoleculeType(); + } + + /** + * Create an instance of {@link OrganismNameType } + * + */ + public OrganismNameType createOrganismNameType() { + return new OrganismNameType(); + } + + /** + * Create an instance of {@link SubcellularLocationType } + * + */ + public SubcellularLocationType createSubcellularLocationType() { + return new SubcellularLocationType(); + } + + /** + * Create an instance of {@link SourceDataType.Strain } + * + */ + public SourceDataType.Strain createSourceDataTypeStrain() { + return new SourceDataType.Strain(); + } + + /** + * Create an instance of {@link SourceDataType.Plasmid } + * + */ + public SourceDataType.Plasmid createSourceDataTypePlasmid() { + return new SourceDataType.Plasmid(); + } + + /** + * Create an instance of {@link SourceDataType.Transposon } + * + */ + public SourceDataType.Transposon createSourceDataTypeTransposon() { + return new SourceDataType.Transposon(); + } + + /** + * Create an instance of {@link SourceDataType.Tissue } + * + */ + public SourceDataType.Tissue createSourceDataTypeTissue() { + return new SourceDataType.Tissue(); + } + + /** + * Create an instance of {@link IsoformType.Name } + * + */ + public IsoformType.Name createIsoformTypeName() { + return new IsoformType.Name(); + } + + /** + * Create an instance of {@link IsoformType.Sequence } + * + */ + public IsoformType.Sequence createIsoformTypeSequence() { + return new IsoformType.Sequence(); + } + + /** + * Create an instance of {@link CommentType.Absorption } + * + */ + public CommentType.Absorption createCommentTypeAbsorption() { + return new CommentType.Absorption(); + } + + /** + * Create an instance of {@link CommentType.Kinetics } + * + */ + public CommentType.Kinetics createCommentTypeKinetics() { + return new CommentType.Kinetics(); + } + + /** + * Create an instance of {@link CommentType.PhDependence } + * + */ + public CommentType.PhDependence createCommentTypePhDependence() { + return new CommentType.PhDependence(); + } + + /** + * Create an instance of {@link CommentType.RedoxPotential } + * + */ + public CommentType.RedoxPotential createCommentTypeRedoxPotential() { + return new CommentType.RedoxPotential(); + } + + /** + * Create an instance of {@link CommentType.TemperatureDependence } + * + */ + public CommentType.TemperatureDependence createCommentTypeTemperatureDependence() { + return new CommentType.TemperatureDependence(); + } + + /** + * Create an instance of {@link CommentType.Link } + * + */ + public CommentType.Link createCommentTypeLink() { + return new CommentType.Link(); + } + + /** + * Create an instance of {@link CommentType.Disease } + * + */ + public CommentType.Disease createCommentTypeDisease() { + return new CommentType.Disease(); + } + + /** + * Create an instance of {@link CommentType.Conflict.Sequence } + * + */ + public CommentType.Conflict.Sequence createCommentTypeConflictSequence() { + return new CommentType.Conflict.Sequence(); + } + + /** + * Create an instance of {@link OrganismType.Lineage } + * + */ + public OrganismType.Lineage createOrganismTypeLineage() { + return new OrganismType.Lineage(); + } + + /** + * Create an instance of {@link ProteinType.RecommendedName } + * + */ + public ProteinType.RecommendedName createProteinTypeRecommendedName() { + return new ProteinType.RecommendedName(); + } + + /** + * Create an instance of {@link ProteinType.AlternativeName } + * + */ + public ProteinType.AlternativeName createProteinTypeAlternativeName() { + return new ProteinType.AlternativeName(); + } + + /** + * Create an instance of {@link ProteinType.SubmittedName } + * + */ + public ProteinType.SubmittedName createProteinTypeSubmittedName() { + return new ProteinType.SubmittedName(); + } + + /** + * Create an instance of {@link ProteinType.Domain } + * + */ + public ProteinType.Domain createProteinTypeDomain() { + return new ProteinType.Domain(); + } + + /** + * Create an instance of {@link ProteinType.Component } + * + */ + public ProteinType.Component createProteinTypeComponent() { + return new ProteinType.Component(); + } + + /** + * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}} + * + */ + @XmlElementDecl(namespace = "https://uniprot.org/uniprot", name = "copyright") + public JAXBElement createCopyright(String value) { + return new JAXBElement(_Copyright_QNAME, String.class, null, value); + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/OrganismNameType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/OrganismNameType.java new file mode 100644 index 000000000..66b821455 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/OrganismNameType.java @@ -0,0 +1,106 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; +import javax.xml.bind.annotation.XmlValue; + + +/** + * Describes different types of source organism names. + * + *

Java class for organismNameType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="organismNameType">
+ *   <simpleContent>
+ *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *       <attribute name="type" use="required">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="common"/>
+ *             <enumeration value="full"/>
+ *             <enumeration value="scientific"/>
+ *             <enumeration value="synonym"/>
+ *             <enumeration value="abbreviation"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *     </extension>
+ *   </simpleContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "organismNameType", propOrder = { + "value" +}) +public class OrganismNameType { + + @XmlValue + protected String value; + @XmlAttribute(name = "type", required = true) + protected String type; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/OrganismType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/OrganismType.java new file mode 100644 index 000000000..b1610c890 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/OrganismType.java @@ -0,0 +1,241 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes the source organism. + * + *

Java class for organismType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="organismType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="name" type="{https://uniprot.org/uniprot}organismNameType" maxOccurs="unbounded"/>
+ *         <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType" maxOccurs="unbounded"/>
+ *         <element name="lineage" minOccurs="0">
+ *           <complexType>
+ *             <complexContent>
+ *               <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *                 <sequence>
+ *                   <element name="taxon" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded"/>
+ *                 </sequence>
+ *               </restriction>
+ *             </complexContent>
+ *           </complexType>
+ *         </element>
+ *       </sequence>
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "organismType", propOrder = { + "name", + "dbReference", + "lineage" +}) +public class OrganismType { + + @XmlElement(required = true) + protected List name; + @XmlElement(required = true) + protected List dbReference; + protected OrganismType.Lineage lineage; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the name property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the name property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getName().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link OrganismNameType } + * + * + */ + public List getName() { + if (name == null) { + name = new ArrayList(); + } + return this.name; + } + + /** + * Gets the value of the dbReference property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the dbReference property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getDbReference().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link DbReferenceType } + * + * + */ + public List getDbReference() { + if (dbReference == null) { + dbReference = new ArrayList(); + } + return this.dbReference; + } + + /** + * Gets the value of the lineage property. + * + * @return + * possible object is + * {@link OrganismType.Lineage } + * + */ + public OrganismType.Lineage getLineage() { + return lineage; + } + + /** + * Sets the value of the lineage property. + * + * @param value + * allowed object is + * {@link OrganismType.Lineage } + * + */ + public void setLineage(OrganismType.Lineage value) { + this.lineage = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <sequence>
+     *         <element name="taxon" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded"/>
+     *       </sequence>
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "taxon" + }) + public static class Lineage { + + @XmlElement(required = true) + protected List taxon; + + /** + * Gets the value of the taxon property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the taxon property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getTaxon().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link String } + * + * + */ + public List getTaxon() { + if (taxon == null) { + taxon = new ArrayList(); + } + return this.taxon; + } + + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PersonType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PersonType.java new file mode 100644 index 000000000..4eb6fcc4e --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PersonType.java @@ -0,0 +1,65 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + *

Java class for personType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="personType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "personType") +public class PersonType { + + @XmlAttribute(name = "name", required = true) + protected String name; + + /** + * Gets the value of the name property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getName() { + return name; + } + + /** + * Sets the value of the name property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setName(String value) { + this.name = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PhysiologicalReactionType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PhysiologicalReactionType.java new file mode 100644 index 000000000..7bcaf0bba --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PhysiologicalReactionType.java @@ -0,0 +1,140 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes a physiological reaction. + * + *

Java class for physiologicalReactionType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="physiologicalReactionType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType"/>
+ *       </sequence>
+ *       <attribute name="direction" use="required">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="left-to-right"/>
+ *             <enumeration value="right-to-left"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "physiologicalReactionType", propOrder = { + "dbReference" +}) +public class PhysiologicalReactionType { + + @XmlElement(required = true) + protected DbReferenceType dbReference; + @XmlAttribute(name = "direction", required = true) + protected String direction; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the dbReference property. + * + * @return + * possible object is + * {@link DbReferenceType } + * + */ + public DbReferenceType getDbReference() { + return dbReference; + } + + /** + * Sets the value of the dbReference property. + * + * @param value + * allowed object is + * {@link DbReferenceType } + * + */ + public void setDbReference(DbReferenceType value) { + this.dbReference = value; + } + + /** + * Gets the value of the direction property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getDirection() { + return direction; + } + + /** + * Sets the value of the direction property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setDirection(String value) { + this.direction = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PositionType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PositionType.java new file mode 100644 index 000000000..c1fb9210a --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PositionType.java @@ -0,0 +1,143 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.math.BigInteger; +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlSchemaType; +import javax.xml.bind.annotation.XmlType; + + +/** + *

Java class for positionType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="positionType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <attribute name="position" type="{http://www.w3.org/2001/XMLSchema}unsignedLong" />
+ *       <attribute name="status" default="certain">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="certain"/>
+ *             <enumeration value="uncertain"/>
+ *             <enumeration value="less than"/>
+ *             <enumeration value="greater than"/>
+ *             <enumeration value="unknown"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "positionType") +public class PositionType { + + @XmlAttribute(name = "position") + @XmlSchemaType(name = "unsignedLong") + protected BigInteger position; + @XmlAttribute(name = "status") + protected String status; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the position property. + * + * @return + * possible object is + * {@link BigInteger } + * + */ + public BigInteger getPosition() { + return position; + } + + /** + * Sets the value of the position property. + * + * @param value + * allowed object is + * {@link BigInteger } + * + */ + public void setPosition(BigInteger value) { + this.position = value; + } + + /** + * Gets the value of the status property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getStatus() { + if (status == null) { + return "certain"; + } else { + return status; + } + } + + /** + * Sets the value of the status property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setStatus(String value) { + this.status = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PropertyType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PropertyType.java new file mode 100644 index 000000000..70462be87 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/PropertyType.java @@ -0,0 +1,92 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + *

Java class for propertyType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="propertyType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "propertyType") +public class PropertyType { + + @XmlAttribute(name = "type", required = true) + protected String type; + @XmlAttribute(name = "value", required = true) + protected String value; + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ProteinExistenceType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ProteinExistenceType.java new file mode 100644 index 000000000..ea7324f26 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ProteinExistenceType.java @@ -0,0 +1,78 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes the evidence for the protein's existence. + * Equivalent to the flat file PE-line. + * + *

Java class for proteinExistenceType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="proteinExistenceType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <attribute name="type" use="required">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="evidence at protein level"/>
+ *             <enumeration value="evidence at transcript level"/>
+ *             <enumeration value="inferred from homology"/>
+ *             <enumeration value="predicted"/>
+ *             <enumeration value="uncertain"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "proteinExistenceType") +public class ProteinExistenceType { + + @XmlAttribute(name = "type", required = true) + protected String type; + + /** + * Gets the value of the type property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getType() { + return type; + } + + /** + * Sets the value of the type property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setType(String value) { + this.type = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ProteinType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ProteinType.java new file mode 100644 index 000000000..8bc20da17 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ProteinType.java @@ -0,0 +1,1109 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes the names for the protein and parts thereof. + * Equivalent to the flat file DE-line. + * + *

Java class for proteinType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="proteinType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <group ref="{https://uniprot.org/uniprot}proteinNameGroup"/>
+ *         <element name="domain" maxOccurs="unbounded" minOccurs="0">
+ *           <complexType>
+ *             <complexContent>
+ *               <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *                 <group ref="{https://uniprot.org/uniprot}proteinNameGroup"/>
+ *               </restriction>
+ *             </complexContent>
+ *           </complexType>
+ *         </element>
+ *         <element name="component" maxOccurs="unbounded" minOccurs="0">
+ *           <complexType>
+ *             <complexContent>
+ *               <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *                 <group ref="{https://uniprot.org/uniprot}proteinNameGroup"/>
+ *               </restriction>
+ *             </complexContent>
+ *           </complexType>
+ *         </element>
+ *       </sequence>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "proteinType", propOrder = { + "recommendedName", + "alternativeName", + "submittedName", + "allergenName", + "biotechName", + "cdAntigenName", + "innName", + "domain", + "component" +}) +public class ProteinType { + + protected ProteinType.RecommendedName recommendedName; + protected List alternativeName; + protected List submittedName; + protected EvidencedStringType allergenName; + protected EvidencedStringType biotechName; + protected List cdAntigenName; + protected List innName; + protected List domain; + protected List component; + + /** + * Gets the value of the recommendedName property. + * + * @return + * possible object is + * {@link ProteinType.RecommendedName } + * + */ + public ProteinType.RecommendedName getRecommendedName() { + return recommendedName; + } + + /** + * Sets the value of the recommendedName property. + * + * @param value + * allowed object is + * {@link ProteinType.RecommendedName } + * + */ + public void setRecommendedName(ProteinType.RecommendedName value) { + this.recommendedName = value; + } + + /** + * Gets the value of the alternativeName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the alternativeName property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getAlternativeName().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link ProteinType.AlternativeName } + * + * + */ + public List getAlternativeName() { + if (alternativeName == null) { + alternativeName = new ArrayList(); + } + return this.alternativeName; + } + + /** + * Gets the value of the submittedName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the submittedName property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getSubmittedName().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link ProteinType.SubmittedName } + * + * + */ + public List getSubmittedName() { + if (submittedName == null) { + submittedName = new ArrayList(); + } + return this.submittedName; + } + + /** + * Gets the value of the allergenName property. + * + * @return + * possible object is + * {@link EvidencedStringType } + * + */ + public EvidencedStringType getAllergenName() { + return allergenName; + } + + /** + * Sets the value of the allergenName property. + * + * @param value + * allowed object is + * {@link EvidencedStringType } + * + */ + public void setAllergenName(EvidencedStringType value) { + this.allergenName = value; + } + + /** + * Gets the value of the biotechName property. + * + * @return + * possible object is + * {@link EvidencedStringType } + * + */ + public EvidencedStringType getBiotechName() { + return biotechName; + } + + /** + * Sets the value of the biotechName property. + * + * @param value + * allowed object is + * {@link EvidencedStringType } + * + */ + public void setBiotechName(EvidencedStringType value) { + this.biotechName = value; + } + + /** + * Gets the value of the cdAntigenName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the cdAntigenName property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getCdAntigenName().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getCdAntigenName() { + if (cdAntigenName == null) { + cdAntigenName = new ArrayList(); + } + return this.cdAntigenName; + } + + /** + * Gets the value of the innName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the innName property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getInnName().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getInnName() { + if (innName == null) { + innName = new ArrayList(); + } + return this.innName; + } + + /** + * Gets the value of the domain property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the domain property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getDomain().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link ProteinType.Domain } + * + * + */ + public List getDomain() { + if (domain == null) { + domain = new ArrayList(); + } + return this.domain; + } + + /** + * Gets the value of the component property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the component property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getComponent().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link ProteinType.Component } + * + * + */ + public List getComponent() { + if (component == null) { + component = new ArrayList(); + } + return this.component; + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <sequence>
+     *         <element name="fullName" type="{https://uniprot.org/uniprot}evidencedStringType" minOccurs="0"/>
+     *         <element name="shortName" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+     *         <element name="ecNumber" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+     *       </sequence>
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "fullName", + "shortName", + "ecNumber" + }) + public static class AlternativeName { + + protected EvidencedStringType fullName; + protected List shortName; + protected List ecNumber; + + /** + * Gets the value of the fullName property. + * + * @return + * possible object is + * {@link EvidencedStringType } + * + */ + public EvidencedStringType getFullName() { + return fullName; + } + + /** + * Sets the value of the fullName property. + * + * @param value + * allowed object is + * {@link EvidencedStringType } + * + */ + public void setFullName(EvidencedStringType value) { + this.fullName = value; + } + + /** + * Gets the value of the shortName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the shortName property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getShortName().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getShortName() { + if (shortName == null) { + shortName = new ArrayList(); + } + return this.shortName; + } + + /** + * Gets the value of the ecNumber property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the ecNumber property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getEcNumber().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getEcNumber() { + if (ecNumber == null) { + ecNumber = new ArrayList(); + } + return this.ecNumber; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <group ref="{https://uniprot.org/uniprot}proteinNameGroup"/>
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "recommendedName", + "alternativeName", + "submittedName", + "allergenName", + "biotechName", + "cdAntigenName", + "innName" + }) + public static class Component { + + protected ProteinType.RecommendedName recommendedName; + protected List alternativeName; + protected List submittedName; + protected EvidencedStringType allergenName; + protected EvidencedStringType biotechName; + protected List cdAntigenName; + protected List innName; + + /** + * Gets the value of the recommendedName property. + * + * @return + * possible object is + * {@link ProteinType.RecommendedName } + * + */ + public ProteinType.RecommendedName getRecommendedName() { + return recommendedName; + } + + /** + * Sets the value of the recommendedName property. + * + * @param value + * allowed object is + * {@link ProteinType.RecommendedName } + * + */ + public void setRecommendedName(ProteinType.RecommendedName value) { + this.recommendedName = value; + } + + /** + * Gets the value of the alternativeName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the alternativeName property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getAlternativeName().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link ProteinType.AlternativeName } + * + * + */ + public List getAlternativeName() { + if (alternativeName == null) { + alternativeName = new ArrayList(); + } + return this.alternativeName; + } + + /** + * Gets the value of the submittedName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the submittedName property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getSubmittedName().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link ProteinType.SubmittedName } + * + * + */ + public List getSubmittedName() { + if (submittedName == null) { + submittedName = new ArrayList(); + } + return this.submittedName; + } + + /** + * Gets the value of the allergenName property. + * + * @return + * possible object is + * {@link EvidencedStringType } + * + */ + public EvidencedStringType getAllergenName() { + return allergenName; + } + + /** + * Sets the value of the allergenName property. + * + * @param value + * allowed object is + * {@link EvidencedStringType } + * + */ + public void setAllergenName(EvidencedStringType value) { + this.allergenName = value; + } + + /** + * Gets the value of the biotechName property. + * + * @return + * possible object is + * {@link EvidencedStringType } + * + */ + public EvidencedStringType getBiotechName() { + return biotechName; + } + + /** + * Sets the value of the biotechName property. + * + * @param value + * allowed object is + * {@link EvidencedStringType } + * + */ + public void setBiotechName(EvidencedStringType value) { + this.biotechName = value; + } + + /** + * Gets the value of the cdAntigenName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the cdAntigenName property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getCdAntigenName().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getCdAntigenName() { + if (cdAntigenName == null) { + cdAntigenName = new ArrayList(); + } + return this.cdAntigenName; + } + + /** + * Gets the value of the innName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the innName property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getInnName().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getInnName() { + if (innName == null) { + innName = new ArrayList(); + } + return this.innName; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <group ref="{https://uniprot.org/uniprot}proteinNameGroup"/>
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "recommendedName", + "alternativeName", + "submittedName", + "allergenName", + "biotechName", + "cdAntigenName", + "innName" + }) + public static class Domain { + + protected ProteinType.RecommendedName recommendedName; + protected List alternativeName; + protected List submittedName; + protected EvidencedStringType allergenName; + protected EvidencedStringType biotechName; + protected List cdAntigenName; + protected List innName; + + /** + * Gets the value of the recommendedName property. + * + * @return + * possible object is + * {@link ProteinType.RecommendedName } + * + */ + public ProteinType.RecommendedName getRecommendedName() { + return recommendedName; + } + + /** + * Sets the value of the recommendedName property. + * + * @param value + * allowed object is + * {@link ProteinType.RecommendedName } + * + */ + public void setRecommendedName(ProteinType.RecommendedName value) { + this.recommendedName = value; + } + + /** + * Gets the value of the alternativeName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the alternativeName property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getAlternativeName().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link ProteinType.AlternativeName } + * + * + */ + public List getAlternativeName() { + if (alternativeName == null) { + alternativeName = new ArrayList(); + } + return this.alternativeName; + } + + /** + * Gets the value of the submittedName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the submittedName property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getSubmittedName().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link ProteinType.SubmittedName } + * + * + */ + public List getSubmittedName() { + if (submittedName == null) { + submittedName = new ArrayList(); + } + return this.submittedName; + } + + /** + * Gets the value of the allergenName property. + * + * @return + * possible object is + * {@link EvidencedStringType } + * + */ + public EvidencedStringType getAllergenName() { + return allergenName; + } + + /** + * Sets the value of the allergenName property. + * + * @param value + * allowed object is + * {@link EvidencedStringType } + * + */ + public void setAllergenName(EvidencedStringType value) { + this.allergenName = value; + } + + /** + * Gets the value of the biotechName property. + * + * @return + * possible object is + * {@link EvidencedStringType } + * + */ + public EvidencedStringType getBiotechName() { + return biotechName; + } + + /** + * Sets the value of the biotechName property. + * + * @param value + * allowed object is + * {@link EvidencedStringType } + * + */ + public void setBiotechName(EvidencedStringType value) { + this.biotechName = value; + } + + /** + * Gets the value of the cdAntigenName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the cdAntigenName property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getCdAntigenName().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getCdAntigenName() { + if (cdAntigenName == null) { + cdAntigenName = new ArrayList(); + } + return this.cdAntigenName; + } + + /** + * Gets the value of the innName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the innName property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getInnName().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getInnName() { + if (innName == null) { + innName = new ArrayList(); + } + return this.innName; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <sequence>
+     *         <element name="fullName" type="{https://uniprot.org/uniprot}evidencedStringType"/>
+     *         <element name="shortName" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+     *         <element name="ecNumber" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+     *       </sequence>
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "fullName", + "shortName", + "ecNumber" + }) + public static class RecommendedName { + + @XmlElement(required = true) + protected EvidencedStringType fullName; + protected List shortName; + protected List ecNumber; + + /** + * Gets the value of the fullName property. + * + * @return + * possible object is + * {@link EvidencedStringType } + * + */ + public EvidencedStringType getFullName() { + return fullName; + } + + /** + * Sets the value of the fullName property. + * + * @param value + * allowed object is + * {@link EvidencedStringType } + * + */ + public void setFullName(EvidencedStringType value) { + this.fullName = value; + } + + /** + * Gets the value of the shortName property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the shortName property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getShortName().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getShortName() { + if (shortName == null) { + shortName = new ArrayList(); + } + return this.shortName; + } + + /** + * Gets the value of the ecNumber property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the ecNumber property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getEcNumber().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getEcNumber() { + if (ecNumber == null) { + ecNumber = new ArrayList(); + } + return this.ecNumber; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <complexContent>
+     *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+     *       <sequence>
+     *         <element name="fullName" type="{https://uniprot.org/uniprot}evidencedStringType"/>
+     *         <element name="ecNumber" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+     *       </sequence>
+     *     </restriction>
+     *   </complexContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "fullName", + "ecNumber" + }) + public static class SubmittedName { + + @XmlElement(required = true) + protected EvidencedStringType fullName; + protected List ecNumber; + + /** + * Gets the value of the fullName property. + * + * @return + * possible object is + * {@link EvidencedStringType } + * + */ + public EvidencedStringType getFullName() { + return fullName; + } + + /** + * Sets the value of the fullName property. + * + * @param value + * allowed object is + * {@link EvidencedStringType } + * + */ + public void setFullName(EvidencedStringType value) { + this.fullName = value; + } + + /** + * Gets the value of the ecNumber property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the ecNumber property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getEcNumber().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getEcNumber() { + if (ecNumber == null) { + ecNumber = new ArrayList(); + } + return this.ecNumber; + } + + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ReactionType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ReactionType.java new file mode 100644 index 000000000..1e2ed9744 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ReactionType.java @@ -0,0 +1,139 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes a chemical reaction. + * + *

Java class for reactionType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="reactionType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="text" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ *         <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType" maxOccurs="unbounded"/>
+ *       </sequence>
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "reactionType", propOrder = { + "text", + "dbReference" +}) +public class ReactionType { + + @XmlElement(required = true) + protected String text; + @XmlElement(required = true) + protected List dbReference; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the text property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getText() { + return text; + } + + /** + * Sets the value of the text property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setText(String value) { + this.text = value; + } + + /** + * Gets the value of the dbReference property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the dbReference property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getDbReference().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link DbReferenceType } + * + * + */ + public List getDbReference() { + if (dbReference == null) { + dbReference = new ArrayList(); + } + return this.dbReference; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ReferenceType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ReferenceType.java new file mode 100644 index 000000000..1ec87250c --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/ReferenceType.java @@ -0,0 +1,193 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes a citation and a summary of its content. + * Equivalent to the flat file RN-, RP-, RC-, RX-, RG-, RA-, RT- and RL-lines. + * + *

Java class for referenceType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="referenceType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="citation" type="{https://uniprot.org/uniprot}citationType"/>
+ *         <group ref="{https://uniprot.org/uniprot}sptrCitationGroup"/>
+ *       </sequence>
+ *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *       <attribute name="key" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "referenceType", propOrder = { + "citation", + "scope", + "source" +}) +public class ReferenceType { + + @XmlElement(required = true) + protected CitationType citation; + @XmlElement(required = true) + protected List scope; + protected SourceDataType source; + @XmlAttribute(name = "evidence") + protected List evidence; + @XmlAttribute(name = "key", required = true) + protected String key; + + /** + * Gets the value of the citation property. + * + * @return + * possible object is + * {@link CitationType } + * + */ + public CitationType getCitation() { + return citation; + } + + /** + * Sets the value of the citation property. + * + * @param value + * allowed object is + * {@link CitationType } + * + */ + public void setCitation(CitationType value) { + this.citation = value; + } + + /** + * Gets the value of the scope property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the scope property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getScope().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link String } + * + * + */ + public List getScope() { + if (scope == null) { + scope = new ArrayList(); + } + return this.scope; + } + + /** + * Gets the value of the source property. + * + * @return + * possible object is + * {@link SourceDataType } + * + */ + public SourceDataType getSource() { + return source; + } + + /** + * Sets the value of the source property. + * + * @param value + * allowed object is + * {@link SourceDataType } + * + */ + public void setSource(SourceDataType value) { + this.source = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEvidence().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + /** + * Gets the value of the key property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getKey() { + return key; + } + + /** + * Sets the value of the key property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setKey(String value) { + this.key = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SequenceType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SequenceType.java new file mode 100644 index 000000000..87c08d606 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SequenceType.java @@ -0,0 +1,242 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlSchemaType; +import javax.xml.bind.annotation.XmlType; +import javax.xml.bind.annotation.XmlValue; +import javax.xml.datatype.XMLGregorianCalendar; + + +/** + *

Java class for sequenceType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="sequenceType">
+ *   <simpleContent>
+ *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *       <attribute name="length" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
+ *       <attribute name="mass" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
+ *       <attribute name="checksum" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       <attribute name="modified" use="required" type="{http://www.w3.org/2001/XMLSchema}date" />
+ *       <attribute name="version" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
+ *       <attribute name="precursor" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       <attribute name="fragment">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="single"/>
+ *             <enumeration value="multiple"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *     </extension>
+ *   </simpleContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "sequenceType", propOrder = { + "value" +}) +public class SequenceType { + + @XmlValue + protected String value; + @XmlAttribute(name = "length", required = true) + protected int length; + @XmlAttribute(name = "mass", required = true) + protected int mass; + @XmlAttribute(name = "checksum", required = true) + protected String checksum; + @XmlAttribute(name = "modified", required = true) + @XmlSchemaType(name = "date") + protected XMLGregorianCalendar modified; + @XmlAttribute(name = "version", required = true) + protected int version; + @XmlAttribute(name = "precursor") + protected Boolean precursor; + @XmlAttribute(name = "fragment") + protected String fragment; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the length property. + * + */ + public int getLength() { + return length; + } + + /** + * Sets the value of the length property. + * + */ + public void setLength(int value) { + this.length = value; + } + + /** + * Gets the value of the mass property. + * + */ + public int getMass() { + return mass; + } + + /** + * Sets the value of the mass property. + * + */ + public void setMass(int value) { + this.mass = value; + } + + /** + * Gets the value of the checksum property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getChecksum() { + return checksum; + } + + /** + * Sets the value of the checksum property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setChecksum(String value) { + this.checksum = value; + } + + /** + * Gets the value of the modified property. + * + * @return + * possible object is + * {@link XMLGregorianCalendar } + * + */ + public XMLGregorianCalendar getModified() { + return modified; + } + + /** + * Sets the value of the modified property. + * + * @param value + * allowed object is + * {@link XMLGregorianCalendar } + * + */ + public void setModified(XMLGregorianCalendar value) { + this.modified = value; + } + + /** + * Gets the value of the version property. + * + */ + public int getVersion() { + return version; + } + + /** + * Sets the value of the version property. + * + */ + public void setVersion(int value) { + this.version = value; + } + + /** + * Gets the value of the precursor property. + * + * @return + * possible object is + * {@link Boolean } + * + */ + public Boolean isPrecursor() { + return precursor; + } + + /** + * Sets the value of the precursor property. + * + * @param value + * allowed object is + * {@link Boolean } + * + */ + public void setPrecursor(Boolean value) { + this.precursor = value; + } + + /** + * Gets the value of the fragment property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getFragment() { + return fragment; + } + + /** + * Sets the value of the fragment property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setFragment(String value) { + this.fragment = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SourceDataType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SourceDataType.java new file mode 100644 index 000000000..1a1fd12dd --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SourceDataType.java @@ -0,0 +1,461 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlElements; +import javax.xml.bind.annotation.XmlType; +import javax.xml.bind.annotation.XmlValue; + + +/** + * Describes the source of the sequence according to the citation. + * Equivalent to the flat file RC-line. + * + *

Java class for sourceDataType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="sourceDataType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <choice maxOccurs="unbounded">
+ *         <element name="strain">
+ *           <complexType>
+ *             <simpleContent>
+ *               <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *                 <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *               </extension>
+ *             </simpleContent>
+ *           </complexType>
+ *         </element>
+ *         <element name="plasmid">
+ *           <complexType>
+ *             <simpleContent>
+ *               <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *                 <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *               </extension>
+ *             </simpleContent>
+ *           </complexType>
+ *         </element>
+ *         <element name="transposon">
+ *           <complexType>
+ *             <simpleContent>
+ *               <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *                 <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *               </extension>
+ *             </simpleContent>
+ *           </complexType>
+ *         </element>
+ *         <element name="tissue">
+ *           <complexType>
+ *             <simpleContent>
+ *               <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *                 <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+ *               </extension>
+ *             </simpleContent>
+ *           </complexType>
+ *         </element>
+ *       </choice>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "sourceDataType", propOrder = { + "strainOrPlasmidOrTransposon" +}) +public class SourceDataType { + + @XmlElements({ + @XmlElement(name = "strain", type = SourceDataType.Strain.class), + @XmlElement(name = "plasmid", type = SourceDataType.Plasmid.class), + @XmlElement(name = "transposon", type = SourceDataType.Transposon.class), + @XmlElement(name = "tissue", type = SourceDataType.Tissue.class) + }) + protected List strainOrPlasmidOrTransposon; + + /** + * Gets the value of the strainOrPlasmidOrTransposon property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the strainOrPlasmidOrTransposon property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getStrainOrPlasmidOrTransposon().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link SourceDataType.Strain } + * {@link SourceDataType.Plasmid } + * {@link SourceDataType.Transposon } + * {@link SourceDataType.Tissue } + * + * + */ + public List getStrainOrPlasmidOrTransposon() { + if (strainOrPlasmidOrTransposon == null) { + strainOrPlasmidOrTransposon = new ArrayList(); + } + return this.strainOrPlasmidOrTransposon; + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <simpleContent>
+     *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+     *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+     *     </extension>
+     *   </simpleContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "value" + }) + public static class Plasmid { + + @XmlValue + protected String value; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getEvidence().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <simpleContent>
+     *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+     *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+     *     </extension>
+     *   </simpleContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "value" + }) + public static class Strain { + + @XmlValue + protected String value; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getEvidence().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <simpleContent>
+     *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+     *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+     *     </extension>
+     *   </simpleContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "value" + }) + public static class Tissue { + + @XmlValue + protected String value; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getEvidence().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + } + + + /** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+     * <complexType>
+     *   <simpleContent>
+     *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+     *       <attribute name="evidence" type="{https://uniprot.org/uniprot}intListType" />
+     *     </extension>
+     *   </simpleContent>
+     * </complexType>
+     * 
+ * + * + */ + @XmlAccessorType(XmlAccessType.FIELD) + @XmlType(name = "", propOrder = { + "value" + }) + public static class Transposon { + + @XmlValue + protected String value; + @XmlAttribute(name = "evidence") + protected List evidence; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the evidence property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the evidence property. + * + *

+ * For example, to add a new item, do as follows: + *

+         *    getEvidence().add(newItem);
+         * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Integer } + * + * + */ + public List getEvidence() { + if (evidence == null) { + evidence = new ArrayList(); + } + return this.evidence; + } + + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SourceType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SourceType.java new file mode 100644 index 000000000..40aecfb8a --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SourceType.java @@ -0,0 +1,98 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.math.BigInteger; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes the source of the data using a database cross-reference (or a 'ref' attribute when the source cannot be found in a public data source, such as PubMed, and is cited only within the UniProtKB entry). + * + *

Java class for sourceType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="sourceType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="dbReference" type="{https://uniprot.org/uniprot}dbReferenceType" minOccurs="0"/>
+ *       </sequence>
+ *       <attribute name="ref" type="{http://www.w3.org/2001/XMLSchema}integer" />
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "sourceType", propOrder = { + "dbReference" +}) +public class SourceType { + + protected DbReferenceType dbReference; + @XmlAttribute(name = "ref") + protected BigInteger ref; + + /** + * Gets the value of the dbReference property. + * + * @return + * possible object is + * {@link DbReferenceType } + * + */ + public DbReferenceType getDbReference() { + return dbReference; + } + + /** + * Sets the value of the dbReference property. + * + * @param value + * allowed object is + * {@link DbReferenceType } + * + */ + public void setDbReference(DbReferenceType value) { + this.dbReference = value; + } + + /** + * Gets the value of the ref property. + * + * @return + * possible object is + * {@link BigInteger } + * + */ + public BigInteger getRef() { + return ref; + } + + /** + * Sets the value of the ref property. + * + * @param value + * allowed object is + * {@link BigInteger } + * + */ + public void setRef(BigInteger value) { + this.ref = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/StatusType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/StatusType.java new file mode 100644 index 000000000..0552f857a --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/StatusType.java @@ -0,0 +1,107 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlAttribute; +import javax.xml.bind.annotation.XmlType; +import javax.xml.bind.annotation.XmlValue; + + +/** + * Indicates whether the name of a plasmid is known or unknown. + * + *

Java class for statusType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="statusType">
+ *   <simpleContent>
+ *     <extension base="<http://www.w3.org/2001/XMLSchema>string">
+ *       <attribute name="status" default="known">
+ *         <simpleType>
+ *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ *             <enumeration value="known"/>
+ *             <enumeration value="unknown"/>
+ *           </restriction>
+ *         </simpleType>
+ *       </attribute>
+ *     </extension>
+ *   </simpleContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "statusType", propOrder = { + "value" +}) +public class StatusType { + + @XmlValue + protected String value; + @XmlAttribute(name = "status") + protected String status; + + /** + * Gets the value of the value property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getValue() { + return value; + } + + /** + * Sets the value of the value property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setValue(String value) { + this.value = value; + } + + /** + * Gets the value of the status property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getStatus() { + if (status == null) { + return "known"; + } else { + return status; + } + } + + /** + * Sets the value of the status property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setStatus(String value) { + this.status = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SubcellularLocationType.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SubcellularLocationType.java new file mode 100644 index 000000000..97b9dd49d --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/SubcellularLocationType.java @@ -0,0 +1,142 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + + +/** + * Describes the subcellular location and optionally the topology and orientation of a molecule. + * + *

Java class for subcellularLocationType complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType name="subcellularLocationType">
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element name="location" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded"/>
+ *         <element name="topology" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+ *         <element name="orientation" type="{https://uniprot.org/uniprot}evidencedStringType" maxOccurs="unbounded" minOccurs="0"/>
+ *       </sequence>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "subcellularLocationType", propOrder = { + "location", + "topology", + "orientation" +}) +public class SubcellularLocationType { + + @XmlElement(required = true) + protected List location; + protected List topology; + protected List orientation; + + /** + * Gets the value of the location property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the location property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getLocation().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getLocation() { + if (location == null) { + location = new ArrayList(); + } + return this.location; + } + + /** + * Gets the value of the topology property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the topology property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getTopology().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getTopology() { + if (topology == null) { + topology = new ArrayList(); + } + return this.topology; + } + + /** + * Gets the value of the orientation property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the orientation property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getOrientation().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link EvidencedStringType } + * + * + */ + public List getOrientation() { + if (orientation == null) { + orientation = new ArrayList(); + } + return this.orientation; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/Uniprot.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/Uniprot.java new file mode 100644 index 000000000..93e871edf --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/Uniprot.java @@ -0,0 +1,105 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + + +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; + +import java.util.ArrayList; +import java.util.List; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlType; + + +/** + *

Java class for anonymous complex type. + * + *

The following schema fragment specifies the expected content contained within this class. + * + *

+ * <complexType>
+ *   <complexContent>
+ *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       <sequence>
+ *         <element ref="{https://uniprot.org/uniprot}entry" maxOccurs="unbounded"/>
+ *         <element ref="{https://uniprot.org/uniprot}copyright" minOccurs="0"/>
+ *       </sequence>
+ *     </restriction>
+ *   </complexContent>
+ * </complexType>
+ * 
+ * + * + */ +@XmlAccessorType(XmlAccessType.FIELD) +@XmlType(name = "", propOrder = { + "entry", + "copyright" +}) +@XmlRootElement(name = "uniprot") +public class Uniprot { + + @XmlElement(required = true) + protected List entry; + protected String copyright; + + /** + * Gets the value of the entry property. + * + *

+ * This accessor method returns a reference to the live list, + * not a snapshot. Therefore any modification you make to the + * returned list will be present inside the JAXB object. + * This is why there is not a set method for the entry property. + * + *

+ * For example, to add a new item, do as follows: + *

+     *    getEntry().add(newItem);
+     * 
+ * + * + *

+ * Objects of the following type(s) are allowed in the list + * {@link Entry } + * + * + */ + public List getEntry() { + if (entry == null) { + entry = new ArrayList(); + } + return this.entry; + } + + /** + * Gets the value of the copyright property. + * + * @return + * possible object is + * {@link String } + * + */ + public String getCopyright() { + return copyright; + } + + /** + * Sets the value of the copyright property. + * + * @param value + * allowed object is + * {@link String } + * + */ + public void setCopyright(String value) { + this.copyright = value; + } + +} diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/package-info.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/package-info.java new file mode 100644 index 000000000..b41de4e5a --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/protein/uniprot/v202502jaxb/package-info.java @@ -0,0 +1,9 @@ +// +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 +// See http://java.sun.com/xml/jaxb +// Any modifications to this file will be lost upon recompilation of the source schema. +// Generated on: 2025.05.30 at 11:28:51 AM CEST +// + +@javax.xml.bind.annotation.XmlSchema(namespace = "https://uniprot.org/uniprot", elementFormDefault = javax.xml.bind.annotation.XmlNsForm.QUALIFIED) +package org.opencb.biodata.formats.protein.uniprot.v202502jaxb; diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/variant/civic/CivicParser.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/variant/civic/CivicParser.java new file mode 100755 index 000000000..1cfb76747 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/variant/civic/CivicParser.java @@ -0,0 +1,423 @@ +/* + * + * + */ + +package org.opencb.biodata.formats.variant.civic; + +import org.apache.commons.lang3.StringUtils; +import org.apache.commons.lang3.tuple.ImmutablePair; +import org.apache.commons.lang3.tuple.Pair; +import org.opencb.biodata.formats.io.FileFormatException; +import org.opencb.biodata.models.core.civic.*; +import org.opencb.commons.utils.FileUtils; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.io.BufferedReader; +import java.io.IOException; +import java.io.InputStreamReader; +import java.nio.file.Path; +import java.util.*; + +public class CivicParser { + + private Path variantSummariesFile; + private Path featureSummariesFile; + private Path molecularProfileSummariesFile; + private Path assertionSummariesFile; + private Path clinicalEvidenceSummariesFile; + private String version; + private String assembly; + private CivicParserCallback callback; + + Map featuresMap; + Map evidencesMap; + Map assertionsMap; + Map profilesMap; + + Map> variantToProfilesMap; + + private static final Logger logger = LoggerFactory.getLogger(CivicParser.class); + + public CivicParser(Path variantSummariesFile, Path featureSummariesFile, Path molecularProfileSummariesFile, + Path assertionSummariesFile, Path clinicalEvidenceSummariesFile, String version, String assembly, + CivicParserCallback callback) { + this.variantSummariesFile = variantSummariesFile; + this.featureSummariesFile = featureSummariesFile; + this.molecularProfileSummariesFile = molecularProfileSummariesFile; + this.assertionSummariesFile = assertionSummariesFile; + this.clinicalEvidenceSummariesFile = clinicalEvidenceSummariesFile; + this.version = version; + this.assembly = assembly; + this.callback = callback; + + this.variantToProfilesMap = new HashMap<>(); + } + + public void parse() throws IOException, FileFormatException { + logger.info("Starting CIViC parsing with version {} for assembly {}", version, assembly); + + // Step 1: Parse features first + parseFeaturesFile(); + + // Step 2: Parse clinical evidence and link to molecular profiles + parseClinicalEvidencesFile(); + + // Step 3: Parse assertions and complete them with evidences + parseAssertionsFile(); + + // Step 4: Parse molecular profiles and complete them with assertions and evidences + parseMolecularProfilesFile(); + + // Step 5: Parse variants and build complete objects + parseVariantsFile(); + } + + private void parseFeaturesFile() throws IOException { + featuresMap = new HashMap<>(); + + try (BufferedReader reader = new BufferedReader(new InputStreamReader(FileUtils.newInputStream(featureSummariesFile)))) { + String line = reader.readLine(); // Skip header + + while ((line = reader.readLine()) != null) { + if (StringUtils.isNotBlank(line)) { + String[] fields = line.split("\t", -1); + CivicFeature feature = parseFeatureFields(fields); + featuresMap.put(feature.getFeatureId(), feature); + } + } + } + + logger.info("Parsed {} features", featuresMap.size()); + } + + private CivicFeature parseFeatureFields(String[] fields) { + return new CivicFeature() + .setFeatureId(getField(fields, 0)) + .setFeatureCivicUrl(getField(fields, 1)) + .setFeatureType(getField(fields, 2)) + .setName(getField(fields, 3)) + .setFeatureAliases(parseStringList(getField(fields, 4))) + .setDescription(getField(fields, 5)) + .setLastReviewDate(getField(fields, 6)) + .setFlagged(parseBoolean(getField(fields, 7))) + .setEntrezId(getField(fields, 8)) + .setNcitId(getField(fields, 9)) + .setFivePrimePartnerStatus(getField(fields, 10)) + .setThreePrimePartnerStatus(getField(fields, 11)) + .setFivePrimeGeneId(getField(fields, 12)) + .setFivePrimeGeneName(getField(fields, 13)) + .setFivePrimeGeneEntrezId(getField(fields, 14)) + .setThreePrimeGeneId(getField(fields, 15)) + .setThreePrimeGeneName(getField(fields, 16)) + .setThreePrimeGeneEntrezId(getField(fields, 17)); + } + + private void parseClinicalEvidencesFile() throws IOException { + evidencesMap = new HashMap<>(); + + try (BufferedReader reader = new BufferedReader(new InputStreamReader(FileUtils.newInputStream(clinicalEvidenceSummariesFile)))) { + String line = reader.readLine(); // Skip header + + while ((line = reader.readLine()) != null) { + if (StringUtils.isNotBlank(line)) { + String[] fields = line.split("\t", -1); + CivicClinicalEvidence evidence = parseClinicalEvidenceFields(fields); + evidencesMap.put(evidence.getEvidenceId(), evidence); + } + } + } + + logger.info("Parsed {} evidences", evidencesMap.size()); + } + + private CivicClinicalEvidence parseClinicalEvidenceFields(String[] fields) { + // 0 1 2 3 4 5 6 7 + // molecular_profile molecular_profile_id disease doid phenotypes therapies therapy_interaction_type evidence_type + // 8 9 10 11 12 13 14 15 + // evidence_direction evidence_level significance evidence_statement citation_id source_type asco_abstract_id citation + // 16 17 18 19 20 21 22 23 + // nct_ids rating evidence_status evidence_id variant_origin last_review_date evidence_civic_url molecular_profile_civic_url + // 24 + // is_flagged + return new CivicClinicalEvidence() + .setDisease(getField(fields, 2)) + .setDoid(getField(fields, 3)) + .setPhenotypes(parseStringList(getField(fields, 4))) + .setTherapies(parseStringList(getField(fields, 5))) + .setTherapyInteractionType(getField(fields, 6)) + .setEvidenceType(getField(fields, 7)) + .setEvidenceDirection(getField(fields, 8)) + .setEvidenceLevel(getField(fields, 9)) + .setSignificance(getField(fields, 10)) + .setEvidenceStatement(getField(fields, 11)) + .setCitationId(getField(fields, 12)) + .setSourceType(getField(fields, 13)) + .setAscoAbstractId(getField(fields, 14)) + .setCitation(getField(fields, 15)) + .setNctIds(parseStringList(getField(fields, 16))) + .setRating(getField(fields, 17)) + .setEvidenceStatus(getField(fields, 18)) + .setEvidenceId(getField(fields, 19)) + .setVariantOrigin(getField(fields, 20)) + .setLastReviewDate(getField(fields, 21)) + .setEvidenceCivicUrl(getField(fields, 22)) + .setFlagged(parseBoolean(getField(fields, 24))); + } + + private void parseAssertionsFile() throws IOException { + assertionsMap = new HashMap<>(); + + try (BufferedReader reader = new BufferedReader(new InputStreamReader(FileUtils.newInputStream(assertionSummariesFile)))) { + String line = reader.readLine(); // Skip header + + while ((line = reader.readLine()) != null) { + if (StringUtils.isNotBlank(line)) { + String[] fields = line.split("\t", -1); + CivicAssertion assertion = parseAssertionFields(fields); + + // Set evidences from evidence map using the evidence IDs in the assertion + List evidenceIds = parseStringList(getField(fields, 18)); + for (String evidenceId : evidenceIds) { + if (evidencesMap.containsKey(evidenceId)) { + assertion.getEvidences().add(evidencesMap.get(evidenceId)); + } + } + + assertionsMap.put(assertion.getAssertionId(), assertion); + } + } + } + + logger.info("Parsed {} assertions and complete with evidences", assertionsMap.size()); + } + + private CivicAssertion parseAssertionFields(String[] fields) { + return new CivicAssertion() + .setDisease(getField(fields, 2)) + .setDoid(getField(fields, 3)) + .setPhenotypes(parseStringList(getField(fields, 4))) + .setTherapies(parseStringList(getField(fields, 5))) + .setAssertionType(getField(fields, 6)) + .setAssertionDirection(getField(fields, 7)) + .setSignificance(getField(fields, 8)) + .setAcmgCodes(parseStringList(getField(fields, 9))) + .setAmpCategory(getField(fields, 10)) + .setNccnGuideline(getField(fields, 11)) + .setNccnGuidelineVersion(getField(fields, 12)) + .setRegulatoryApproval(getField(fields, 13)) + .setFdaCompanionTest(getField(fields, 14)) + .setAssertionSummary(getField(fields, 15)) + .setAssertionDescription(getField(fields, 16)) + .setAssertionId(getField(fields, 17)) + .setLastReviewDate(getField(fields, 19)) + .setAssertionCivicUrl(getField(fields, 20)) + .setFlagged(parseBoolean(getField(fields, 23))); + } + + private void parseMolecularProfilesFile() throws IOException { + profilesMap = new HashMap<>(); + + try (BufferedReader reader = new BufferedReader(new InputStreamReader(FileUtils.newInputStream(molecularProfileSummariesFile)))) { + String line = reader.readLine(); // Skip header + + while ((line = reader.readLine()) != null) { + if (StringUtils.isNotBlank(line)) { + String[] fields = line.split("\t", -1); + CivicMolecularProfile profile = parseMolecularProfileFields(fields); + + // Set evidences from evidence map using the evidence IDs in the molecular profile + List evidenceIds = parseStringList(getField(fields, 6)); + for (String evidenceId : evidenceIds) { + if (evidencesMap.containsKey(evidenceId)) { + profile.getEvidences().add(evidencesMap.get(evidenceId)); + } + } + + // Set assertions from assertion map using the assertion IDs in the molecular profile + List assertionIds = parseStringList(getField(fields, 8)); + for (String assertionId : assertionIds) { + if (assertionsMap.containsKey(assertionId)) { + profile.getAssertions().add(assertionsMap.get(assertionId)); + } + } + + profilesMap.put(profile.getMolecularProfileId(), profile); + + // Add to the variant to profiles map + // This is necessary because there are situations that a given profile is not include in the VariantSummaries.tsv file + // but in the MolecularProfilesSummarie.tsv file (usually when the profile includes multiple variants) + List variantIds = parseStringList(getField(fields, 3)); + for (String variantId : variantIds) { + if (!variantToProfilesMap.containsKey(variantId)) { + variantToProfilesMap.put(variantId, new HashSet<>()); + } + variantToProfilesMap.get(variantId).add(profile.getMolecularProfileId()); + } + } + } + } + + logger.info("Parsed {} molecular profiles and complete with assertions and evidences", profilesMap.size()); + } + + private CivicMolecularProfile parseMolecularProfileFields(String[] fields) { + // 0 1 2 3 4 5 6 7 + // name molecular_profile_id summary variant_ids variants_civic_url evidence_score evidence_item_ids evidence_items_civic_url + // 8 9 10 11 12 + // assertion_ids assertions_civic_url aliases last_review_date is_flagged + return new CivicMolecularProfile() + .setName(getField(fields, 0)) + .setMolecularProfileId(getField(fields, 1)) + .setSummary(getField(fields, 2)) + .setEvidenceScore(getField(fields, 5)) + .setAliases(parseStringList(getField(fields, 10))) + .setLastReviewDate(getField(fields, 11)) + .setFlagged(parseBoolean(getField(fields, 12))); + } + + private void parseVariantsFile() throws IOException { + int totalVariants = 0; + int numVariants = 0; + int numVariantsSkippedByAssemblyEmpty = 0; + int numVariantsSkippedByAssemblyMismatch = 0; + + try (BufferedReader reader = new BufferedReader(new InputStreamReader(FileUtils.newInputStream(variantSummariesFile)))) { + String line = reader.readLine(); // Skip header + + while ((line = reader.readLine()) != null) { + if (StringUtils.isNotBlank(line)) { + totalVariants++; + + String[] fields = line.split("\t", -1); + + // Filter by assembly + String variantAssembly = getField(fields, 22); + if (StringUtils.isEmpty(variantAssembly)) { + numVariantsSkippedByAssemblyEmpty++; + logger.warn("Skipping variant ID {} due to assembly is empty", getField(fields, 0)); + continue; + } + if (!assembly.equalsIgnoreCase(variantAssembly)) { + numVariantsSkippedByAssemblyMismatch++; + logger.warn("Skipping variant ID {} due to assembly mismatch: expected {}, found {}", getField(fields, 0), + assembly, variantAssembly); + continue; + } + + CivicVariant variant = parseVariantFields(fields); + + // Link feature and enhance with transcript/exon info + String featureId = getField(fields, 3); + if (featuresMap.containsKey(featureId)) { + CivicFeature feature = featuresMap.get(featureId); + // Enhance feature with transcript/exon information from variant file + feature.setFivePrimeTranscript(getField(fields, 32)) + .setFivePrimeEndExon(getField(fields, 33)) + .setFivePrimeExonOffset(getField(fields, 34)) + .setFivePrimeExonOffsetDirection(getField(fields, 35)) + .setThreePrimeTranscript(getField(fields, 36)) + .setThreePrimeStartExon(getField(fields, 37)) + .setThreePrimeExonOffset(getField(fields, 38)) + .setThreePrimeExonOffsetDirection(getField(fields, 39)); + + variant.setFeature(feature); + } + + // Link molecular profiles from profiles map using the single variant molecular profile ID + String singleVariantMolecularProfileId = getField(fields, 11); + if (StringUtils.isNotEmpty(singleVariantMolecularProfileId)) { + if (!variantToProfilesMap.containsKey(variant.getVariantId())) { + variantToProfilesMap.put(variant.getVariantId(), new HashSet<>()); + } + variantToProfilesMap.get(variant.getVariantId()).add(singleVariantMolecularProfileId); + } + + // Iterate the list of molecular profile IDs associated to the variant and link the profilesfrom the profiles map + List profileIds = new ArrayList<>(variantToProfilesMap.get(variant.getVariantId())); + for (String profileId : profileIds) { + if (profilesMap.containsKey(profileId)) { + variant.getMolecularProfiles().add(profilesMap.get(profileId)); + } + } + + // Process variant through callback + if (callback.processCivicVariant(variant)) { + numVariants++; + } else { + // Add warning to log and continue the parsing + logger.warn("CIViC parsing callback returned false for variant ID: {}", variant.getVariantId()); + } + } + } + } + + logger.info("Parsed {} variants, {} passed the callback filter", totalVariants, numVariants); + logger.info("Skipped {} variants due to empty assembly", numVariantsSkippedByAssemblyEmpty); + logger.info("Skipped {} variants due to assembly mismatch", numVariantsSkippedByAssemblyMismatch); + } + + private static CivicVariant parseVariantFields(String[] fields) { + return new CivicVariant() + .setVariantId(getField(fields, 0)) + .setVariantCivicUrl(getField(fields, 1)) + .setVariant(getField(fields, 6)) + .setVariantAliases(parseStringList(getField(fields, 7))) + .setFlagged(parseBoolean(getField(fields, 8))) + .setVariantGroups(parseStringList(getField(fields, 9))) + .setVariantTypes(parseStringList(getField(fields, 10))) + .setLastReviewDate(getField(fields, 12)) + .setGene(getField(fields, 13)) + .setEntrezId(getField(fields, 14)) + .setChromosome(getField(fields, 15)) + .setStart(getField(fields, 16)) + .setStop(getField(fields, 17)) + .setReferenceBases(getField(fields, 18)) + .setVariantBases(getField(fields, 19)) + .setRepresentativeTranscript(getField(fields, 20)) + .setEnsemblVersion(getField(fields, 21)) + .setReferenceBuild(getField(fields, 22)) + .setHgvsDescriptions(parseStringList(getField(fields, 23))) + .setAlleleRegistryId(getField(fields, 24)) + .setClinvarIds(parseStringList(getField(fields, 25))) + .setNcitId(getField(fields, 26)) + .setViccCompliantName(getField(fields, 31)); + } + + // Helper methods + private static String getField(String[] fields, int index) { + if (index < fields.length && StringUtils.isNotBlank(fields[index])) { + return fields[index]; + } + return null; + } + + private static Boolean parseBoolean(String value) { + if (StringUtils.isNotBlank(value)) { + return "true".equalsIgnoreCase(value) || "1".equals(value); + } + return null; + } + + private static List parseStringList(String value) { + if (StringUtils.isNotBlank(value)) { + return Arrays.asList(value.split(",\\s*")); + } + return new ArrayList<>(); + } +} \ No newline at end of file diff --git a/biodata-formats/src/main/java/org/opencb/biodata/formats/variant/civic/CivicParserCallback.java b/biodata-formats/src/main/java/org/opencb/biodata/formats/variant/civic/CivicParserCallback.java new file mode 100644 index 000000000..e517baff0 --- /dev/null +++ b/biodata-formats/src/main/java/org/opencb/biodata/formats/variant/civic/CivicParserCallback.java @@ -0,0 +1,7 @@ +package org.opencb.biodata.formats.variant.civic; + +import org.opencb.biodata.models.core.civic.CivicVariant; + +public interface CivicParserCallback { + boolean processCivicVariant(CivicVariant civicVariant); +} diff --git a/biodata-formats/src/test/java/org/opencb/biodata/formats/feature/chimerdb/ChimerDbParserTest.java b/biodata-formats/src/test/java/org/opencb/biodata/formats/feature/chimerdb/ChimerDbParserTest.java new file mode 100644 index 000000000..b89419f82 --- /dev/null +++ b/biodata-formats/src/test/java/org/opencb/biodata/formats/feature/chimerdb/ChimerDbParserTest.java @@ -0,0 +1,46 @@ +package org.opencb.biodata.formats.feature.chimerdb; + + +import org.junit.Assert; +import org.opencb.biodata.models.core.GeneFusion; +import org.opencb.biodata.models.core.chimerdb.ChimerKb; + +import java.io.IOException; +import java.nio.file.Path; +import java.nio.file.Paths; + +public class ChimerDbParserTest { + + public void testParse() throws IOException { + Path xlsxPath = Paths.get(getClass().getResource("/ChimerKB4.small.xlsx").getPath()); + + ChimerDbParserTest.MyCallback callback = new ChimerDbParserTest.MyCallback(">>> Testing message"); + + ChimerKbParser.parse(xlsxPath, callback); + Assert.assertEquals(50, callback.getGeneFusions().getChimerKb().size()); + } + + // Implementation of the MirBaseParserCallback function + public class MyCallback implements ChimerDbParserCallback { + private String msg; + private GeneFusion geneFusions; + + public MyCallback(String msg) { + this.msg = msg; + this.geneFusions = new GeneFusion(); + } + + @Override + public boolean processChimerDbObject(ChimerKb chimerKb) { + System.out.println(msg); + System.out.println(chimerKb.toString()); + geneFusions.getChimerKb().add(chimerKb); + return true; + } + + public GeneFusion getGeneFusions() { + return geneFusions; + } + } + +} \ No newline at end of file diff --git a/biodata-formats/src/test/java/org/opencb/biodata/formats/feature/mirbase/MirBaseParserTest.java b/biodata-formats/src/test/java/org/opencb/biodata/formats/feature/mirbase/MirBaseParserTest.java new file mode 100644 index 000000000..162e5d5b1 --- /dev/null +++ b/biodata-formats/src/test/java/org/opencb/biodata/formats/feature/mirbase/MirBaseParserTest.java @@ -0,0 +1,105 @@ +package org.opencb.biodata.formats.feature.mirbase; + +import org.junit.Assert; +import org.junit.Test; +import org.opencb.biodata.models.core.MiRnaGene; +import org.opencb.biodata.models.core.MiRnaMature; + +import java.io.IOException; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.ArrayList; +import java.util.List; + +public class MirBaseParserTest { + + + + // Implementation of the MirBaseParserCallback function + public class MyCallback implements MirBaseParserCallback { + private String msg; + private List miRnaGenes; + + public MyCallback(String msg) { + this.msg = msg; + this.miRnaGenes = new ArrayList<>(); + } + + @Override + public boolean processMiRnaGene(MiRnaGene miRnaGene) { + System.out.println(msg); + System.out.println(miRnaGene.toString()); + miRnaGenes.add(miRnaGene); + return true; + } + + public List getMiRnaGenes() { + return miRnaGenes; + } + + public MiRnaGene getMiRnaGene(String accession) { + for (MiRnaGene miRnaGene : miRnaGenes) { + if (accession.equals(miRnaGene.getAccession())) { + return miRnaGene; + } + } + return null; + } + + public int getCounter() { + return miRnaGenes.size(); + } + } + + @Test + public void testMirBaseParser() throws IOException { + Path datFile = Paths.get(getClass().getResource("/miRNA.small.dat.gz").getPath()); + + MyCallback callback = new MyCallback(">>> Testing message"); + + MirBaseParser.parse(datFile, "Homo sapiens", callback); + Assert.assertEquals(50, callback.getCounter()); + + MiRnaGene mi0000060 = callback.getMiRnaGene("MI0000060"); + Assert.assertEquals("hsa-let-7a-1", mi0000060.getId()); + Assert.assertEquals("ugggaUGAGGUAGUAGGUUGUAUAGUUuuagggucacacccaccacugggagauaaCUAUACAAUCUACUGUCUUUCcua".toUpperCase(), mi0000060.getSequence().toUpperCase()); + int found = 0; + for (MiRnaMature mature : mi0000060.getMatures()) { + if ("MIMAT0000062".equals(mature.getAccession())) { + found++; + Assert.assertEquals("hsa-let-7a-5p", mature.getId()); + Assert.assertEquals("UGAGGUAGUAGGUUGUAUAGUU".toUpperCase(), mature.getSequence().toUpperCase()); + Assert.assertEquals(6, mature.getStart()); + Assert.assertEquals(27, mature.getEnd()); + } else if ("MIMAT0004481".equals(mature.getAccession())) { + found++; + Assert.assertEquals("hsa-let-7a-3p", mature.getId()); + Assert.assertEquals("CUAUACAAUCUACUGUCUUUC".toUpperCase(), mature.getSequence().toUpperCase()); + Assert.assertEquals(57, mature.getStart()); + Assert.assertEquals(77, mature.getEnd()); + } + } + Assert.assertEquals(2, found); + + MiRnaGene mi0000077 = callback.getMiRnaGene("MI0000077"); + Assert.assertEquals("hsa-mir-21", mi0000077.getId()); + Assert.assertEquals("ugucgggUAGCUUAUCAGACUGAUGUUGAcuguugaaucucauggCAACACCAGUCGAUGGGCUGUcugaca".toUpperCase(), mi0000077.getSequence().toUpperCase()); + found = 0; + for (MiRnaMature mature : mi0000077.getMatures()) { + if ("MIMAT0000076".equals(mature.getAccession())) { + found++; + Assert.assertEquals("hsa-miR-21-5p", mature.getId()); + Assert.assertEquals("UAGCUUAUCAGACUGAUGUUGA".toUpperCase(), mature.getSequence().toUpperCase()); + Assert.assertEquals(8, mature.getStart()); + Assert.assertEquals(29, mature.getEnd()); + } else if ("MIMAT0004494".equals(mature.getAccession())) { + found++; + Assert.assertEquals("hsa-miR-21-3p", mature.getId()); + Assert.assertEquals("CAACACCAGUCGAUGGGCUGU".toUpperCase(), mature.getSequence().toUpperCase()); + Assert.assertEquals(46, mature.getStart()); + Assert.assertEquals(66, mature.getEnd()); + } + } + Assert.assertEquals(2, found); + } +} \ No newline at end of file diff --git a/biodata-formats/src/test/java/org/opencb/biodata/formats/protein/uniprot/UniProtParserTest.java b/biodata-formats/src/test/java/org/opencb/biodata/formats/protein/uniprot/UniProtParserTest.java new file mode 100644 index 000000000..3344ff37c --- /dev/null +++ b/biodata-formats/src/test/java/org/opencb/biodata/formats/protein/uniprot/UniProtParserTest.java @@ -0,0 +1,22 @@ +package org.opencb.biodata.formats.protein.uniprot; + +import org.junit.Assert; +import org.junit.Test; +import org.opencb.biodata.formats.protein.uniprot.v202502jaxb.Uniprot; + +import javax.xml.bind.JAXBException; + +public class UniProtParserTest { + + @Test + public void testParse() throws JAXBException { + + String fullFilename = getClass().getResource("/uniprot-202502/uniprot-test.xml").getPath(); + + Uniprot uniprot = (Uniprot) UniProtParser.loadXMLInfo(fullFilename, UniProtParser.UNIPROT_202502_CONTEXT); + + System.out.println("fullFilename = " + fullFilename); + System.out.println("uniprot.getEntry().size() = " + uniprot.getEntry().size()); + Assert.assertEquals(1, uniprot.getEntry().size()); + } +} \ No newline at end of file diff --git a/biodata-formats/src/test/java/org/opencb/biodata/formats/variant/civic/CivicParserTest.java b/biodata-formats/src/test/java/org/opencb/biodata/formats/variant/civic/CivicParserTest.java new file mode 100644 index 000000000..5f55c35b8 --- /dev/null +++ b/biodata-formats/src/test/java/org/opencb/biodata/formats/variant/civic/CivicParserTest.java @@ -0,0 +1,69 @@ +package org.opencb.biodata.formats.variant.civic; + +import com.fasterxml.jackson.databind.ObjectMapper; +import org.junit.Assert; +import org.junit.Assume; +import org.junit.Test; +import org.opencb.biodata.formats.io.FileFormatException; +import org.opencb.biodata.models.core.civic.CivicVariant; + +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.ArrayList; +import java.util.List; + +public class CivicParserTest { + + // Implementation of the LineCallback function + public class MyCallback implements CivicParserCallback { + private String msg; + private List civicVariants; + + public MyCallback(String msg) { + this.msg = msg; + this.civicVariants = new ArrayList<>(); + } + + @Override + public boolean processCivicVariant(CivicVariant civicVariant) { + System.out.println(msg + ": CIViC ID = " + civicVariant.getVariantId() + ", position: " + civicVariant.getChromosome() + + ":" + civicVariant.getStart() + ":" + civicVariant.getReferenceBases() + ":" + civicVariant.getVariantBases()); + civicVariants.add(civicVariant); + return true; + } + + public List getCivicVariants() { + return civicVariants; + } + } + + @Test + public void testCivicParser() throws IOException, FileFormatException { + Path civicPath = Paths.get("/opt/civic-data/"); + Assume.assumeTrue(Files.exists(civicPath)); + + String assembly = "grch38"; + String version = "v1"; + Path variantSummariesFile = civicPath.resolve("01-Sep-2025-VariantSummaries.tsv"); + Path featureSummariesFile = civicPath.resolve("01-Sep-2025-FeatureSummaries.tsv"); + Path molecularProfileSummariesFile = civicPath.resolve("01-Sep-2025-MolecularProfileSummaries.tsv"); + Path assertionSummariesFile = civicPath.resolve("01-Sep-2025-AssertionSummaries.tsv"); + Path clinicalEvidenceSummariesFile = civicPath.resolve("01-Sep-2025-ClinicalEvidenceSummaries.tsv"); + + MyCallback callback = new MyCallback(">>> Testing message"); + + CivicParser parser = new CivicParser(variantSummariesFile, featureSummariesFile, molecularProfileSummariesFile, + assertionSummariesFile, clinicalEvidenceSummariesFile, version, assembly, callback); + + parser.parse(); + List civicVariants = callback.getCivicVariants(); + + // Only 2 variants are GRCh38 + Assert.assertEquals(2, civicVariants.size()); + for (CivicVariant civicVariant : civicVariants) { + System.out.println(new ObjectMapper().writerFor(CivicVariant.class).writeValueAsString(civicVariant)); + } + } +} \ No newline at end of file diff --git a/biodata-formats/src/test/resources/ChimerKB4.small.xlsx b/biodata-formats/src/test/resources/ChimerKB4.small.xlsx new file mode 100644 index 000000000..99f979804 Binary files /dev/null and b/biodata-formats/src/test/resources/ChimerKB4.small.xlsx differ diff --git a/biodata-formats/src/test/resources/miRNA.small.dat.gz b/biodata-formats/src/test/resources/miRNA.small.dat.gz new file mode 100644 index 000000000..3d0fec10c Binary files /dev/null and b/biodata-formats/src/test/resources/miRNA.small.dat.gz differ diff --git a/biodata-formats/src/test/resources/uniprot-202502/uniprot-test.xml b/biodata-formats/src/test/resources/uniprot-202502/uniprot-test.xml new file mode 100644 index 000000000..b39ad575e --- /dev/null +++ b/biodata-formats/src/test/resources/uniprot-202502/uniprot-test.xml @@ -0,0 +1,118 @@ + + + + Q49VE6 + Y2119_STAS1 + + + UPF0741 protein SSP2119 + + + + SSP2119 + + + Staphylococcus saprophyticus subsp. saprophyticus (strain ATCC 15305 / DSM 20229 / NCIMB 8711 / NCTC 7292 / S-41) + + + Bacteria + Bacillati + Bacillota + Bacilli + Bacillales + Staphylococcaceae + Staphylococcus + + + + + Whole genome sequence of Staphylococcus saprophyticus reveals the pathogenesis of uncomplicated urinary tract infection. + + + + + + + + + + + + + + + + + + + NUCLEOTIDE SEQUENCE [LARGE SCALE GENOMIC DNA] + + ATCC 15305 / DSM 20229 / NCIMB 8711 / NCTC 7292 / S-41 + + + + Belongs to the UPF0741 family. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Coiled coil + Reference proteome + + + + + + + + + + + + + + + + + + + + + + + + + + + + + MQNKFLICDDCQGVNCKSLEKKLTKLDPEAEIEIGCQSYCGPGRRKTFAFVNNRPLAALTEDELMEKVEKQLQKPRDHEEEERLRKRNEERKRRKEEQDRKLKEKLAQRKHK + + \ No newline at end of file diff --git a/biodata-models/src/main/avro/variantAnnotation.avdl b/biodata-models/src/main/avro/variantAnnotation.avdl index 320c38efe..5c07a42c2 100644 --- a/biodata-models/src/main/avro/variantAnnotation.avdl +++ b/biodata-models/src/main/avro/variantAnnotation.avdl @@ -55,6 +55,35 @@ protocol VariantAnnotations { string source; } + record GeneImprinting { + string geneName; + string status; + string expressedAllele; + string source; + union { null, map } attributes; + } + + record GeneFusionBreakpoint { + string geneName; + string chromosome; + int position; + string strand; + } + + record GeneFusionSummary { + string pair; + string source; + union { null, GeneFusionBreakpoint } headGene; + union { null, GeneFusionBreakpoint } tailGene; + union { null, array } pmid; + union { null, array } diseases; + union { null, boolean } kinase; + union { null, boolean } oncogene; + union { null, boolean } tumorSuppresor; + union { null, boolean } receptor; + union { null, boolean } transcriptionFactor; + } + record PopulationFrequency { string study; string population; @@ -275,6 +304,31 @@ protocol VariantAnnotations { union { null, array } studies; } + record PubmedReference { + union { null, string } id; + union { null, string } title; + union { null, string } journal; + union { null, string } `date`; + union { null, string } url; + } + + record PolygenicScoreVariant { + union { null, string } effectAllele; + union { null, string } otherAllele; + union { null, map } values; + } + + record PolygenicScoreAnnotation { + union { null, string } id; + union { null, string } name; + union { null, string } source; + union { null, string } version; + union { null, array } traits; + union { null, array } pubmedReferences; + union { null, array> } values; + union { null, array } variants; + } + record CancerHotspotAlternateAnnotation { union { null, string } aminoacidAlternate; union { null, int } count; @@ -341,9 +395,12 @@ protocol VariantAnnotations { union { null, array } gwas; union { null, array } cancerHotspots; union { null, array } functionalScore; + union { null, array } polygenicScores; union { null, array } cytoband; union { null, array } repeat; union { null, array } drugs; + union { null, array } geneImprinting; + union { null, array } geneFusions; union { null, map } additionalAttributes = null; } diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/GeneAnnotation.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/GeneAnnotation.java index 376a0fc8c..6dce7c6ce 100644 --- a/biodata-models/src/main/java/org/opencb/biodata/models/core/GeneAnnotation.java +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/GeneAnnotation.java @@ -19,12 +19,9 @@ package org.opencb.biodata.models.core; -import org.opencb.biodata.models.variant.avro.Expression; -import org.opencb.biodata.models.variant.avro.GeneDrugInteraction; -import org.opencb.biodata.models.variant.avro.GeneTraitAssociation; -import org.opencb.biodata.models.variant.avro.Constraint; - +import org.opencb.biodata.models.variant.avro.*; +import java.util.ArrayList; import java.util.List; @@ -37,34 +34,46 @@ public class GeneAnnotation { private List mirnaTargets; private List cancerAssociations; private List cancerHotspots; + private List geneImprinting; + private GeneFusion geneFusions; public GeneAnnotation() { + this.expression = new ArrayList<>(); + this.diseases = new ArrayList<>(); + this.drugs = new ArrayList<>(); + this.constraints = new ArrayList<>(); + this.mirnaTargets = new ArrayList<>(); + this.cancerAssociations = new ArrayList<>(); + this.cancerHotspots = new ArrayList<>(); + this.geneImprinting = new ArrayList<>(); + this.geneFusions = new GeneFusion(); } @Deprecated public GeneAnnotation(List expression, List diseases, List drugs, List constraints, List mirnaTargets) { - this.expression = expression; - this.diseases = diseases; - this.drugs = drugs; - this.constraints = constraints; - this.mirnaTargets = mirnaTargets; + this(expression, diseases, drugs, constraints, mirnaTargets, new ArrayList<>(), new ArrayList<>(), new ArrayList<>(), + new GeneFusion()); } @Deprecated public GeneAnnotation(List expression, List diseases, List drugs, List constraints, List mirnaTargets, List cancerAssociations) { - this.expression = expression; - this.diseases = diseases; - this.drugs = drugs; - this.constraints = constraints; - this.mirnaTargets = mirnaTargets; - this.cancerAssociations = cancerAssociations; + this(expression, diseases, drugs, constraints, mirnaTargets, cancerAssociations, new ArrayList<>(), new ArrayList<>(), + new GeneFusion()); } + @Deprecated public GeneAnnotation(List expression, List diseases, List drugs, List constraints, List mirnaTargets, List cancerAssociations, List cancerHotspots) { + this(expression, diseases, drugs, constraints, mirnaTargets, cancerAssociations, cancerHotspots, new ArrayList<>(), + new GeneFusion()); + } + + public GeneAnnotation(List expression, List diseases, List drugs, + List constraints, List mirnaTargets, List cancerAssociations, + List cancerHotspots, List geneImprinting, GeneFusion geneFusions) { this.expression = expression; this.diseases = diseases; this.drugs = drugs; @@ -72,6 +81,8 @@ public GeneAnnotation(List expression, List di this.mirnaTargets = mirnaTargets; this.cancerAssociations = cancerAssociations; this.cancerHotspots = cancerHotspots; + this.geneImprinting = geneImprinting; + this.geneFusions = geneFusions; } @Override @@ -84,6 +95,8 @@ public String toString() { sb.append(", mirnaTargets=").append(mirnaTargets); sb.append(", cancerAssociations=").append(cancerAssociations); sb.append(", cancerHotspots=").append(cancerHotspots); + sb.append(", geneImprinting=").append(geneImprinting); + sb.append(", geneFusions=").append(geneFusions); sb.append('}'); return sb.toString(); } @@ -150,4 +163,22 @@ public GeneAnnotation setCancerHotspots(List cancerHotspots) { this.cancerHotspots = cancerHotspots; return this; } + + public List getGeneImprinting() { + return geneImprinting; + } + + public GeneAnnotation setGeneImprinting(List geneImprinting) { + this.geneImprinting = geneImprinting; + return this; + } + + public GeneFusion getGeneFusions() { + return geneFusions; + } + + public GeneAnnotation setGeneFusions(GeneFusion geneFusions) { + this.geneFusions = geneFusions; + return this; + } } diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/GeneFusion.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/GeneFusion.java new file mode 100644 index 000000000..bc30b355f --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/GeneFusion.java @@ -0,0 +1,83 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core; + +import org.opencb.biodata.models.core.chimerdb.ChimerKb; +import org.opencb.biodata.models.core.chimerdb.ChimerPub; +import org.opencb.biodata.models.core.chimerdb.ChimerSeq; + +import java.util.ArrayList; +import java.util.List; + +public class GeneFusion { + + private List chimerKb; + private List chimerPub; + private List chimerSeq; + + public GeneFusion() { + this.chimerKb = new ArrayList<>(); + this.chimerPub = new ArrayList<>(); + this.chimerSeq = new ArrayList<>(); + } + + public GeneFusion(List chimerKb, List chimerPub, List chimerSeq) { + this.chimerKb = chimerKb; + this.chimerPub = chimerPub; + this.chimerSeq = chimerSeq; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("GeneFusion{"); + sb.append("chimerKb=").append(chimerKb); + sb.append(", chimerPub=").append(chimerPub); + sb.append(", chimerSeq=").append(chimerSeq); + sb.append('}'); + return sb.toString(); + } + + public List getChimerKb() { + return chimerKb; + } + + public GeneFusion setChimerKb(List chimerKb) { + this.chimerKb = chimerKb; + return this; + } + + public List getChimerPub() { + return chimerPub; + } + + public GeneFusion setChimerPub(List chimerPub) { + this.chimerPub = chimerPub; + return this; + } + + public List getChimerSeq() { + return chimerSeq; + } + + public GeneFusion setChimerSeq(List chimerSeq) { + this.chimerSeq = chimerSeq; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/MiRnaGene.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/MiRnaGene.java index 482ccda69..e31a5bfa0 100644 --- a/biodata-models/src/main/java/org/opencb/biodata/models/core/MiRnaGene.java +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/MiRnaGene.java @@ -40,7 +40,7 @@ public class MiRnaGene { private List matures; public MiRnaGene() { - + matures = new ArrayList<>(); } public MiRnaGene(String accession, String id, String status, String sequence, List matures) { diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/ProteinSubstitutionPrediction.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/ProteinSubstitutionPrediction.java new file mode 100644 index 000000000..995234520 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/ProteinSubstitutionPrediction.java @@ -0,0 +1,163 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core; + +import java.util.ArrayList; +import java.util.List; + +public class ProteinSubstitutionPrediction { + + private String chromosome; + private int position; + private String reference; + private String transcriptId; + private String uniprotId; + private int aaPosition; + private String aaReference; + private String source; + private String version; + private List scores; + + public ProteinSubstitutionPrediction() { + this.scores = new ArrayList<>(); + } + + public ProteinSubstitutionPrediction(String chromosome, int position, String reference, String transcriptId, String uniprotId, + int aaPosition, String aaReference, String source, String version, + List scores) { + this.chromosome = chromosome; + this.position = position; + this.reference = reference; + this.transcriptId = transcriptId; + this.uniprotId = uniprotId; + this.aaPosition = aaPosition; + this.aaReference = aaReference; + this.source = source; + this.version = version; + this.scores = scores; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("ProteinSubstitutionPrediction{"); + sb.append("chromosome='").append(chromosome).append('\''); + sb.append(", position=").append(position); + sb.append(", reference='").append(reference).append('\''); + sb.append(", transcriptId='").append(transcriptId).append('\''); + sb.append(", uniprotId='").append(uniprotId).append('\''); + sb.append(", aaPosition=").append(aaPosition); + sb.append(", aaReference='").append(aaReference).append('\''); + sb.append(", source='").append(source).append('\''); + sb.append(", version='").append(version).append('\''); + sb.append(", scores=").append(scores); + sb.append('}'); + return sb.toString(); + } + + public String getChromosome() { + return chromosome; + } + + public ProteinSubstitutionPrediction setChromosome(String chromosome) { + this.chromosome = chromosome; + return this; + } + + public int getPosition() { + return position; + } + + public ProteinSubstitutionPrediction setPosition(int position) { + this.position = position; + return this; + } + + public String getReference() { + return reference; + } + + public ProteinSubstitutionPrediction setReference(String reference) { + this.reference = reference; + return this; + } + + public String getTranscriptId() { + return transcriptId; + } + + public ProteinSubstitutionPrediction setTranscriptId(String transcriptId) { + this.transcriptId = transcriptId; + return this; + } + + public String getUniprotId() { + return uniprotId; + } + + public ProteinSubstitutionPrediction setUniprotId(String uniprotId) { + this.uniprotId = uniprotId; + return this; + } + + public int getAaPosition() { + return aaPosition; + } + + public ProteinSubstitutionPrediction setAaPosition(int aaPosition) { + this.aaPosition = aaPosition; + return this; + } + + public String getAaReference() { + return aaReference; + } + + public ProteinSubstitutionPrediction setAaReference(String aaReference) { + this.aaReference = aaReference; + return this; + } + + public String getSource() { + return source; + } + + public ProteinSubstitutionPrediction setSource(String source) { + this.source = source; + return this; + } + + public String getVersion() { + return version; + } + + public ProteinSubstitutionPrediction setVersion(String version) { + this.version = version; + return this; + } + + public List getScores() { + return scores; + } + + public ProteinSubstitutionPrediction setScores(List scores) { + this.scores = scores; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/ProteinSubstitutionPredictionScore.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/ProteinSubstitutionPredictionScore.java new file mode 100644 index 000000000..671ac0402 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/ProteinSubstitutionPredictionScore.java @@ -0,0 +1,85 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core; + +public class ProteinSubstitutionPredictionScore { + + private String alternate; + private String aaAlternate; + private double score; + private String effect; + + public ProteinSubstitutionPredictionScore() { + } + + public ProteinSubstitutionPredictionScore(String alternate, String aaAlternate, double score, String effect) { + this.alternate = alternate; + this.aaAlternate = aaAlternate; + this.score = score; + this.effect = effect; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("ProteinSubstitutionPredictionScore{"); + sb.append("alternate='").append(alternate).append('\''); + sb.append(", aaAlternate='").append(aaAlternate).append('\''); + sb.append(", score=").append(score); + sb.append(", effect='").append(effect).append('\''); + sb.append('}'); + return sb.toString(); + } + + public String getAlternate() { + return alternate; + } + + public ProteinSubstitutionPredictionScore setAlternate(String alternate) { + this.alternate = alternate; + return this; + } + + public String getAaAlternate() { + return aaAlternate; + } + + public ProteinSubstitutionPredictionScore setAaAlternate(String aaAlternate) { + this.aaAlternate = aaAlternate; + return this; + } + + public double getScore() { + return score; + } + + public ProteinSubstitutionPredictionScore setScore(double score) { + this.score = score; + return this; + } + + public String getEffect() { + return effect; + } + + public ProteinSubstitutionPredictionScore setEffect(String effect) { + this.effect = effect; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerKb.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerKb.java new file mode 100644 index 000000000..6dad082aa --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerKb.java @@ -0,0 +1,386 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core.chimerdb; + +import java.util.ArrayList; +import java.util.List; + +public class ChimerKb { + + public static final String SOURCE = "chimerkb"; + + // 0 1 2 3 4 5 6 7 8 9 10 + // id ChimerDB_Type Source webSource Fusion_pair 5Gene_Junction 3Gene_Junction H_gene H_chr H_position H_strand + // 11 12 13 14 15 16 17 18 + // T_gene T_chr T_position T_strand Genomic_breakpoint Exonic_breakpoint Breakpoint_Type Genome_Build_Version + // 19 20 21 22 23 24 25 26 27 28 + // PMID Disease Validation Frame Chr_info Kinase Oncogene Tumor_suppressor Receptor Transcription_Factor + // 29 30 31 + // ChimerPub ChimerSeq ChimerSeq+ + + private String id; + private String chimerDbType; + private String chimerSource; + private String webSource; + private String fusionPair; + private String fiveGeneJunction; + private String threeGeneJunction; + private ChimerKbGeneBreakpoint headGene; + private ChimerKbGeneBreakpoint tailGene; + private boolean genomicBreakpoint; + private boolean exonicBreakpoint; + private String breakpointType; + private String genomeBuildVersion; + private List pmid; + private List diseases; + private List validations; + private String frame; + private String chrInfo; + private boolean kinase; + private boolean oncogene; + private boolean tumorSuppressor; + private boolean receptor; + private boolean transcriptionFactor; + private boolean chimerPub; + private boolean chimerSeq; + private boolean chimerSeqPlus; + + private String source; + + public ChimerKb() { + this.pmid = new ArrayList<>(); + this.diseases = new ArrayList<>(); + this.validations = new ArrayList<>(); + + this.source = SOURCE; + } + + public ChimerKb(String id, String chimerDbType, String chimerSource, String webSource, String fusionPair, String fiveGeneJunction, + String threeGeneJunction, ChimerKbGeneBreakpoint headGene, ChimerKbGeneBreakpoint tailGene, boolean genomicBreakpoint, + boolean exonicBreakpoint, String breakpointType, String genomeBuildVersion, List pmid, List diseases, + List validations, String frame, String chrInfo, boolean kinase, boolean oncogene, boolean tumorSuppressor, + boolean receptor, boolean transcriptionFactor, boolean chimerPub, boolean chimerSeq, boolean chimerSeqPlus, + String source) { + this.id = id; + this.chimerDbType = chimerDbType; + this.chimerSource = chimerSource; + this.webSource = webSource; + this.fusionPair = fusionPair; + this.fiveGeneJunction = fiveGeneJunction; + this.threeGeneJunction = threeGeneJunction; + this.headGene = headGene; + this.tailGene = tailGene; + this.genomicBreakpoint = genomicBreakpoint; + this.exonicBreakpoint = exonicBreakpoint; + this.breakpointType = breakpointType; + this.genomeBuildVersion = genomeBuildVersion; + this.pmid = pmid; + this.diseases = diseases; + this.validations = validations; + this.frame = frame; + this.chrInfo = chrInfo; + this.kinase = kinase; + this.oncogene = oncogene; + this.tumorSuppressor = tumorSuppressor; + this.receptor = receptor; + this.transcriptionFactor = transcriptionFactor; + this.chimerPub = chimerPub; + this.chimerSeq = chimerSeq; + this.chimerSeqPlus = chimerSeqPlus; + this.source = source; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("ChimerKb{"); + sb.append("id='").append(id).append('\''); + sb.append(", chimerDbType='").append(chimerDbType).append('\''); + sb.append(", chimerSource='").append(chimerSource).append('\''); + sb.append(", webSource='").append(webSource).append('\''); + sb.append(", fusionPair='").append(fusionPair).append('\''); + sb.append(", fiveGeneJunction='").append(fiveGeneJunction).append('\''); + sb.append(", threeGeneJunction='").append(threeGeneJunction).append('\''); + sb.append(", headGene=").append(headGene); + sb.append(", tailGene=").append(tailGene); + sb.append(", genomicBreakpoint='").append(genomicBreakpoint).append('\''); + sb.append(", exonicBreakpoint='").append(exonicBreakpoint).append('\''); + sb.append(", breakpointType='").append(breakpointType).append('\''); + sb.append(", genomeBuildVersion='").append(genomeBuildVersion).append('\''); + sb.append(", pmid=").append(pmid); + sb.append(", diseases=").append(diseases); + sb.append(", validations=").append(validations); + sb.append(", frame='").append(frame).append('\''); + sb.append(", chrInfo='").append(chrInfo).append('\''); + sb.append(", kinase=").append(kinase); + sb.append(", oncogene=").append(oncogene); + sb.append(", tumorSuppressor=").append(tumorSuppressor); + sb.append(", receptor=").append(receptor); + sb.append(", transcriptionFactor=").append(transcriptionFactor); + sb.append(", chimerPub=").append(chimerPub); + sb.append(", chimerSeq=").append(chimerSeq); + sb.append(", chimerSeqPlus=").append(chimerSeqPlus); + sb.append(", source='").append(source).append('\''); + sb.append('}'); + return sb.toString(); + } + + public String getId() { + return id; + } + + public ChimerKb setId(String id) { + this.id = id; + return this; + } + + public String getChimerDbType() { + return chimerDbType; + } + + public ChimerKb setChimerDbType(String chimerDbType) { + this.chimerDbType = chimerDbType; + return this; + } + + public String getChimerSource() { + return chimerSource; + } + + public ChimerKb setChimerSource(String chimerSource) { + this.chimerSource = chimerSource; + return this; + } + + public String getWebSource() { + return webSource; + } + + public ChimerKb setWebSource(String webSource) { + this.webSource = webSource; + return this; + } + + public String getFusionPair() { + return fusionPair; + } + + public ChimerKb setFusionPair(String fusionPair) { + this.fusionPair = fusionPair; + return this; + } + + public String getFiveGeneJunction() { + return fiveGeneJunction; + } + + public ChimerKb setFiveGeneJunction(String fiveGeneJunction) { + this.fiveGeneJunction = fiveGeneJunction; + return this; + } + + public String getThreeGeneJunction() { + return threeGeneJunction; + } + + public ChimerKb setThreeGeneJunction(String threeGeneJunction) { + this.threeGeneJunction = threeGeneJunction; + return this; + } + + public ChimerKbGeneBreakpoint getHeadGene() { + return headGene; + } + + public ChimerKb setHeadGene(ChimerKbGeneBreakpoint headGene) { + this.headGene = headGene; + return this; + } + + public ChimerKbGeneBreakpoint getTailGene() { + return tailGene; + } + + public ChimerKb setTailGene(ChimerKbGeneBreakpoint tailGene) { + this.tailGene = tailGene; + return this; + } + + public boolean getGenomicBreakpoint() { + return genomicBreakpoint; + } + + public ChimerKb setGenomicBreakpoint(boolean genomicBreakpoint) { + this.genomicBreakpoint = genomicBreakpoint; + return this; + } + + public boolean getExonicBreakpoint() { + return exonicBreakpoint; + } + + public ChimerKb setExonicBreakpoint(boolean exonicBreakpoint) { + this.exonicBreakpoint = exonicBreakpoint; + return this; + } + + public String getBreakpointType() { + return breakpointType; + } + + public ChimerKb setBreakpointType(String breakpointType) { + this.breakpointType = breakpointType; + return this; + } + + public String getGenomeBuildVersion() { + return genomeBuildVersion; + } + + public ChimerKb setGenomeBuildVersion(String genomeBuildVersion) { + this.genomeBuildVersion = genomeBuildVersion; + return this; + } + + public List getPmid() { + return pmid; + } + + public ChimerKb setPmid(List pmid) { + this.pmid = pmid; + return this; + } + + public List getDiseases() { + return diseases; + } + + public ChimerKb setDiseases(List diseases) { + this.diseases = diseases; + return this; + } + + public List getValidations() { + return validations; + } + + public ChimerKb setValidations(List validations) { + this.validations = validations; + return this; + } + + public String getFrame() { + return frame; + } + + public ChimerKb setFrame(String frame) { + this.frame = frame; + return this; + } + + public String getChrInfo() { + return chrInfo; + } + + public ChimerKb setChrInfo(String chrInfo) { + this.chrInfo = chrInfo; + return this; + } + + public boolean isKinase() { + return kinase; + } + + public ChimerKb setKinase(boolean kinase) { + this.kinase = kinase; + return this; + } + + public boolean isOncogene() { + return oncogene; + } + + public ChimerKb setOncogene(boolean oncogene) { + this.oncogene = oncogene; + return this; + } + + public boolean isTumorSuppressor() { + return tumorSuppressor; + } + + public ChimerKb setTumorSuppressor(boolean tumorSuppressor) { + this.tumorSuppressor = tumorSuppressor; + return this; + } + + public boolean isReceptor() { + return receptor; + } + + public ChimerKb setReceptor(boolean receptor) { + this.receptor = receptor; + return this; + } + + public boolean isTranscriptionFactor() { + return transcriptionFactor; + } + + public ChimerKb setTranscriptionFactor(boolean transcriptionFactor) { + this.transcriptionFactor = transcriptionFactor; + return this; + } + + public boolean isChimerPub() { + return chimerPub; + } + + public ChimerKb setChimerPub(boolean chimerPub) { + this.chimerPub = chimerPub; + return this; + } + + public boolean isChimerSeq() { + return chimerSeq; + } + + public ChimerKb setChimerSeq(boolean chimerSeq) { + this.chimerSeq = chimerSeq; + return this; + } + + public boolean isChimerSeqPlus() { + return chimerSeqPlus; + } + + public ChimerKb setChimerSeqPlus(boolean chimerSeqPlus) { + this.chimerSeqPlus = chimerSeqPlus; + return this; + } + + public String getSource() { + return source; + } + + public ChimerKb setSource(String source) { + this.source = source; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerKbGeneBreakpoint.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerKbGeneBreakpoint.java new file mode 100644 index 000000000..9f8cdb230 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerKbGeneBreakpoint.java @@ -0,0 +1,85 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core.chimerdb; + +public class ChimerKbGeneBreakpoint { + + protected String geneName; + protected String chromosome; + protected int position; + protected String strand; + + public ChimerKbGeneBreakpoint() { + } + + public ChimerKbGeneBreakpoint(String geneName, String chromosome, int position, String strand) { + this.geneName = geneName; + this.chromosome = chromosome; + this.position = position; + this.strand = strand; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("ChimerKbGeneBreakpoint{"); + sb.append("geneName='").append(geneName).append('\''); + sb.append(", chromosome='").append(chromosome).append('\''); + sb.append(", position=").append(position); + sb.append(", strand='").append(strand).append('\''); + sb.append('}'); + return sb.toString(); + } + + public String getGeneName() { + return geneName; + } + + public ChimerKbGeneBreakpoint setGeneName(String geneName) { + this.geneName = geneName; + return this; + } + + public String getChromosome() { + return chromosome; + } + + public ChimerKbGeneBreakpoint setChromosome(String chromosome) { + this.chromosome = chromosome; + return this; + } + + public int getPosition() { + return position; + } + + public ChimerKbGeneBreakpoint setPosition(int position) { + this.position = position; + return this; + } + + public String getStrand() { + return strand; + } + + public ChimerKbGeneBreakpoint setStrand(String strand) { + this.strand = strand; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerPub.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerPub.java new file mode 100644 index 000000000..f78a90768 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerPub.java @@ -0,0 +1,312 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core.chimerdb; + +import java.util.ArrayList; +import java.util.List; + +public class ChimerPub { + + public static final String SOURCE = "chimerpub"; + + // 0 1 2 3 4 5 6 7 8 9 10 11 12 + // id Fusion_pair Translocation H_gene T_gene PMID Score Disease Validation Kinase Oncogene Tumor_suppressor Receptor + // 13 14 15 16 17 18 19 + // Transcription_Factor ChimerKB ChimerSeq ChimerSeq+ Sentence_highlight H_gene_highlight T_gene_highlight + // 20 21 + // Disease_highlight Validation_highlight + + private String id; + private String fusionPair; + private String translocation; + private ChimerPubGeneBreakpoint headGene; + private ChimerPubGeneBreakpoint tailGene; + private List pmid; + private double score; + private List diseases; + private List validations; + private boolean kinase; + private boolean oncogene; + private boolean tumorSuppressor; + private boolean receptor; + private boolean transcriptionFactor; + private boolean chimerKb; + private boolean chimerSeq; + private boolean chimerSeqPlus; + private String senteceHighlight; + private String diseaseHighlight; + private String validationHighlight; + + private String source; + + public ChimerPub() { + this.headGene = new ChimerPubGeneBreakpoint(); + this.tailGene = new ChimerPubGeneBreakpoint(); + this.pmid = new ArrayList<>(); + this.diseases = new ArrayList<>(); + this.validations = new ArrayList<>(); + + this.source = SOURCE; + } + + public ChimerPub(String id, String fusionPair, String translocation, ChimerPubGeneBreakpoint headGene, ChimerPubGeneBreakpoint tailGene, + List pmid, double score, List diseases, List validations, boolean kinase, boolean oncogene, + boolean tumorSuppressor, boolean receptor, boolean transcriptionFactor, boolean chimerKb, boolean chimerSeq, + boolean chimerSeqPlus, String senteceHighlight, String diseaseHighlight, String validationHighlight, String source) { + this.id = id; + this.fusionPair = fusionPair; + this.translocation = translocation; + this.headGene = headGene; + this.tailGene = tailGene; + this.pmid = pmid; + this.score = score; + this.diseases = diseases; + this.validations = validations; + this.kinase = kinase; + this.oncogene = oncogene; + this.tumorSuppressor = tumorSuppressor; + this.receptor = receptor; + this.transcriptionFactor = transcriptionFactor; + this.chimerKb = chimerKb; + this.chimerSeq = chimerSeq; + this.chimerSeqPlus = chimerSeqPlus; + this.senteceHighlight = senteceHighlight; + this.diseaseHighlight = diseaseHighlight; + this.validationHighlight = validationHighlight; + this.source = source; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("ChimerPub{"); + sb.append("id='").append(id).append('\''); + sb.append(", fusionPair='").append(fusionPair).append('\''); + sb.append(", translocation='").append(translocation).append('\''); + sb.append(", headGene=").append(headGene); + sb.append(", tailGene=").append(tailGene); + sb.append(", pmid=").append(pmid); + sb.append(", score=").append(score); + sb.append(", diseases=").append(diseases); + sb.append(", validations=").append(validations); + sb.append(", kinase=").append(kinase); + sb.append(", oncogene=").append(oncogene); + sb.append(", tumorSuppressor=").append(tumorSuppressor); + sb.append(", receptor=").append(receptor); + sb.append(", transcriptionFactor=").append(transcriptionFactor); + sb.append(", chimerKb=").append(chimerKb); + sb.append(", chimerSeq=").append(chimerSeq); + sb.append(", chimerSeqPlus=").append(chimerSeqPlus); + sb.append(", senteceHighlight='").append(senteceHighlight).append('\''); + sb.append(", diseaseHighlight='").append(diseaseHighlight).append('\''); + sb.append(", validationHighlight='").append(validationHighlight).append('\''); + sb.append(", source='").append(source).append('\''); + sb.append('}'); + return sb.toString(); + } + + public String getId() { + return id; + } + + public ChimerPub setId(String id) { + this.id = id; + return this; + } + + public String getFusionPair() { + return fusionPair; + } + + public ChimerPub setFusionPair(String fusionPair) { + this.fusionPair = fusionPair; + return this; + } + + public String getTranslocation() { + return translocation; + } + + public ChimerPub setTranslocation(String translocation) { + this.translocation = translocation; + return this; + } + + public ChimerPubGeneBreakpoint getHeadGene() { + return headGene; + } + + public ChimerPub setHeadGene(ChimerPubGeneBreakpoint headGene) { + this.headGene = headGene; + return this; + } + + public ChimerPubGeneBreakpoint getTailGene() { + return tailGene; + } + + public ChimerPub setTailGene(ChimerPubGeneBreakpoint tailGene) { + this.tailGene = tailGene; + return this; + } + + public List getPmid() { + return pmid; + } + + public ChimerPub setPmid(List pmid) { + this.pmid = pmid; + return this; + } + + public double getScore() { + return score; + } + + public ChimerPub setScore(double score) { + this.score = score; + return this; + } + + public List getDiseases() { + return diseases; + } + + public ChimerPub setDiseases(List diseases) { + this.diseases = diseases; + return this; + } + + public List getValidations() { + return validations; + } + + public ChimerPub setValidations(List validations) { + this.validations = validations; + return this; + } + + public boolean isKinase() { + return kinase; + } + + public ChimerPub setKinase(boolean kinase) { + this.kinase = kinase; + return this; + } + + public boolean isOncogene() { + return oncogene; + } + + public ChimerPub setOncogene(boolean oncogene) { + this.oncogene = oncogene; + return this; + } + + public boolean isTumorSuppressor() { + return tumorSuppressor; + } + + public ChimerPub setTumorSuppressor(boolean tumorSuppressor) { + this.tumorSuppressor = tumorSuppressor; + return this; + } + + public boolean isReceptor() { + return receptor; + } + + public ChimerPub setReceptor(boolean receptor) { + this.receptor = receptor; + return this; + } + + public boolean isTranscriptionFactor() { + return transcriptionFactor; + } + + public ChimerPub setTranscriptionFactor(boolean transcriptionFactor) { + this.transcriptionFactor = transcriptionFactor; + return this; + } + + public boolean isChimerKb() { + return chimerKb; + } + + public ChimerPub setChimerKb(boolean chimerKb) { + this.chimerKb = chimerKb; + return this; + } + + public boolean isChimerSeq() { + return chimerSeq; + } + + public ChimerPub setChimerSeq(boolean chimerSeq) { + this.chimerSeq = chimerSeq; + return this; + } + + public boolean isChimerSeqPlus() { + return chimerSeqPlus; + } + + public ChimerPub setChimerSeqPlus(boolean chimerSeqPlus) { + this.chimerSeqPlus = chimerSeqPlus; + return this; + } + + public String getSenteceHighlight() { + return senteceHighlight; + } + + public ChimerPub setSenteceHighlight(String senteceHighlight) { + this.senteceHighlight = senteceHighlight; + return this; + } + + public String getDiseaseHighlight() { + return diseaseHighlight; + } + + public ChimerPub setDiseaseHighlight(String diseaseHighlight) { + this.diseaseHighlight = diseaseHighlight; + return this; + } + + public String getValidationHighlight() { + return validationHighlight; + } + + public ChimerPub setValidationHighlight(String validationHighlight) { + this.validationHighlight = validationHighlight; + return this; + } + + public String getSource() { + return source; + } + + public ChimerPub setSource(String source) { + this.source = source; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerPubGeneBreakpoint.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerPubGeneBreakpoint.java new file mode 100644 index 000000000..8615f331b --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerPubGeneBreakpoint.java @@ -0,0 +1,61 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core.chimerdb; + +public class ChimerPubGeneBreakpoint { + + private String geneName; + private String highlight; + + public ChimerPubGeneBreakpoint() { + } + + public ChimerPubGeneBreakpoint(String geneName, String highlight) { + this.geneName = geneName; + this.highlight = highlight; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("ChimerPubGeneBreakpoint{"); + sb.append("geneName='").append(geneName).append('\''); + sb.append(", highlight='").append(highlight).append('\''); + sb.append('}'); + return sb.toString(); + } + + public String getGeneName() { + return geneName; + } + + public ChimerPubGeneBreakpoint setGeneName(String geneName) { + this.geneName = geneName; + return this; + } + + public String getHighlight() { + return highlight; + } + + public ChimerPubGeneBreakpoint setHighlight(String highlight) { + this.highlight = highlight; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerSeq.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerSeq.java new file mode 100644 index 000000000..97a26f807 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerSeq.java @@ -0,0 +1,299 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core.chimerdb; + +public class ChimerSeq { + + public static final String SOURCE = "chimerseq"; + + // 0 1 2 3 4 5 6 7 8 9 10 11 12 + // id ChimerDB_Type Source webSource Fusion_pair H_gene H_chr H_position H_strand T_gene T_chr T_position T_strand + // 13 14 15 16 17 18 19 20 + // Genomic_breakpoint Genome_Build_Version Cancertype BarcodeID Seed_reads_num Spanning_pairs_num Junction_reads_num Frame + // 21 22 23 24 25 26 27 28 29 30 + // Chr_info H_locus H_kinase H_oncogene H_tumor_suppressor H_receptor H_transcription_factor T_locus T_kinase T_oncogene + // 31 32 33 34 35 36 + // T_tumor_suppressor T_receptor T_transcription_factor ChimerKB ChimerPub Highly_Reliable_Seq + + + private String id; + private String chimerDbType; + private String chimerSource; + private String webSource; + private String fusionPair; + private ChimerSeqGeneBreakpoint headGene; + private ChimerSeqGeneBreakpoint tailGene; + private String genomicBreakpoint; + private String genomeBuildVersion; + private String cancerType; + private String barcodeId; + private int seedReadsNum; + private int spanningPairsNum; + private int junctionReadsNum; + private String frame; + private String chrInfo; + private boolean chimerKb; + private boolean chimerPub; + private boolean highlyReliableSeq; + + private String source; + + public ChimerSeq() { + this.headGene = new ChimerSeqGeneBreakpoint(); + this.tailGene = new ChimerSeqGeneBreakpoint(); + + this.source = SOURCE; + } + + public ChimerSeq(String id, String chimerDbType, String chimerSource, String webSource, String fusionPair, + ChimerSeqGeneBreakpoint headGene, ChimerSeqGeneBreakpoint tailGene, String genomicBreakpoint, + String genomeBuildVersion, String cancerType, String barcodeId, int seedReadsNum, int spanningPairsNum, + int junctionReadsNum, String frame, String chrInfo, boolean chimerKb, boolean chimerPub, boolean highlyReliableSeq, + String source) { + this.id = id; + this.chimerDbType = chimerDbType; + this.chimerSource = chimerSource; + this.webSource = webSource; + this.fusionPair = fusionPair; + this.headGene = headGene; + this.tailGene = tailGene; + this.genomicBreakpoint = genomicBreakpoint; + this.genomeBuildVersion = genomeBuildVersion; + this.cancerType = cancerType; + this.barcodeId = barcodeId; + this.seedReadsNum = seedReadsNum; + this.spanningPairsNum = spanningPairsNum; + this.junctionReadsNum = junctionReadsNum; + this.frame = frame; + this.chrInfo = chrInfo; + this.chimerKb = chimerKb; + this.chimerPub = chimerPub; + this.highlyReliableSeq = highlyReliableSeq; + + this.source = source; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("ChimerSeq{"); + sb.append("id='").append(id).append('\''); + sb.append(", chimerDbType='").append(chimerDbType).append('\''); + sb.append(", chimerSource='").append(chimerSource).append('\''); + sb.append(", webSource='").append(webSource).append('\''); + sb.append(", fusionPair='").append(fusionPair).append('\''); + sb.append(", headGene=").append(headGene); + sb.append(", tailGene=").append(tailGene); + sb.append(", genomicBreakpoint='").append(genomicBreakpoint).append('\''); + sb.append(", genomeBuildVersion='").append(genomeBuildVersion).append('\''); + sb.append(", cancerType='").append(cancerType).append('\''); + sb.append(", barcodeId='").append(barcodeId).append('\''); + sb.append(", seedReadsNum=").append(seedReadsNum); + sb.append(", spanningPairsNum=").append(spanningPairsNum); + sb.append(", junctionReadsNum=").append(junctionReadsNum); + sb.append(", frame='").append(frame).append('\''); + sb.append(", chrInfo='").append(chrInfo).append('\''); + sb.append(", chimerKb=").append(chimerKb); + sb.append(", chimerPub=").append(chimerPub); + sb.append(", highlyReliableSeq='").append(highlyReliableSeq).append('\''); + sb.append(", source='").append(source).append('\''); + sb.append('}'); + return sb.toString(); + } + + public String getId() { + return id; + } + + public ChimerSeq setId(String id) { + this.id = id; + return this; + } + + public String getChimerDbType() { + return chimerDbType; + } + + public ChimerSeq setChimerDbType(String chimerDbType) { + this.chimerDbType = chimerDbType; + return this; + } + + public String getChimerSource() { + return chimerSource; + } + + public ChimerSeq setChimerSource(String chimerSource) { + this.chimerSource = chimerSource; + return this; + } + + public String getWebSource() { + return webSource; + } + + public ChimerSeq setWebSource(String webSource) { + this.webSource = webSource; + return this; + } + + public String getFusionPair() { + return fusionPair; + } + + public ChimerSeq setFusionPair(String fusionPair) { + this.fusionPair = fusionPair; + return this; + } + + public ChimerSeqGeneBreakpoint getHeadGene() { + return headGene; + } + + public ChimerSeq setHeadGene(ChimerSeqGeneBreakpoint headGene) { + this.headGene = headGene; + return this; + } + + public ChimerSeqGeneBreakpoint getTailGene() { + return tailGene; + } + + public ChimerSeq setTailGene(ChimerSeqGeneBreakpoint tailGene) { + this.tailGene = tailGene; + return this; + } + + public String getGenomicBreakpoint() { + return genomicBreakpoint; + } + + public ChimerSeq setGenomicBreakpoint(String genomicBreakpoint) { + this.genomicBreakpoint = genomicBreakpoint; + return this; + } + + public String getGenomeBuildVersion() { + return genomeBuildVersion; + } + + public ChimerSeq setGenomeBuildVersion(String genomeBuildVersion) { + this.genomeBuildVersion = genomeBuildVersion; + return this; + } + + public String getCancerType() { + return cancerType; + } + + public ChimerSeq setCancerType(String cancerType) { + this.cancerType = cancerType; + return this; + } + + public String getBarcodeId() { + return barcodeId; + } + + public ChimerSeq setBarcodeId(String barcodeId) { + this.barcodeId = barcodeId; + return this; + } + + public int getSeedReadsNum() { + return seedReadsNum; + } + + public ChimerSeq setSeedReadsNum(int seedReadsNum) { + this.seedReadsNum = seedReadsNum; + return this; + } + + public int getSpanningPairsNum() { + return spanningPairsNum; + } + + public ChimerSeq setSpanningPairsNum(int spanningPairsNum) { + this.spanningPairsNum = spanningPairsNum; + return this; + } + + public int getJunctionReadsNum() { + return junctionReadsNum; + } + + public ChimerSeq setJunctionReadsNum(int junctionReadsNum) { + this.junctionReadsNum = junctionReadsNum; + return this; + } + + public String getFrame() { + return frame; + } + + public ChimerSeq setFrame(String frame) { + this.frame = frame; + return this; + } + + public String getChrInfo() { + return chrInfo; + } + + public ChimerSeq setChrInfo(String chrInfo) { + this.chrInfo = chrInfo; + return this; + } + + public boolean isChimerKb() { + return chimerKb; + } + + public ChimerSeq setChimerKb(boolean chimerKb) { + this.chimerKb = chimerKb; + return this; + } + + public boolean isChimerPub() { + return chimerPub; + } + + public ChimerSeq setChimerPub(boolean chimerPub) { + this.chimerPub = chimerPub; + return this; + } + + public boolean getHighlyReliableSeq() { + return highlyReliableSeq; + } + + public ChimerSeq setHighlyReliableSeq(boolean highlyReliableSeq) { + this.highlyReliableSeq = highlyReliableSeq; + return this; + } + + public String getSource() { + return source; + } + + public ChimerSeq setSource(String source) { + this.source = source; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerSeqGeneBreakpoint.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerSeqGeneBreakpoint.java new file mode 100644 index 000000000..29604f96f --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/chimerdb/ChimerSeqGeneBreakpoint.java @@ -0,0 +1,118 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core.chimerdb; + +public class ChimerSeqGeneBreakpoint extends ChimerKbGeneBreakpoint { + + private String locus; + private boolean kinase; + private boolean oncogene; + private boolean tumorSuppressor; + private boolean receptor; + private boolean transcriptionFactor; + + public ChimerSeqGeneBreakpoint() { + super(); + } + + public ChimerSeqGeneBreakpoint(String geneName, String chromosome, int position, String strand, String locus, boolean kinase, + boolean oncogene, boolean tumorSuppressor, boolean receptor, boolean transcriptionFactor) { + super(geneName, chromosome, position, strand); + this.locus = locus; + this.kinase = kinase; + this.oncogene = oncogene; + this.tumorSuppressor = tumorSuppressor; + this.receptor = receptor; + this.transcriptionFactor = transcriptionFactor; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("ChimerSeqGeneBreakpoint{"); + sb.append("locus='").append(locus).append('\''); + sb.append(", kinase=").append(kinase); + sb.append(", oncogene=").append(oncogene); + sb.append(", tumorSuppressor=").append(tumorSuppressor); + sb.append(", receptor=").append(receptor); + sb.append(", transcriptionFactor=").append(transcriptionFactor); + sb.append(", geneName='").append(geneName).append('\''); + sb.append(", chromosome='").append(chromosome).append('\''); + sb.append(", position=").append(position); + sb.append(", strand='").append(strand).append('\''); + sb.append('}'); + return sb.toString(); + } + + public String getLocus() { + return locus; + } + + public ChimerSeqGeneBreakpoint setLocus(String locus) { + this.locus = locus; + return this; + } + + public boolean isKinase() { + return kinase; + } + + public ChimerSeqGeneBreakpoint setKinase(boolean kinase) { + this.kinase = kinase; + return this; + } + + public boolean isOncogene() { + return oncogene; + } + + public ChimerSeqGeneBreakpoint setOncogene(boolean oncogene) { + this.oncogene = oncogene; + return this; + } + + public boolean isTumorSuppressor() { + return tumorSuppressor; + } + + public ChimerSeqGeneBreakpoint setTumorSuppressor(boolean tumorSuppressor) { + this.tumorSuppressor = tumorSuppressor; + return this; + } + + public boolean isReceptor() { + return receptor; + } + + public ChimerSeqGeneBreakpoint setReceptor(boolean receptor) { + this.receptor = receptor; + return this; + } + + public boolean isTranscriptionFactor() { + return transcriptionFactor; + } + + public ChimerSeqGeneBreakpoint setTranscriptionFactor(boolean transcriptionFactor) { + this.transcriptionFactor = transcriptionFactor; + return this; + } +} + + diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicAssertion.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicAssertion.java new file mode 100644 index 000000000..098e97b44 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicAssertion.java @@ -0,0 +1,246 @@ +package org.opencb.biodata.models.core.civic; + +import java.util.ArrayList; +import java.util.List; + +public class CivicAssertion { + + // From AssertionSummaries.tsv + private String disease; + private String doid; + private List phenotypes; + private List therapies; + private String assertionType; + private String assertionDirection; + private String significance; + private List acmgCodes; + private String ampCategory; + private String nccnGuideline; + private String nccnGuidelineVersion; + private String regulatoryApproval; + private String fdaCompanionTest; + private String assertionSummary; + private String assertionDescription; + private String assertionId; + private String lastReviewDate; + private String assertionCivicUrl; + private Boolean isFlagged; + + // Associated data + private List evidences; + + public CivicAssertion() { + this.phenotypes = new ArrayList<>(); + this.therapies = new ArrayList<>(); + this.acmgCodes = new ArrayList<>(); + + this.evidences = new ArrayList<>(); + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("CivicAssertion{"); + sb.append("disease='").append(disease).append('\''); + sb.append(", doid='").append(doid).append('\''); + sb.append(", phenotypes=").append(phenotypes); + sb.append(", therapies=").append(therapies); + sb.append(", assertionType='").append(assertionType).append('\''); + sb.append(", assertionDirection='").append(assertionDirection).append('\''); + sb.append(", significance='").append(significance).append('\''); + sb.append(", acmgCodes=").append(acmgCodes); + sb.append(", ampCategory='").append(ampCategory).append('\''); + sb.append(", nccnGuideline='").append(nccnGuideline).append('\''); + sb.append(", nccnGuidelineVersion='").append(nccnGuidelineVersion).append('\''); + sb.append(", regulatoryApproval='").append(regulatoryApproval).append('\''); + sb.append(", fdaCompanionTest='").append(fdaCompanionTest).append('\''); + sb.append(", assertionSummary='").append(assertionSummary).append('\''); + sb.append(", assertionDescription='").append(assertionDescription).append('\''); + sb.append(", assertionId='").append(assertionId).append('\''); + sb.append(", lastReviewDate='").append(lastReviewDate).append('\''); + sb.append(", assertionCivicUrl='").append(assertionCivicUrl).append('\''); + sb.append(", isFlagged=").append(isFlagged); + sb.append(", evidences=").append(evidences); + sb.append('}'); + return sb.toString(); + } + + public String getDisease() { + return disease; + } + + public CivicAssertion setDisease(String disease) { + this.disease = disease; + return this; + } + + public String getDoid() { + return doid; + } + + public CivicAssertion setDoid(String doid) { + this.doid = doid; + return this; + } + + public List getPhenotypes() { + return phenotypes; + } + + public CivicAssertion setPhenotypes(List phenotypes) { + this.phenotypes = phenotypes; + return this; + } + + public List getTherapies() { + return therapies; + } + + public CivicAssertion setTherapies(List therapies) { + this.therapies = therapies; + return this; + } + + public String getAssertionType() { + return assertionType; + } + + public CivicAssertion setAssertionType(String assertionType) { + this.assertionType = assertionType; + return this; + } + + public String getAssertionDirection() { + return assertionDirection; + } + + public CivicAssertion setAssertionDirection(String assertionDirection) { + this.assertionDirection = assertionDirection; + return this; + } + + public String getSignificance() { + return significance; + } + + public CivicAssertion setSignificance(String significance) { + this.significance = significance; + return this; + } + + public List getAcmgCodes() { + return acmgCodes; + } + + public CivicAssertion setAcmgCodes(List acmgCodes) { + this.acmgCodes = acmgCodes; + return this; + } + + public String getAmpCategory() { + return ampCategory; + } + + public CivicAssertion setAmpCategory(String ampCategory) { + this.ampCategory = ampCategory; + return this; + } + + public String getNccnGuideline() { + return nccnGuideline; + } + + public CivicAssertion setNccnGuideline(String nccnGuideline) { + this.nccnGuideline = nccnGuideline; + return this; + } + + public String getNccnGuidelineVersion() { + return nccnGuidelineVersion; + } + + public CivicAssertion setNccnGuidelineVersion(String nccnGuidelineVersion) { + this.nccnGuidelineVersion = nccnGuidelineVersion; + return this; + } + + public String getRegulatoryApproval() { + return regulatoryApproval; + } + + public CivicAssertion setRegulatoryApproval(String regulatoryApproval) { + this.regulatoryApproval = regulatoryApproval; + return this; + } + + public String getFdaCompanionTest() { + return fdaCompanionTest; + } + + public CivicAssertion setFdaCompanionTest(String fdaCompanionTest) { + this.fdaCompanionTest = fdaCompanionTest; + return this; + } + + public String getAssertionSummary() { + return assertionSummary; + } + + public CivicAssertion setAssertionSummary(String assertionSummary) { + this.assertionSummary = assertionSummary; + return this; + } + + public String getAssertionDescription() { + return assertionDescription; + } + + public CivicAssertion setAssertionDescription(String assertionDescription) { + this.assertionDescription = assertionDescription; + return this; + } + + public String getAssertionId() { + return assertionId; + } + + public CivicAssertion setAssertionId(String assertionId) { + this.assertionId = assertionId; + return this; + } + + public String getLastReviewDate() { + return lastReviewDate; + } + + public CivicAssertion setLastReviewDate(String lastReviewDate) { + this.lastReviewDate = lastReviewDate; + return this; + } + + public String getAssertionCivicUrl() { + return assertionCivicUrl; + } + + public CivicAssertion setAssertionCivicUrl(String assertionCivicUrl) { + this.assertionCivicUrl = assertionCivicUrl; + return this; + } + + public Boolean getFlagged() { + return isFlagged; + } + + public CivicAssertion setFlagged(Boolean flagged) { + isFlagged = flagged; + return this; + } + + public List getEvidences() { + return evidences; + } + + public CivicAssertion setEvidences(List evidences) { + this.evidences = evidences; + return this; + } +} \ No newline at end of file diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicClinicalEvidence.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicClinicalEvidence.java new file mode 100644 index 000000000..56df46a53 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicClinicalEvidence.java @@ -0,0 +1,264 @@ +package org.opencb.biodata.models.core.civic; + +import java.util.ArrayList; +import java.util.List; + +public class CivicClinicalEvidence { + + // From ClinicalEvidenceSummaries.tsv + private String disease; + private String doid; + private List phenotypes; + private List therapies; + private String therapyInteractionType; + private String evidenceType; + private String evidenceDirection; + private String evidenceLevel; + private String significance; + private String evidenceStatement; + private String citationId; + private String sourceType; + private String ascoAbstractId; + private String citation; + private List nctIds; + private String rating; + private String evidenceStatus; + private String evidenceId; + private String variantOrigin; + private String lastReviewDate; + private String evidenceCivicUrl; + private Boolean isFlagged; + + public CivicClinicalEvidence() { + this.phenotypes = new ArrayList<>(); + this.therapies = new ArrayList<>(); + this.nctIds = new ArrayList<>(); + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("CivicClinicalEvidence{"); + sb.append(", disease='").append(disease).append('\''); + sb.append(", doid='").append(doid).append('\''); + sb.append(", phenotypes=").append(phenotypes); + sb.append(", therapies=").append(therapies); + sb.append(", therapyInteractionType='").append(therapyInteractionType).append('\''); + sb.append(", evidenceType='").append(evidenceType).append('\''); + sb.append(", evidenceDirection='").append(evidenceDirection).append('\''); + sb.append(", evidenceLevel='").append(evidenceLevel).append('\''); + sb.append(", significance='").append(significance).append('\''); + sb.append(", evidenceStatement='").append(evidenceStatement).append('\''); + sb.append(", citationId='").append(citationId).append('\''); + sb.append(", sourceType='").append(sourceType).append('\''); + sb.append(", ascoAbstractId='").append(ascoAbstractId).append('\''); + sb.append(", citation='").append(citation).append('\''); + sb.append(", nctIds=").append(nctIds); + sb.append(", rating='").append(rating).append('\''); + sb.append(", evidenceStatus='").append(evidenceStatus).append('\''); + sb.append(", evidenceId='").append(evidenceId).append('\''); + sb.append(", variantOrigin='").append(variantOrigin).append('\''); + sb.append(", lastReviewDate='").append(lastReviewDate).append('\''); + sb.append(", evidenceCivicUrl='").append(evidenceCivicUrl).append('\''); + sb.append(", isFlagged=").append(isFlagged); + sb.append('}'); + return sb.toString(); + } + + public String getDisease() { + return disease; + } + + public CivicClinicalEvidence setDisease(String disease) { + this.disease = disease; + return this; + } + + public String getDoid() { + return doid; + } + + public CivicClinicalEvidence setDoid(String doid) { + this.doid = doid; + return this; + } + + public List getPhenotypes() { + return phenotypes; + } + + public CivicClinicalEvidence setPhenotypes(List phenotypes) { + this.phenotypes = phenotypes; + return this; + } + + public List getTherapies() { + return therapies; + } + + public CivicClinicalEvidence setTherapies(List therapies) { + this.therapies = therapies; + return this; + } + + public String getTherapyInteractionType() { + return therapyInteractionType; + } + + public CivicClinicalEvidence setTherapyInteractionType(String therapyInteractionType) { + this.therapyInteractionType = therapyInteractionType; + return this; + } + + public String getEvidenceType() { + return evidenceType; + } + + public CivicClinicalEvidence setEvidenceType(String evidenceType) { + this.evidenceType = evidenceType; + return this; + } + + public String getEvidenceDirection() { + return evidenceDirection; + } + + public CivicClinicalEvidence setEvidenceDirection(String evidenceDirection) { + this.evidenceDirection = evidenceDirection; + return this; + } + + public String getEvidenceLevel() { + return evidenceLevel; + } + + public CivicClinicalEvidence setEvidenceLevel(String evidenceLevel) { + this.evidenceLevel = evidenceLevel; + return this; + } + + public String getSignificance() { + return significance; + } + + public CivicClinicalEvidence setSignificance(String significance) { + this.significance = significance; + return this; + } + + public String getEvidenceStatement() { + return evidenceStatement; + } + + public CivicClinicalEvidence setEvidenceStatement(String evidenceStatement) { + this.evidenceStatement = evidenceStatement; + return this; + } + + public String getCitationId() { + return citationId; + } + + public CivicClinicalEvidence setCitationId(String citationId) { + this.citationId = citationId; + return this; + } + + public String getSourceType() { + return sourceType; + } + + public CivicClinicalEvidence setSourceType(String sourceType) { + this.sourceType = sourceType; + return this; + } + + public String getAscoAbstractId() { + return ascoAbstractId; + } + + public CivicClinicalEvidence setAscoAbstractId(String ascoAbstractId) { + this.ascoAbstractId = ascoAbstractId; + return this; + } + + public String getCitation() { + return citation; + } + + public CivicClinicalEvidence setCitation(String citation) { + this.citation = citation; + return this; + } + + public List getNctIds() { + return nctIds; + } + + public CivicClinicalEvidence setNctIds(List nctIds) { + this.nctIds = nctIds; + return this; + } + + public String getRating() { + return rating; + } + + public CivicClinicalEvidence setRating(String rating) { + this.rating = rating; + return this; + } + + public String getEvidenceStatus() { + return evidenceStatus; + } + + public CivicClinicalEvidence setEvidenceStatus(String evidenceStatus) { + this.evidenceStatus = evidenceStatus; + return this; + } + + public String getEvidenceId() { + return evidenceId; + } + + public CivicClinicalEvidence setEvidenceId(String evidenceId) { + this.evidenceId = evidenceId; + return this; + } + + public String getVariantOrigin() { + return variantOrigin; + } + + public CivicClinicalEvidence setVariantOrigin(String variantOrigin) { + this.variantOrigin = variantOrigin; + return this; + } + + public String getLastReviewDate() { + return lastReviewDate; + } + + public CivicClinicalEvidence setLastReviewDate(String lastReviewDate) { + this.lastReviewDate = lastReviewDate; + return this; + } + + public String getEvidenceCivicUrl() { + return evidenceCivicUrl; + } + + public CivicClinicalEvidence setEvidenceCivicUrl(String evidenceCivicUrl) { + this.evidenceCivicUrl = evidenceCivicUrl; + return this; + } + + public Boolean getFlagged() { + return isFlagged; + } + + public CivicClinicalEvidence setFlagged(Boolean flagged) { + isFlagged = flagged; + return this; + } +} \ No newline at end of file diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicFeature.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicFeature.java new file mode 100644 index 000000000..e70a27cc3 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicFeature.java @@ -0,0 +1,330 @@ +package org.opencb.biodata.models.core.civic; + +import java.util.ArrayList; +import java.util.List; + +public class CivicFeature { + + // From FeatureSummaries.tsv + private String featureId; + private String featureCivicUrl; + private String featureType; + private String name; + private List featureAliases; + private String description; + private String lastReviewDate; + private Boolean isFlagged; + private String entrezId; + private String ncitId; + private String fivePrimePartnerStatus; + private String threePrimePartnerStatus; + private String fivePrimeGeneId; + private String fivePrimeGeneName; + private String fivePrimeGeneEntrezId; + private String threePrimeGeneId; + private String threePrimeGeneName; + private String threePrimeGeneEntrezId; + + // Additional transcript/exon information from VariantSummaries.tsv + private String fivePrimePartner; + private String threePrimePartner; + private String fivePrimeTranscript; + private String fivePrimeEndExon; + private String fivePrimeExonOffset; + private String fivePrimeExonOffsetDirection; + private String threePrimeTranscript; + private String threePrimeStartExon; + private String threePrimeExonOffset; + private String threePrimeExonOffsetDirection; + + public CivicFeature() { + this.featureAliases = new ArrayList<>(); + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("CivicFeature{"); + sb.append("featureId='").append(featureId).append('\''); + sb.append(", featureCivicUrl='").append(featureCivicUrl).append('\''); + sb.append(", featureType='").append(featureType).append('\''); + sb.append(", name='").append(name).append('\''); + sb.append(", featureAliases=").append(featureAliases); + sb.append(", description='").append(description).append('\''); + sb.append(", lastReviewDate='").append(lastReviewDate).append('\''); + sb.append(", isFlagged=").append(isFlagged); + sb.append(", entrezId='").append(entrezId).append('\''); + sb.append(", ncitId='").append(ncitId).append('\''); + sb.append(", fivePrimePartnerStatus='").append(fivePrimePartnerStatus).append('\''); + sb.append(", threePrimePartnerStatus='").append(threePrimePartnerStatus).append('\''); + sb.append(", fivePrimeGeneId='").append(fivePrimeGeneId).append('\''); + sb.append(", fivePrimeGeneName='").append(fivePrimeGeneName).append('\''); + sb.append(", fivePrimeGeneEntrezId='").append(fivePrimeGeneEntrezId).append('\''); + sb.append(", threePrimeGeneId='").append(threePrimeGeneId).append('\''); + sb.append(", threePrimeGeneName='").append(threePrimeGeneName).append('\''); + sb.append(", threePrimeGeneEntrezId='").append(threePrimeGeneEntrezId).append('\''); + sb.append(", fivePrimePartner='").append(fivePrimePartner).append('\''); + sb.append(", threePrimePartner='").append(threePrimePartner).append('\''); + sb.append(", fivePrimeTranscript='").append(fivePrimeTranscript).append('\''); + sb.append(", fivePrimeEndExon='").append(fivePrimeEndExon).append('\''); + sb.append(", fivePrimeExonOffset='").append(fivePrimeExonOffset).append('\''); + sb.append(", fivePrimeExonOffsetDirection='").append(fivePrimeExonOffsetDirection).append('\''); + sb.append(", threePrimeTranscript='").append(threePrimeTranscript).append('\''); + sb.append(", threePrimeStartExon='").append(threePrimeStartExon).append('\''); + sb.append(", threePrimeExonOffset='").append(threePrimeExonOffset).append('\''); + sb.append(", threePrimeExonOffsetDirection='").append(threePrimeExonOffsetDirection).append('\''); + sb.append('}'); + return sb.toString(); + } + + public String getFeatureId() { + return featureId; + } + + public CivicFeature setFeatureId(String featureId) { + this.featureId = featureId; + return this; + } + + public String getFeatureCivicUrl() { + return featureCivicUrl; + } + + public CivicFeature setFeatureCivicUrl(String featureCivicUrl) { + this.featureCivicUrl = featureCivicUrl; + return this; + } + + public String getFeatureType() { + return featureType; + } + + public CivicFeature setFeatureType(String featureType) { + this.featureType = featureType; + return this; + } + + public String getName() { + return name; + } + + public CivicFeature setName(String name) { + this.name = name; + return this; + } + + public List getFeatureAliases() { + return featureAliases; + } + + public CivicFeature setFeatureAliases(List featureAliases) { + this.featureAliases = featureAliases; + return this; + } + + public String getDescription() { + return description; + } + + public CivicFeature setDescription(String description) { + this.description = description; + return this; + } + + public String getLastReviewDate() { + return lastReviewDate; + } + + public CivicFeature setLastReviewDate(String lastReviewDate) { + this.lastReviewDate = lastReviewDate; + return this; + } + + public Boolean getFlagged() { + return isFlagged; + } + + public CivicFeature setFlagged(Boolean flagged) { + isFlagged = flagged; + return this; + } + + public String getEntrezId() { + return entrezId; + } + + public CivicFeature setEntrezId(String entrezId) { + this.entrezId = entrezId; + return this; + } + + public String getNcitId() { + return ncitId; + } + + public CivicFeature setNcitId(String ncitId) { + this.ncitId = ncitId; + return this; + } + + public String getFivePrimePartnerStatus() { + return fivePrimePartnerStatus; + } + + public CivicFeature setFivePrimePartnerStatus(String fivePrimePartnerStatus) { + this.fivePrimePartnerStatus = fivePrimePartnerStatus; + return this; + } + + public String getThreePrimePartnerStatus() { + return threePrimePartnerStatus; + } + + public CivicFeature setThreePrimePartnerStatus(String threePrimePartnerStatus) { + this.threePrimePartnerStatus = threePrimePartnerStatus; + return this; + } + + public String getFivePrimeGeneId() { + return fivePrimeGeneId; + } + + public CivicFeature setFivePrimeGeneId(String fivePrimeGeneId) { + this.fivePrimeGeneId = fivePrimeGeneId; + return this; + } + + public String getFivePrimeGeneName() { + return fivePrimeGeneName; + } + + public CivicFeature setFivePrimeGeneName(String fivePrimeGeneName) { + this.fivePrimeGeneName = fivePrimeGeneName; + return this; + } + + public String getFivePrimeGeneEntrezId() { + return fivePrimeGeneEntrezId; + } + + public CivicFeature setFivePrimeGeneEntrezId(String fivePrimeGeneEntrezId) { + this.fivePrimeGeneEntrezId = fivePrimeGeneEntrezId; + return this; + } + + public String getThreePrimeGeneId() { + return threePrimeGeneId; + } + + public CivicFeature setThreePrimeGeneId(String threePrimeGeneId) { + this.threePrimeGeneId = threePrimeGeneId; + return this; + } + + public String getThreePrimeGeneName() { + return threePrimeGeneName; + } + + public CivicFeature setThreePrimeGeneName(String threePrimeGeneName) { + this.threePrimeGeneName = threePrimeGeneName; + return this; + } + + public String getThreePrimeGeneEntrezId() { + return threePrimeGeneEntrezId; + } + + public CivicFeature setThreePrimeGeneEntrezId(String threePrimeGeneEntrezId) { + this.threePrimeGeneEntrezId = threePrimeGeneEntrezId; + return this; + } + + public String getFivePrimePartner() { + return fivePrimePartner; + } + + public CivicFeature setFivePrimePartner(String fivePrimePartner) { + this.fivePrimePartner = fivePrimePartner; + return this; + } + + public String getThreePrimePartner() { + return threePrimePartner; + } + + public CivicFeature setThreePrimePartner(String threePrimePartner) { + this.threePrimePartner = threePrimePartner; + return this; + } + + public String getFivePrimeTranscript() { + return fivePrimeTranscript; + } + + public CivicFeature setFivePrimeTranscript(String fivePrimeTranscript) { + this.fivePrimeTranscript = fivePrimeTranscript; + return this; + } + + public String getFivePrimeEndExon() { + return fivePrimeEndExon; + } + + public CivicFeature setFivePrimeEndExon(String fivePrimeEndExon) { + this.fivePrimeEndExon = fivePrimeEndExon; + return this; + } + + public String getFivePrimeExonOffset() { + return fivePrimeExonOffset; + } + + public CivicFeature setFivePrimeExonOffset(String fivePrimeExonOffset) { + this.fivePrimeExonOffset = fivePrimeExonOffset; + return this; + } + + public String getFivePrimeExonOffsetDirection() { + return fivePrimeExonOffsetDirection; + } + + public CivicFeature setFivePrimeExonOffsetDirection(String fivePrimeExonOffsetDirection) { + this.fivePrimeExonOffsetDirection = fivePrimeExonOffsetDirection; + return this; + } + + public String getThreePrimeTranscript() { + return threePrimeTranscript; + } + + public CivicFeature setThreePrimeTranscript(String threePrimeTranscript) { + this.threePrimeTranscript = threePrimeTranscript; + return this; + } + + public String getThreePrimeStartExon() { + return threePrimeStartExon; + } + + public CivicFeature setThreePrimeStartExon(String threePrimeStartExon) { + this.threePrimeStartExon = threePrimeStartExon; + return this; + } + + public String getThreePrimeExonOffset() { + return threePrimeExonOffset; + } + + public CivicFeature setThreePrimeExonOffset(String threePrimeExonOffset) { + this.threePrimeExonOffset = threePrimeExonOffset; + return this; + } + + public String getThreePrimeExonOffsetDirection() { + return threePrimeExonOffsetDirection; + } + + public CivicFeature setThreePrimeExonOffsetDirection(String threePrimeExonOffsetDirection) { + this.threePrimeExonOffsetDirection = threePrimeExonOffsetDirection; + return this; + } +} \ No newline at end of file diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicMolecularProfile.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicMolecularProfile.java new file mode 100644 index 000000000..7c7800dfe --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicMolecularProfile.java @@ -0,0 +1,124 @@ +package org.opencb.biodata.models.core.civic; + +import java.util.ArrayList; +import java.util.List; + +public class CivicMolecularProfile { + + // From MolecularProfileSummaries.tsv + private String name; + private String molecularProfileId; + private String summary; + private String evidenceScore; + private List aliases; + private String lastReviewDate; + private Boolean isFlagged; + + // Associated data + private List assertions; + private List evidences; + + public CivicMolecularProfile() { + this.aliases = new ArrayList<>(); + + this.assertions = new ArrayList<>(); + this.evidences = new ArrayList<>(); + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("CivicMolecularProfile{"); + sb.append("name='").append(name).append('\''); + sb.append(", molecularProfileId='").append(molecularProfileId).append('\''); + sb.append(", summary='").append(summary).append('\''); + sb.append(", evidenceScore='").append(evidenceScore).append('\''); + sb.append(", aliases=").append(aliases); + sb.append(", lastReviewDate='").append(lastReviewDate).append('\''); + sb.append(", isFlagged=").append(isFlagged); + sb.append(", assertions=").append(assertions); + sb.append(", evidences=").append(evidences); + sb.append('}'); + return sb.toString(); + } + + public String getName() { + return name; + } + + public CivicMolecularProfile setName(String name) { + this.name = name; + return this; + } + + public String getMolecularProfileId() { + return molecularProfileId; + } + + public CivicMolecularProfile setMolecularProfileId(String molecularProfileId) { + this.molecularProfileId = molecularProfileId; + return this; + } + + public String getSummary() { + return summary; + } + + public CivicMolecularProfile setSummary(String summary) { + this.summary = summary; + return this; + } + + public String getEvidenceScore() { + return evidenceScore; + } + + public CivicMolecularProfile setEvidenceScore(String evidenceScore) { + this.evidenceScore = evidenceScore; + return this; + } + + public List getAliases() { + return aliases; + } + + public CivicMolecularProfile setAliases(List aliases) { + this.aliases = aliases; + return this; + } + + public String getLastReviewDate() { + return lastReviewDate; + } + + public CivicMolecularProfile setLastReviewDate(String lastReviewDate) { + this.lastReviewDate = lastReviewDate; + return this; + } + + public Boolean getFlagged() { + return isFlagged; + } + + public CivicMolecularProfile setFlagged(Boolean flagged) { + isFlagged = flagged; + return this; + } + + public List getAssertions() { + return assertions; + } + + public CivicMolecularProfile setAssertions(List assertions) { + this.assertions = assertions; + return this; + } + + public List getEvidences() { + return evidences; + } + + public CivicMolecularProfile setEvidences(List evidences) { + this.evidences = evidences; + return this; + } +} \ No newline at end of file diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicVariant.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicVariant.java new file mode 100644 index 000000000..78597dec0 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/civic/CivicVariant.java @@ -0,0 +1,304 @@ +package org.opencb.biodata.models.core.civic; + +import java.util.ArrayList; +import java.util.List; + +public class CivicVariant { + + // From VariantSummaries.tsv + private String variantId; + private String variantCivicUrl; + private String variant; + private List variantAliases; + private Boolean isFlagged; + private List variantGroups; + private List variantTypes; + private String lastReviewDate; + private String gene; + private String entrezId; + private String chromosome; + private String start; + private String stop; + private String referenceBases; + private String variantBases; + private String representativeTranscript; + private String ensemblVersion; + private String referenceBuild; + private List hgvsDescriptions; + private String alleleRegistryId; + private List clinvarIds; + private String ncitId; + private String viccCompliantName; + + // Associated data + private CivicFeature feature; + private List molecularProfiles; + + public CivicVariant() { + this.variantAliases = new ArrayList<>(); + this.variantGroups = new ArrayList<>(); + this.variantTypes = new ArrayList<>(); + this.hgvsDescriptions = new ArrayList<>(); + this.clinvarIds = new ArrayList<>(); + + this.feature = new CivicFeature(); + this.molecularProfiles = new ArrayList<>(); + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("CivicVariant{"); + sb.append("variantId='").append(variantId).append('\''); + sb.append(", variantCivicUrl='").append(variantCivicUrl).append('\''); + sb.append(", variant='").append(variant).append('\''); + sb.append(", variantAliases=").append(variantAliases); + sb.append(", isFlagged=").append(isFlagged); + sb.append(", variantGroups=").append(variantGroups); + sb.append(", variantTypes=").append(variantTypes); + sb.append(", lastReviewDate='").append(lastReviewDate).append('\''); + sb.append(", gene='").append(gene).append('\''); + sb.append(", entrezId='").append(entrezId).append('\''); + sb.append(", chromosome='").append(chromosome).append('\''); + sb.append(", start='").append(start).append('\''); + sb.append(", stop='").append(stop).append('\''); + sb.append(", referenceBases='").append(referenceBases).append('\''); + sb.append(", variantBases='").append(variantBases).append('\''); + sb.append(", representativeTranscript='").append(representativeTranscript).append('\''); + sb.append(", ensemblVersion='").append(ensemblVersion).append('\''); + sb.append(", referenceBuild='").append(referenceBuild).append('\''); + sb.append(", hgvsDescriptions=").append(hgvsDescriptions); + sb.append(", alleleRegistryId='").append(alleleRegistryId).append('\''); + sb.append(", clinvarIds=").append(clinvarIds); + sb.append(", ncitId='").append(ncitId).append('\''); + sb.append(", viccCompliantName='").append(viccCompliantName).append('\''); + sb.append(", feature=").append(feature); + sb.append(", molecularProfiles=").append(molecularProfiles); + sb.append('}'); + return sb.toString(); + } + + public String getVariantId() { + return variantId; + } + + public CivicVariant setVariantId(String variantId) { + this.variantId = variantId; + return this; + } + + public String getVariantCivicUrl() { + return variantCivicUrl; + } + + public CivicVariant setVariantCivicUrl(String variantCivicUrl) { + this.variantCivicUrl = variantCivicUrl; + return this; + } + + public String getVariant() { + return variant; + } + + public CivicVariant setVariant(String variant) { + this.variant = variant; + return this; + } + + public List getVariantAliases() { + return variantAliases; + } + + public CivicVariant setVariantAliases(List variantAliases) { + this.variantAliases = variantAliases; + return this; + } + + public Boolean getFlagged() { + return isFlagged; + } + + public CivicVariant setFlagged(Boolean flagged) { + isFlagged = flagged; + return this; + } + + public List getVariantGroups() { + return variantGroups; + } + + public CivicVariant setVariantGroups(List variantGroups) { + this.variantGroups = variantGroups; + return this; + } + + public List getVariantTypes() { + return variantTypes; + } + + public CivicVariant setVariantTypes(List variantTypes) { + this.variantTypes = variantTypes; + return this; + } + + public String getLastReviewDate() { + return lastReviewDate; + } + + public CivicVariant setLastReviewDate(String lastReviewDate) { + this.lastReviewDate = lastReviewDate; + return this; + } + + public String getGene() { + return gene; + } + + public CivicVariant setGene(String gene) { + this.gene = gene; + return this; + } + + public String getEntrezId() { + return entrezId; + } + + public CivicVariant setEntrezId(String entrezId) { + this.entrezId = entrezId; + return this; + } + + public String getChromosome() { + return chromosome; + } + + public CivicVariant setChromosome(String chromosome) { + this.chromosome = chromosome; + return this; + } + + public String getStart() { + return start; + } + + public CivicVariant setStart(String start) { + this.start = start; + return this; + } + + public String getStop() { + return stop; + } + + public CivicVariant setStop(String stop) { + this.stop = stop; + return this; + } + + public String getReferenceBases() { + return referenceBases; + } + + public CivicVariant setReferenceBases(String referenceBases) { + this.referenceBases = referenceBases; + return this; + } + + public String getVariantBases() { + return variantBases; + } + + public CivicVariant setVariantBases(String variantBases) { + this.variantBases = variantBases; + return this; + } + + public String getRepresentativeTranscript() { + return representativeTranscript; + } + + public CivicVariant setRepresentativeTranscript(String representativeTranscript) { + this.representativeTranscript = representativeTranscript; + return this; + } + + public String getEnsemblVersion() { + return ensemblVersion; + } + + public CivicVariant setEnsemblVersion(String ensemblVersion) { + this.ensemblVersion = ensemblVersion; + return this; + } + + public String getReferenceBuild() { + return referenceBuild; + } + + public CivicVariant setReferenceBuild(String referenceBuild) { + this.referenceBuild = referenceBuild; + return this; + } + + public List getHgvsDescriptions() { + return hgvsDescriptions; + } + + public CivicVariant setHgvsDescriptions(List hgvsDescriptions) { + this.hgvsDescriptions = hgvsDescriptions; + return this; + } + + public String getAlleleRegistryId() { + return alleleRegistryId; + } + + public CivicVariant setAlleleRegistryId(String alleleRegistryId) { + this.alleleRegistryId = alleleRegistryId; + return this; + } + + public List getClinvarIds() { + return clinvarIds; + } + + public CivicVariant setClinvarIds(List clinvarIds) { + this.clinvarIds = clinvarIds; + return this; + } + + public String getNcitId() { + return ncitId; + } + + public CivicVariant setNcitId(String ncitId) { + this.ncitId = ncitId; + return this; + } + + public String getViccCompliantName() { + return viccCompliantName; + } + + public CivicVariant setViccCompliantName(String viccCompliantName) { + this.viccCompliantName = viccCompliantName; + return this; + } + + public CivicFeature getFeature() { + return feature; + } + + public CivicVariant setFeature(CivicFeature feature) { + this.feature = feature; + return this; + } + + public List getMolecularProfiles() { + return molecularProfiles; + } + + public CivicVariant setMolecularProfiles(List molecularProfiles) { + this.molecularProfiles = molecularProfiles; + return this; + } +} \ No newline at end of file diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/CommonPolygenicScore.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/CommonPolygenicScore.java new file mode 100644 index 000000000..740770a38 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/CommonPolygenicScore.java @@ -0,0 +1,144 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core.pgs; + +import org.opencb.biodata.models.variant.avro.OntologyTermAnnotation; +import org.opencb.biodata.models.variant.avro.PubmedReference; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +public class CommonPolygenicScore { + private String id; + private String name; + private String source; + private String version; + private List pubmedRefs; + private List traits; + private List cohorts; + private List> values; + + public CommonPolygenicScore() { + this.pubmedRefs = new ArrayList<>(); + this.traits = new ArrayList<>(); + this.cohorts = new ArrayList<>(); + this.values = new ArrayList<>(); + } + + public CommonPolygenicScore(String id, String name, String source, String version, List pubmedRefs, + List traits, List cohorts, List> values) { + this.id = id; + this.name = name; + this.source = source; + this.version = version; + this.pubmedRefs = pubmedRefs; + this.traits = traits; + this.cohorts = cohorts; + this.values = values; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("CommonPolygenicScore{"); + sb.append("id='").append(id).append('\''); + sb.append(", name='").append(name).append('\''); + sb.append(", source='").append(source).append('\''); + sb.append(", version='").append(version).append('\''); + sb.append(", pubmedRefs=").append(pubmedRefs); + sb.append(", traits=").append(traits); + sb.append(", cohorts=").append(cohorts); + sb.append(", values=").append(values); + sb.append('}'); + return sb.toString(); + } + + public String getId() { + return id; + } + + public CommonPolygenicScore setId(String id) { + this.id = id; + return this; + } + + public String getName() { + return name; + } + + public CommonPolygenicScore setName(String name) { + this.name = name; + return this; + } + + public String getSource() { + return source; + } + + public CommonPolygenicScore setSource(String source) { + this.source = source; + return this; + } + + public String getVersion() { + return version; + } + + public CommonPolygenicScore setVersion(String version) { + this.version = version; + return this; + } + + public List getPubmedRefs() { + return pubmedRefs; + } + + public CommonPolygenicScore setPubmedRefs(List pubmedRefs) { + this.pubmedRefs = pubmedRefs; + return this; + } + + public List getTraits() { + return traits; + } + + public CommonPolygenicScore setTraits(List traits) { + this.traits = traits; + return this; + } + + public List getCohorts() { + return cohorts; + } + + public CommonPolygenicScore setCohorts(List cohorts) { + this.cohorts = cohorts; + return this; + } + + public List> getValues() { + return values; + } + + public CommonPolygenicScore setValues(List> values) { + this.values = values; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/PgsCohort.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/PgsCohort.java new file mode 100644 index 000000000..c5d44e7d5 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/PgsCohort.java @@ -0,0 +1,72 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core.pgs; + +public class PgsCohort { + private String id; + private String name; + private String description; + + public PgsCohort() { + } + + public PgsCohort(String id, String name, String description) { + this.id = id; + this.name = name; + this.description = description; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("PgsCohort{"); + sb.append("id='").append(id).append('\''); + sb.append(", name='").append(name).append('\''); + sb.append(", description='").append(description).append('\''); + sb.append('}'); + return sb.toString(); + } + + public String getId() { + return id; + } + + public PgsCohort setId(String id) { + this.id = id; + return this; + } + + public String getName() { + return name; + } + + public PgsCohort setName(String name) { + this.name = name; + return this; + } + + public String getDescription() { + return description; + } + + public PgsCohort setDescription(String description) { + this.description = description; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/PolygenicScore.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/PolygenicScore.java new file mode 100644 index 000000000..181484342 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/PolygenicScore.java @@ -0,0 +1,65 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core.pgs; + +import java.util.HashMap; +import java.util.Map; + +public class PolygenicScore { + + private String id; + private Map values; + + public PolygenicScore() { + this.values = new HashMap<>(); + } + + public PolygenicScore(String id, Map values) { + this.id = id; + this.values = values; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("PolygenicScore{"); + sb.append("id='").append(id).append('\''); + sb.append(", values=").append(values); + sb.append('}'); + return sb.toString(); + } + + public String getId() { + return id; + } + + public PolygenicScore setId(String id) { + this.id = id; + return this; + } + + public Map getValues() { + return values; + } + + public PolygenicScore setValues(Map values) { + this.values = values; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/VariantPolygenicScore.java b/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/VariantPolygenicScore.java new file mode 100644 index 000000000..aff344883 --- /dev/null +++ b/biodata-models/src/main/java/org/opencb/biodata/models/core/pgs/VariantPolygenicScore.java @@ -0,0 +1,100 @@ +/* + * + * + */ + +package org.opencb.biodata.models.core.pgs; + +import java.util.List; + +public class VariantPolygenicScore { + + private String chromosome; + private int position; + private String effectAllele; + private String otherAllele; + private List polygenicScores; + + public VariantPolygenicScore() { + } + + public VariantPolygenicScore(String chromosome, int position, String effectAllele, String otherAllele, + List polygenicScores) { + this.chromosome = chromosome; + this.position = position; + this.effectAllele = effectAllele; + this.otherAllele = otherAllele; + this.polygenicScores = polygenicScores; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("VariantPolygenicScore{"); + sb.append("chromosome='").append(chromosome).append('\''); + sb.append(", position=").append(position); + sb.append(", effectAllele='").append(effectAllele).append('\''); + sb.append(", otherAllele='").append(otherAllele).append('\''); + sb.append(", polygenicScores=").append(polygenicScores); + sb.append('}'); + return sb.toString(); + } + + public String getChromosome() { + return chromosome; + } + + public VariantPolygenicScore setChromosome(String chromosome) { + this.chromosome = chromosome; + return this; + } + + public int getPosition() { + return position; + } + + public VariantPolygenicScore setPosition(int position) { + this.position = position; + return this; + } + + public String getEffectAllele() { + return effectAllele; + } + + public VariantPolygenicScore setEffectAllele(String effectAllele) { + this.effectAllele = effectAllele; + return this; + } + + public String getOtherAllele() { + return otherAllele; + } + + public VariantPolygenicScore setOtherAllele(String otherAllele) { + this.otherAllele = otherAllele; + return this; + } + + public List getPolygenicScores() { + return polygenicScores; + } + + public VariantPolygenicScore setPolygenicScores(List polygenicScores) { + this.polygenicScores = polygenicScores; + return this; + } +} diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/pharma/guideline/Literature.java b/biodata-models/src/main/java/org/opencb/biodata/models/pharma/guideline/Literature.java index e657d4141..81eeb6513 100644 --- a/biodata-models/src/main/java/org/opencb/biodata/models/pharma/guideline/Literature.java +++ b/biodata-models/src/main/java/org/opencb/biodata/models/pharma/guideline/Literature.java @@ -8,7 +8,9 @@ public class Literature { private String _sameAs; private List crossReferences; private String objCls; + private String pubDate; private List terms; + private String type; public float getId() { return id; @@ -55,6 +57,15 @@ public Literature setObjCls(String objCls) { return this; } + public String getPubDate() { + return pubDate; + } + + public Literature setPubDate(String pubDate) { + this.pubDate = pubDate; + return this; + } + public List getTerms() { return terms; } @@ -63,6 +74,15 @@ public Literature setTerms(List terms) { this.terms = terms; return this; } + + public String getType() { + return type; + } + + public Literature setType(String type) { + this.type = type; + return this; + } } diff --git a/biodata-models/src/main/java/org/opencb/biodata/models/pharma/guideline/PharmaDosingGuideline.java b/biodata-models/src/main/java/org/opencb/biodata/models/pharma/guideline/PharmaDosingGuideline.java index 0f2e39ef8..11e1b9f09 100644 --- a/biodata-models/src/main/java/org/opencb/biodata/models/pharma/guideline/PharmaDosingGuideline.java +++ b/biodata-models/src/main/java/org/opencb/biodata/models/pharma/guideline/PharmaDosingGuideline.java @@ -15,6 +15,7 @@ public class PharmaDosingGuideline { private boolean hasTestingInfo; private List history; private List literature; + private boolean otherPrescribingGuidance; private boolean pediatric; private PediatricMarkdown pediatricMarkdown; private boolean recommendation; @@ -136,6 +137,15 @@ public PharmaDosingGuideline setLiterature(List literature) { return this; } + public boolean isOtherPrescribingGuidance() { + return otherPrescribingGuidance; + } + + public PharmaDosingGuideline setOtherPrescribingGuidance(boolean otherPrescribingGuidance) { + this.otherPrescribingGuidance = otherPrescribingGuidance; + return this; + } + public boolean isPediatric() { return pediatric; } diff --git a/pom.xml b/pom.xml index 8f3244305..50975f0e7 100644 --- a/pom.xml +++ b/pom.xml @@ -37,6 +37,7 @@ + 7.0.0-SNAPSHOT 2.14.3 @@ -50,7 +51,7 @@ 3.14.0 19.0 - 2.12.0 + 2.15.0 5.0.0 0.6.0a5 4.3.1 @@ -67,6 +68,7 @@ UTF-8 1.2.17 1.9.13 + 5.4.0 @@ -334,6 +336,17 @@ log4j ${log4j.version} + + + org.apache.poi + poi + ${poi.version} + + + org.apache.poi + poi-ooxml + ${poi.version} +