Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
openbis
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
sispub
openbis
Commits
c83f339a
Commit
c83f339a
authored
14 years ago
by
felmer
Browse files
Options
Downloads
Patches
Plain Diff
logging improved
SVN: 20561
parent
5d3d455e
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
rtd_yeastx/source/java/ch/systemsx/cisd/yeastx/etl/DatasetMappingResolver.java
+6
-6
6 additions, 6 deletions
...a/ch/systemsx/cisd/yeastx/etl/DatasetMappingResolver.java
with
6 additions
and
6 deletions
rtd_yeastx/source/java/ch/systemsx/cisd/yeastx/etl/DatasetMappingResolver.java
+
6
−
6
View file @
c83f339a
...
@@ -122,7 +122,7 @@ class DatasetMappingResolver
...
@@ -122,7 +122,7 @@ class DatasetMappingResolver
// The main purpose of this checks is to ensure that sample with the given code exists.
// The main purpose of this checks is to ensure that sample with the given code exists.
// If it is not a case, we will try to check if the specified sample label is unique (in
// If it is not a case, we will try to check if the specified sample label is unique (in
// all experiments).
// all experiments).
if
(
isConnected
ToExperiment
(
sampleCodeOrLabel
,
mapping
,
log
))
if
(
sampleExistsAndBelongs
ToExperiment
(
mapping
,
sampleCodeOrLabel
,
log
))
{
{
return
sampleCodeOrLabel
;
return
sampleCodeOrLabel
;
}
}
...
@@ -139,7 +139,7 @@ class DatasetMappingResolver
...
@@ -139,7 +139,7 @@ class DatasetMappingResolver
}
else
if
(
samples
.
size
()
==
0
)
}
else
if
(
samples
.
size
()
==
0
)
{
{
// try to assume that the sample code, not name, has been provided
// try to assume that the sample code, not name, has been provided
if
(
isConnected
ToExperiment
(
sampleCodeOrLabel
,
mapping
,
log
))
if
(
sampleExistsAndBelongs
ToExperiment
(
mapping
,
sampleCodeOrLabel
,
log
))
{
{
return
sampleCodeOrLabel
;
return
sampleCodeOrLabel
;
}
else
}
else
...
@@ -255,7 +255,7 @@ class DatasetMappingResolver
...
@@ -255,7 +255,7 @@ class DatasetMappingResolver
"when dataset is connected to a sample it cannot have parent datasets."
);
"when dataset is connected to a sample it cannot have parent datasets."
);
return
false
;
return
false
;
}
}
return
sampleExistsAndBelongsToExperiment
(
mapping
,
log
,
sampleCode
);
return
sampleExistsAndBelongsToExperiment
(
mapping
,
sampleCode
,
log
);
}
}
}
}
...
@@ -337,9 +337,9 @@ class DatasetMappingResolver
...
@@ -337,9 +337,9 @@ class DatasetMappingResolver
}
}
private
boolean
sampleExistsAndBelongsToExperiment
(
DataSetMappingInformation
mapping
,
private
boolean
sampleExistsAndBelongsToExperiment
(
DataSetMappingInformation
mapping
,
LogUtils
log
,
String
sampleCode
)
String
sampleCode
,
LogUtils
log
)
{
{
if
(
isConnectedToExperiment
(
sampleCode
,
mapping
,
log
)
==
false
)
if
(
isConnectedToExperiment
(
mapping
,
sampleCode
,
log
)
==
false
)
{
{
log
.
datasetMappingError
(
mapping
,
"sample with the code '%s' does not exist"
log
.
datasetMappingError
(
mapping
,
"sample with the code '%s' does not exist"
+
" or is not connected to any experiment"
,
sampleCode
);
+
" or is not connected to any experiment"
,
sampleCode
);
...
@@ -348,7 +348,7 @@ class DatasetMappingResolver
...
@@ -348,7 +348,7 @@ class DatasetMappingResolver
return
true
;
return
true
;
}
}
private
boolean
isConnectedToExperiment
(
String
sampleCode
,
DataSetMappingInformation
mapping
,
private
boolean
isConnectedToExperiment
(
DataSetMappingInformation
mapping
,
String
sampleCode
,
LogUtils
log
)
LogUtils
log
)
{
{
SampleIdentifier
sampleIdentifier
=
createSampleIdentifier
(
sampleCode
,
mapping
);
SampleIdentifier
sampleIdentifier
=
createSampleIdentifier
(
sampleCode
,
mapping
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment