diff --git a/.github/workflows/test-analysis.yml b/.github/workflows/test-analysis.yml index 732d92a4e56..a83cea15dc9 100644 --- a/.github/workflows/test-analysis.yml +++ b/.github/workflows/test-analysis.yml @@ -8,6 +8,7 @@ on: required: true mvn_opts: type: string + required: false default: "" secrets: @@ -82,3 +83,4 @@ jobs: report_paths: './**/surefire-reports/TEST-*.xml' commit: '${{ github.sha }}' fail_on_test_failures: true + diff --git a/opencga-analysis/src/main/java/org/opencb/opencga/analysis/wrappers/exomiser/ExomiserWrapperAnalysisExecutor.java b/opencga-analysis/src/main/java/org/opencb/opencga/analysis/wrappers/exomiser/ExomiserWrapperAnalysisExecutor.java index 1b19e410b5b..099d3c6c7db 100644 --- a/opencga-analysis/src/main/java/org/opencb/opencga/analysis/wrappers/exomiser/ExomiserWrapperAnalysisExecutor.java +++ b/opencga-analysis/src/main/java/org/opencb/opencga/analysis/wrappers/exomiser/ExomiserWrapperAnalysisExecutor.java @@ -7,7 +7,6 @@ import org.opencb.biodata.models.clinical.Phenotype; import org.opencb.biodata.models.clinical.pedigree.Member; import org.opencb.biodata.models.clinical.pedigree.Pedigree; -import org.opencb.biodata.models.core.SexOntologyTermAnnotation; import org.opencb.biodata.models.pedigree.IndividualProperty; import org.opencb.commons.datastore.core.QueryOptions; import org.opencb.commons.exec.Command; @@ -21,12 +20,9 @@ import org.opencb.opencga.core.exceptions.ToolExecutorException; import org.opencb.opencga.core.models.family.Family; import org.opencb.opencga.core.models.individual.Individual; -import org.opencb.opencga.core.models.sample.Sample; import org.opencb.opencga.core.tools.annotations.ToolExecutor; import org.opencb.opencga.storage.core.exceptions.StorageEngineException; -import org.opencb.opencga.storage.core.variant.adaptors.VariantField; import org.opencb.opencga.storage.core.variant.adaptors.VariantQuery; -import org.opencb.opencga.storage.core.variant.adaptors.VariantQueryParam; import org.opencb.opencga.storage.core.variant.io.VariantWriterFactory; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -36,7 +32,6 @@ import java.nio.file.Path; import java.nio.file.Paths; import java.util.*; -import java.util.stream.Collectors; @ToolExecutor(id = ExomiserWrapperAnalysisExecutor.ID, tool = ExomiserWrapperAnalysis.ID, @@ -133,7 +128,8 @@ public void run() throws ToolException { .sample(sampleId) .includeSample(samples) .includeSampleData("GT") - .unknownGenotype("./."); + .unknownGenotype("./.") + .append("includeAllFromSampleIndex", true); QueryOptions queryOptions = new QueryOptions(QueryOptions.INCLUDE, "id,studies.samples"); diff --git a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/OpenCgaCompleter.java b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/OpenCgaCompleter.java index 8b3fc6bbc51..b023618b21f 100644 --- a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/OpenCgaCompleter.java +++ b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/OpenCgaCompleter.java @@ -1,5 +1,5 @@ /* -* Copyright 2015-2023-08-31 OpenCB +* Copyright 2015-2023-09-08 OpenCB * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/OpencgaCliOptionsParser.java b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/OpencgaCliOptionsParser.java index 471a564c487..93ae1e2ed26 100644 --- a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/OpencgaCliOptionsParser.java +++ b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/OpencgaCliOptionsParser.java @@ -1,5 +1,5 @@ /* -* Copyright 2015-2023-08-31 OpenCB +* Copyright 2015-2023-09-08 OpenCB * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/AnalysisClinicalCommandOptions.java b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/AnalysisClinicalCommandOptions.java index 48261ca8a3c..95636ad4c3f 100644 --- a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/AnalysisClinicalCommandOptions.java +++ b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/AnalysisClinicalCommandOptions.java @@ -275,7 +275,7 @@ public class DistinctCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list of Clinical Analysis IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of Clinical Analysis IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list of Clinical Analysis UUIDs up to a maximum of 100", required = false, arity = 1) @@ -284,7 +284,7 @@ public class DistinctCommandOptions { @Parameter(names = {"--type"}, description = "Clinical Analysis type", required = false, arity = 1) public String type; - @Parameter(names = {"--disorder"}, description = "Clinical Analysis disorder", required = false, arity = 1) + @Parameter(names = {"--disorder"}, description = "Clinical Analysis disorder. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String disorder; @Parameter(names = {"--files"}, description = "Clinical Analysis files", required = false, arity = 1) @@ -364,7 +364,7 @@ public class DistinctInterpretationCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list of Interpretation IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of Interpretation IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list of Interpretation UUIDs up to a maximum of 100", required = false, arity = 1) @@ -376,7 +376,7 @@ public class DistinctInterpretationCommandOptions { @Parameter(names = {"--analyst-id"}, description = "Analyst ID", required = false, arity = 1) public String analystId; - @Parameter(names = {"--method-name"}, description = "Interpretation method name", required = false, arity = 1) + @Parameter(names = {"--method-name"}, description = "Interpretation method name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String methodName; @Parameter(names = {"--panels"}, description = "Interpretation panels", required = false, arity = 1) @@ -432,7 +432,7 @@ public class SearchInterpretationCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list of Interpretation IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of Interpretation IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list of Interpretation UUIDs up to a maximum of 100", required = false, arity = 1) @@ -444,7 +444,7 @@ public class SearchInterpretationCommandOptions { @Parameter(names = {"--analyst-id"}, description = "Analyst ID", required = false, arity = 1) public String analystId; - @Parameter(names = {"--method-name"}, description = "Interpretation method name", required = false, arity = 1) + @Parameter(names = {"--method-name"}, description = "Interpretation method name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String methodName; @Parameter(names = {"--panels"}, description = "Interpretation panels", required = false, arity = 1) @@ -1488,7 +1488,7 @@ public class SearchCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list of Clinical Analysis IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of Clinical Analysis IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list of Clinical Analysis UUIDs up to a maximum of 100", required = false, arity = 1) @@ -1497,7 +1497,7 @@ public class SearchCommandOptions { @Parameter(names = {"--type"}, description = "Clinical Analysis type", required = false, arity = 1) public String type; - @Parameter(names = {"--disorder"}, description = "Clinical Analysis disorder", required = false, arity = 1) + @Parameter(names = {"--disorder"}, description = "Clinical Analysis disorder. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String disorder; @Parameter(names = {"--files"}, description = "Clinical Analysis files", required = false, arity = 1) diff --git a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/CohortsCommandOptions.java b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/CohortsCommandOptions.java index 13373914df4..03f08e58c9e 100644 --- a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/CohortsCommandOptions.java +++ b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/CohortsCommandOptions.java @@ -242,10 +242,10 @@ public class DistinctCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list of cohort IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of cohort IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; - @Parameter(names = {"--name", "-n"}, description = "Comma separated list of cohort names up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--name", "-n"}, description = "Comma separated list of cohort names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String name; @Parameter(names = {"--uuid"}, description = "Comma separated list of cohort IDs up to a maximum of 100", required = false, arity = 1) @@ -334,7 +334,7 @@ public class GenerateCommandOptions { @Parameter(names = {"--status"}, description = "Filter by status", required = false, arity = 1) public String status; - @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names", required = false, arity = 1) + @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String phenotypes; @Parameter(names = {"--annotation"}, description = "Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0", required = false, arity = 1) @@ -411,10 +411,10 @@ public class SearchCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list of cohort IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of cohort IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; - @Parameter(names = {"--name", "-n"}, description = "Comma separated list of cohort names up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--name", "-n"}, description = "Comma separated list of cohort names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String name; @Parameter(names = {"--uuid"}, description = "Comma separated list of cohort IDs up to a maximum of 100", required = false, arity = 1) diff --git a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/DiseasePanelsCommandOptions.java b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/DiseasePanelsCommandOptions.java index c6e353a7dca..1f0f1cbb9bc 100644 --- a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/DiseasePanelsCommandOptions.java +++ b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/DiseasePanelsCommandOptions.java @@ -157,37 +157,37 @@ public class DistinctCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list of panel IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of panel IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list of panel UUIDs up to a maximum of 100", required = false, arity = 1) public String uuid; - @Parameter(names = {"--name", "-n"}, description = "Comma separated list of panel names up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--name", "-n"}, description = "Comma separated list of panel names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String name; @Parameter(names = {"--internal-status"}, description = "Filter by internal status", required = false, arity = 1) public String internalStatus; - @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names", required = false, arity = 1) + @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String disorders; - @Parameter(names = {"--variants"}, description = "Comma separated list of variant ids", required = false, arity = 1) + @Parameter(names = {"--variants"}, description = "Comma separated list of variant ids. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String variants; - @Parameter(names = {"--genes"}, description = "Comma separated list of gene ids", required = false, arity = 1) + @Parameter(names = {"--genes"}, description = "Comma separated list of gene ids. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String genes; @Parameter(names = {"--source"}, description = "Comma separated list of source ids or names.", required = false, arity = 1) public String source; - @Parameter(names = {"--regions"}, description = "Comma separated list of regions", required = false, arity = 1) + @Parameter(names = {"--regions"}, description = "Comma separated list of regions. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String regions; - @Parameter(names = {"--categories"}, description = "Comma separated list of category names", required = false, arity = 1) + @Parameter(names = {"--categories"}, description = "Comma separated list of category names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String categories; - @Parameter(names = {"--tags"}, description = "Panel tags", required = false, arity = 1) + @Parameter(names = {"--tags"}, description = "Panel tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String tags; @Parameter(names = {"--deleted"}, description = "Boolean to retrieve deleted entries", required = false, help = true, arity = 0) @@ -275,37 +275,37 @@ public class SearchCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list of panel IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of panel IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list of panel UUIDs up to a maximum of 100", required = false, arity = 1) public String uuid; - @Parameter(names = {"--name", "-n"}, description = "Comma separated list of panel names up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--name", "-n"}, description = "Comma separated list of panel names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String name; @Parameter(names = {"--internal-status"}, description = "Filter by internal status", required = false, arity = 1) public String internalStatus; - @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names", required = false, arity = 1) + @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String disorders; - @Parameter(names = {"--variants"}, description = "Comma separated list of variant ids", required = false, arity = 1) + @Parameter(names = {"--variants"}, description = "Comma separated list of variant ids. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String variants; - @Parameter(names = {"--genes"}, description = "Comma separated list of gene ids", required = false, arity = 1) + @Parameter(names = {"--genes"}, description = "Comma separated list of gene ids. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String genes; @Parameter(names = {"--source"}, description = "Comma separated list of source ids or names.", required = false, arity = 1) public String source; - @Parameter(names = {"--regions"}, description = "Comma separated list of regions", required = false, arity = 1) + @Parameter(names = {"--regions"}, description = "Comma separated list of regions. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String regions; - @Parameter(names = {"--categories"}, description = "Comma separated list of category names", required = false, arity = 1) + @Parameter(names = {"--categories"}, description = "Comma separated list of category names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String categories; - @Parameter(names = {"--tags"}, description = "Panel tags", required = false, arity = 1) + @Parameter(names = {"--tags"}, description = "Panel tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String tags; @Parameter(names = {"--deleted"}, description = "Boolean to retrieve deleted entries", required = false, help = true, arity = 0) diff --git a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/FamiliesCommandOptions.java b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/FamiliesCommandOptions.java index 9530f60074d..3c57ef335ba 100644 --- a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/FamiliesCommandOptions.java +++ b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/FamiliesCommandOptions.java @@ -252,10 +252,10 @@ public class DistinctCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list family IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list family IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; - @Parameter(names = {"--name", "-n"}, description = "Comma separated list family names up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--name", "-n"}, description = "Comma separated list family names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String name; @Parameter(names = {"--uuid"}, description = "Comma separated list family UUIDs up to a maximum of 100", required = false, arity = 1) @@ -270,10 +270,10 @@ public class DistinctCommandOptions { @Parameter(names = {"--samples"}, description = "Comma separated list of member's samples", required = false, arity = 1) public String samples; - @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names", required = false, arity = 1) + @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String phenotypes; - @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names", required = false, arity = 1) + @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String disorders; @Parameter(names = {"--creation-date", "--cd"}, description = "Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805", required = false, arity = 1) @@ -335,10 +335,10 @@ public class SearchCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list family IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list family IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; - @Parameter(names = {"--name", "-n"}, description = "Comma separated list family names up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--name", "-n"}, description = "Comma separated list family names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String name; @Parameter(names = {"--uuid"}, description = "Comma separated list family UUIDs up to a maximum of 100", required = false, arity = 1) @@ -353,10 +353,10 @@ public class SearchCommandOptions { @Parameter(names = {"--samples"}, description = "Comma separated list of member's samples", required = false, arity = 1) public String samples; - @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names", required = false, arity = 1) + @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String phenotypes; - @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names", required = false, arity = 1) + @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String disorders; @Parameter(names = {"--creation-date", "--cd"}, description = "Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805", required = false, arity = 1) diff --git a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/FilesCommandOptions.java b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/FilesCommandOptions.java index d1d4e0bf0a8..5ea18955f58 100644 --- a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/FilesCommandOptions.java +++ b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/FilesCommandOptions.java @@ -327,19 +327,19 @@ public class DistinctCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list of file IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of file IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list file UUIDs up to a maximum of 100", required = false, arity = 1) public String uuid; - @Parameter(names = {"--name", "-n"}, description = "Comma separated list of file names", required = false, arity = 1) + @Parameter(names = {"--name", "-n"}, description = "Comma separated list of file names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String name; - @Parameter(names = {"--path"}, description = "Comma separated list of paths", required = false, arity = 1) + @Parameter(names = {"--path"}, description = "Comma separated list of paths. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String path; - @Parameter(names = {"--uri", "--input", "-i"}, description = "Comma separated list of uris", required = false, arity = 1) + @Parameter(names = {"--uri", "--input", "-i"}, description = "Comma separated list of uris. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String uri; @Parameter(names = {"--type"}, description = "File type, either FILE or DIRECTORY", required = false, arity = 1) @@ -378,7 +378,7 @@ public class DistinctCommandOptions { @Parameter(names = {"--description"}, description = "Description", required = false, arity = 1) public String description; - @Parameter(names = {"--tags"}, description = "Tags", required = false, arity = 1) + @Parameter(names = {"--tags"}, description = "Tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String tags; @Parameter(names = {"--size"}, description = "File size", required = false, arity = 1) @@ -609,19 +609,19 @@ public class SearchCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list of file IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of file IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list file UUIDs up to a maximum of 100", required = false, arity = 1) public String uuid; - @Parameter(names = {"--name", "-n"}, description = "Comma separated list of file names", required = false, arity = 1) + @Parameter(names = {"--name", "-n"}, description = "Comma separated list of file names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String name; - @Parameter(names = {"--path"}, description = "Comma separated list of paths", required = false, arity = 1) + @Parameter(names = {"--path"}, description = "Comma separated list of paths. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String path; - @Parameter(names = {"--uri", "--input", "-i"}, description = "Comma separated list of uris", required = false, arity = 1) + @Parameter(names = {"--uri", "--input", "-i"}, description = "Comma separated list of uris. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String uri; @Parameter(names = {"--type"}, description = "File type, either FILE or DIRECTORY", required = false, arity = 1) @@ -660,7 +660,7 @@ public class SearchCommandOptions { @Parameter(names = {"--description"}, description = "Description", required = false, arity = 1) public String description; - @Parameter(names = {"--tags"}, description = "Tags", required = false, arity = 1) + @Parameter(names = {"--tags"}, description = "Tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String tags; @Parameter(names = {"--size"}, description = "File size", required = false, arity = 1) diff --git a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/IndividualsCommandOptions.java b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/IndividualsCommandOptions.java index a9e20c70232..d0238597f52 100644 --- a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/IndividualsCommandOptions.java +++ b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/IndividualsCommandOptions.java @@ -350,13 +350,13 @@ public class DistinctCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list individual IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list individual IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list individual UUIDs up to a maximum of 100", required = false, arity = 1) public String uuid; - @Parameter(names = {"--name", "-n"}, description = "Comma separated list individual names up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--name", "-n"}, description = "Comma separated list individual names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String name; @Parameter(names = {"--family-ids"}, description = "Comma separated list of family ids the individuals may belong to.", required = false, arity = 1) @@ -374,22 +374,22 @@ public class DistinctCommandOptions { @Parameter(names = {"--sex"}, description = "Individual sex", required = false, arity = 1) public String sex; - @Parameter(names = {"--ethnicity"}, description = "Individual ethnicity", required = false, arity = 1) + @Parameter(names = {"--ethnicity"}, description = "Individual ethnicity. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String ethnicity; @Parameter(names = {"--date-of-birth"}, description = "Individual date of birth", required = false, arity = 1) public String dateOfBirth; - @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names", required = false, arity = 1) + @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String disorders; - @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names", required = false, arity = 1) + @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String phenotypes; - @Parameter(names = {"--population-name"}, description = "Population name", required = false, arity = 1) + @Parameter(names = {"--population-name"}, description = "Population name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String populationName; - @Parameter(names = {"--population-subpopulation"}, description = "Subpopulation name", required = false, arity = 1) + @Parameter(names = {"--population-subpopulation"}, description = "Subpopulation name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String populationSubpopulation; @Parameter(names = {"--karyotypic-sex"}, description = "Individual karyotypic sex", required = false, arity = 1) @@ -457,13 +457,13 @@ public class SearchCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list individual IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list individual IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list individual UUIDs up to a maximum of 100", required = false, arity = 1) public String uuid; - @Parameter(names = {"--name", "-n"}, description = "Comma separated list individual names up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--name", "-n"}, description = "Comma separated list individual names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String name; @Parameter(names = {"--father"}, description = "Father ID, name or UUID", required = false, arity = 1) @@ -484,19 +484,19 @@ public class SearchCommandOptions { @Parameter(names = {"--date-of-birth"}, description = "Individual date of birth", required = false, arity = 1) public String dateOfBirth; - @Parameter(names = {"--ethnicity"}, description = "Individual ethnicity", required = false, arity = 1) + @Parameter(names = {"--ethnicity"}, description = "Individual ethnicity. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String ethnicity; - @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names", required = false, arity = 1) + @Parameter(names = {"--disorders"}, description = "Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String disorders; - @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names", required = false, arity = 1) + @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String phenotypes; - @Parameter(names = {"--population-name"}, description = "Population name", required = false, arity = 1) + @Parameter(names = {"--population-name"}, description = "Population name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String populationName; - @Parameter(names = {"--population-subpopulation"}, description = "Subpopulation name", required = false, arity = 1) + @Parameter(names = {"--population-subpopulation"}, description = "Subpopulation name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String populationSubpopulation; @Parameter(names = {"--karyotypic-sex"}, description = "Individual karyotypic sex", required = false, arity = 1) diff --git a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/JobsCommandOptions.java b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/JobsCommandOptions.java index 44eac65bf28..04b6caae03c 100644 --- a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/JobsCommandOptions.java +++ b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/JobsCommandOptions.java @@ -241,13 +241,13 @@ public class DistinctCommandOptions { @Parameter(names = {"--other-studies"}, description = "Flag indicating the entries being queried can belong to any related study, not just the primary one.", required = false, help = true, arity = 0) public boolean otherStudies = false; - @Parameter(names = {"--id"}, description = "Comma separated list of job IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of job IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list of job UUIDs up to a maximum of 100", required = false, arity = 1) public String uuid; - @Parameter(names = {"--tool-id"}, description = "Tool ID executed by the job", required = false, arity = 1) + @Parameter(names = {"--tool-id"}, description = "Tool ID executed by the job. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String toolId; @Parameter(names = {"--tool-type"}, description = "Tool type executed by the job [OPERATION, ANALYSIS]", required = false, arity = 1) @@ -362,13 +362,13 @@ public class SearchCommandOptions { @Parameter(names = {"--other-studies"}, description = "Flag indicating the entries being queried can belong to any related study, not just the primary one.", required = false, help = true, arity = 0) public boolean otherStudies = false; - @Parameter(names = {"--id"}, description = "Comma separated list of job IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list of job IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list of job UUIDs up to a maximum of 100", required = false, arity = 1) public String uuid; - @Parameter(names = {"--tool-id"}, description = "Tool ID executed by the job", required = false, arity = 1) + @Parameter(names = {"--tool-id"}, description = "Tool ID executed by the job. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String toolId; @Parameter(names = {"--tool-type"}, description = "Tool type executed by the job [OPERATION, ANALYSIS]", required = false, arity = 1) diff --git a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/SamplesCommandOptions.java b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/SamplesCommandOptions.java index 0099fbf2a90..8cfc8fed346 100644 --- a/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/SamplesCommandOptions.java +++ b/opencga-app/src/main/java/org/opencb/opencga/app/cli/main/options/SamplesCommandOptions.java @@ -305,7 +305,7 @@ public class DistinctCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list sample IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list sample IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list sample UUIDs up to a maximum of 100", required = false, arity = 1) @@ -356,7 +356,7 @@ public class DistinctCommandOptions { @Parameter(names = {"--collection-method"}, description = "Collection method", required = false, arity = 1) public String collectionMethod; - @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names", required = false, arity = 1) + @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String phenotypes; @Parameter(names = {"--annotation"}, description = "Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0", required = false, arity = 1) @@ -468,7 +468,7 @@ public class SearchCommandOptions { @Parameter(names = {"--study", "-s"}, description = "Study [[user@]project:]study where study and project can be either the ID or UUID", required = false, arity = 1) public String study; - @Parameter(names = {"--id"}, description = "Comma separated list sample IDs up to a maximum of 100", required = false, arity = 1) + @Parameter(names = {"--id"}, description = "Comma separated list sample IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String id; @Parameter(names = {"--uuid"}, description = "Comma separated list sample UUIDs up to a maximum of 100", required = false, arity = 1) @@ -519,7 +519,7 @@ public class SearchCommandOptions { @Parameter(names = {"--collection-method"}, description = "Collection method", required = false, arity = 1) public String collectionMethod; - @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names", required = false, arity = 1) + @Parameter(names = {"--phenotypes"}, description = "Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.", required = false, arity = 1) public String phenotypes; @Parameter(names = {"--annotation"}, description = "Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0", required = false, arity = 1) diff --git a/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/MongoDBAdaptor.java b/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/MongoDBAdaptor.java index 376c835b8a8..a3b47c037dc 100644 --- a/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/MongoDBAdaptor.java +++ b/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/MongoDBAdaptor.java @@ -376,6 +376,41 @@ protected OpenCGAResult groupBy(MongoDBCollection collection, Bson query, List(aggregate); } + public static QueryOptions addPrefixInOptions(QueryOptions options, String prefix) { + if (options == null) { + return null; + } + + QueryOptions queryOptions = new QueryOptions(options); + + if (queryOptions.containsKey(QueryOptions.INCLUDE)) { + Set includeList = new HashSet<>(queryOptions.getAsStringList(QueryOptions.INCLUDE)); + List newInclude = new ArrayList<>(includeList.size()); + for (String key : includeList) { + if (key.startsWith(prefix)) { + newInclude.add(key); + } else { + newInclude.add(prefix + key); + } + } + queryOptions.put(QueryOptions.INCLUDE, newInclude); + } + if (queryOptions.containsKey(QueryOptions.EXCLUDE)) { + Set excludeList = new HashSet<>(queryOptions.getAsStringList(QueryOptions.EXCLUDE)); + List newExclude = new ArrayList<>(excludeList.size()); + for (String key : excludeList) { + if (key.startsWith(prefix)) { + newExclude.add(key); + } else { + newExclude.add(prefix + key); + } + } + queryOptions.put(QueryOptions.EXCLUDE, newExclude); + } + + return queryOptions; + } + /** * Filter QueryOptions object to ensure the keys provided are always included. * diff --git a/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/ProjectMongoDBAdaptor.java b/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/ProjectMongoDBAdaptor.java index 297ff31f27e..1474f1ed4e1 100644 --- a/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/ProjectMongoDBAdaptor.java +++ b/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/ProjectMongoDBAdaptor.java @@ -771,8 +771,10 @@ private MongoDBIterator getMongoCursor(ClientSession clientSession, Qu aggregates.add(Aggregates.match(bsonQuery)); // Check include - QueryOptions qOptions = options != null ? new QueryOptions(options) : new QueryOptions(); - List includeList = new ArrayList<>(); + QueryOptions qOptions = filterQueryOptions(options, Arrays.asList(QueryParams.UID.key(), QueryParams.FQN.key())); + qOptions = addPrefixInOptions(qOptions, "projects."); + + /*List includeList = new ArrayList<>(); if (options != null && options.get(QueryOptions.INCLUDE) != null) { List optionsAsStringList = options.getAsStringList(QueryOptions.INCLUDE); includeList.addAll(optionsAsStringList.stream().collect(Collectors.toList())); @@ -792,6 +794,7 @@ private MongoDBIterator getMongoCursor(ClientSession clientSession, Qu } qOptions.put(QueryOptions.INCLUDE, includeList); } + */ for (Bson aggregate : aggregates) { logger.debug("Get project: Aggregate : {}", aggregate.toBsonDocument()); diff --git a/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/StudyMongoDBAdaptor.java b/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/StudyMongoDBAdaptor.java index 34510e96868..d2e01a601be 100644 --- a/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/StudyMongoDBAdaptor.java +++ b/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/StudyMongoDBAdaptor.java @@ -318,10 +318,10 @@ Study insert(ClientSession clientSession, Project project, Study study) } @Override - public OpenCGAResult getAllStudiesInProject(long projectId, QueryOptions options) throws CatalogDBException { + public OpenCGAResult getAllStudiesInProject(long projectUid, QueryOptions options) throws CatalogDBException { long startTime = startQuery(); - dbAdaptorFactory.getCatalogProjectDbAdaptor().checkId(projectId); - Query query = new Query(QueryParams.PROJECT_ID.key(), projectId); + dbAdaptorFactory.getCatalogProjectDbAdaptor().checkId(projectUid); + Query query = new Query(QueryParams.PROJECT_UID.key(), projectUid); return endQuery(startTime, get(query, options)); } diff --git a/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/iterators/ProjectCatalogMongoDBIterator.java b/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/iterators/ProjectCatalogMongoDBIterator.java index 52aa62fb1e0..0cc8fc56180 100644 --- a/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/iterators/ProjectCatalogMongoDBIterator.java +++ b/opencga-catalog/src/main/java/org/opencb/opencga/catalog/db/mongodb/iterators/ProjectCatalogMongoDBIterator.java @@ -25,6 +25,7 @@ public class ProjectCatalogMongoDBIterator extends CatalogMongoDBIterator private final String user; private final QueryOptions options; + private boolean includeStudyInfo; private final StudyMongoDBAdaptor studyDBAdaptor; private QueryOptions studyQueryOptions; @@ -44,6 +45,7 @@ public ProjectCatalogMongoDBIterator(MongoDBIterator mongoCursor, Clie this.studyDBAdaptor = dbAdaptorFactory.getCatalogStudyDBAdaptor(); this.options = options != null ? new QueryOptions(options) : new QueryOptions(); + this.includeStudyInfo = includeStudyInfo(); this.studyQueryOptions = createInnerQueryOptionsForVersionedEntity(this.options, ProjectDBAdaptor.QueryParams.STUDIES.key(), false); this.studyQueryOptions = MongoDBAdaptor.filterQueryOptions(this.studyQueryOptions, Collections.singletonList(MongoDBAdaptor.PRIVATE_PROJECT)); @@ -90,8 +92,7 @@ private void fetchNextBatch() { projectListBuffer.add(projectDocument); counter++; - if (options == null || !options.containsKey(QueryOptions.EXCLUDE) - || !options.getAsStringList(QueryOptions.EXCLUDE).contains("projects.studies")) { + if (includeStudyInfo) { projectUidSet.add(projectDocument.get(UID, Long.class)); } } @@ -130,4 +131,29 @@ private void fetchNextBatch() { } } } + + private boolean includeStudyInfo() { + if (options == null) { + return true; + } + if (options.containsKey(QueryOptions.EXCLUDE)) { + List list = options.getAsStringList(QueryOptions.EXCLUDE); + for (String exclude : list) { + if (exclude.equals("studies") || exclude.equals("projects.studies")) { + return false; + } + } + return true; + } else if (options.containsKey(QueryOptions.INCLUDE)) { + List list = options.getAsStringList(QueryOptions.INCLUDE); + for (String include : list) { + if (include.startsWith("studies") || include.startsWith("projects.studies")) { + return true; + } + } + return false; + } else { + return true; + } + } } diff --git a/opencga-catalog/src/main/java/org/opencb/opencga/catalog/managers/ProjectManager.java b/opencga-catalog/src/main/java/org/opencb/opencga/catalog/managers/ProjectManager.java index 249d14ab057..7900d958a42 100644 --- a/opencga-catalog/src/main/java/org/opencb/opencga/catalog/managers/ProjectManager.java +++ b/opencga-catalog/src/main/java/org/opencb/opencga/catalog/managers/ProjectManager.java @@ -610,7 +610,9 @@ public OpenCGAResult incrementRelease(String projectStr, String session int currentRelease = project.getCurrentRelease(); // Check current release has been used at least in one study or file or cohort or individual... - List allStudiesInProject = project.getStudies(); + QueryOptions studyOptions = keepFieldInQueryOptions(StudyManager.INCLUDE_STUDY_IDS, StudyDBAdaptor.QueryParams.RELEASE.key()); + OpenCGAResult studyResult = studyDBAdaptor.getAllStudiesInProject(projectUid, studyOptions); + List allStudiesInProject = studyResult.getResults(); if (allStudiesInProject.isEmpty()) { throw new CatalogException("Cannot increment current release number. No studies found for release " + currentRelease); } diff --git a/opencga-catalog/src/test/java/org/opencb/opencga/catalog/managers/ProjectManagerTest.java b/opencga-catalog/src/test/java/org/opencb/opencga/catalog/managers/ProjectManagerTest.java index 2490163b781..611a3a6204b 100644 --- a/opencga-catalog/src/test/java/org/opencb/opencga/catalog/managers/ProjectManagerTest.java +++ b/opencga-catalog/src/test/java/org/opencb/opencga/catalog/managers/ProjectManagerTest.java @@ -17,6 +17,7 @@ package org.opencb.opencga.catalog.managers; import com.fasterxml.jackson.core.JsonProcessingException; +import org.apache.commons.collections4.CollectionUtils; import org.junit.Before; import org.junit.Rule; import org.junit.Test; @@ -161,6 +162,42 @@ public void searchProjects() throws CatalogException { } + @Test + public void searchProjectsUsingInclude() throws CatalogException { + OpenCGAResult projects = catalogManager.getProjectManager().search(new Query(), + new QueryOptions(QueryOptions.INCLUDE, ProjectDBAdaptor.QueryParams.ID.key()), sessionIdUser); + assertEquals(1, projects.getNumResults()); + for (Project project : projects.getResults()) { + assertNotNull(project.getId()); + assertNull(project.getDescription()); + assertNull(project.getName()); + assertNull(project.getStudies()); + assertTrue(CollectionUtils.isEmpty(project.getStudies())); + } + + projects = catalogManager.getProjectManager().search(new Query(), + new QueryOptions(QueryOptions.INCLUDE, ProjectDBAdaptor.QueryParams.STUDIES.key()), sessionIdUser); + assertEquals(1, projects.getNumResults()); + for (Project project : projects.getResults()) { + assertNull(project.getId()); + assertNull(project.getDescription()); + assertNull(project.getName()); + assertNotNull(project.getStudies()); + assertTrue(CollectionUtils.isNotEmpty(project.getStudies())); + } + + projects = catalogManager.getProjectManager().search(new Query(), + new QueryOptions(QueryOptions.EXCLUDE, ProjectDBAdaptor.QueryParams.NAME.key()), sessionIdUser); + assertEquals(1, projects.getNumResults()); + for (Project project : projects.getResults()) { + assertNotNull(project.getId()); + assertNull(project.getName()); + assertNotNull(project.getDescription()); + assertNotNull(project.getStudies()); + assertFalse(CollectionUtils.isEmpty(project.getStudies())); + } + } + @Test public void getSharedProjects() throws CatalogException { try { diff --git a/opencga-client/src/main/R/R/Admin-methods.R b/opencga-client/src/main/R/R/Admin-methods.R index 683aadd80e1..52e55fc3918 100644 --- a/opencga-client/src/main/R/R/Admin-methods.R +++ b/opencga-client/src/main/R/R/Admin-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/R/R/Alignment-methods.R b/opencga-client/src/main/R/R/Alignment-methods.R index 175943692f6..66dcf64a9a4 100644 --- a/opencga-client/src/main/R/R/Alignment-methods.R +++ b/opencga-client/src/main/R/R/Alignment-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/R/R/AllGenerics.R b/opencga-client/src/main/R/R/AllGenerics.R index 088e6976532..2b49e7247d0 100644 --- a/opencga-client/src/main/R/R/AllGenerics.R +++ b/opencga-client/src/main/R/R/AllGenerics.R @@ -1,26 +1,26 @@ # ############################################################################## ## UserClient -setGeneric("userClient", function(OpencgaR, filterId, users, user, endpointName, params=NULL, ...) +setGeneric("userClient", function(OpencgaR, users, user, filterId, endpointName, params=NULL, ...) standardGeneric("userClient")) # ############################################################################## ## ProjectClient -setGeneric("projectClient", function(OpencgaR, project, projects, endpointName, params=NULL, ...) +setGeneric("projectClient", function(OpencgaR, projects, project, endpointName, params=NULL, ...) standardGeneric("projectClient")) # ############################################################################## ## StudyClient -setGeneric("studyClient", function(OpencgaR, members, variableSet, studies, study, templateId, group, endpointName, params=NULL, ...) +setGeneric("studyClient", function(OpencgaR, study, group, variableSet, studies, members, templateId, endpointName, params=NULL, ...) standardGeneric("studyClient")) # ############################################################################## ## FileClient -setGeneric("fileClient", function(OpencgaR, members, annotationSet, file, files, folder, endpointName, params=NULL, ...) +setGeneric("fileClient", function(OpencgaR, folder, annotationSet, file, members, files, endpointName, params=NULL, ...) standardGeneric("fileClient")) # ############################################################################## ## JobClient -setGeneric("jobClient", function(OpencgaR, job, members, jobs, endpointName, params=NULL, ...) +setGeneric("jobClient", function(OpencgaR, members, jobs, job, endpointName, params=NULL, ...) standardGeneric("jobClient")) # ############################################################################## @@ -30,7 +30,7 @@ setGeneric("sampleClient", function(OpencgaR, samples, members, sample, annotati # ############################################################################## ## IndividualClient -setGeneric("individualClient", function(OpencgaR, members, individuals, annotationSet, individual, endpointName, params=NULL, ...) +setGeneric("individualClient", function(OpencgaR, individuals, members, individual, annotationSet, endpointName, params=NULL, ...) standardGeneric("individualClient")) # ############################################################################## @@ -40,7 +40,7 @@ setGeneric("familyClient", function(OpencgaR, family, members, families, annotat # ############################################################################## ## CohortClient -setGeneric("cohortClient", function(OpencgaR, members, cohort, annotationSet, cohorts, endpointName, params=NULL, ...) +setGeneric("cohortClient", function(OpencgaR, annotationSet, members, cohort, cohorts, endpointName, params=NULL, ...) standardGeneric("cohortClient")) # ############################################################################## @@ -60,7 +60,7 @@ setGeneric("variantClient", function(OpencgaR, endpointName, params=NULL, ...) # ############################################################################## ## ClinicalClient -setGeneric("clinicalClient", function(OpencgaR, interpretation, members, interpretations, clinicalAnalyses, clinicalAnalysis, endpointName, params=NULL, ...) +setGeneric("clinicalClient", function(OpencgaR, clinicalAnalyses, interpretation, clinicalAnalysis, interpretations, members, endpointName, params=NULL, ...) standardGeneric("clinicalClient")) # ############################################################################## diff --git a/opencga-client/src/main/R/R/Clinical-methods.R b/opencga-client/src/main/R/R/Clinical-methods.R index b87af69bca9..36200235c2a 100644 --- a/opencga-client/src/main/R/R/Clinical-methods.R +++ b/opencga-client/src/main/R/R/Clinical-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. @@ -58,7 +58,7 @@ #' [*]: Required parameter #' @export -setMethod("clinicalClient", "OpencgaR", function(OpencgaR, interpretation, members, interpretations, clinicalAnalyses, clinicalAnalysis, endpointName, params=NULL, ...) { +setMethod("clinicalClient", "OpencgaR", function(OpencgaR, clinicalAnalyses, interpretation, clinicalAnalysis, interpretations, members, endpointName, params=NULL, ...) { switch(endpointName, #' @section Endpoint /{apiVersion}/analysis/clinical/acl/{members}/update: @@ -94,10 +94,10 @@ setMethod("clinicalClient", "OpencgaR", function(OpencgaR, interpretation, membe #' @section Endpoint /{apiVersion}/analysis/clinical/distinct: #' Clinical Analysis distinct method. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list of Clinical Analysis IDs up to a maximum of 100. + #' @param id Comma separated list of Clinical Analysis IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list of Clinical Analysis UUIDs up to a maximum of 100. #' @param type Clinical Analysis type. - #' @param disorder Clinical Analysis disorder. + #' @param disorder Clinical Analysis disorder. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param files Clinical Analysis files. #' @param sample Sample associated to the proband or any member of a family. #' @param individual Proband or any member of a family. @@ -126,11 +126,11 @@ setMethod("clinicalClient", "OpencgaR", function(OpencgaR, interpretation, membe #' @section Endpoint /{apiVersion}/analysis/clinical/interpretation/distinct: #' Interpretation distinct method. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list of Interpretation IDs up to a maximum of 100. + #' @param id Comma separated list of Interpretation IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list of Interpretation UUIDs up to a maximum of 100. #' @param clinicalAnalysisId Clinical Analysis id. #' @param analystId Analyst ID. - #' @param methodName Interpretation method name. + #' @param methodName Interpretation method name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param panels Interpretation panels. #' @param primaryFindings Interpretation primary findings. #' @param secondaryFindings Interpretation secondary findings. @@ -152,11 +152,11 @@ setMethod("clinicalClient", "OpencgaR", function(OpencgaR, interpretation, membe #' @param skip Number of results to skip. #' @param sort Sort the results. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list of Interpretation IDs up to a maximum of 100. + #' @param id Comma separated list of Interpretation IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list of Interpretation UUIDs up to a maximum of 100. #' @param clinicalAnalysisId Clinical Analysis id. #' @param analystId Analyst ID. - #' @param methodName Interpretation method name. + #' @param methodName Interpretation method name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param panels Interpretation panels. #' @param primaryFindings Interpretation primary findings. #' @param secondaryFindings Interpretation secondary findings. @@ -484,10 +484,10 @@ setMethod("clinicalClient", "OpencgaR", function(OpencgaR, interpretation, membe #' @param skip Number of results to skip. #' @param count Get the total number of results matching the query. Deactivated by default. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list of Clinical Analysis IDs up to a maximum of 100. + #' @param id Comma separated list of Clinical Analysis IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list of Clinical Analysis UUIDs up to a maximum of 100. #' @param type Clinical Analysis type. - #' @param disorder Clinical Analysis disorder. + #' @param disorder Clinical Analysis disorder. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param files Clinical Analysis files. #' @param sample Sample associated to the proband or any member of a family. #' @param individual Proband or any member of a family. diff --git a/opencga-client/src/main/R/R/Cohort-methods.R b/opencga-client/src/main/R/R/Cohort-methods.R index 4aafeeb7609..3ae1d7734b5 100644 --- a/opencga-client/src/main/R/R/Cohort-methods.R +++ b/opencga-client/src/main/R/R/Cohort-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. @@ -39,7 +39,7 @@ #' [*]: Required parameter #' @export -setMethod("cohortClient", "OpencgaR", function(OpencgaR, members, cohort, annotationSet, cohorts, endpointName, params=NULL, ...) { +setMethod("cohortClient", "OpencgaR", function(OpencgaR, annotationSet, members, cohort, cohorts, endpointName, params=NULL, ...) { switch(endpointName, #' @section Endpoint /{apiVersion}/cohorts/acl/{members}/update: @@ -97,8 +97,8 @@ setMethod("cohortClient", "OpencgaR", function(OpencgaR, members, cohort, annota #' @section Endpoint /{apiVersion}/cohorts/distinct: #' Cohort distinct method. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list of cohort IDs up to a maximum of 100. - #' @param name Comma separated list of cohort names up to a maximum of 100. + #' @param id Comma separated list of cohort IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param name Comma separated list of cohort names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list of cohort IDs up to a maximum of 100. #' @param type Cohort type. #' @param creationDate creationDate. @@ -128,7 +128,7 @@ setMethod("cohortClient", "OpencgaR", function(OpencgaR, members, cohort, annota #' @param modificationDate Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. #' @param internalStatus Filter by internal status. #' @param status Filter by status. - #' @param phenotypes Comma separated list of phenotype ids or names. + #' @param phenotypes Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param annotation Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. #' @param acl Filter entries for which a user has the provided permissions. Format: acl={user}:{permissions}. Example: acl=john:WRITE,WRITE_ANNOTATIONS will return all entries for which user john has both WRITE and WRITE_ANNOTATIONS permissions. Only study owners or administrators can query by this field. . #' @param release Release when it was created. @@ -147,8 +147,8 @@ setMethod("cohortClient", "OpencgaR", function(OpencgaR, members, cohort, annota #' @param count Get the total number of results matching the query. Deactivated by default. #' @param flattenAnnotations Flatten the annotations?. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list of cohort IDs up to a maximum of 100. - #' @param name Comma separated list of cohort names up to a maximum of 100. + #' @param id Comma separated list of cohort IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param name Comma separated list of cohort names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list of cohort IDs up to a maximum of 100. #' @param type Cohort type. #' @param creationDate creationDate. diff --git a/opencga-client/src/main/R/R/Family-methods.R b/opencga-client/src/main/R/R/Family-methods.R index 069bac92a64..ffeb618a259 100644 --- a/opencga-client/src/main/R/R/Family-methods.R +++ b/opencga-client/src/main/R/R/Family-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. @@ -98,14 +98,14 @@ setMethod("familyClient", "OpencgaR", function(OpencgaR, family, members, famili #' @section Endpoint /{apiVersion}/families/distinct: #' Family distinct method. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list family IDs up to a maximum of 100. - #' @param name Comma separated list family names up to a maximum of 100. + #' @param id Comma separated list family IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param name Comma separated list family names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list family UUIDs up to a maximum of 100. #' @param members Comma separated list of family members. #' @param expectedSize Expected size of the family (number of members). #' @param samples Comma separated list of member's samples. - #' @param phenotypes Comma separated list of phenotype ids or names. - #' @param disorders Comma separated list of disorder ids or names. + #' @param phenotypes Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param disorders Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param creationDate Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. #' @param modificationDate Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. #' @param deleted Boolean to retrieve deleted entries. @@ -128,14 +128,14 @@ setMethod("familyClient", "OpencgaR", function(OpencgaR, family, members, famili #' @param count Get the total number of results matching the query. Deactivated by default. #' @param flattenAnnotations Flatten the annotations?. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list family IDs up to a maximum of 100. - #' @param name Comma separated list family names up to a maximum of 100. + #' @param id Comma separated list family IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param name Comma separated list family names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list family UUIDs up to a maximum of 100. #' @param members Comma separated list of family members. #' @param expectedSize Expected size of the family (number of members). #' @param samples Comma separated list of member's samples. - #' @param phenotypes Comma separated list of phenotype ids or names. - #' @param disorders Comma separated list of disorder ids or names. + #' @param phenotypes Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param disorders Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param creationDate Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. #' @param modificationDate Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. #' @param deleted Boolean to retrieve deleted entries. diff --git a/opencga-client/src/main/R/R/File-methods.R b/opencga-client/src/main/R/R/File-methods.R index 1db2de2c791..5db25da7799 100644 --- a/opencga-client/src/main/R/R/File-methods.R +++ b/opencga-client/src/main/R/R/File-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. @@ -54,7 +54,7 @@ #' [*]: Required parameter #' @export -setMethod("fileClient", "OpencgaR", function(OpencgaR, members, annotationSet, file, files, folder, endpointName, params=NULL, ...) { +setMethod("fileClient", "OpencgaR", function(OpencgaR, folder, annotationSet, file, members, files, endpointName, params=NULL, ...) { switch(endpointName, #' @section Endpoint /{apiVersion}/files/acl/{members}/update: @@ -122,11 +122,11 @@ setMethod("fileClient", "OpencgaR", function(OpencgaR, members, annotationSet, f #' @section Endpoint /{apiVersion}/files/distinct: #' File distinct method. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list of file IDs up to a maximum of 100. + #' @param id Comma separated list of file IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list file UUIDs up to a maximum of 100. - #' @param name Comma separated list of file names. - #' @param path Comma separated list of paths. - #' @param uri Comma separated list of uris. + #' @param name Comma separated list of file names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param path Comma separated list of paths. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param uri Comma separated list of uris. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param type File type, either FILE or DIRECTORY. #' @param bioformat Comma separated Bioformat values. For existing Bioformats see files/bioformats. #' @param format Comma separated Format values. For existing Formats see files/formats. @@ -139,7 +139,7 @@ setMethod("fileClient", "OpencgaR", function(OpencgaR, members, annotationSet, f #' @param creationDate Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. #' @param modificationDate Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. #' @param description Description. - #' @param tags Tags. + #' @param tags Tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param size File size. #' @param sampleIds Comma separated list sample IDs or UUIDs up to a maximum of 100. #' @param jobId Job ID that created the file(s) or folder(s). @@ -207,11 +207,11 @@ setMethod("fileClient", "OpencgaR", function(OpencgaR, members, annotationSet, f #' @param count Get the total number of results matching the query. Deactivated by default. #' @param flattenAnnotations Boolean indicating to flatten the annotations. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list of file IDs up to a maximum of 100. + #' @param id Comma separated list of file IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list file UUIDs up to a maximum of 100. - #' @param name Comma separated list of file names. - #' @param path Comma separated list of paths. - #' @param uri Comma separated list of uris. + #' @param name Comma separated list of file names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param path Comma separated list of paths. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param uri Comma separated list of uris. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param type File type, either FILE or DIRECTORY. #' @param bioformat Comma separated Bioformat values. For existing Bioformats see files/bioformats. #' @param format Comma separated Format values. For existing Formats see files/formats. @@ -224,7 +224,7 @@ setMethod("fileClient", "OpencgaR", function(OpencgaR, members, annotationSet, f #' @param creationDate Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. #' @param modificationDate Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. #' @param description Description. - #' @param tags Tags. + #' @param tags Tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param size File size. #' @param sampleIds Comma separated list sample IDs or UUIDs up to a maximum of 100. #' @param jobId Job ID that created the file(s) or folder(s). diff --git a/opencga-client/src/main/R/R/GA4GH-methods.R b/opencga-client/src/main/R/R/GA4GH-methods.R index 3d4b5de60c2..8aae23ad4a6 100644 --- a/opencga-client/src/main/R/R/GA4GH-methods.R +++ b/opencga-client/src/main/R/R/GA4GH-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/R/R/Individual-methods.R b/opencga-client/src/main/R/R/Individual-methods.R index 348b34679a1..35b01f1ce71 100644 --- a/opencga-client/src/main/R/R/Individual-methods.R +++ b/opencga-client/src/main/R/R/Individual-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. @@ -39,7 +39,7 @@ #' [*]: Required parameter #' @export -setMethod("individualClient", "OpencgaR", function(OpencgaR, members, individuals, annotationSet, individual, endpointName, params=NULL, ...) { +setMethod("individualClient", "OpencgaR", function(OpencgaR, individuals, members, individual, annotationSet, endpointName, params=NULL, ...) { switch(endpointName, #' @section Endpoint /{apiVersion}/individuals/acl/{members}/update: @@ -106,20 +106,20 @@ setMethod("individualClient", "OpencgaR", function(OpencgaR, members, individual #' @section Endpoint /{apiVersion}/individuals/distinct: #' Individual distinct method. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list individual IDs up to a maximum of 100. + #' @param id Comma separated list individual IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list individual UUIDs up to a maximum of 100. - #' @param name Comma separated list individual names up to a maximum of 100. + #' @param name Comma separated list individual names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param familyIds Comma separated list of family ids the individuals may belong to. #' @param father Father ID, name or UUID. #' @param mother Mother ID, name or UUID. #' @param samples Sample ID, name or UUID. #' @param sex Individual sex. - #' @param ethnicity Individual ethnicity. + #' @param ethnicity Individual ethnicity. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param dateOfBirth Individual date of birth. - #' @param disorders Comma separated list of disorder ids or names. - #' @param phenotypes Comma separated list of phenotype ids or names. - #' @param populationName Population name. - #' @param populationSubpopulation Subpopulation name. + #' @param disorders Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param phenotypes Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param populationName Population name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param populationSubpopulation Subpopulation name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param karyotypicSex Individual karyotypic sex. #' @param lifeStatus Individual life status. #' @param internalStatus Filter by internal status. @@ -144,20 +144,20 @@ setMethod("individualClient", "OpencgaR", function(OpencgaR, members, individual #' @param count Get the total number of results matching the query. Deactivated by default. #' @param flattenAnnotations Flatten the annotations?. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list individual IDs up to a maximum of 100. + #' @param id Comma separated list individual IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list individual UUIDs up to a maximum of 100. - #' @param name Comma separated list individual names up to a maximum of 100. + #' @param name Comma separated list individual names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param father Father ID, name or UUID. #' @param mother Mother ID, name or UUID. #' @param samples Sample ID, name or UUID. #' @param familyIds Comma separated list of family ids the individuals may belong to. #' @param sex Individual sex. #' @param dateOfBirth Individual date of birth. - #' @param ethnicity Individual ethnicity. - #' @param disorders Comma separated list of disorder ids or names. - #' @param phenotypes Comma separated list of phenotype ids or names. - #' @param populationName Population name. - #' @param populationSubpopulation Subpopulation name. + #' @param ethnicity Individual ethnicity. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param disorders Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param phenotypes Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param populationName Population name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param populationSubpopulation Subpopulation name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param karyotypicSex Individual karyotypic sex. #' @param lifeStatus Individual life status. #' @param internalStatus Filter by internal status. diff --git a/opencga-client/src/main/R/R/Job-methods.R b/opencga-client/src/main/R/R/Job-methods.R index 59955bac486..d61eb46c702 100644 --- a/opencga-client/src/main/R/R/Job-methods.R +++ b/opencga-client/src/main/R/R/Job-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. @@ -40,7 +40,7 @@ #' [*]: Required parameter #' @export -setMethod("jobClient", "OpencgaR", function(OpencgaR, job, members, jobs, endpointName, params=NULL, ...) { +setMethod("jobClient", "OpencgaR", function(OpencgaR, members, jobs, job, endpointName, params=NULL, ...) { switch(endpointName, #' @section Endpoint /{apiVersion}/jobs/acl/{members}/update: @@ -87,9 +87,9 @@ setMethod("jobClient", "OpencgaR", function(OpencgaR, job, members, jobs, endpoi #' Job distinct method. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. #' @param otherStudies Flag indicating the entries being queried can belong to any related study, not just the primary one. - #' @param id Comma separated list of job IDs up to a maximum of 100. + #' @param id Comma separated list of job IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list of job UUIDs up to a maximum of 100. - #' @param toolId Tool ID executed by the job. + #' @param toolId Tool ID executed by the job. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param toolType Tool type executed by the job [OPERATION, ANALYSIS]. #' @param userId User that created the job. #' @param priority Priority of the job. @@ -128,9 +128,9 @@ setMethod("jobClient", "OpencgaR", function(OpencgaR, job, members, jobs, endpoi #' @param count Get the total number of results matching the query. Deactivated by default. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. #' @param otherStudies Flag indicating the entries being queried can belong to any related study, not just the primary one. - #' @param id Comma separated list of job IDs up to a maximum of 100. + #' @param id Comma separated list of job IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list of job UUIDs up to a maximum of 100. - #' @param toolId Tool ID executed by the job. + #' @param toolId Tool ID executed by the job. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param toolType Tool type executed by the job [OPERATION, ANALYSIS]. #' @param userId User that created the job. #' @param priority Priority of the job. @@ -155,7 +155,7 @@ setMethod("jobClient", "OpencgaR", function(OpencgaR, job, members, jobs, endpoi #' @param internalStatus Filter by internal status. #' @param priority Priority of the job. #' @param userId User that created the job. - #' @param toolId Tool ID executed by the job. + #' @param toolId Tool ID executed by the job. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. top=fetchOpenCGA(object=OpencgaR, category="jobs", categoryId=NULL, subcategory=NULL, subcategoryId=NULL, action="top", params=params, httpMethod="GET", as.queryParam=NULL, ...), diff --git a/opencga-client/src/main/R/R/Meta-methods.R b/opencga-client/src/main/R/R/Meta-methods.R index 386dc6d24da..100a6e11e6f 100644 --- a/opencga-client/src/main/R/R/Meta-methods.R +++ b/opencga-client/src/main/R/R/Meta-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/R/R/Operation-methods.R b/opencga-client/src/main/R/R/Operation-methods.R index f143297e89e..73e41e1eefe 100644 --- a/opencga-client/src/main/R/R/Operation-methods.R +++ b/opencga-client/src/main/R/R/Operation-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/R/R/Panel-methods.R b/opencga-client/src/main/R/R/Panel-methods.R index 1a7bf7bdbca..bf61ce54f10 100644 --- a/opencga-client/src/main/R/R/Panel-methods.R +++ b/opencga-client/src/main/R/R/Panel-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. @@ -62,17 +62,17 @@ setMethod("panelClient", "OpencgaR", function(OpencgaR, members, panels, endpoin #' @section Endpoint /{apiVersion}/panels/distinct: #' Panel distinct method. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list of panel IDs up to a maximum of 100. + #' @param id Comma separated list of panel IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list of panel UUIDs up to a maximum of 100. - #' @param name Comma separated list of panel names up to a maximum of 100. + #' @param name Comma separated list of panel names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param internalStatus Filter by internal status. - #' @param disorders Comma separated list of disorder ids or names. - #' @param variants Comma separated list of variant ids. - #' @param genes Comma separated list of gene ids. + #' @param disorders Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param variants Comma separated list of variant ids. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param genes Comma separated list of gene ids. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param source Comma separated list of source ids or names. - #' @param regions Comma separated list of regions. - #' @param categories Comma separated list of category names. - #' @param tags Panel tags. + #' @param regions Comma separated list of regions. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param categories Comma separated list of category names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param tags Panel tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param deleted Boolean to retrieve deleted entries. #' @param status Filter by status. #' @param creationDate Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. @@ -103,17 +103,17 @@ setMethod("panelClient", "OpencgaR", function(OpencgaR, members, panels, endpoin #' @param skip Number of results to skip. #' @param count Get the total number of results matching the query. Deactivated by default. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list of panel IDs up to a maximum of 100. + #' @param id Comma separated list of panel IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list of panel UUIDs up to a maximum of 100. - #' @param name Comma separated list of panel names up to a maximum of 100. + #' @param name Comma separated list of panel names up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param internalStatus Filter by internal status. - #' @param disorders Comma separated list of disorder ids or names. - #' @param variants Comma separated list of variant ids. - #' @param genes Comma separated list of gene ids. + #' @param disorders Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param variants Comma separated list of variant ids. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param genes Comma separated list of gene ids. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param source Comma separated list of source ids or names. - #' @param regions Comma separated list of regions. - #' @param categories Comma separated list of category names. - #' @param tags Panel tags. + #' @param regions Comma separated list of regions. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param categories Comma separated list of category names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + #' @param tags Panel tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param deleted Boolean to retrieve deleted entries. #' @param status Filter by status. #' @param creationDate Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. diff --git a/opencga-client/src/main/R/R/Project-methods.R b/opencga-client/src/main/R/R/Project-methods.R index 3e68f49bfe5..3911d6f5f9a 100644 --- a/opencga-client/src/main/R/R/Project-methods.R +++ b/opencga-client/src/main/R/R/Project-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. @@ -34,7 +34,7 @@ #' [*]: Required parameter #' @export -setMethod("projectClient", "OpencgaR", function(OpencgaR, project, projects, endpointName, params=NULL, ...) { +setMethod("projectClient", "OpencgaR", function(OpencgaR, projects, project, endpointName, params=NULL, ...) { switch(endpointName, #' @section Endpoint /{apiVersion}/projects/create: diff --git a/opencga-client/src/main/R/R/Sample-methods.R b/opencga-client/src/main/R/R/Sample-methods.R index a78d57987f3..44d4e5e58bb 100644 --- a/opencga-client/src/main/R/R/Sample-methods.R +++ b/opencga-client/src/main/R/R/Sample-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. @@ -98,7 +98,7 @@ setMethod("sampleClient", "OpencgaR", function(OpencgaR, samples, members, sampl #' @section Endpoint /{apiVersion}/samples/distinct: #' Sample distinct method. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list sample IDs up to a maximum of 100. + #' @param id Comma separated list sample IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list sample UUIDs up to a maximum of 100. #' @param somatic Somatic sample. #' @param individualId Individual ID or UUID. @@ -115,7 +115,7 @@ setMethod("sampleClient", "OpencgaR", function(OpencgaR, samples, members, sampl #' @param collectionFrom Collection from. #' @param collectionType Collection type. #' @param collectionMethod Collection method. - #' @param phenotypes Comma separated list of phenotype ids or names. + #' @param phenotypes Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param annotation Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. #' @param acl Filter entries for which a user has the provided permissions. Format: acl={user}:{permissions}. Example: acl=john:WRITE,WRITE_ANNOTATIONS will return all entries for which user john has both WRITE and WRITE_ANNOTATIONS permissions. Only study owners or administrators can query by this field. . #' @param internalRgaStatus Index status of the sample for the Recessive Gene Analysis. Allowed values: ['NOT_INDEXED INDEXED INVALID_PERMISSIONS INVALID_METADATA INVALID'] @@ -157,7 +157,7 @@ setMethod("sampleClient", "OpencgaR", function(OpencgaR, samples, members, sampl #' @param includeIndividual Include Individual object as an attribute. #' @param flattenAnnotations Flatten the annotations?. #' @param study Study [[user@]project:]study where study and project can be either the ID or UUID. - #' @param id Comma separated list sample IDs up to a maximum of 100. + #' @param id Comma separated list sample IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param uuid Comma separated list sample UUIDs up to a maximum of 100. #' @param somatic Somatic sample. #' @param individualId Individual ID or UUID. @@ -174,7 +174,7 @@ setMethod("sampleClient", "OpencgaR", function(OpencgaR, samples, members, sampl #' @param collectionFrom Collection from. #' @param collectionType Collection type. #' @param collectionMethod Collection method. - #' @param phenotypes Comma separated list of phenotype ids or names. + #' @param phenotypes Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. #' @param annotation Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. #' @param acl Filter entries for which a user has the provided permissions. Format: acl={user}:{permissions}. Example: acl=john:WRITE,WRITE_ANNOTATIONS will return all entries for which user john has both WRITE and WRITE_ANNOTATIONS permissions. Only study owners or administrators can query by this field. . #' @param internalRgaStatus Index status of the sample for the Recessive Gene Analysis. Allowed values: ['NOT_INDEXED INDEXED INVALID_PERMISSIONS INVALID_METADATA INVALID'] diff --git a/opencga-client/src/main/R/R/Study-methods.R b/opencga-client/src/main/R/R/Study-methods.R index 682812a7583..ab51f6a4a8d 100644 --- a/opencga-client/src/main/R/R/Study-methods.R +++ b/opencga-client/src/main/R/R/Study-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. @@ -46,7 +46,7 @@ #' [*]: Required parameter #' @export -setMethod("studyClient", "OpencgaR", function(OpencgaR, members, variableSet, studies, study, templateId, group, endpointName, params=NULL, ...) { +setMethod("studyClient", "OpencgaR", function(OpencgaR, study, group, variableSet, studies, members, templateId, endpointName, params=NULL, ...) { switch(endpointName, #' @section Endpoint /{apiVersion}/studies/acl/{members}/update: diff --git a/opencga-client/src/main/R/R/User-methods.R b/opencga-client/src/main/R/R/User-methods.R index 71089917286..671c70ca6c9 100644 --- a/opencga-client/src/main/R/R/User-methods.R +++ b/opencga-client/src/main/R/R/User-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. @@ -38,7 +38,7 @@ #' [*]: Required parameter #' @export -setMethod("userClient", "OpencgaR", function(OpencgaR, filterId, users, user, endpointName, params=NULL, ...) { +setMethod("userClient", "OpencgaR", function(OpencgaR, users, user, filterId, endpointName, params=NULL, ...) { switch(endpointName, #' @section Endpoint /{apiVersion}/users/login: diff --git a/opencga-client/src/main/R/R/Variant-methods.R b/opencga-client/src/main/R/R/Variant-methods.R index 1925f53cf1d..911cd8ecc94 100644 --- a/opencga-client/src/main/R/R/Variant-methods.R +++ b/opencga-client/src/main/R/R/Variant-methods.R @@ -2,7 +2,7 @@ # WARNING: AUTOGENERATED CODE # # This code was generated by a tool. -# Autogenerated on: 2023-08-31 +# Autogenerated on: 2023-09-08 # # Manual changes to this file may cause unexpected behavior in your application. # Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/AdminClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/AdminClient.java index 71bae1378cd..b4b8cc001d6 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/AdminClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/AdminClient.java @@ -36,7 +36,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/AlignmentClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/AlignmentClient.java index e902d0d6454..ae7aef83174 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/AlignmentClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/AlignmentClient.java @@ -40,7 +40,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/ClinicalAnalysisClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/ClinicalAnalysisClient.java index 012238a332a..912ef505958 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/ClinicalAnalysisClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/ClinicalAnalysisClient.java @@ -51,7 +51,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -127,10 +127,12 @@ public RestResponse create(ClinicalAnalysisCreateParams data, * @param field Comma separated list of fields for which to obtain the distinct values. * @param params Map containing any of the following optional parameters. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list of Clinical Analysis IDs up to a maximum of 100. + * id: Comma separated list of Clinical Analysis IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list of Clinical Analysis UUIDs up to a maximum of 100. * type: Clinical Analysis type. - * disorder: Clinical Analysis disorder. + * disorder: Clinical Analysis disorder. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. * files: Clinical Analysis files. * sample: Sample associated to the proband or any member of a family. * individual: Proband or any member of a family. @@ -166,11 +168,13 @@ public RestResponse distinct(String field, ObjectMap params) throws C * @param field Comma separated list of fields for which to obtain the distinct values. * @param params Map containing any of the following optional parameters. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list of Interpretation IDs up to a maximum of 100. + * id: Comma separated list of Interpretation IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list of Interpretation UUIDs up to a maximum of 100. * clinicalAnalysisId: Clinical Analysis id. * analystId: Analyst ID. - * methodName: Interpretation method name. + * methodName: Interpretation method name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' + * e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * panels: Interpretation panels. * primaryFindings: Interpretation primary findings. * secondaryFindings: Interpretation secondary findings. @@ -197,11 +201,13 @@ public RestResponse distinctInterpretation(String field, ObjectMap pa * skip: Number of results to skip. * sort: Sort the results. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list of Interpretation IDs up to a maximum of 100. + * id: Comma separated list of Interpretation IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list of Interpretation UUIDs up to a maximum of 100. * clinicalAnalysisId: Clinical Analysis id. * analystId: Analyst ID. - * methodName: Interpretation method name. + * methodName: Interpretation method name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' + * e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * panels: Interpretation panels. * primaryFindings: Interpretation primary findings. * secondaryFindings: Interpretation secondary findings. @@ -614,10 +620,12 @@ public RestResponse summaryRgaVariant(ObjectMap params * skip: Number of results to skip. * count: Get the total number of results matching the query. Deactivated by default. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list of Clinical Analysis IDs up to a maximum of 100. + * id: Comma separated list of Clinical Analysis IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list of Clinical Analysis UUIDs up to a maximum of 100. * type: Clinical Analysis type. - * disorder: Clinical Analysis disorder. + * disorder: Clinical Analysis disorder. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. * files: Clinical Analysis files. * sample: Sample associated to the proband or any member of a family. * individual: Proband or any member of a family. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/CohortClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/CohortClient.java index 024ddc75a4c..88cc7b62b23 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/CohortClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/CohortClient.java @@ -37,7 +37,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -144,8 +144,10 @@ public RestResponse create(CohortCreateParams data, ObjectMap params) th * @param field Comma separated list of fields for which to obtain the distinct values. * @param params Map containing any of the following optional parameters. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list of cohort IDs up to a maximum of 100. - * name: Comma separated list of cohort names up to a maximum of 100. + * id: Comma separated list of cohort IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * name: Comma separated list of cohort names up to a maximum of 100. Also admits basic regular expressions using the operator + * '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list of cohort IDs up to a maximum of 100. * type: Cohort type. * creationDate: creationDate. @@ -182,7 +184,8 @@ public RestResponse distinct(String field, ObjectMap params) throws Clie * modificationDate: Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * internalStatus: Filter by internal status. * status: Filter by status. - * phenotypes: Comma separated list of phenotype ids or names. + * phenotypes: Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * annotation: Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit * http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. * acl: Filter entries for which a user has the provided permissions. Format: acl={user}:{permissions}. Example: @@ -210,8 +213,10 @@ public RestResponse generate(CohortGenerateParams data, ObjectMap params * count: Get the total number of results matching the query. Deactivated by default. * flattenAnnotations: Flatten the annotations?. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list of cohort IDs up to a maximum of 100. - * name: Comma separated list of cohort names up to a maximum of 100. + * id: Comma separated list of cohort IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * name: Comma separated list of cohort names up to a maximum of 100. Also admits basic regular expressions using the operator + * '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list of cohort IDs up to a maximum of 100. * type: Cohort type. * creationDate: creationDate. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/DiseasePanelClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/DiseasePanelClient.java index ba7055998a1..61f2af635da 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/DiseasePanelClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/DiseasePanelClient.java @@ -35,7 +35,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -93,17 +93,27 @@ public RestResponse create(PanelCreateParams data, ObjectMap params) thro * @param field Comma separated list of fields for which to obtain the distinct values. * @param params Map containing any of the following optional parameters. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list of panel IDs up to a maximum of 100. + * id: Comma separated list of panel IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list of panel UUIDs up to a maximum of 100. - * name: Comma separated list of panel names up to a maximum of 100. + * name: Comma separated list of panel names up to a maximum of 100. Also admits basic regular expressions using the operator + * '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * internalStatus: Filter by internal status. - * disorders: Comma separated list of disorder ids or names. - * variants: Comma separated list of variant ids. - * genes: Comma separated list of gene ids. + * disorders: Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.. Also admits basic regular + * expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case + * insensitive search. + * variants: Comma separated list of variant ids. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * genes: Comma separated list of gene ids. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' + * e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * source: Comma separated list of source ids or names. - * regions: Comma separated list of regions. - * categories: Comma separated list of category names. - * tags: Panel tags. + * regions: Comma separated list of regions. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' + * e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * categories: Comma separated list of category names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * tags: Panel tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + * sensitive, '~/value/i' for case insensitive search. * deleted: Boolean to retrieve deleted entries. * status: Filter by status. * creationDate: Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. @@ -149,17 +159,27 @@ public RestResponse importPanels(PanelImportParams data, ObjectMap params) * skip: Number of results to skip. * count: Get the total number of results matching the query. Deactivated by default. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list of panel IDs up to a maximum of 100. + * id: Comma separated list of panel IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list of panel UUIDs up to a maximum of 100. - * name: Comma separated list of panel names up to a maximum of 100. + * name: Comma separated list of panel names up to a maximum of 100. Also admits basic regular expressions using the operator + * '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * internalStatus: Filter by internal status. - * disorders: Comma separated list of disorder ids or names. - * variants: Comma separated list of variant ids. - * genes: Comma separated list of gene ids. + * disorders: Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.. Also admits basic regular + * expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case + * insensitive search. + * variants: Comma separated list of variant ids. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * genes: Comma separated list of gene ids. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' + * e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * source: Comma separated list of source ids or names. - * regions: Comma separated list of regions. - * categories: Comma separated list of category names. - * tags: Panel tags. + * regions: Comma separated list of regions. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' + * e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * categories: Comma separated list of category names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * tags: Panel tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + * sensitive, '~/value/i' for case insensitive search. * deleted: Boolean to retrieve deleted entries. * status: Filter by status. * creationDate: Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/FamilyClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/FamilyClient.java index 9b7142415e4..6280a7026e0 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/FamilyClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/FamilyClient.java @@ -36,7 +36,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -145,14 +145,18 @@ public RestResponse create(FamilyCreateParams data, ObjectMap params) th * @param field Comma separated list of fields for which to obtain the distinct values. * @param params Map containing any of the following optional parameters. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list family IDs up to a maximum of 100. - * name: Comma separated list family names up to a maximum of 100. + * id: Comma separated list family IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * name: Comma separated list family names up to a maximum of 100. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list family UUIDs up to a maximum of 100. * members: Comma separated list of family members. * expectedSize: Expected size of the family (number of members). * samples: Comma separated list of member's samples. - * phenotypes: Comma separated list of phenotype ids or names. - * disorders: Comma separated list of disorder ids or names. + * phenotypes: Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * disorders: Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * creationDate: Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * modificationDate: Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * deleted: Boolean to retrieve deleted entries. @@ -184,14 +188,18 @@ public RestResponse distinct(String field, ObjectMap params) throws Clie * count: Get the total number of results matching the query. Deactivated by default. * flattenAnnotations: Flatten the annotations?. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list family IDs up to a maximum of 100. - * name: Comma separated list family names up to a maximum of 100. + * id: Comma separated list family IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * name: Comma separated list family names up to a maximum of 100. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list family UUIDs up to a maximum of 100. * members: Comma separated list of family members. * expectedSize: Expected size of the family (number of members). * samples: Comma separated list of member's samples. - * phenotypes: Comma separated list of phenotype ids or names. - * disorders: Comma separated list of disorder ids or names. + * phenotypes: Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * disorders: Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * creationDate: Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * modificationDate: Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * deleted: Boolean to retrieve deleted entries. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/FileClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/FileClient.java index c40f63da5d7..ce6df1ebb2e 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/FileClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/FileClient.java @@ -43,7 +43,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -164,11 +164,15 @@ public RestResponse create(FileCreateParams data, ObjectMap params) throws * @param field Comma separated list of fields for which to obtain the distinct values. * @param params Map containing any of the following optional parameters. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list of file IDs up to a maximum of 100. + * id: Comma separated list of file IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list file UUIDs up to a maximum of 100. - * name: Comma separated list of file names. - * path: Comma separated list of paths. - * uri: Comma separated list of uris. + * name: Comma separated list of file names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' + * e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * path: Comma separated list of paths. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. + * uri: Comma separated list of uris. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. * type: File type, either FILE or DIRECTORY. * bioformat: Comma separated Bioformat values. For existing Bioformats see files/bioformats. * format: Comma separated Format values. For existing Formats see files/formats. @@ -181,7 +185,8 @@ public RestResponse create(FileCreateParams data, ObjectMap params) throws * creationDate: Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * modificationDate: Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * description: Description. - * tags: Tags. + * tags: Tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + * sensitive, '~/value/i' for case insensitive search. * size: File size. * sampleIds: Comma separated list sample IDs or UUIDs up to a maximum of 100. * jobId: Job ID that created the file(s) or folder(s). @@ -290,11 +295,15 @@ public RestResponse runPostlink(PostLinkToolParams data, ObjectMap params) * count: Get the total number of results matching the query. Deactivated by default. * flattenAnnotations: Boolean indicating to flatten the annotations. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list of file IDs up to a maximum of 100. + * id: Comma separated list of file IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list file UUIDs up to a maximum of 100. - * name: Comma separated list of file names. - * path: Comma separated list of paths. - * uri: Comma separated list of uris. + * name: Comma separated list of file names. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' + * e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * path: Comma separated list of paths. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. + * uri: Comma separated list of uris. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. * type: File type, either FILE or DIRECTORY. * bioformat: Comma separated Bioformat values. For existing Bioformats see files/bioformats. * format: Comma separated Format values. For existing Formats see files/formats. @@ -307,7 +316,8 @@ public RestResponse runPostlink(PostLinkToolParams data, ObjectMap params) * creationDate: Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * modificationDate: Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * description: Description. - * tags: Tags. + * tags: Tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + * sensitive, '~/value/i' for case insensitive search. * size: File size. * sampleIds: Comma separated list sample IDs or UUIDs up to a maximum of 100. * jobId: Job ID that created the file(s) or folder(s). diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/GA4GHClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/GA4GHClient.java index a4afee831af..28170cb2746 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/GA4GHClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/GA4GHClient.java @@ -27,7 +27,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/IndividualClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/IndividualClient.java index 2b291285857..eb24455c52a 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/IndividualClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/IndividualClient.java @@ -36,7 +36,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -153,20 +153,27 @@ public RestResponse create(IndividualCreateParams data, ObjectMap pa * @param field Comma separated list of fields for which to obtain the distinct values. * @param params Map containing any of the following optional parameters. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list individual IDs up to a maximum of 100. + * id: Comma separated list individual IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list individual UUIDs up to a maximum of 100. - * name: Comma separated list individual names up to a maximum of 100. + * name: Comma separated list individual names up to a maximum of 100. Also admits basic regular expressions using the operator + * '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * familyIds: Comma separated list of family ids the individuals may belong to. * father: Father ID, name or UUID. * mother: Mother ID, name or UUID. * samples: Sample ID, name or UUID. * sex: Individual sex. - * ethnicity: Individual ethnicity. + * ethnicity: Individual ethnicity. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. * dateOfBirth: Individual date of birth. - * disorders: Comma separated list of disorder ids or names. - * phenotypes: Comma separated list of phenotype ids or names. - * populationName: Population name. - * populationSubpopulation: Subpopulation name. + * disorders: Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * phenotypes: Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * populationName: Population name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. + * populationSubpopulation: Subpopulation name. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * karyotypicSex: Individual karyotypic sex. * lifeStatus: Individual life status. * internalStatus: Filter by internal status. @@ -200,20 +207,27 @@ public RestResponse distinct(String field, ObjectMap params) throws Clie * count: Get the total number of results matching the query. Deactivated by default. * flattenAnnotations: Flatten the annotations?. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list individual IDs up to a maximum of 100. + * id: Comma separated list individual IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list individual UUIDs up to a maximum of 100. - * name: Comma separated list individual names up to a maximum of 100. + * name: Comma separated list individual names up to a maximum of 100. Also admits basic regular expressions using the operator + * '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * father: Father ID, name or UUID. * mother: Mother ID, name or UUID. * samples: Sample ID, name or UUID. * familyIds: Comma separated list of family ids the individuals may belong to. * sex: Individual sex. * dateOfBirth: Individual date of birth. - * ethnicity: Individual ethnicity. - * disorders: Comma separated list of disorder ids or names. - * phenotypes: Comma separated list of phenotype ids or names. - * populationName: Population name. - * populationSubpopulation: Subpopulation name. + * ethnicity: Individual ethnicity. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. + * disorders: Comma separated list of disorder ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * phenotypes: Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * populationName: Population name. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. + * populationSubpopulation: Subpopulation name. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * karyotypicSex: Individual karyotypic sex. * lifeStatus: Individual life status. * internalStatus: Filter by internal status. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/JobClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/JobClient.java index 35e20d6ea8d..68934888520 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/JobClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/JobClient.java @@ -37,7 +37,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -120,9 +120,11 @@ public RestResponse create(JobCreateParams data, ObjectMap params) throws C * @param params Map containing any of the following optional parameters. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. * otherStudies: Flag indicating the entries being queried can belong to any related study, not just the primary one. - * id: Comma separated list of job IDs up to a maximum of 100. + * id: Comma separated list of job IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list of job UUIDs up to a maximum of 100. - * toolId: Tool ID executed by the job. + * toolId: Tool ID executed by the job. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. * toolType: Tool type executed by the job [OPERATION, ANALYSIS]. * userId: User that created the job. * priority: Priority of the job. @@ -176,9 +178,11 @@ public RestResponse retry(JobRetryParams data, ObjectMap params) throws Cli * count: Get the total number of results matching the query. Deactivated by default. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. * otherStudies: Flag indicating the entries being queried can belong to any related study, not just the primary one. - * id: Comma separated list of job IDs up to a maximum of 100. + * id: Comma separated list of job IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list of job UUIDs up to a maximum of 100. - * toolId: Tool ID executed by the job. + * toolId: Tool ID executed by the job. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. * toolType: Tool type executed by the job [OPERATION, ANALYSIS]. * userId: User that created the job. * priority: Priority of the job. @@ -211,7 +215,8 @@ public RestResponse search(ObjectMap params) throws ClientException { * internalStatus: Filter by internal status. * priority: Priority of the job. * userId: User that created the job. - * toolId: Tool ID executed by the job. + * toolId: Tool ID executed by the job. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. * @return a RestResponse object. * @throws ClientException ClientException if there is any server error. */ diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/MetaClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/MetaClient.java index 2a4c2afb9b8..b68b929186c 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/MetaClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/MetaClient.java @@ -28,7 +28,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/ProjectClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/ProjectClient.java index b1dd2d4757b..395b4593856 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/ProjectClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/ProjectClient.java @@ -32,7 +32,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/SampleClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/SampleClient.java index 31b281cccd2..f2874078762 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/SampleClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/SampleClient.java @@ -36,7 +36,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -145,7 +145,8 @@ public RestResponse create(SampleCreateParams data, ObjectMap params) th * @param field Comma separated list of fields for which to obtain the distinct values. * @param params Map containing any of the following optional parameters. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list sample IDs up to a maximum of 100. + * id: Comma separated list sample IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list sample UUIDs up to a maximum of 100. * somatic: Somatic sample. * individualId: Individual ID or UUID. @@ -162,7 +163,8 @@ public RestResponse create(SampleCreateParams data, ObjectMap params) th * collectionFrom: Collection from. * collectionType: Collection type. * collectionMethod: Collection method. - * phenotypes: Comma separated list of phenotype ids or names. + * phenotypes: Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * annotation: Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit * http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. * acl: Filter entries for which a user has the provided permissions. Format: acl={user}:{permissions}. Example: @@ -221,7 +223,8 @@ public RestResponse load(String file, ObjectMap params) throws ClientExc * includeIndividual: Include Individual object as an attribute. * flattenAnnotations: Flatten the annotations?. * study: Study [[user@]project:]study where study and project can be either the ID or UUID. - * id: Comma separated list sample IDs up to a maximum of 100. + * id: Comma separated list sample IDs up to a maximum of 100. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * uuid: Comma separated list sample UUIDs up to a maximum of 100. * somatic: Somatic sample. * individualId: Individual ID or UUID. @@ -238,7 +241,8 @@ public RestResponse load(String file, ObjectMap params) throws ClientExc * collectionFrom: Collection from. * collectionType: Collection type. * collectionMethod: Collection method. - * phenotypes: Comma separated list of phenotype ids or names. + * phenotypes: Comma separated list of phenotype ids or names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * annotation: Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit * http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. * acl: Filter entries for which a user has the provided permissions. Format: acl={user}:{permissions}. Example: diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/StudyClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/StudyClient.java index 6e4fb4a9495..6216f78b94b 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/StudyClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/StudyClient.java @@ -45,7 +45,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/UserClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/UserClient.java index 3443565c6a3..93c49bdf998 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/UserClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/UserClient.java @@ -36,7 +36,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/VariantClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/VariantClient.java index fe1f4de3e99..c96321b199a 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/VariantClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/VariantClient.java @@ -62,7 +62,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/VariantOperationClient.java b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/VariantOperationClient.java index e2b9052903e..4b870042648 100644 --- a/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/VariantOperationClient.java +++ b/opencga-client/src/main/java/org/opencb/opencga/client/rest/clients/VariantOperationClient.java @@ -50,7 +50,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. -* Autogenerated on: 2023-08-31 +* Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/javascript/Admin.js b/opencga-client/src/main/javascript/Admin.js index 60a9d5b1c9e..5edf0a466c6 100644 --- a/opencga-client/src/main/javascript/Admin.js +++ b/opencga-client/src/main/javascript/Admin.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/javascript/Alignment.js b/opencga-client/src/main/javascript/Alignment.js index 10a7da5bad2..874adaf6b67 100644 --- a/opencga-client/src/main/javascript/Alignment.js +++ b/opencga-client/src/main/javascript/Alignment.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/javascript/ClinicalAnalysis.js b/opencga-client/src/main/javascript/ClinicalAnalysis.js index 687447b8005..7b04cf20cdd 100644 --- a/opencga-client/src/main/javascript/ClinicalAnalysis.js +++ b/opencga-client/src/main/javascript/ClinicalAnalysis.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -76,10 +76,12 @@ export default class ClinicalAnalysis extends OpenCGAParentClass { * @param {String} field - Comma separated list of fields for which to obtain the distinct values. * @param {Object} [params] - The Object containing the following optional parameters: * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list of Clinical Analysis IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of Clinical Analysis IDs up to a maximum of 100. Also admits basic regular + * expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list of Clinical Analysis UUIDs up to a maximum of 100. * @param {String} [params.type] - Clinical Analysis type. - * @param {String} [params.disorder] - Clinical Analysis disorder. + * @param {String} [params.disorder] - Clinical Analysis disorder. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.files] - Clinical Analysis files. * @param {String} [params.sample] - Sample associated to the proband or any member of a family. * @param {String} [params.individual] - Proband or any member of a family. @@ -112,11 +114,13 @@ export default class ClinicalAnalysis extends OpenCGAParentClass { * @param {String} field - Comma separated list of fields for which to obtain the distinct values. * @param {Object} [params] - The Object containing the following optional parameters: * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list of Interpretation IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of Interpretation IDs up to a maximum of 100. Also admits basic regular expressions + * using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list of Interpretation UUIDs up to a maximum of 100. * @param {String} [params.clinicalAnalysisId] - Clinical Analysis id. * @param {String} [params.analystId] - Analyst ID. - * @param {String} [params.methodName] - Interpretation method name. + * @param {String} [params.methodName] - Interpretation method name. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.panels] - Interpretation panels. * @param {String} [params.primaryFindings] - Interpretation primary findings. * @param {String} [params.secondaryFindings] - Interpretation secondary findings. @@ -140,11 +144,13 @@ export default class ClinicalAnalysis extends OpenCGAParentClass { * @param {Number} [params.skip] - Number of results to skip. * @param {Boolean} [params.sort] - Sort the results. * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list of Interpretation IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of Interpretation IDs up to a maximum of 100. Also admits basic regular expressions + * using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list of Interpretation UUIDs up to a maximum of 100. * @param {String} [params.clinicalAnalysisId] - Clinical Analysis id. * @param {String} [params.analystId] - Analyst ID. - * @param {String} [params.methodName] - Interpretation method name. + * @param {String} [params.methodName] - Interpretation method name. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.panels] - Interpretation panels. * @param {String} [params.primaryFindings] - Interpretation primary findings. * @param {String} [params.secondaryFindings] - Interpretation secondary findings. @@ -513,10 +519,12 @@ export default class ClinicalAnalysis extends OpenCGAParentClass { * @param {Boolean} [params.count = "false"] - Get the total number of results matching the query. Deactivated by default. The default * value is false. * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list of Clinical Analysis IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of Clinical Analysis IDs up to a maximum of 100. Also admits basic regular + * expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list of Clinical Analysis UUIDs up to a maximum of 100. * @param {String} [params.type] - Clinical Analysis type. - * @param {String} [params.disorder] - Clinical Analysis disorder. + * @param {String} [params.disorder] - Clinical Analysis disorder. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.files] - Clinical Analysis files. * @param {String} [params.sample] - Sample associated to the proband or any member of a family. * @param {String} [params.individual] - Proband or any member of a family. diff --git a/opencga-client/src/main/javascript/Cohort.js b/opencga-client/src/main/javascript/Cohort.js index f121ff941f5..139868db04d 100644 --- a/opencga-client/src/main/javascript/Cohort.js +++ b/opencga-client/src/main/javascript/Cohort.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -101,8 +101,10 @@ export default class Cohort extends OpenCGAParentClass { * @param {String} field - Comma separated list of fields for which to obtain the distinct values. * @param {Object} [params] - The Object containing the following optional parameters: * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list of cohort IDs up to a maximum of 100. - * @param {String} [params.name] - Comma separated list of cohort names up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of cohort IDs up to a maximum of 100. Also admits basic regular expressions using + * the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.name] - Comma separated list of cohort names up to a maximum of 100. Also admits basic regular expressions + * using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list of cohort IDs up to a maximum of 100. * @param {String} [params.type] - Cohort type. * @param {String} [params.creationDate] - creationDate. @@ -135,7 +137,8 @@ export default class Cohort extends OpenCGAParentClass { * @param {String} [params.modificationDate] - Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * @param {String} [params.internalStatus] - Filter by internal status. * @param {String} [params.status] - Filter by status. - * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. + * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.annotation] - Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit * http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. * @param {String} [params.acl] - Filter entries for which a user has the provided permissions. Format: acl={user}:{permissions}. @@ -161,8 +164,10 @@ export default class Cohort extends OpenCGAParentClass { * value is false. * @param {Boolean} [params.flattenAnnotations = "false"] - Flatten the annotations?. The default value is false. * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list of cohort IDs up to a maximum of 100. - * @param {String} [params.name] - Comma separated list of cohort names up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of cohort IDs up to a maximum of 100. Also admits basic regular expressions using + * the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.name] - Comma separated list of cohort names up to a maximum of 100. Also admits basic regular expressions + * using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list of cohort IDs up to a maximum of 100. * @param {String} [params.type] - Cohort type. * @param {String} [params.creationDate] - creationDate. diff --git a/opencga-client/src/main/javascript/DiseasePanel.js b/opencga-client/src/main/javascript/DiseasePanel.js index 1216496f705..2f8e596a9a9 100644 --- a/opencga-client/src/main/javascript/DiseasePanel.js +++ b/opencga-client/src/main/javascript/DiseasePanel.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -62,17 +62,27 @@ export default class DiseasePanel extends OpenCGAParentClass { * @param {String} field - Comma separated list of fields for which to obtain the distinct values. * @param {Object} [params] - The Object containing the following optional parameters: * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list of panel IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of panel IDs up to a maximum of 100. Also admits basic regular expressions using + * the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list of panel UUIDs up to a maximum of 100. - * @param {String} [params.name] - Comma separated list of panel names up to a maximum of 100. + * @param {String} [params.name] - Comma separated list of panel names up to a maximum of 100. Also admits basic regular expressions + * using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.internalStatus] - Filter by internal status. - * @param {String} [params.disorders] - Comma separated list of disorder ids or names. - * @param {String} [params.variants] - Comma separated list of variant ids. - * @param {String} [params.genes] - Comma separated list of gene ids. + * @param {String} [params.disorders] - Comma separated list of disorder ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.. Also admits basic + * regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive + * search. + * @param {String} [params.variants] - Comma separated list of variant ids. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.genes] - Comma separated list of gene ids. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.source] - Comma separated list of source ids or names. - * @param {String} [params.regions] - Comma separated list of regions. - * @param {String} [params.categories] - Comma separated list of category names. - * @param {String} [params.tags] - Panel tags. + * @param {String} [params.regions] - Comma separated list of regions. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.categories] - Comma separated list of category names. Also admits basic regular expressions using the operator + * '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.tags] - Panel tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {Boolean} [params.deleted = "false"] - Boolean to retrieve deleted entries. The default value is false. * @param {String} [params.status] - Filter by status. * @param {String} [params.creationDate] - Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. @@ -112,17 +122,27 @@ export default class DiseasePanel extends OpenCGAParentClass { * @param {Boolean} [params.count = "false"] - Get the total number of results matching the query. Deactivated by default. The default * value is false. * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list of panel IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of panel IDs up to a maximum of 100. Also admits basic regular expressions using + * the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list of panel UUIDs up to a maximum of 100. - * @param {String} [params.name] - Comma separated list of panel names up to a maximum of 100. + * @param {String} [params.name] - Comma separated list of panel names up to a maximum of 100. Also admits basic regular expressions + * using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.internalStatus] - Filter by internal status. - * @param {String} [params.disorders] - Comma separated list of disorder ids or names. - * @param {String} [params.variants] - Comma separated list of variant ids. - * @param {String} [params.genes] - Comma separated list of gene ids. + * @param {String} [params.disorders] - Comma separated list of disorder ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search.. Also admits basic + * regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive + * search. + * @param {String} [params.variants] - Comma separated list of variant ids. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.genes] - Comma separated list of gene ids. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.source] - Comma separated list of source ids or names. - * @param {String} [params.regions] - Comma separated list of regions. - * @param {String} [params.categories] - Comma separated list of category names. - * @param {String} [params.tags] - Panel tags. + * @param {String} [params.regions] - Comma separated list of regions. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.categories] - Comma separated list of category names. Also admits basic regular expressions using the operator + * '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.tags] - Panel tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. + * '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {Boolean} [params.deleted = "false"] - Boolean to retrieve deleted entries. The default value is false. * @param {String} [params.status] - Filter by status. * @param {String} [params.creationDate] - Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. diff --git a/opencga-client/src/main/javascript/Family.js b/opencga-client/src/main/javascript/Family.js index ea150256018..ffd436567e0 100644 --- a/opencga-client/src/main/javascript/Family.js +++ b/opencga-client/src/main/javascript/Family.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -104,14 +104,18 @@ export default class Family extends OpenCGAParentClass { * @param {String} field - Comma separated list of fields for which to obtain the distinct values. * @param {Object} [params] - The Object containing the following optional parameters: * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list family IDs up to a maximum of 100. - * @param {String} [params.name] - Comma separated list family names up to a maximum of 100. + * @param {String} [params.id] - Comma separated list family IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.name] - Comma separated list family names up to a maximum of 100. Also admits basic regular expressions using + * the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list family UUIDs up to a maximum of 100. * @param {String} [params.members] - Comma separated list of family members. * @param {Number} [params.expectedSize] - Expected size of the family (number of members). * @param {String} [params.samples] - Comma separated list of member's samples. - * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. - * @param {String} [params.disorders] - Comma separated list of disorder ids or names. + * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.disorders] - Comma separated list of disorder ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.creationDate] - Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * @param {String} [params.modificationDate] - Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * @param {Boolean} [params.deleted = "false"] - Boolean to retrieve deleted entries. The default value is false. @@ -140,14 +144,18 @@ export default class Family extends OpenCGAParentClass { * value is false. * @param {Boolean} [params.flattenAnnotations = "false"] - Flatten the annotations?. The default value is false. * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list family IDs up to a maximum of 100. - * @param {String} [params.name] - Comma separated list family names up to a maximum of 100. + * @param {String} [params.id] - Comma separated list family IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.name] - Comma separated list family names up to a maximum of 100. Also admits basic regular expressions using + * the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list family UUIDs up to a maximum of 100. * @param {String} [params.members] - Comma separated list of family members. * @param {Number} [params.expectedSize] - Expected size of the family (number of members). * @param {String} [params.samples] - Comma separated list of member's samples. - * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. - * @param {String} [params.disorders] - Comma separated list of disorder ids or names. + * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.disorders] - Comma separated list of disorder ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.creationDate] - Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * @param {String} [params.modificationDate] - Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * @param {Boolean} [params.deleted = "false"] - Boolean to retrieve deleted entries. The default value is false. diff --git a/opencga-client/src/main/javascript/File.js b/opencga-client/src/main/javascript/File.js index 80d2eac1817..a2455a0953f 100644 --- a/opencga-client/src/main/javascript/File.js +++ b/opencga-client/src/main/javascript/File.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -112,11 +112,15 @@ export default class File extends OpenCGAParentClass { * @param {String} field - Comma separated list of fields for which to obtain the distinct values. * @param {Object} [params] - The Object containing the following optional parameters: * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list of file IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of file IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list file UUIDs up to a maximum of 100. - * @param {String} [params.name] - Comma separated list of file names. - * @param {String} [params.path] - Comma separated list of paths. - * @param {String} [params.uri] - Comma separated list of uris. + * @param {String} [params.name] - Comma separated list of file names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.path] - Comma separated list of paths. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.uri] - Comma separated list of uris. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.type] - File type, either FILE or DIRECTORY. * @param {String} [params.bioformat] - Comma separated Bioformat values. For existing Bioformats see files/bioformats. * @param {String} [params.format] - Comma separated Format values. For existing Formats see files/formats. @@ -129,7 +133,8 @@ export default class File extends OpenCGAParentClass { * @param {String} [params.creationDate] - Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * @param {String} [params.modificationDate] - Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * @param {String} [params.description] - Description. - * @param {String} [params.tags] - Tags. + * @param {String} [params.tags] - Tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' + * for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.size] - File size. * @param {String} [params.sampleIds] - Comma separated list sample IDs or UUIDs up to a maximum of 100. * @param {String} [params.jobId] - Job ID that created the file(s) or folder(s). @@ -220,11 +225,15 @@ export default class File extends OpenCGAParentClass { * value is false. * @param {Boolean} [params.flattenAnnotations = "false"] - Boolean indicating to flatten the annotations. The default value is false. * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list of file IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of file IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list file UUIDs up to a maximum of 100. - * @param {String} [params.name] - Comma separated list of file names. - * @param {String} [params.path] - Comma separated list of paths. - * @param {String} [params.uri] - Comma separated list of uris. + * @param {String} [params.name] - Comma separated list of file names. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.path] - Comma separated list of paths. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.uri] - Comma separated list of uris. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.type] - File type, either FILE or DIRECTORY. * @param {String} [params.bioformat] - Comma separated Bioformat values. For existing Bioformats see files/bioformats. * @param {String} [params.format] - Comma separated Format values. For existing Formats see files/formats. @@ -237,7 +246,8 @@ export default class File extends OpenCGAParentClass { * @param {String} [params.creationDate] - Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * @param {String} [params.modificationDate] - Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. * @param {String} [params.description] - Description. - * @param {String} [params.tags] - Tags. + * @param {String} [params.tags] - Tags. Also admits basic regular expressions using the operator '~', i.e. '~{perl-regex}' e.g. '~value' + * for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.size] - File size. * @param {String} [params.sampleIds] - Comma separated list sample IDs or UUIDs up to a maximum of 100. * @param {String} [params.jobId] - Job ID that created the file(s) or folder(s). diff --git a/opencga-client/src/main/javascript/GA4GH.js b/opencga-client/src/main/javascript/GA4GH.js index 41810680d69..f5e18645184 100644 --- a/opencga-client/src/main/javascript/GA4GH.js +++ b/opencga-client/src/main/javascript/GA4GH.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/javascript/Individual.js b/opencga-client/src/main/javascript/Individual.js index c611dbc3d20..da0324012b5 100644 --- a/opencga-client/src/main/javascript/Individual.js +++ b/opencga-client/src/main/javascript/Individual.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -111,20 +111,27 @@ export default class Individual extends OpenCGAParentClass { * @param {String} field - Comma separated list of fields for which to obtain the distinct values. * @param {Object} [params] - The Object containing the following optional parameters: * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list individual IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list individual IDs up to a maximum of 100. Also admits basic regular expressions using + * the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list individual UUIDs up to a maximum of 100. - * @param {String} [params.name] - Comma separated list individual names up to a maximum of 100. + * @param {String} [params.name] - Comma separated list individual names up to a maximum of 100. Also admits basic regular expressions + * using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.familyIds] - Comma separated list of family ids the individuals may belong to. * @param {String} [params.father] - Father ID, name or UUID. * @param {String} [params.mother] - Mother ID, name or UUID. * @param {String} [params.samples] - Sample ID, name or UUID. * @param {String} [params.sex] - Individual sex. - * @param {String} [params.ethnicity] - Individual ethnicity. + * @param {String} [params.ethnicity] - Individual ethnicity. Also admits basic regular expressions using the operator '~', i.e. '~{perl- + * regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.dateOfBirth] - Individual date of birth. - * @param {String} [params.disorders] - Comma separated list of disorder ids or names. - * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. - * @param {String} [params.populationName] - Population name. - * @param {String} [params.populationSubpopulation] - Subpopulation name. + * @param {String} [params.disorders] - Comma separated list of disorder ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.populationName] - Population name. Also admits basic regular expressions using the operator '~', i.e. '~{perl- + * regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.populationSubpopulation] - Subpopulation name. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.karyotypicSex] - Individual karyotypic sex. * @param {String} [params.lifeStatus] - Individual life status. * @param {String} [params.internalStatus] - Filter by internal status. @@ -155,20 +162,27 @@ export default class Individual extends OpenCGAParentClass { * value is false. * @param {Boolean} [params.flattenAnnotations = "false"] - Flatten the annotations?. The default value is false. * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list individual IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list individual IDs up to a maximum of 100. Also admits basic regular expressions using + * the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list individual UUIDs up to a maximum of 100. - * @param {String} [params.name] - Comma separated list individual names up to a maximum of 100. + * @param {String} [params.name] - Comma separated list individual names up to a maximum of 100. Also admits basic regular expressions + * using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.father] - Father ID, name or UUID. * @param {String} [params.mother] - Mother ID, name or UUID. * @param {String} [params.samples] - Sample ID, name or UUID. * @param {String} [params.familyIds] - Comma separated list of family ids the individuals may belong to. * @param {String} [params.sex] - Individual sex. * @param {String} [params.dateOfBirth] - Individual date of birth. - * @param {String} [params.ethnicity] - Individual ethnicity. - * @param {String} [params.disorders] - Comma separated list of disorder ids or names. - * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. - * @param {String} [params.populationName] - Population name. - * @param {String} [params.populationSubpopulation] - Subpopulation name. + * @param {String} [params.ethnicity] - Individual ethnicity. Also admits basic regular expressions using the operator '~', i.e. '~{perl- + * regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.disorders] - Comma separated list of disorder ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.populationName] - Population name. Also admits basic regular expressions using the operator '~', i.e. '~{perl- + * regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. + * @param {String} [params.populationSubpopulation] - Subpopulation name. Also admits basic regular expressions using the operator '~', + * i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.karyotypicSex] - Individual karyotypic sex. * @param {String} [params.lifeStatus] - Individual life status. * @param {String} [params.internalStatus] - Filter by internal status. diff --git a/opencga-client/src/main/javascript/Job.js b/opencga-client/src/main/javascript/Job.js index e751db7fb46..1125c50f9f1 100644 --- a/opencga-client/src/main/javascript/Job.js +++ b/opencga-client/src/main/javascript/Job.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -85,9 +85,11 @@ export default class Job extends OpenCGAParentClass { * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. * @param {Boolean} [params.otherStudies = "false"] - Flag indicating the entries being queried can belong to any related study, not just * the primary one. The default value is false. - * @param {String} [params.id] - Comma separated list of job IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of job IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list of job UUIDs up to a maximum of 100. - * @param {String} [params.toolId] - Tool ID executed by the job. + * @param {String} [params.toolId] - Tool ID executed by the job. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.toolType] - Tool type executed by the job [OPERATION, ANALYSIS]. * @param {String} [params.userId] - User that created the job. * @param {String} [params.priority] - Priority of the job. @@ -136,9 +138,11 @@ export default class Job extends OpenCGAParentClass { * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. * @param {Boolean} [params.otherStudies = "false"] - Flag indicating the entries being queried can belong to any related study, not just * the primary one. The default value is false. - * @param {String} [params.id] - Comma separated list of job IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list of job IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list of job UUIDs up to a maximum of 100. - * @param {String} [params.toolId] - Tool ID executed by the job. + * @param {String} [params.toolId] - Tool ID executed by the job. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.toolType] - Tool type executed by the job [OPERATION, ANALYSIS]. * @param {String} [params.userId] - User that created the job. * @param {String} [params.priority] - Priority of the job. @@ -168,7 +172,8 @@ export default class Job extends OpenCGAParentClass { * @param {String} [params.internalStatus] - Filter by internal status. * @param {String} [params.priority] - Priority of the job. * @param {String} [params.userId] - User that created the job. - * @param {String} [params.toolId] - Tool ID executed by the job. + * @param {String} [params.toolId] - Tool ID executed by the job. Also admits basic regular expressions using the operator '~', i.e. + * '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @returns {Promise} Promise object in the form of RestResponse instance. */ top(params) { diff --git a/opencga-client/src/main/javascript/Meta.js b/opencga-client/src/main/javascript/Meta.js index f49c2c01b37..ca2c12b459b 100644 --- a/opencga-client/src/main/javascript/Meta.js +++ b/opencga-client/src/main/javascript/Meta.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/javascript/Project.js b/opencga-client/src/main/javascript/Project.js index 0e5880626c3..9ed80c76552 100644 --- a/opencga-client/src/main/javascript/Project.js +++ b/opencga-client/src/main/javascript/Project.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/javascript/Sample.js b/opencga-client/src/main/javascript/Sample.js index 21a7247620e..ebe4b047ade 100644 --- a/opencga-client/src/main/javascript/Sample.js +++ b/opencga-client/src/main/javascript/Sample.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. @@ -103,7 +103,8 @@ export default class Sample extends OpenCGAParentClass { * @param {String} field - Comma separated list of fields for which to obtain the distinct values. * @param {Object} [params] - The Object containing the following optional parameters: * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list sample IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list sample IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list sample UUIDs up to a maximum of 100. * @param {Boolean} [params.somatic] - Somatic sample. * @param {String} [params.individualId] - Individual ID or UUID. @@ -120,7 +121,8 @@ export default class Sample extends OpenCGAParentClass { * @param {String} [params.collectionFrom] - Collection from. * @param {String} [params.collectionType] - Collection type. * @param {String} [params.collectionMethod] - Collection method. - * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. + * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.annotation] - Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit * http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. * @param {String} [params.acl] - Filter entries for which a user has the provided permissions. Format: acl={user}:{permissions}. @@ -173,7 +175,8 @@ export default class Sample extends OpenCGAParentClass { * @param {Boolean} [params.includeIndividual = "false"] - Include Individual object as an attribute. The default value is false. * @param {Boolean} [params.flattenAnnotations = "false"] - Flatten the annotations?. The default value is false. * @param {String} [params.study] - Study [[user@]project:]study where study and project can be either the ID or UUID. - * @param {String} [params.id] - Comma separated list sample IDs up to a maximum of 100. + * @param {String} [params.id] - Comma separated list sample IDs up to a maximum of 100. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.uuid] - Comma separated list sample UUIDs up to a maximum of 100. * @param {Boolean} [params.somatic] - Somatic sample. * @param {String} [params.individualId] - Individual ID or UUID. @@ -190,7 +193,8 @@ export default class Sample extends OpenCGAParentClass { * @param {String} [params.collectionFrom] - Collection from. * @param {String} [params.collectionType] - Collection type. * @param {String} [params.collectionMethod] - Collection method. - * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. + * @param {String} [params.phenotypes] - Comma separated list of phenotype ids or names. Also admits basic regular expressions using the + * operator '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search. * @param {String} [params.annotation] - Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit * http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. * @param {String} [params.acl] - Filter entries for which a user has the provided permissions. Format: acl={user}:{permissions}. diff --git a/opencga-client/src/main/javascript/Study.js b/opencga-client/src/main/javascript/Study.js index c9e4deb0aac..09159e5bc29 100644 --- a/opencga-client/src/main/javascript/Study.js +++ b/opencga-client/src/main/javascript/Study.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/javascript/User.js b/opencga-client/src/main/javascript/User.js index 904b617010a..bd11746e1de 100644 --- a/opencga-client/src/main/javascript/User.js +++ b/opencga-client/src/main/javascript/User.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/javascript/Variant.js b/opencga-client/src/main/javascript/Variant.js index 3430052c798..34884a86bb7 100644 --- a/opencga-client/src/main/javascript/Variant.js +++ b/opencga-client/src/main/javascript/Variant.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/javascript/VariantOperation.js b/opencga-client/src/main/javascript/VariantOperation.js index 5582f9cfd53..2ce54e16534 100644 --- a/opencga-client/src/main/javascript/VariantOperation.js +++ b/opencga-client/src/main/javascript/VariantOperation.js @@ -12,7 +12,7 @@ * WARNING: AUTOGENERATED CODE * * This code was generated by a tool. - * Autogenerated on: 2023-08-31 + * Autogenerated on: 2023-09-08 * * Manual changes to this file may cause unexpected behavior in your application. * Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/admin_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/admin_client.py index 98954f3e971..53fdc052390 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/admin_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/admin_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/alignment_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/alignment_client.py index 7a9da2b0a02..091948e5f53 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/alignment_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/alignment_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/clinical_analysis_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/clinical_analysis_client.py index 7c5b60dc1a3..83ab4dbb7da 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/clinical_analysis_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/clinical_analysis_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. @@ -86,11 +86,16 @@ def distinct(self, field, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list of Clinical Analysis IDs up to a - maximum of 100. + maximum of 100. Also admits basic regular expressions using the + operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + sensitive, '~/value/i' for case insensitive search. :param str uuid: Comma separated list of Clinical Analysis UUIDs up to a maximum of 100. :param str type: Clinical Analysis type. - :param str disorder: Clinical Analysis disorder. + :param str disorder: Clinical Analysis disorder. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str files: Clinical Analysis files. :param str sample: Sample associated to the proband or any member of a family. @@ -133,12 +138,17 @@ def distinct_interpretation(self, field, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list of Interpretation IDs up to a - maximum of 100. + maximum of 100. Also admits basic regular expressions using the + operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + sensitive, '~/value/i' for case insensitive search. :param str uuid: Comma separated list of Interpretation UUIDs up to a maximum of 100. :param str clinical_analysis_id: Clinical Analysis id. :param str analyst_id: Analyst ID. - :param str method_name: Interpretation method name. + :param str method_name: Interpretation method name. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str panels: Interpretation panels. :param str primary_findings: Interpretation primary findings. :param str secondary_findings: Interpretation secondary findings. @@ -169,12 +179,17 @@ def search_interpretation(self, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list of Interpretation IDs up to a - maximum of 100. + maximum of 100. Also admits basic regular expressions using the + operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + sensitive, '~/value/i' for case insensitive search. :param str uuid: Comma separated list of Interpretation UUIDs up to a maximum of 100. :param str clinical_analysis_id: Clinical Analysis id. :param str analyst_id: Analyst ID. - :param str method_name: Interpretation method name. + :param str method_name: Interpretation method name. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str panels: Interpretation panels. :param str primary_findings: Interpretation primary findings. :param str secondary_findings: Interpretation secondary findings. @@ -606,11 +621,16 @@ def search(self, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list of Clinical Analysis IDs up to a - maximum of 100. + maximum of 100. Also admits basic regular expressions using the + operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + sensitive, '~/value/i' for case insensitive search. :param str uuid: Comma separated list of Clinical Analysis UUIDs up to a maximum of 100. :param str type: Clinical Analysis type. - :param str disorder: Clinical Analysis disorder. + :param str disorder: Clinical Analysis disorder. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str files: Clinical Analysis files. :param str sample: Sample associated to the proband or any member of a family. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/cohort_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/cohort_client.py index 0a3b30eab24..445f4a66826 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/cohort_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/cohort_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. @@ -121,9 +121,13 @@ def distinct(self, field, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list of cohort IDs up to a maximum of - 100. + 100. Also admits basic regular expressions using the operator '~', + i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' + for case insensitive search. :param str name: Comma separated list of cohort names up to a maximum - of 100. + of 100. Also admits basic regular expressions using the operator + '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, + '~/value/i' for case insensitive search. :param str uuid: Comma separated list of cohort IDs up to a maximum of 100. :param str type: Cohort type. @@ -166,6 +170,9 @@ def generate(self, data=None, **options): :param str internal_status: Filter by internal status. :param str status: Filter by status. :param str phenotypes: Comma separated list of phenotype ids or names. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str annotation: Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. @@ -200,9 +207,13 @@ def search(self, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list of cohort IDs up to a maximum of - 100. + 100. Also admits basic regular expressions using the operator '~', + i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' + for case insensitive search. :param str name: Comma separated list of cohort names up to a maximum - of 100. + of 100. Also admits basic regular expressions using the operator + '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, + '~/value/i' for case insensitive search. :param str uuid: Comma separated list of cohort IDs up to a maximum of 100. :param str type: Cohort type. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/disease_panel_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/disease_panel_client.py index e5176a346f7..fdf80361f55 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/disease_panel_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/disease_panel_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. @@ -67,19 +67,42 @@ def distinct(self, field, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list of panel IDs up to a maximum of - 100. + 100. Also admits basic regular expressions using the operator '~', + i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' + for case insensitive search. :param str uuid: Comma separated list of panel UUIDs up to a maximum of 100. :param str name: Comma separated list of panel names up to a maximum - of 100. + of 100. Also admits basic regular expressions using the operator + '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, + '~/value/i' for case insensitive search. :param str internal_status: Filter by internal status. :param str disorders: Comma separated list of disorder ids or names. - :param str variants: Comma separated list of variant ids. - :param str genes: Comma separated list of gene ids. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search.. Also admits basic regular expressions + using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + sensitive, '~/value/i' for case insensitive search. + :param str variants: Comma separated list of variant ids. Also admits + basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. + :param str genes: Comma separated list of gene ids. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str source: Comma separated list of source ids or names. - :param str regions: Comma separated list of regions. - :param str categories: Comma separated list of category names. - :param str tags: Panel tags. + :param str regions: Comma separated list of regions. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. + :param str categories: Comma separated list of category names. Also + admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. + :param str tags: Panel tags. Also admits basic regular expressions + using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + sensitive, '~/value/i' for case insensitive search. :param bool deleted: Boolean to retrieve deleted entries. :param str status: Filter by status. :param str creation_date: Creation date. Format: yyyyMMddHHmmss. @@ -133,19 +156,42 @@ def search(self, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list of panel IDs up to a maximum of - 100. + 100. Also admits basic regular expressions using the operator '~', + i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' + for case insensitive search. :param str uuid: Comma separated list of panel UUIDs up to a maximum of 100. :param str name: Comma separated list of panel names up to a maximum - of 100. + of 100. Also admits basic regular expressions using the operator + '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, + '~/value/i' for case insensitive search. :param str internal_status: Filter by internal status. :param str disorders: Comma separated list of disorder ids or names. - :param str variants: Comma separated list of variant ids. - :param str genes: Comma separated list of gene ids. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search.. Also admits basic regular expressions + using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + sensitive, '~/value/i' for case insensitive search. + :param str variants: Comma separated list of variant ids. Also admits + basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. + :param str genes: Comma separated list of gene ids. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str source: Comma separated list of source ids or names. - :param str regions: Comma separated list of regions. - :param str categories: Comma separated list of category names. - :param str tags: Panel tags. + :param str regions: Comma separated list of regions. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. + :param str categories: Comma separated list of category names. Also + admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. + :param str tags: Panel tags. Also admits basic regular expressions + using the operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + sensitive, '~/value/i' for case insensitive search. :param bool deleted: Boolean to retrieve deleted entries. :param str status: Filter by status. :param str creation_date: Creation date. Format: yyyyMMddHHmmss. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/family_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/family_client.py index 198bccd8143..6642396fb41 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/family_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/family_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. @@ -124,8 +124,13 @@ def distinct(self, field, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list family IDs up to a maximum of 100. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str name: Comma separated list family names up to a maximum of - 100. + 100. Also admits basic regular expressions using the operator '~', + i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' + for case insensitive search. :param str uuid: Comma separated list family UUIDs up to a maximum of 100. :param str members: Comma separated list of family members. @@ -133,7 +138,13 @@ def distinct(self, field, **options): members). :param str samples: Comma separated list of member's samples. :param str phenotypes: Comma separated list of phenotype ids or names. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str disorders: Comma separated list of disorder ids or names. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str creation_date: Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. :param str modification_date: Modification date. Format: @@ -174,8 +185,13 @@ def search(self, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list family IDs up to a maximum of 100. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str name: Comma separated list family names up to a maximum of - 100. + 100. Also admits basic regular expressions using the operator '~', + i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' + for case insensitive search. :param str uuid: Comma separated list family UUIDs up to a maximum of 100. :param str members: Comma separated list of family members. @@ -183,7 +199,13 @@ def search(self, **options): members). :param str samples: Comma separated list of member's samples. :param str phenotypes: Comma separated list of phenotype ids or names. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str disorders: Comma separated list of disorder ids or names. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str creation_date: Creation date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. :param str modification_date: Modification date. Format: diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/file_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/file_client.py index 8ef5f6a3cee..45719c4b213 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/file_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/file_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. @@ -129,12 +129,23 @@ def distinct(self, field, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list of file IDs up to a maximum of - 100. + 100. Also admits basic regular expressions using the operator '~', + i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' + for case insensitive search. :param str uuid: Comma separated list file UUIDs up to a maximum of 100. - :param str name: Comma separated list of file names. - :param str path: Comma separated list of paths. - :param str uri: Comma separated list of uris. + :param str name: Comma separated list of file names. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. + :param str path: Comma separated list of paths. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. + :param str uri: Comma separated list of uris. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str type: File type, either FILE or DIRECTORY. :param str bioformat: Comma separated Bioformat values. For existing Bioformats see files/bioformats. @@ -154,7 +165,9 @@ def distinct(self, field, **options): :param str modification_date: Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. :param str description: Description. - :param str tags: Tags. + :param str tags: Tags. Also admits basic regular expressions using the + operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + sensitive, '~/value/i' for case insensitive search. :param str size: File size. :param str sample_ids: Comma separated list sample IDs or UUIDs up to a maximum of 100. @@ -269,12 +282,23 @@ def search(self, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list of file IDs up to a maximum of - 100. + 100. Also admits basic regular expressions using the operator '~', + i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' + for case insensitive search. :param str uuid: Comma separated list file UUIDs up to a maximum of 100. - :param str name: Comma separated list of file names. - :param str path: Comma separated list of paths. - :param str uri: Comma separated list of uris. + :param str name: Comma separated list of file names. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. + :param str path: Comma separated list of paths. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. + :param str uri: Comma separated list of uris. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str type: File type, either FILE or DIRECTORY. :param str bioformat: Comma separated Bioformat values. For existing Bioformats see files/bioformats. @@ -294,7 +318,9 @@ def search(self, **options): :param str modification_date: Modification date. Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805. :param str description: Description. - :param str tags: Tags. + :param str tags: Tags. Also admits basic regular expressions using the + operator '~', i.e. '~{perl-regex}' e.g. '~value' for case + sensitive, '~/value/i' for case insensitive search. :param str size: File size. :param str sample_ids: Comma separated list sample IDs or UUIDs up to a maximum of 100. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/ga4gh_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/ga4gh_client.py index 4ed3b96720b..a7ec7e99b6c 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/ga4gh_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/ga4gh_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/individual_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/individual_client.py index 34ec70ec784..044a326dd67 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/individual_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/individual_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. @@ -132,23 +132,42 @@ def distinct(self, field, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list individual IDs up to a maximum of - 100. + 100. Also admits basic regular expressions using the operator '~', + i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' + for case insensitive search. :param str uuid: Comma separated list individual UUIDs up to a maximum of 100. :param str name: Comma separated list individual names up to a maximum - of 100. + of 100. Also admits basic regular expressions using the operator + '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, + '~/value/i' for case insensitive search. :param str family_ids: Comma separated list of family ids the individuals may belong to. :param str father: Father ID, name or UUID. :param str mother: Mother ID, name or UUID. :param str samples: Sample ID, name or UUID. :param str sex: Individual sex. - :param str ethnicity: Individual ethnicity. + :param str ethnicity: Individual ethnicity. Also admits basic regular + expressions using the operator '~', i.e. '~{perl-regex}' e.g. + '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str date_of_birth: Individual date of birth. :param str disorders: Comma separated list of disorder ids or names. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str phenotypes: Comma separated list of phenotype ids or names. - :param str population_name: Population name. - :param str population_subpopulation: Subpopulation name. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. + :param str population_name: Population name. Also admits basic regular + expressions using the operator '~', i.e. '~{perl-regex}' e.g. + '~value' for case sensitive, '~/value/i' for case insensitive + search. + :param str population_subpopulation: Subpopulation name. Also admits + basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str karyotypic_sex: Individual karyotypic sex. :param str life_status: Individual life status. :param str internal_status: Filter by internal status. @@ -191,11 +210,15 @@ def search(self, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list individual IDs up to a maximum of - 100. + 100. Also admits basic regular expressions using the operator '~', + i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' + for case insensitive search. :param str uuid: Comma separated list individual UUIDs up to a maximum of 100. :param str name: Comma separated list individual names up to a maximum - of 100. + of 100. Also admits basic regular expressions using the operator + '~', i.e. '~{perl-regex}' e.g. '~value' for case sensitive, + '~/value/i' for case insensitive search. :param str father: Father ID, name or UUID. :param str mother: Mother ID, name or UUID. :param str samples: Sample ID, name or UUID. @@ -203,11 +226,26 @@ def search(self, **options): individuals may belong to. :param str sex: Individual sex. :param str date_of_birth: Individual date of birth. - :param str ethnicity: Individual ethnicity. + :param str ethnicity: Individual ethnicity. Also admits basic regular + expressions using the operator '~', i.e. '~{perl-regex}' e.g. + '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str disorders: Comma separated list of disorder ids or names. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str phenotypes: Comma separated list of phenotype ids or names. - :param str population_name: Population name. - :param str population_subpopulation: Subpopulation name. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. + :param str population_name: Population name. Also admits basic regular + expressions using the operator '~', i.e. '~{perl-regex}' e.g. + '~value' for case sensitive, '~/value/i' for case insensitive + search. + :param str population_subpopulation: Subpopulation name. Also admits + basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str karyotypic_sex: Individual karyotypic sex. :param str life_status: Individual life status. :param str internal_status: Filter by internal status. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/job_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/job_client.py index d12fbfa375a..eeda7834cd9 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/job_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/job_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. @@ -92,9 +92,15 @@ def distinct(self, field, **options): :param bool other_studies: Flag indicating the entries being queried can belong to any related study, not just the primary one. :param str id: Comma separated list of job IDs up to a maximum of 100. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str uuid: Comma separated list of job UUIDs up to a maximum of 100. - :param str tool_id: Tool ID executed by the job. + :param str tool_id: Tool ID executed by the job. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str tool_type: Tool type executed by the job [OPERATION, ANALYSIS]. :param str user_id: User that created the job. @@ -157,9 +163,15 @@ def search(self, **options): :param bool other_studies: Flag indicating the entries being queried can belong to any related study, not just the primary one. :param str id: Comma separated list of job IDs up to a maximum of 100. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str uuid: Comma separated list of job UUIDs up to a maximum of 100. - :param str tool_id: Tool ID executed by the job. + :param str tool_id: Tool ID executed by the job. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. :param str tool_type: Tool type executed by the job [OPERATION, ANALYSIS]. :param str user_id: User that created the job. @@ -196,7 +208,10 @@ def top(self, **options): :param str internal_status: Filter by internal status. :param str priority: Priority of the job. :param str user_id: User that created the job. - :param str tool_id: Tool ID executed by the job. + :param str tool_id: Tool ID executed by the job. Also admits basic + regular expressions using the operator '~', i.e. '~{perl-regex}' + e.g. '~value' for case sensitive, '~/value/i' for case insensitive + search. """ return self._get(category='jobs', resource='top', **options) diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/meta_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/meta_client.py index c334170020b..bee9670a694 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/meta_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/meta_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/project_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/project_client.py index f9c91a6177f..c3b4c0a9e38 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/project_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/project_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/sample_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/sample_client.py index d9afbca66d7..7cf520ad6c0 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/sample_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/sample_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. @@ -122,6 +122,9 @@ def distinct(self, field, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list sample IDs up to a maximum of 100. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str uuid: Comma separated list sample UUIDs up to a maximum of 100. :param bool somatic: Somatic sample. @@ -143,6 +146,9 @@ def distinct(self, field, **options): :param str collection_type: Collection type. :param str collection_method: Collection method. :param str phenotypes: Comma separated list of phenotype ids or names. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str annotation: Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. @@ -215,6 +221,9 @@ def search(self, **options): :param str study: Study [[user@]project:]study where study and project can be either the ID or UUID. :param str id: Comma separated list sample IDs up to a maximum of 100. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str uuid: Comma separated list sample UUIDs up to a maximum of 100. :param bool somatic: Somatic sample. @@ -236,6 +245,9 @@ def search(self, **options): :param str collection_type: Collection type. :param str collection_method: Collection method. :param str phenotypes: Comma separated list of phenotype ids or names. + Also admits basic regular expressions using the operator '~', i.e. + '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for + case insensitive search. :param str annotation: Annotation filters. Example: age>30;gender=FEMALE. For more information, please visit http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/study_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/study_client.py index 5698145ea79..09a0d3d5e96 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/study_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/study_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/user_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/user_client.py index 36018f0560f..c05e00b0e30 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/user_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/user_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/variant_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/variant_client.py index c6143f58c4d..7a2081d3bbb 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/variant_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/variant_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-client/src/main/python/pyopencga/rest_clients/variant_operation_client.py b/opencga-client/src/main/python/pyopencga/rest_clients/variant_operation_client.py index 10e74c335a6..775c3130a2b 100644 --- a/opencga-client/src/main/python/pyopencga/rest_clients/variant_operation_client.py +++ b/opencga-client/src/main/python/pyopencga/rest_clients/variant_operation_client.py @@ -2,7 +2,7 @@ WARNING: AUTOGENERATED CODE This code was generated by a tool. - Autogenerated on: 2023-08-31 + Autogenerated on: 2023-09-08 Manual changes to this file may cause unexpected behavior in your application. Manual changes to this file will be overwritten if the code is regenerated. diff --git a/opencga-core/src/main/java/org/opencb/opencga/core/api/ParamConstants.java b/opencga-core/src/main/java/org/opencb/opencga/core/api/ParamConstants.java index b1e57dbc24a..ebcfa07153c 100644 --- a/opencga-core/src/main/java/org/opencb/opencga/core/api/ParamConstants.java +++ b/opencga-core/src/main/java/org/opencb/opencga/core/api/ParamConstants.java @@ -38,6 +38,8 @@ public class ParamConstants { public static final String RELEASE_DESCRIPTION = "Release when it was created"; public static final String INTERNAL_STATUS_PARAM = "internalStatus"; public static final String INTERNAL_STATUS_DESCRIPTION = "Filter by internal status"; + private static final String REGEX_SUPPORT = ". Also admits basic regular expressions using the operator '~', " + + "i.e. '~{perl-regex}' e.g. '~value' for case sensitive, '~/value/i' for case insensitive search."; @Deprecated // Use INTERNAL_VARIANT_INDEX_STATUS_PARAM public static final String INTERNAL_INDEX_STATUS_PARAM = "internalIndexStatus"; public static final String INTERNAL_VARIANT_INDEX_STATUS_PARAM = "internalVariantIndexStatus"; @@ -66,9 +68,9 @@ public class ParamConstants { public static final String DISTINCT_FIELD_PARAM = "field"; public static final String DISTINCT_FIELD_DESCRIPTION = "Comma separated list of fields for which to obtain the distinct values"; public static final String PHENOTYPES_PARAM = "phenotypes"; - public static final String PHENOTYPES_DESCRIPTION = "Comma separated list of phenotype ids or names"; + public static final String PHENOTYPES_DESCRIPTION = "Comma separated list of phenotype ids or names" + REGEX_SUPPORT; public static final String DISORDERS_PARAM = "disorders"; - public static final String DISORDERS_DESCRIPTION = "Comma separated list of disorder ids or names"; + public static final String DISORDERS_DESCRIPTION = "Comma separated list of disorder ids or names" + REGEX_SUPPORT; public static final String BODY_PARAM = "body"; public static final String OVERWRITE = "overwrite"; @@ -169,12 +171,12 @@ public class ParamConstants { + "exception whenever one of the entries looked for cannot be shown for whichever reason"; public static final String FILE_ID_DESCRIPTION = "File ID"; public static final String FILE_NAME_DESCRIPTION = "File name"; - public static final String FILE_NAMES_DESCRIPTION = "Comma separated list of file names"; + public static final String FILE_NAMES_DESCRIPTION = "Comma separated list of file names" + REGEX_SUPPORT; // --------------------------------------------- public static final String FILE_PATH_PARAM = "path"; public static final String FILE_PATH_DESCRIPTION = "File path"; - public static final String FILE_PATHS_DESCRIPTION = "Comma separated list of paths"; - public static final String FILE_URIS_DESCRIPTION = "Comma separated list of uris"; + public static final String FILE_PATHS_DESCRIPTION = "Comma separated list of paths" + REGEX_SUPPORT; + public static final String FILE_URIS_DESCRIPTION = "Comma separated list of uris" + REGEX_SUPPORT; public static final String FILE_TYPE_DESCRIPTION = "File type, either FILE or DIRECTORY"; public static final String FILE_FORMAT_DESCRIPTION = "Comma separated Format values. For existing Formats see files/formats"; public static final String FILE_EXTERNAL_DESCRIPTION = "Boolean field indicating whether to filter by external or non external files"; @@ -182,7 +184,7 @@ public class ParamConstants { "files/bioformats"; public static final String FILE_STATUS_DESCRIPTION = "File status"; public static final String FILE_DESCRIPTION_DESCRIPTION = "Description"; - public static final String FILE_TAGS_DESCRIPTION = "Tags"; + public static final String FILE_TAGS_DESCRIPTION = "Tags" + REGEX_SUPPORT; public static final String FILE_SOFTWARE_NAME_PARAM = "softwareName"; public static final String FILE_SOFTWARE_NAME_DESCRIPTION = "Software name"; public static final String FILE_JOB_ID_DESCRIPTION = "Job ID that created the file(s) or folder(s)"; @@ -316,12 +318,12 @@ public class ParamConstants { public static final String INDIVIDUAL_MOTHER_DESCRIPTION = "Mother ID, name or UUID"; public static final String INDIVIDUAL_SAMPLES_DESCRIPTION = "Sample ID, name or UUID"; public static final String INDIVIDUAL_SEX_DESCRIPTION = "Individual sex"; - public static final String INDIVIDUAL_ETHNICITY_DESCRIPTION = "Individual ethnicity"; + public static final String INDIVIDUAL_ETHNICITY_DESCRIPTION = "Individual ethnicity" + REGEX_SUPPORT; public static final String INDIVIDUAL_DATE_OF_BIRTH_DESCRIPTION = "Individual date of birth"; public static final String INDIVIDUAL_DISORDERS_DESCRIPTION = DISORDERS_DESCRIPTION; public static final String INDIVIDUAL_PHENOTYPES_DESCRIPTION = PHENOTYPES_DESCRIPTION; - public static final String INDIVIDUAL_POPULATION_NAME_DESCRIPTION = "Population name"; - public static final String INDIVIDUAL_POPULATION_SUBPOPULATION_DESCRIPTION = "Subpopulation name"; + public static final String INDIVIDUAL_POPULATION_NAME_DESCRIPTION = "Population name" + REGEX_SUPPORT; + public static final String INDIVIDUAL_POPULATION_SUBPOPULATION_DESCRIPTION = "Subpopulation name" + REGEX_SUPPORT; public static final String INDIVIDUAL_KARYOTYPIC_SEX_DESCRIPTION = "Individual karyotypic sex"; public static final String INDIVIDUAL_LIFE_STATUS_DESCRIPTION = "Individual life status"; public static final String INDIVIDUAL_DELETED_DESCRIPTION = DELETED_DESCRIPTION; @@ -422,7 +424,7 @@ public class ParamConstants { public static final String CLINICAL_STATUS_PARAM = STATUS_PARAM; public static final String CLINICAL_INTERNAL_STATUS_PARAM = INTERNAL_STATUS_PARAM; public static final String CLINICAL_TYPE_DESCRIPTION = "Clinical Analysis type"; - public static final String CLINICAL_DISORDER_DESCRIPTION = "Clinical Analysis disorder"; + public static final String CLINICAL_DISORDER_DESCRIPTION = "Clinical Analysis disorder" + REGEX_SUPPORT; public static final String CLINICAL_FILES_DESCRIPTION = "Clinical Analysis files"; public static final String CLINICAL_SAMPLE_DESCRIPTION = "Sample associated to the proband or any member of a family"; public static final String CLINICAL_INDIVIDUAL_DESCRIPTION = "Proband or any member of a family"; @@ -466,7 +468,7 @@ public class ParamConstants { public static final String INTERPRETATION_LOCKED_PARAM = "locked"; public static final String INTERPRETATION_CLINICAL_ANALYSIS_ID_DESCRIPTION = "Clinical Analysis id"; public static final String INTERPRETATION_ANALYST_ID_DESCRIPTION = "Analyst ID"; - public static final String INTERPRETATION_METHOD_NAME_DESCRIPTION = "Interpretation method name"; + public static final String INTERPRETATION_METHOD_NAME_DESCRIPTION = "Interpretation method name" + REGEX_SUPPORT; public static final String INTERPRETATION_PANELS_DESCRIPTION = "Interpretation panels"; public static final String INTERPRETATION_PRIMARY_FINDINGS_IDS_DESCRIPTION = "Interpretation primary findings"; public static final String INTERPRETATION_SECONDARY_FINDINGS_IDS_DESCRIPTION = "Interpretation secondary findings"; @@ -498,12 +500,12 @@ public class ParamConstants { public static final String PANEL_ACL_PARAM = ACL_PARAM; public static final String PANEL_RELEASE_PARAM = RELEASE_PARAM; public static final String PANEL_SNAPSHOT_PARAM = SNAPSHOT_PARAM; - public static final String PANEL_DISORDERS_DESCRIPTION = DISORDERS_DESCRIPTION; - public static final String PANEL_VARIANTS_DESCRIPTION = "Comma separated list of variant ids"; - public static final String PANEL_GENES_DESCRIPTION = "Comma separated list of gene ids"; - public static final String PANEL_REGIONS_DESCRIPTION = "Comma separated list of regions"; - public static final String PANEL_CATEGORIES_DESCRIPTION = "Comma separated list of category names"; - public static final String PANEL_TAGS_DESCRIPTION = "Panel tags"; + public static final String PANEL_DISORDERS_DESCRIPTION = DISORDERS_DESCRIPTION + REGEX_SUPPORT; + public static final String PANEL_VARIANTS_DESCRIPTION = "Comma separated list of variant ids" + REGEX_SUPPORT; + public static final String PANEL_GENES_DESCRIPTION = "Comma separated list of gene ids" + REGEX_SUPPORT; + public static final String PANEL_REGIONS_DESCRIPTION = "Comma separated list of regions" + REGEX_SUPPORT; + public static final String PANEL_CATEGORIES_DESCRIPTION = "Comma separated list of category names" + REGEX_SUPPORT; + public static final String PANEL_TAGS_DESCRIPTION = "Panel tags" + REGEX_SUPPORT; public static final String PANEL_DELETED_DESCRIPTION = DELETED_DESCRIPTION; public static final String PANEL_STATUS_DESCRIPTION = STATUS_DESCRIPTION; @@ -539,7 +541,7 @@ public class ParamConstants { public static final String JOB_DEPENDS_ON_DESCRIPTION = "Comma separated list of existing job IDs the job will depend on."; public static final String JOB_TOOL_ID_PARAM = "toolId"; public static final String JOB_TOOL_TYPE_PARAM = "toolType"; - public static final String JOB_TOOL_ID_DESCRIPTION = "Tool ID executed by the job"; + public static final String JOB_TOOL_ID_DESCRIPTION = "Tool ID executed by the job" + REGEX_SUPPORT; public static final String JOB_TOOL_TYPE_DESCRIPTION = "Tool type executed by the job [OPERATION, ANALYSIS]"; public static final String JOB_USER_PARAM = "userId"; public static final String JOB_USER_DESCRIPTION = "User that created the job"; @@ -1475,34 +1477,34 @@ public class ParamConstants { public static final String ADMIN_CATALOG_JWT_SECRETKEY = "The body web service secretKey parameter"; private static final String UP_TO_100 = " up to a maximum of 100"; public static final String FILES_DESCRIPTION = "Comma separated list of file IDs or names" + UP_TO_100; - public static final String FILES_ID_DESCRIPTION = "Comma separated list of file IDs" + UP_TO_100; + public static final String FILES_ID_DESCRIPTION = "Comma separated list of file IDs" + UP_TO_100 + REGEX_SUPPORT; public static final String FILES_UUID_DESCRIPTION = "Comma separated list file UUIDs" + UP_TO_100; public static final String SAMPLES_DESCRIPTION = "Comma separated list sample IDs or UUIDs" + UP_TO_100; - public static final String SAMPLES_ID_DESCRIPTION = "Comma separated list sample IDs" + UP_TO_100; + public static final String SAMPLES_ID_DESCRIPTION = "Comma separated list sample IDs" + UP_TO_100 + REGEX_SUPPORT; public static final String SAMPLES_UUID_DESCRIPTION = "Comma separated list sample UUIDs" + UP_TO_100; public static final String INDIVIDUALS_DESCRIPTION = "Comma separated list of individual IDs, names or UUIDs" + UP_TO_100; - public static final String INDIVIDUALS_ID_DESCRIPTION = "Comma separated list individual IDs" + UP_TO_100; - public static final String INDIVIDUAL_NAME_DESCRIPTION = "Comma separated list individual names" + UP_TO_100; + public static final String INDIVIDUALS_ID_DESCRIPTION = "Comma separated list individual IDs" + UP_TO_100 + REGEX_SUPPORT; + public static final String INDIVIDUAL_NAME_DESCRIPTION = "Comma separated list individual names" + UP_TO_100 + REGEX_SUPPORT; public static final String INDIVIDUAL_UUID_DESCRIPTION = "Comma separated list individual UUIDs" + UP_TO_100; public static final String FAMILIES_DESCRIPTION = "Comma separated list of family IDs or names" + UP_TO_100; - public static final String FAMILY_ID_DESCRIPTION = "Comma separated list family IDs" + UP_TO_100; - public static final String FAMILY_NAME_DESCRIPTION = "Comma separated list family names" + UP_TO_100; + public static final String FAMILY_ID_DESCRIPTION = "Comma separated list family IDs" + UP_TO_100 + REGEX_SUPPORT; + public static final String FAMILY_NAME_DESCRIPTION = "Comma separated list family names" + UP_TO_100 + REGEX_SUPPORT; public static final String FAMILY_UUID_DESCRIPTION = "Comma separated list family UUIDs" + UP_TO_100; public static final String COHORTS_DESCRIPTION = "Comma separated list of cohort IDs or UUIDs" + UP_TO_100; - public static final String COHORT_IDS_DESCRIPTION = "Comma separated list of cohort IDs" + UP_TO_100; - public static final String COHORT_NAMES_DESCRIPTION = "Comma separated list of cohort names" + UP_TO_100; + public static final String COHORT_IDS_DESCRIPTION = "Comma separated list of cohort IDs" + UP_TO_100 + REGEX_SUPPORT; + public static final String COHORT_NAMES_DESCRIPTION = "Comma separated list of cohort names" + UP_TO_100 + REGEX_SUPPORT; public static final String COHORT_UUIDS_DESCRIPTION = "Comma separated list of cohort IDs" + UP_TO_100; - public static final String CLINICAL_ID_DESCRIPTION = "Comma separated list of Clinical Analysis IDs" + UP_TO_100; + public static final String CLINICAL_ID_DESCRIPTION = "Comma separated list of Clinical Analysis IDs" + UP_TO_100 + REGEX_SUPPORT; public static final String CLINICAL_UUID_DESCRIPTION = "Comma separated list of Clinical Analysis UUIDs" + UP_TO_100; public static final String CLINICAL_ANALYSES_DESCRIPTION = "Comma separated list of clinical analysis IDs or names" + UP_TO_100; - public static final String INTERPRETATION_ID_DESCRIPTION = "Comma separated list of Interpretation IDs" + UP_TO_100; + public static final String INTERPRETATION_ID_DESCRIPTION = "Comma separated list of Interpretation IDs" + UP_TO_100 + REGEX_SUPPORT; public static final String INTERPRETATION_UUID_DESCRIPTION = "Comma separated list of Interpretation UUIDs" + UP_TO_100; public static final String INTERPRETATION_DESCRIPTION = "Comma separated list of clinical interpretation IDs " + UP_TO_100; - public static final String PANEL_ID_DESCRIPTION = "Comma separated list of panel IDs " + UP_TO_100; + public static final String PANEL_ID_DESCRIPTION = "Comma separated list of panel IDs " + UP_TO_100 + REGEX_SUPPORT; public static final String PANEL_UUID_DESCRIPTION = "Comma separated list of panel UUIDs " + UP_TO_100; - public static final String PANEL_NAME_DESCRIPTION = "Comma separated list of panel names " + UP_TO_100; + public static final String PANEL_NAME_DESCRIPTION = "Comma separated list of panel names " + UP_TO_100 + REGEX_SUPPORT; public static final String JOBS_DESCRIPTION = "Comma separated list of job IDs or UUIDs" + UP_TO_100; - public static final String JOB_IDS_DESCRIPTION = "Comma separated list of job IDs" + UP_TO_100; + public static final String JOB_IDS_DESCRIPTION = "Comma separated list of job IDs" + UP_TO_100 + REGEX_SUPPORT; public static final String JOB_UUIDS_DESCRIPTION = "Comma separated list of job UUIDs" + UP_TO_100; // --------------------------------------------- public static final String PROJECTS_DESCRIPTION = "Comma separated list of projects [user@]project" + UP_TO_100; diff --git a/opencga-core/src/main/java/org/opencb/opencga/core/config/storage/SampleIndexConfiguration.java b/opencga-core/src/main/java/org/opencb/opencga/core/config/storage/SampleIndexConfiguration.java index f2e6bf1c3f8..21178f7fdf4 100644 --- a/opencga-core/src/main/java/org/opencb/opencga/core/config/storage/SampleIndexConfiguration.java +++ b/opencga-core/src/main/java/org/opencb/opencga/core/config/storage/SampleIndexConfiguration.java @@ -386,6 +386,15 @@ public List getCustomFields() { return customFields; } + public IndexFieldConfiguration getCustomField(IndexFieldConfiguration.Source source, String key) { + for (IndexFieldConfiguration s : customFields) { + if (s.getKey().equals(key) && s.getSource() == source) { + return s; + } + } + return null; + } + public int getFilePositionBits() { return filePositionBits; } @@ -705,4 +714,13 @@ public boolean equals(Object o) { public int hashCode() { return Objects.hash(fileIndexConfiguration, annotationIndexConfiguration); } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("SampleIndexConfiguration{"); + sb.append("fileIndexConfiguration=").append(fileIndexConfiguration); + sb.append(", annotationIndexConfiguration=").append(annotationIndexConfiguration); + sb.append('}'); + return sb.toString(); + } } diff --git a/opencga-storage/opencga-storage-core/src/main/java/org/opencb/opencga/storage/core/metadata/models/ProjectMetadata.java b/opencga-storage/opencga-storage-core/src/main/java/org/opencb/opencga/storage/core/metadata/models/ProjectMetadata.java index c27111d1c03..e64deedff64 100644 --- a/opencga-storage/opencga-storage-core/src/main/java/org/opencb/opencga/storage/core/metadata/models/ProjectMetadata.java +++ b/opencga-storage/opencga-storage-core/src/main/java/org/opencb/opencga/storage/core/metadata/models/ProjectMetadata.java @@ -85,10 +85,6 @@ public VariantAnnotationMetadata() { sourceVersion = new ArrayList<>(); } - public VariantAnnotationMetadata(int id, String name, Date creationDate, VariantAnnotatorProgram annotator, - List sourceVersion, DataRelease dataRelease) { - - } public VariantAnnotationMetadata(int id, String name, Date creationDate, VariantAnnotatorProgram annotator, List sourceVersion, DataRelease dataRelease, List privateSources) { this.id = id; diff --git a/opencga-storage/opencga-storage-core/src/main/java/org/opencb/opencga/storage/core/variant/query/VariantQueryUtils.java b/opencga-storage/opencga-storage-core/src/main/java/org/opencb/opencga/storage/core/variant/query/VariantQueryUtils.java index 6e7831c69ed..114379c77a9 100644 --- a/opencga-storage/opencga-storage-core/src/main/java/org/opencb/opencga/storage/core/variant/query/VariantQueryUtils.java +++ b/opencga-storage/opencga-storage-core/src/main/java/org/opencb/opencga/storage/core/variant/query/VariantQueryUtils.java @@ -25,6 +25,7 @@ import org.opencb.biodata.models.core.Region; import org.opencb.biodata.models.variant.StudyEntry; import org.opencb.biodata.models.variant.Variant; +import org.opencb.biodata.models.variant.VariantBuilder; import org.opencb.biodata.models.variant.annotation.ConsequenceTypeMappings; import org.opencb.biodata.models.variant.avro.*; import org.opencb.commons.datastore.core.*; @@ -515,9 +516,18 @@ public static boolean isHpo(String value) { */ public static boolean isVariantId(String value) { int count = StringUtils.countMatches(value, ':'); - return count == 3 - // It may have more colons if is a symbolic alternate like , or a breakend 4:100:C:]15:300]A - || count > 3 && StringUtils.containsAny(value, '<', '[', ']'); + if (count == 3) { + return true; + } + if (count > 3) { + try { + new VariantBuilder(value); + } catch (RuntimeException e) { + return false; + } + return true; + } + return false; } /** diff --git a/opencga-storage/opencga-storage-core/src/test/java/org/opencb/opencga/storage/core/variant/adaptors/VariantQueryUtilsTest.java b/opencga-storage/opencga-storage-core/src/test/java/org/opencb/opencga/storage/core/variant/adaptors/VariantQueryUtilsTest.java index 8f14f1a202b..c939064307e 100644 --- a/opencga-storage/opencga-storage-core/src/test/java/org/opencb/opencga/storage/core/variant/adaptors/VariantQueryUtilsTest.java +++ b/opencga-storage/opencga-storage-core/src/test/java/org/opencb/opencga/storage/core/variant/adaptors/VariantQueryUtilsTest.java @@ -435,6 +435,8 @@ public void isVariantId() { checkIsVariantId("1:1000:A:T"); checkIsVariantId("1:1000-2000:A:T"); checkIsVariantId("1:1000-2000:A:"); + checkIsVariantId("HLA-DRB1*04:03:01:3349:GAGACAGAG:-", true); + checkIsVariantId("HLA-DRB1*04:03:01:3349:GAGACAGAG:-:2", false); checkIsVariantId("11:14525312:-:]11:14521700]."); checkIsVariantId("4:100:C:[15:300[A"); checkIsVariantId("4:100:C:]15:300]A"); @@ -442,8 +444,6 @@ public void isVariantId() { } public void checkIsVariantId(String v) { - - boolean actual = VariantQueryUtils.isVariantId(v); boolean expected; try { new Variant(v); @@ -451,6 +451,11 @@ public void checkIsVariantId(String v) { } catch (Exception e) { expected = false; } + checkIsVariantId(v, expected); + } + + public void checkIsVariantId(String v, boolean expected) { + boolean actual = VariantQueryUtils.isVariantId(v); assertEquals(v, expected, actual); } diff --git a/opencga-storage/opencga-storage-core/src/test/resources/variant-multiallelic.vcf b/opencga-storage/opencga-storage-core/src/test/resources/variant-multiallelic.vcf new file mode 100644 index 00000000000..dc1cfc5d784 --- /dev/null +++ b/opencga-storage/opencga-storage-core/src/test/resources/variant-multiallelic.vcf @@ -0,0 +1,20 @@ +##fileformat=VCFv4.1 +##FILTER= +##FILTER= +##FILTER= +##FILTER= +##FORMAT= +##FORMAT= +##FORMAT= +##command=seq 1000000 500 3000000 | while read i ; do echo -e "chr1\t$i\t.\tA\tC\t$RANDOM\tPASS\t.\tGT\t0/1\t1/1\t1|0\t0|1" ; done +#CHROM POS ID REF ALT QUAL FILTER INFO FORMAT NA19600 NA19660 NA19661 NA19685 +chr1 1000000 . A C,T 5 noPass,noPass2 . GT 1/2 1/1 0|0 0|1 +chr1 1000010 . A AC,CA 20 PASS . GT 1/2 1/1 0|0 0|1 +chr1 1000020 . AT T,A 60 . . GT 1/2 1/1 0|0 0|1 +chr1 1000030 . C G 60 . PASS GT 1/0 1/1 0|0 0|1 +chr1 1000040 . C G 60 . PASS GT 1/0 1/1 0|0 0|1 +chr1 1000050 . C G 60 . PASS GT 1/0 1/1 0|0 0|1 +chr1 1000060 . C G 60 . PASS GT 1/0 1/1 0|0 0|1 +chr1 1000070 . C G 60 . PASS GT 1/0 1/1 0|0 0|1 +chr1 1000080 . C G 60 . PASS GT 1/0 1/1 0|0 0|1 +chr1 1000090 . C G 60 . PASS GT 1/0 1/1 0|0 0|1 \ No newline at end of file diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/SampleIndexOnlyVariantQueryExecutor.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/SampleIndexOnlyVariantQueryExecutor.java index 4e33e778ca4..5829a9580a8 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/SampleIndexOnlyVariantQueryExecutor.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/SampleIndexOnlyVariantQueryExecutor.java @@ -16,7 +16,9 @@ import org.opencb.commons.run.Task; import org.opencb.opencga.core.common.BatchUtils; import org.opencb.opencga.core.common.TimeUtils; +import org.opencb.opencga.core.config.storage.IndexFieldConfiguration; import org.opencb.opencga.core.response.VariantQueryResult; +import org.opencb.opencga.storage.core.io.bit.BitBuffer; import org.opencb.opencga.storage.core.metadata.VariantStorageMetadataManager; import org.opencb.opencga.storage.core.metadata.models.SampleMetadata; import org.opencb.opencga.storage.core.metadata.models.TaskMetadata; @@ -31,10 +33,12 @@ import org.opencb.opencga.storage.core.variant.query.projection.VariantQueryProjectionParser; import org.opencb.opencga.storage.hadoop.variant.adaptors.VariantHadoopDBAdaptor; import org.opencb.opencga.storage.hadoop.variant.converters.HBaseToVariantConverter; +import org.opencb.opencga.storage.hadoop.variant.index.core.IndexField; import org.opencb.opencga.storage.hadoop.variant.index.family.GenotypeCodec; import org.opencb.opencga.storage.hadoop.variant.index.query.SampleIndexQuery; import org.opencb.opencga.storage.hadoop.variant.index.sample.SampleIndexDBAdaptor; import org.opencb.opencga.storage.hadoop.variant.index.sample.SampleIndexQueryParser; +import org.opencb.opencga.storage.hadoop.variant.index.sample.SampleIndexSchema; import org.opencb.opencga.storage.hadoop.variant.index.sample.SampleVariantIndexEntry; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -42,6 +46,7 @@ import java.io.IOException; import java.util.*; import java.util.concurrent.*; +import java.util.function.BiConsumer; import java.util.stream.Collectors; import static org.opencb.opencga.storage.core.variant.query.VariantQueryUtils.NONE; @@ -61,7 +66,7 @@ public class SampleIndexOnlyVariantQueryExecutor extends VariantQueryExecutor { private final VariantHadoopDBAdaptor dbAdaptor; private final VariantQueryParser variantQueryParser; private final VariantQueryProjectionParser variantQueryProjectionParser; - private Logger logger = LoggerFactory.getLogger(SampleIndexOnlyVariantQueryExecutor.class); + private static Logger logger = LoggerFactory.getLogger(SampleIndexOnlyVariantQueryExecutor.class); private static final ExecutorService THREAD_POOL = Executors.newCachedThreadPool(new BasicThreadFactory.Builder() .namingPattern("sample-index-async-count-%s") @@ -171,8 +176,9 @@ private VariantDBIterator getVariantDBIterator(SampleIndexQuery sampleIndexQuery } catch (IOException e) { throw VariantQueryException.internalException(e).setQuery(inputQuery); } - SampleVariantIndexEntryToVariantConverter converter = - new SampleVariantIndexEntryToVariantConverter(parsedQuery, sampleIndexQuery, dbAdaptor.getMetadataManager()); + boolean includeAll = inputQuery.getBoolean("includeAllFromSampleIndex", false); + SampleVariantIndexEntryToVariantConverter converter = new SampleVariantIndexEntryToVariantConverter( + parsedQuery, sampleIndexQuery, dbAdaptor.getMetadataManager(), includeAll); variantIterator = VariantDBIterator.wrapper(Iterators.transform(rawIterator, converter::convert)); AddMissingDataTask task = new AddMissingDataTask( parsedQuery, sampleIndexQuery, dbAdaptor.getMetadataManager()); @@ -286,7 +292,7 @@ private static class SampleVariantIndexEntryToVariantConverter implements Conver enum FamilyRole { MOTHER, FATHER, - SAMPLE + SAMPLE; } private final boolean includeStudy; @@ -296,9 +302,18 @@ enum FamilyRole { private String motherName; private String fatherName; private LinkedHashMap samplesPosition; + private List sampleFiles; + private IndexField filterField; + private IndexField qualField; + private final SampleIndexSchema schema; + private final boolean includeAll; + SampleVariantIndexEntryToVariantConverter(ParsedVariantQuery parseQuery, SampleIndexQuery sampleIndexQuery, - VariantStorageMetadataManager metadataManager) { + VariantStorageMetadataManager metadataManager, boolean includeAll) { + schema = sampleIndexQuery.getSchema(); + this.includeAll = includeAll; + VariantQueryProjection projection = parseQuery.getProjection(); includeStudy = !projection.getStudyIds().isEmpty(); if (includeStudy) { @@ -348,6 +363,31 @@ enum FamilyRole { this.fatherName = null; } + if (includeAll) { + if (sampleMetadata == null) { + sampleMetadata = metadataManager.getSampleMetadata(studyId, sampleId); + } + if (sampleMetadata.isMultiFileSample()) { + List sampleFileIds = sampleMetadata.getFiles(); + sampleFiles = new ArrayList<>(sampleFileIds.size()); + for (Integer fileId : sampleFileIds) { + sampleFiles.add(metadataManager.getFileName(studyId, fileId)); + } + } else { + List fileIds = metadataManager.getFileIdsFromSampleId(studyId, sampleId, true); + if (fileIds.isEmpty()) { + logger.warn("Sample without indexed files!"); + sampleFiles = Collections.singletonList("sample_without_indexed_files.vcf"); + } else { + String fileName = metadataManager.getFileName(studyId, fileIds.get(0)); + sampleFiles = Collections.singletonList(fileName); + } + } + filterField = schema.getFileIndex() + .getCustomField(IndexFieldConfiguration.Source.FILE, StudyEntry.FILTER); + qualField = schema.getFileIndex() + .getCustomField(IndexFieldConfiguration.Source.FILE, StudyEntry.QUAL); + } } } @@ -360,24 +400,49 @@ public Variant convert(SampleVariantIndexEntry entry) { studyEntry.setStudyId(studyName); studyEntry.setSampleDataKeys(Collections.singletonList("GT")); studyEntry.setSamples(new ArrayList<>(familyRoleOrder.size())); + SampleEntry sampleEntry = null; for (FamilyRole role : familyRoleOrder) { switch (role) { case MOTHER: studyEntry.getSamples().add(new SampleEntry(motherName, null, - Collections.singletonList(GenotypeCodec.decodeMother(entry.getParentsCode())))); + Arrays.asList(GenotypeCodec.decodeMother(entry.getParentsCode())))); break; case FATHER: studyEntry.getSamples().add(new SampleEntry(fatherName, null, - Collections.singletonList(GenotypeCodec.decodeFather(entry.getParentsCode())))); + Arrays.asList(GenotypeCodec.decodeFather(entry.getParentsCode())))); break; case SAMPLE: - studyEntry.getSamples().add(new SampleEntry(sampleName, null, - Collections.singletonList(entry.getGenotype()))); + sampleEntry = new SampleEntry(sampleName, null, + Arrays.asList(entry.getGenotype())); + studyEntry.getSamples().add(sampleEntry); break; default: throw new IllegalStateException("Unexpected value: " + role); } } + if (includeAll) { + HashMap fileAttributes = new HashMap<>(); + for (BitBuffer fileIndexBitBuffer : entry.getFilesIndex()) { + String filter = filterField.readAndDecode(fileIndexBitBuffer); + if (filter == null) { + filter = "NA"; + } + fileAttributes.put(StudyEntry.FILTER, filter); + String qual = qualField.readAndDecode(fileIndexBitBuffer); + if (qual == null) { + qual = "NA"; + } + fileAttributes.put(StudyEntry.QUAL, qual); + + Integer idx = schema.getFileIndex().getFilePositionIndex().readAndDecode(fileIndexBitBuffer); + String fileName = sampleFiles.get(idx); + studyEntry.setFiles(new ArrayList<>()); + studyEntry.getFiles().add(new FileEntry(fileName, null, fileAttributes)); + if (sampleEntry != null) { + sampleEntry.setFileIndex(0); + } + } + } studyEntry.setSortedSamplesPosition(samplesPosition); v.setStudies(Collections.singletonList(studyEntry)); } @@ -388,9 +453,11 @@ public Variant convert(SampleVariantIndexEntry entry) { private class AddMissingDataTask implements Task { private final ParsedVariantQuery parsedQuery; private final String studyName; - private final List samples; - private final List files; - private final List allFiles; + private final String sampleName; + private final List filesFromSample; + private final List includeSamples; + private final List allFiles; // from all includedSamples + private final int gtIdx; AddMissingDataTask(ParsedVariantQuery parsedQuery, SampleIndexQuery sampleIndexQuery, VariantStorageMetadataManager metadataManager) { @@ -406,9 +473,9 @@ private class AddMissingDataTask implements Task { throw new IllegalStateException("Unexpected number of samples. Expected one, found " + sampleIndexQuery.getSamplesMap().keySet()); } - samples = new ArrayList<>(projectionStudy.getSamples().size()); + includeSamples = new ArrayList<>(projectionStudy.getSamples().size()); for (Integer sample : projectionStudy.getSamples()) { - samples.add(metadataManager.getSampleName(studyId, sample)); + includeSamples.add(metadataManager.getSampleName(studyId, sample)); } Set allFileIds = metadataManager.getFileIdsFromSampleIds(studyId, projectionStudy.getSamples(), true); allFiles = new ArrayList<>(allFileIds.size()); @@ -416,13 +483,15 @@ private class AddMissingDataTask implements Task { allFiles.add(metadataManager.getFileName(studyId, fileId)); } - String sampleName = sampleIndexQuery.getSamplesMap().keySet().iterator().next(); + sampleName = sampleIndexQuery.getSamplesMap().keySet().iterator().next(); Integer sampleId = metadataManager.getSampleId(studyId, sampleName); List fileIds = metadataManager.getFileIdsFromSampleId(studyId, sampleId, true); - files = new ArrayList<>(fileIds.size()); + filesFromSample = new ArrayList<>(fileIds.size()); for (Integer fileId : fileIds) { - files.add(metadataManager.getFileName(studyId, fileId)); + filesFromSample.add(metadataManager.getFileName(studyId, fileId)); } + List includeSampleData = VariantQueryUtils.getIncludeSampleData(parsedQuery.getInputQuery()); + gtIdx = includeSampleData.indexOf("GT"); } @Override @@ -468,7 +537,7 @@ public List apply(List variants) { // Should end in few seconds future.get(90, TimeUnit.SECONDS); } catch (InterruptedException | ExecutionException | TimeoutException e) { - throw new VariantQueryException("Error fetching original call for INDELs"); + throw new VariantQueryException("Error fetching extra data", e); } } logger.info("Fetch {} partial variants in {} in {} threads", @@ -478,6 +547,10 @@ public List apply(List variants) { return variants; } + /** + * Fetch the Secondary alternates, sample GTs and original call of these variants. + * @param toReadFull variants to complete + */ private void addSecondaryAlternates(List toReadFull) { // StopWatch stopWatch = StopWatch.createStarted(); Set includeFields = new HashSet<>(VariantField.getIncludeFields(parsedQuery.getInputOptions())); @@ -491,27 +564,38 @@ private void addSecondaryAlternates(List toReadFull) { options.put(VariantHadoopDBAdaptor.QUIET, true); options.put(VariantHadoopDBAdaptor.NATIVE, true); - Map fullVariants = dbAdaptor.get(new VariantQuery() + Map variantsExtra = dbAdaptor.get(new VariantQuery() .id(toReadFull) .study(studyName) - .includeSample(samples) - .includeSampleData(VariantQueryUtils.getIncludeSampleData(parsedQuery.getInputQuery())) + .includeSample(includeSamples) + .includeSampleData("GT") // read only GT .includeFile(allFiles), options) .getResults().stream().collect(Collectors.toMap(Variant::toString, v -> v)); for (Variant variant : toReadFull) { - Variant fullVariant = fullVariants.get(variant.toString()); - if (fullVariant == null) { + Variant variantExtra = variantsExtra.get(variant.toString()); + if (variantExtra == null) { // TODO: Should we fail here? // throw new VariantQueryException("Variant " + variant + " not found!"); logger.warn("Variant " + variant + " not found!"); continue; } - StudyEntry fullStudy = fullVariant.getStudies().get(0); - fullStudy.getFiles().forEach(f -> f.setData(Collections.emptyMap())); - fullStudy.setStats(Collections.emptyList()); - variant.setStudies(Collections.singletonList(fullStudy)); + StudyEntry studyExtra = variantExtra.getStudies().get(0); + StudyEntry study = variant.getStudies().get(0); + + study.setSecondaryAlternates(studyExtra.getSecondaryAlternates()); + + mergeFileEntries(study, studyExtra.getFiles(), (fe, newFe) -> { + fe.setCall(newFe.getCall()); + }); + // merge sampleEntries + for (int i = 0; i < includeSamples.size(); i++) { + SampleEntry sample = study.getSample(i); + SampleEntry sampleExtra = studyExtra.getSample(i); + + sample.getData().set(gtIdx, sampleExtra.getData().get(0)); + } } // logger.info(" # Fetch {} SEC_ALTS in {}", toReadFull.size(), TimeUtils.durationToString(stopWatch)); } @@ -522,7 +606,7 @@ private void addOriginalCall(List variants, String study) { for (Variant variant : dbAdaptor.iterable( new Query() .append(VariantQueryParam.ID.key(), variants) - .append(VariantQueryParam.INCLUDE_FILE.key(), files) + .append(VariantQueryParam.INCLUDE_FILE.key(), filesFromSample) .append(VariantQueryParam.INCLUDE_SAMPLE.key(), NONE) .append(VariantQueryParam.INCLUDE_STUDY.key(), study), new QueryOptions() @@ -544,12 +628,33 @@ private void addOriginalCall(List variants, String study) { logger.warn("Variant " + variant + " not found!"); continue; } - variant.getStudies().get(0).setFiles(fileEntries); + StudyEntry studyEntry = variant.getStudies().get(0); + mergeFileEntries(studyEntry, fileEntries, (fe, newFe) -> { + fe.setCall(newFe.getCall()); + }); } // logger.info(" # Fetch {} INDEL original call in {}", filesMap.size(), TimeUtils.durationToString(stopWatch)); } - + private void mergeFileEntries(StudyEntry studyEntry, List newFileEntries, + BiConsumer merge) { + if (studyEntry.getFiles() == null) { + studyEntry.setFiles(new ArrayList<>(newFileEntries.size())); + } + for (FileEntry newFileEntry : newFileEntries) { + FileEntry fileEntry = studyEntry.getFile(newFileEntry.getFileId()); + if (fileEntry == null) { + fileEntry = new FileEntry(newFileEntry.getFileId(), null, new HashMap<>()); + studyEntry.getFiles().add(fileEntry); + if (filesFromSample.contains(fileEntry.getFileId())) { + SampleEntry sampleEntry = studyEntry.getSample(sampleName); + if (sampleEntry.getFileIndex() == null) { + sampleEntry.setFileIndex(studyEntry.getFiles().size() - 1); + } + } + } + merge.accept(fileEntry, newFileEntry); + } + } } - } diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalIndexField.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalIndexField.java index 1ebc25bbe97..59e373257d7 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalIndexField.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalIndexField.java @@ -8,10 +8,7 @@ import org.opencb.opencga.storage.hadoop.variant.index.core.filters.MultiValueIndexFieldFilter; import org.opencb.opencga.storage.hadoop.variant.index.core.filters.SingleValueIndexFieldFilter; -import java.util.Collections; -import java.util.HashMap; -import java.util.List; -import java.util.Map; +import java.util.*; import java.util.stream.Collectors; /** @@ -22,7 +19,7 @@ * Value "0" represents NA. */ public class CategoricalIndexField extends IndexField implements IndexCodec { - private final int numBits; + private final int bitLength; private final IndexCodec codec; public static CategoricalIndexField create(IndexFieldConfiguration configuration, int bitOffset) { @@ -43,18 +40,18 @@ public CategoricalIndexField(IndexFieldConfiguration configuration, int bitOffse numValues = values.length; codec = new BasicCodec<>(values, valuesMapping); } - this.numBits = Math.max(1, IndexUtils.log2(numValues - 1) + 1); + this.bitLength = Math.max(1, IndexUtils.log2(numValues - 1) + 1); } public CategoricalIndexField(IndexFieldConfiguration configuration, int bitOffset, int numValues, IndexCodec codec) { super(configuration, bitOffset); - this.numBits = IndexUtils.log2(numValues - 1) + 1; + this.bitLength = IndexUtils.log2(numValues - 1) + 1; this.codec = codec; } @Override public int getBitLength() { - return numBits; + return bitLength; } @Override @@ -124,6 +121,16 @@ public T decode(int code) { public boolean ambiguous(int code) { return ambiguousValues[code]; } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("BasicCodec{"); + sb.append("values=").append(Arrays.toString(values)); + sb.append(", valuesMappingRev=").append(valuesMappingRev); + sb.append(", ambiguousValues=").append(Arrays.toString(ambiguousValues)); + sb.append('}'); + return sb.toString(); + } } private static class BasicCodecWithNa implements IndexCodec { @@ -178,6 +185,20 @@ public T decode(int code) { public boolean ambiguous(int code) { return ambiguousValues[code]; } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("BasicCodecWithNa{"); + sb.append("values=").append(Arrays.toString(values)); + sb.append(", valuesMappingRev=").append(valuesMappingRev); + sb.append(", ambiguousValues=").append(Arrays.toString(ambiguousValues)); + sb.append('}'); + return sb.toString(); + } + } + + protected IndexCodec getCodec() { + return codec; } @Override @@ -195,4 +216,14 @@ public boolean ambiguous(int code) { return codec.ambiguous(code); } + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("CategoricalIndexField{"); + sb.append("configuration=").append(getConfiguration()); + sb.append(", bitOffset=").append(getBitOffset()); + sb.append(", bitLength=").append(bitLength); + sb.append(", codec=").append(codec); + sb.append('}'); + return sb.toString(); + } } diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalMultiValuedIndexField.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalMultiValuedIndexField.java index 3f172f9db72..e7bafeb4b11 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalMultiValuedIndexField.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalMultiValuedIndexField.java @@ -20,7 +20,7 @@ */ public class CategoricalMultiValuedIndexField extends CategoricalIndexField> { - private final int numBits; + private final int bitLength; public static CategoricalMultiValuedIndexField createMultiValued(IndexFieldConfiguration configuration, int bitOffset) { return new CategoricalMultiValuedIndexField<>( @@ -41,7 +41,7 @@ public CategoricalMultiValuedIndexField(IndexFieldConfiguration configuration, i private CategoricalMultiValuedIndexField(IndexFieldConfiguration configuration, int bitOffset, T[] values, MaskValueCodec codec) { super(configuration, bitOffset, values.length, codec); - numBits = codec.numBits; + bitLength = codec.numBits; } @Override @@ -59,7 +59,7 @@ protected IndexFieldFilter getSingleValueIndexFilter(OpValue> opValue) { @Override public int getBitLength() { - return numBits; + return bitLength; } /** @@ -145,6 +145,28 @@ public List decode(int code) { public boolean ambiguous(int code) { return code == NA || (code & ambiguousValues) != 0; } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("MaskValueCodec{"); + sb.append("values=").append(Arrays.toString(values)); + sb.append(", otherValuePosition=").append(otherValuePosition); + sb.append(", valuesPosition=").append(valuesPosition); + sb.append(", numBits=").append(numBits); + sb.append(", ambiguousValues=").append(ambiguousValues); + sb.append('}'); + return sb.toString(); + } } + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("CategoricalMultiValuedIndexField{"); + sb.append("configuration=").append(getConfiguration()); + sb.append(", codec=").append(getCodec()); + sb.append(", bitOffset=").append(getBitOffset()); + sb.append(", bitLength=").append(bitLength); + sb.append('}'); + return sb.toString(); + } } diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/FixedSizeIndexSchema.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/FixedSizeIndexSchema.java index 727d21c6ae6..1b2592caec9 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/FixedSizeIndexSchema.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/FixedSizeIndexSchema.java @@ -38,4 +38,12 @@ public BitBuffer read(BitBuffer buffer, int i) { return buffer.getBitBuffer(i * indexSizeBits, indexSizeBits); } + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("FixedSizeIndexSchema{"); + sb.append("indexSizeBits=").append(indexSizeBits); + sb.append(", fields=").append(fields); + sb.append('}'); + return sb.toString(); + } } diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/IndexField.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/IndexField.java index aa12c98653f..ae0715ff52e 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/IndexField.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/IndexField.java @@ -170,4 +170,12 @@ public R decode(int code) { }; } + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("IndexField{"); + sb.append("configuration=").append(configuration); + sb.append(", bitOffset=").append(bitOffset); + sb.append('}'); + return sb.toString(); + } } diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/RangeIndexField.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/RangeIndexField.java index 5cf4d9e75c0..5e37863cee7 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/RangeIndexField.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/RangeIndexField.java @@ -7,6 +7,7 @@ import org.opencb.opencga.storage.hadoop.variant.index.core.filters.IndexFieldFilter; import org.opencb.opencga.storage.hadoop.variant.index.core.filters.RangeIndexFieldFilter; +import java.util.Arrays; import java.util.List; /** @@ -18,7 +19,7 @@ public class RangeIndexField extends IndexField { private final double[] thresholds; private final double min; private final double max; - private final int numBits; + private final int bitLength; private final IndexCodec codec; private int numRanges; @@ -40,7 +41,7 @@ public RangeIndexField(IndexFieldConfiguration configuration, int bitOffset, dou } else { codec = new NonNullableRangeCodec(); } - numBits = Math.max(1, IndexUtils.log2(numRanges - 1) + 1); + bitLength = Math.max(1, IndexUtils.log2(numRanges - 1) + 1); if (configuration.getType().equals(IndexFieldConfiguration.Type.RANGE_GT)) { // Add one DELTA to each value to invert ranges from [s, e) to (s, e], therefore the operation ">" is exact for (int i = 0; i < thresholds.length; i++) { @@ -77,7 +78,7 @@ public double getMax() { @Override public int getBitLength() { - return numBits; + return bitLength; } @Override @@ -120,13 +121,20 @@ public int encode(Double value) { @Override public Double decode(int code) { - return code == thresholds.length ? max : code < 0 ? min : thresholds[code]; + return code <= 0 ? min : thresholds[code - 1]; } @Override public boolean ambiguous(int code) { return true; } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("NonNullableRangeCodec{"); + sb.append('}'); + return sb.toString(); + } } public class NullableRangeCodec extends NonNullableRangeCodec { @@ -142,6 +150,13 @@ public int encode(Double value) { public Double decode(int code) { return code == NA ? null : super.decode(code - 1); } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("NullableRangeCodec{"); + sb.append('}'); + return sb.toString(); + } } /** @@ -174,4 +189,19 @@ public static boolean lessThan(double a, double b) { public static boolean equalsTo(double a, double b) { return Math.abs(a - b) < (DELTA / 10); } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("RangeIndexField{"); + sb.append("configuration=").append(getConfiguration()); + sb.append(", bitOffset=").append(getBitOffset()); + sb.append(", bitLength=").append(bitLength); + sb.append(", thresholds=").append(Arrays.toString(thresholds)); + sb.append(", min=").append(min); + sb.append(", max=").append(max); + sb.append(", codec=").append(codec); + sb.append(", numRanges=").append(numRanges); + sb.append('}'); + return sb.toString(); + } } diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/SingleFieldIndexSchema.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/SingleFieldIndexSchema.java index 58da9585b8f..2f2cf67409a 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/SingleFieldIndexSchema.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/core/SingleFieldIndexSchema.java @@ -21,4 +21,12 @@ public int readFieldValue(BitBuffer buffer, int i) { // return getField().read(read(buffer, i)); return buffer.getIntPartial(i * getBitsLength(), getBitsLength()); } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("SingleFieldIndexSchema{"); + sb.append("field=").append(field); + sb.append('}'); + return sb.toString(); + } } diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/family/MendelianErrorSampleIndexEntryIterator.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/family/MendelianErrorSampleIndexEntryIterator.java index 233129ef337..f089c82f20e 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/family/MendelianErrorSampleIndexEntryIterator.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/family/MendelianErrorSampleIndexEntryIterator.java @@ -125,9 +125,12 @@ public Variant next() { @Override public SampleVariantIndexEntry nextSampleVariantIndexEntry() { AnnotationIndexEntry annotationIndexEntry = nextAnnotationIndexEntry(); - BitBuffer fileIndex = null; + List filesIndex = new ArrayList<>(); if (hasFileIndex()) { - fileIndex = nextFileIndexEntry(); + filesIndex.add(nextFileIndexEntry()); + while (isMultiFileIndex()) { + filesIndex.add(nextMultiFileIndexEntry()); + } } String genotype = nextGenotype(); int meCode = nextMendelianErrorCode(); @@ -136,7 +139,7 @@ public SampleVariantIndexEntry nextSampleVariantIndexEntry() { parentsCode = nextParentsIndexEntry(); } Variant variant = next(); - return new SampleVariantIndexEntry(variant, fileIndex, genotype, annotationIndexEntry, parentsCode, meCode); + return new SampleVariantIndexEntry(variant, filesIndex, genotype, annotationIndexEntry, parentsCode, meCode); } @Override diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/AbstractSampleIndexEntryFilter.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/AbstractSampleIndexEntryFilter.java index 7cb87773f0c..1a0fd0935d9 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/AbstractSampleIndexEntryFilter.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/AbstractSampleIndexEntryFilter.java @@ -206,7 +206,12 @@ private Collection filter(SampleIndexEntry entry, boolean count) { entry.getSampleId(), entry.getChromosome(), entry.getBatchStart(), gtEntry.getGt()); - logger.warn(gtEntry.toStringSummary()); + try { + logger.warn(gtEntry.toStringSummary()); + logger.warn(converter.getSchema().toString()); + } catch (Exception exception) { + e.addSuppressed(exception); + } throw e; } if (!variants.isEmpty()) { diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/FileIndexSchema.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/FileIndexSchema.java index 4ea023e75e5..a383109139d 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/FileIndexSchema.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/FileIndexSchema.java @@ -213,7 +213,32 @@ private static IndexField buildCustomIndexField(IndexFieldConfiguration } else { return Arrays.asList(s.split(VCFConstants.FILTER_CODE_SEPARATOR)); } - }, v -> v == null ? null : String.join(VCFConstants.FILTER_CODE_SEPARATOR, v)); + }, values -> { + if (values == null || values.isEmpty()) { + return null; + } + if (values.size() == 1) { + String value = values.get(0); + if (value == null) { + return null; + } else { + return value; + } + } else { + StringBuilder sb = new StringBuilder(); + for (String v : values) { + if (sb.length() != 0) { + sb.append(VCFConstants.FILTER_CODE_SEPARATOR); + } + if (v == null) { + sb.append("NA"); + } else { + sb.append(v); + } + } + return sb.toString(); + } + }); } else { return new CategoricalMultiValuedIndexField<>(conf, bitOffset, conf.getValues()) .from(s -> { diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexDBLoader.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexDBLoader.java index 428e835025c..f2700831e94 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexDBLoader.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexDBLoader.java @@ -143,7 +143,8 @@ public void addVariant(int sampleIdx, String gt, SampleVariantIndexEntry variant throw new IllegalArgumentException("Already loaded variant " + variantIndexEntry.getVariant()); } } - if (schema.getFileIndex().isMultiFile(variantIndexEntry.getFileIndex())) { + if (variantIndexEntry.getFilesIndex().size() > 1 + || schema.getFileIndex().isMultiFile(variantIndexEntry.getFilesIndex().get(0))) { throw new IllegalArgumentException("Unexpected multi-file at variant " + variantIndexEntry.getVariant()); } sampleEntry.add(gt, variantIndexEntry); diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexEntryIterator.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexEntryIterator.java index 61627ddfd7b..da9c4a3a517 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexEntryIterator.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexEntryIterator.java @@ -4,7 +4,9 @@ import org.opencb.opencga.storage.core.io.bit.BitBuffer; import org.opencb.opencga.storage.hadoop.variant.index.annotation.AnnotationIndexEntry; +import java.util.ArrayList; import java.util.Iterator; +import java.util.List; /** * Iterate through the variants of a SampleIndexEntry. @@ -36,9 +38,12 @@ default SampleVariantIndexEntry nextSampleVariantIndexEntry() { // This object could be reused annotationIndexEntry = new AnnotationIndexEntry(annotationIndexEntry); } - BitBuffer fileIndex = null; + List filesIndex = new ArrayList<>(); if (hasFileIndex()) { - fileIndex = nextFileIndexEntry(); + filesIndex.add(nextFileIndexEntry()); + while (isMultiFileIndex()) { + filesIndex.add(nextMultiFileIndexEntry()); + } } Byte parentsCode = null; if (hasParentsIndex()) { @@ -46,7 +51,7 @@ default SampleVariantIndexEntry nextSampleVariantIndexEntry() { } String genotype = nextGenotype(); Variant variant = next(); - return new SampleVariantIndexEntry(variant, fileIndex, genotype, annotationIndexEntry, parentsCode); + return new SampleVariantIndexEntry(variant, filesIndex, genotype, annotationIndexEntry, parentsCode, null); } /** diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexSchema.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexSchema.java index 2a82e5d1750..d050421a160 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexSchema.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexSchema.java @@ -198,6 +198,22 @@ public FileIndexSchema getFileIndex() { return fileIndex; } + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("SampleIndexSchema{"); + sb.append("version=").append(version); + sb.append(", configuration=").append(configuration); + sb.append(", fileIndex=").append(fileIndex); + sb.append(", popFreqIndex=").append(popFreqIndex); + sb.append(", ctIndex=").append(ctIndex); + sb.append(", biotypeIndex=").append(biotypeIndex); + sb.append(", transcriptFlagIndexSchema=").append(transcriptFlagIndexSchema); + sb.append(", ctBtTfIndex=").append(ctBtTfIndex); + sb.append(", clinicalIndexSchema=").append(clinicalIndexSchema); + sb.append('}'); + return sb.toString(); + } + public static int getChunkStart(Integer start) { return (start / BATCH_SIZE) * BATCH_SIZE; } diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexVariantBiConverter.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexVariantBiConverter.java index 4c0fb21701f..d8961251205 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexVariantBiConverter.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexVariantBiConverter.java @@ -196,6 +196,10 @@ public MendelianErrorSampleIndexEntryIterator toMendelianIterator(SampleIndexEnt return new MendelianErrorSampleIndexEntryIterator(sampleIndexEntry, schema); } + public SampleIndexSchema getSchema() { + return schema; + } + private abstract static class SampleIndexGtEntryIterator implements SampleIndexEntryIterator { protected SampleIndexEntry.SampleIndexGtEntry gtEntry; private final SampleIndexSchema schema; diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleVariantIndexEntry.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleVariantIndexEntry.java index 359591ed3d1..3d919ce846f 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleVariantIndexEntry.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleVariantIndexEntry.java @@ -6,7 +6,9 @@ import org.opencb.opencga.storage.core.io.bit.BitBuffer; import org.opencb.opencga.storage.hadoop.variant.index.annotation.AnnotationIndexEntry; +import java.util.Collections; import java.util.Comparator; +import java.util.List; import java.util.Objects; import static org.opencb.opencga.storage.hadoop.variant.index.sample.SampleIndexSchema.INTRA_CHROMOSOME_VARIANT_COMPARATOR; @@ -15,21 +17,18 @@ public class SampleVariantIndexEntry { private final Variant variant; private final String genotype; + @Deprecated private final BitBuffer fileIndex; + private final List filesIndex; private final AnnotationIndexEntry annotationIndexEntry; private final Integer meCode; private final Byte parentsCode; public SampleVariantIndexEntry(Variant variant, BitBuffer fileIndex) { - this(variant, fileIndex, null, null, null); + this(variant, Collections.singletonList(fileIndex), null, null, null, null); } - public SampleVariantIndexEntry(Variant variant, BitBuffer fileIndex, String genotype, AnnotationIndexEntry annotationIndexEntry, - Byte parentsCode) { - this(variant, fileIndex, genotype, annotationIndexEntry, parentsCode, null); - } - - public SampleVariantIndexEntry(Variant variant, BitBuffer fileIndex, String genotype, AnnotationIndexEntry annotationIndexEntry, + public SampleVariantIndexEntry(Variant variant, List filesIndex, String genotype, AnnotationIndexEntry annotationIndexEntry, Byte parentsCode, Integer meCode) { if (CollectionUtils.isEmpty(variant.getImpl().getStudies())) { this.variant = variant; @@ -48,7 +47,12 @@ public SampleVariantIndexEntry(Variant variant, BitBuffer fileIndex, String geno variant.getType(), null, null)); } - this.fileIndex = fileIndex; + this.filesIndex = filesIndex; + if (filesIndex == null) { + this.fileIndex = null; + } else { + this.fileIndex = filesIndex.get(0); + } this.genotype = genotype; this.annotationIndexEntry = annotationIndexEntry; this.meCode = meCode; @@ -59,10 +63,15 @@ public Variant getVariant() { return variant; } + @Deprecated public BitBuffer getFileIndex() { return fileIndex; } + public List getFilesIndex() { + return filesIndex; + } + public String getGenotype() { return genotype; } @@ -88,7 +97,7 @@ public boolean equals(Object o) { return false; } SampleVariantIndexEntry that = (SampleVariantIndexEntry) o; - return fileIndex.equals(that.fileIndex) && Objects.equals(variant, that.variant); + return filesIndex.equals(that.filesIndex) && Objects.equals(variant, that.variant); } @Override @@ -106,7 +115,7 @@ public String toString(SampleIndexSchema schema, String separator) { sb.append(separator).append("gt: ") .append(this.getGenotype()); sb.append(separator).append("file: ") - .append(this.getFileIndex()); + .append(this.getFilesIndex()); if (annotationIndexEntry != null) { annotationIndexEntry.toString(schema, separator, sb); } diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/VariantTypeIndexCodec.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/VariantTypeIndexCodec.java index dd4acb565b2..a385183398f 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/VariantTypeIndexCodec.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/main/java/org/opencb/opencga/storage/hadoop/variant/index/sample/VariantTypeIndexCodec.java @@ -74,4 +74,11 @@ public VariantType decode(int code) { public boolean ambiguous(int code) { return code == TYPE_OTHER_CODE || code == TYPE_CNV_CODE; } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("VariantTypeIndexCodec{"); + sb.append('}'); + return sb.toString(); + } } diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/test/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalIndexFieldTest.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/test/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalIndexFieldTest.java index a062617da1f..feae2ca31e6 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/test/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalIndexFieldTest.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/test/java/org/opencb/opencga/storage/hadoop/variant/index/core/CategoricalIndexFieldTest.java @@ -1,7 +1,9 @@ package org.opencb.opencga.storage.hadoop.variant.index.core; +import org.apache.commons.lang3.tuple.Pair; import org.junit.Test; import org.junit.experimental.categories.Category; +import org.opencb.biodata.models.variant.StudyEntry; import org.opencb.opencga.core.config.storage.IndexFieldConfiguration; import org.opencb.opencga.core.config.storage.SampleIndexConfiguration; import org.opencb.opencga.core.testclassification.duration.ShortTests; @@ -15,6 +17,7 @@ import java.util.Set; import static org.junit.Assert.assertEquals; +import static org.opencb.opencga.core.config.storage.IndexFieldConfiguration.Source.FILE; import static org.opencb.opencga.core.config.storage.IndexFieldConfiguration.Source.SAMPLE; @Category(ShortTests.class) @@ -39,10 +42,57 @@ public void testLength() { assertEquals(3, CategoricalIndexField.create(new IndexFieldConfiguration(SAMPLE, "K", IndexFieldConfiguration.Type.CATEGORICAL, "1", "2", "3", "4", "5", "6").setNullable(nullable), 0).getBitLength()); } + @Test + public void testEncodeDecodeQual() { + SampleIndexSchema indexSchema = SampleIndexSchema.defaultSampleIndexSchema(); + IndexField qualfield = indexSchema.getFileIndex().getCustomField(FILE, StudyEntry.QUAL); + + List> pairs = Arrays.asList( + Pair.of("45", "30.0"), + Pair.of("25", "20.0"), + Pair.of("30", "30.0"), + Pair.of("10", "10.0"), + Pair.of("0", Double.toString(Double.MIN_VALUE)) + ); + for (Pair pair : pairs) { + String qual = pair.getKey(); + String expectedQual = pair.getValue(); + int encode = qualfield.encode(qual); + String actualQual = qualfield.decode(encode); + assertEquals(expectedQual, actualQual); + } + } + + @Test + public void testEncodeDecodeFilter() { + SampleIndexConfiguration indexConfiguration = SampleIndexConfiguration.defaultConfiguration(); + indexConfiguration.getFileIndexConfiguration().getCustomField(FILE, StudyEntry.FILTER) + .setType(IndexFieldConfiguration.Type.CATEGORICAL_MULTI_VALUE) + .setValues("PASS", "noPass"); + SampleIndexSchema indexSchema = new SampleIndexSchema(indexConfiguration, 0); + IndexField field = indexSchema.getFileIndex().getCustomField(FILE, StudyEntry.FILTER); + + List> pairs = Arrays.asList( + Pair.of("PASS", "PASS"), + Pair.of("asdfasdf", null), + Pair.of("noPass", "noPass"), + Pair.of("PASS;noPass", "PASS;noPass"), + Pair.of("PASS;noPass;other;another", "PASS;noPass;NA"), + Pair.of(".", null) + ); + for (Pair pair : pairs) { + String filter = pair.getKey(); + String expectedFilter = pair.getValue(); + int encode = field.encode(filter); + String actualFilter = field.decode(encode); + assertEquals(expectedFilter, actualFilter); + } + } + @Test public void testEncodeDecode() { SampleIndexSchema indexSchema = SampleIndexSchema.defaultSampleIndexSchema(); - CategoricalMultiValuedIndexField field = (CategoricalMultiValuedIndexField) indexSchema.getCtIndex().getField(); + CategoricalMultiValuedIndexField field = indexSchema.getCtIndex().getField(); List expected = Arrays.asList("synonymous_variant", "missense_variant"); int encode = field.encode(expected); diff --git a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/test/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexTest.java b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/test/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexTest.java index 7693fc1a53e..0319c2bc43b 100644 --- a/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/test/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexTest.java +++ b/opencga-storage/opencga-storage-hadoop/opencga-storage-hadoop-core/src/test/java/org/opencb/opencga/storage/hadoop/variant/index/sample/SampleIndexTest.java @@ -14,8 +14,10 @@ import org.junit.experimental.categories.Category; import org.junit.rules.ExternalResource; import org.opencb.biodata.models.core.Region; +import org.opencb.biodata.models.variant.StudyEntry; import org.opencb.biodata.models.variant.Variant; import org.opencb.biodata.models.variant.avro.ConsequenceType; +import org.opencb.biodata.models.variant.avro.FileEntry; import org.opencb.biodata.models.variant.avro.VariantType; import org.opencb.biodata.models.variant.metadata.SampleVariantStats; import org.opencb.commons.datastore.core.*; @@ -59,6 +61,7 @@ import java.util.*; import java.util.concurrent.TimeUnit; import java.util.concurrent.atomic.AtomicInteger; +import java.util.function.Function; import java.util.stream.Collectors; import static java.util.stream.Collectors.*; @@ -84,13 +87,23 @@ public class SampleIndexTest extends VariantStorageBaseTest implements HadoopVar private static boolean loaded = false; public static final String STUDY_NAME_3 = "study_3"; public static final String STUDY_NAME_4 = "study_4"; - public static final String STUDY_NAME_5 = "study_5"; - private static final List studies = Arrays.asList(STUDY_NAME, STUDY_NAME_2, STUDY_NAME_3, STUDY_NAME_4, STUDY_NAME_5); + public static final String STUDY_NAME_5 = "study_5"; // large SV + public static final String STUDY_NAME_6 = "study_6"; // multiallelic + private static final List studies = Arrays.asList( + STUDY_NAME, + STUDY_NAME_2, + STUDY_NAME_3, + STUDY_NAME_4, + STUDY_NAME_5, + STUDY_NAME_6 + ); private static final Map> sampleNames = new HashMap>() {{ put(STUDY_NAME, Arrays.asList("NA19600", "NA19660", "NA19661", "NA19685")); put(STUDY_NAME_2, Arrays.asList("NA19600", "NA19660", "NA19661", "NA19685")); put(STUDY_NAME_3, Arrays.asList("NA12877", "NA12878")); put(STUDY_NAME_4, Arrays.asList("NA19600", "NA19660", "NA19661", "NA19685")); + put(STUDY_NAME_5, Arrays.asList("NA19600", "NA19660", "NA19661", "NA19685")); + put(STUDY_NAME_6, Arrays.asList("NA19600", "NA19660", "NA19661", "NA19685")); }}; // private static List> trios = Arrays.asList( // Arrays.asList("NA19600", "NA19660", "NA19661"), @@ -192,6 +205,19 @@ public void load() throws Exception { runETL(engine, getResourceUri("variant-large-sv.vcf"), outputUri, params, true, true, true); engine.familyIndex(STUDY_NAME_5, trios, new ObjectMap()); + // Study 6, multiallelic + SampleIndexConfiguration sampleIndexConfiguration = SampleIndexConfiguration.defaultConfiguration(); + sampleIndexConfiguration.getFileIndexConfiguration().getCustomField(IndexFieldConfiguration.Source.FILE, "FILTER") + .setValues("PASS", "noPass", "noPass2"); + engine.getMetadataManager().addSampleIndexConfiguration(STUDY_NAME_6, sampleIndexConfiguration, true); + + params = new ObjectMap() + .append(VariantStorageOptions.STUDY.key(), STUDY_NAME_6) + .append(VariantStorageOptions.ANNOTATE.key(), false) + .append(VariantStorageOptions.STATS_CALCULATE.key(), false); + runETL(engine, getResourceUri("variant-multiallelic.vcf"), outputUri, params, true, true, true); + engine.familyIndex(STUDY_NAME_6, trios, new ObjectMap()); + // ---------------- Annotate // variantStorageEngine.getConfiguration().getCellbase().setUrl(ParamConstants.CELLBASE_URL); @@ -1122,9 +1148,42 @@ public void testSampleIndexOnlyVariantQueryExecutor() { new QueryOptions(QueryOptions.INCLUDE, Arrays.asList(VariantField.ID, VariantField.STUDIES_SAMPLES)), SampleIndexOnlyVariantQueryExecutor.class); + testSampleIndexOnlyVariantQueryExecutor( + new VariantQuery() + .study(STUDY_NAME_6) + .sample("NA19600") + .includeGenotype(true), + new QueryOptions(QueryOptions.INCLUDE, Arrays.asList(VariantField.ID, VariantField.STUDIES_SAMPLES)), + SampleIndexOnlyVariantQueryExecutor.class); + + testSampleIndexOnlyVariantQueryExecutor( + new VariantQuery() + .study(STUDY_NAME_6) + .sample("NA19600") + .includeGenotype(true) + .append("includeAllFromSampleIndex", true), + new QueryOptions(QueryOptions.INCLUDE, Arrays.asList(VariantField.ID, VariantField.STUDIES_SAMPLES)), + SampleIndexOnlyVariantQueryExecutor.class, + v -> { + assertEquals(v.toString(), 1, v.getStudies().get(0).getFiles().size()); + for (FileEntry fe : v.getStudies().get(0).getFiles()) { + assertNotNull(fe.getData().get(StudyEntry.FILTER)); + fe.setData(Collections.emptyMap()); + } + v.getStudies().get(0).getFiles().removeIf(fe -> fe.getCall() == null); + if (v.getStudies().get(0).getFiles().isEmpty()) { + v.getStudies().get(0).getSamples().forEach(s -> s.setFileIndex(null)); + } + return v; + }); } private void testSampleIndexOnlyVariantQueryExecutor(VariantQuery query, QueryOptions options, Class expected) { + testSampleIndexOnlyVariantQueryExecutor(query, options, expected, v -> v); + } + + private void testSampleIndexOnlyVariantQueryExecutor(VariantQuery query, QueryOptions options, Class expected, + Function mapper) { VariantQueryExecutor variantQueryExecutor = variantStorageEngine.getVariantQueryExecutor( query, options); @@ -1158,6 +1217,7 @@ private void testSampleIndexOnlyVariantQueryExecutor(VariantQuery query, QueryOp for (int i = 0; i < actualVariants.size(); i++) { Variant av = actualVariants.get(i); Variant ev = expectedVariants.get(i); + mapper.apply(av); if (!ev.getStudies().isEmpty()) { if (av.getLengthAlternate() == 0 || av.getLengthReference() == 0) { // System.out.println("-------" + av + "----------");