Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
metexplore
met4j
Commits
c36a29f3
Commit
c36a29f3
authored
Apr 19, 2022
by
cfrainay
Browse files
fix duplicated refs
parent
ab85151a
Changes
1
Hide whitespace changes
Inline
Side-by-side
met4j-toolbox/src/main/java/fr/inrae/toulouse/metexplore/met4j_toolbox/attributes/ExtractSbmlAnnot.java
View file @
c36a29f3
...
...
@@ -73,18 +73,21 @@ public class ExtractSbmlAnnot extends AbstractMet4jApplication {
int
i
=
0
;
for
(
BioEntity
e
:
entities
){
StringBuffer
sb
=
new
StringBuffer
(
e
.
getId
());
Set
<
BioRef
>
refSet
=
e
.
getRefs
(
db
);
if
(
refSet
!=
null
){
i
+=
1
;
if
(
uniq
)
refSet
=
new
HashSet
<
BioRef
>(
Arrays
.
asList
(
refSet
.
iterator
().
next
()));
if
(
uniq
)
refSet
=
new
HashSet
<
BioRef
>(
Arrays
.
asList
(
refSet
.
iterator
().
next
()));
for
(
BioRef
ref
:
refSet
){
StringBuffer
sb
=
new
StringBuffer
();
sb
.
append
(
e
.
getId
());
sb
.
append
(
sep
);
sb
.
append
(
ref
.
getId
());
sb
.
append
(
"\n"
);
fw
.
write
(
sb
.
toString
());
}
}
else
if
(!
skip
){
StringBuffer
sb
=
new
StringBuffer
();
sb
.
append
(
e
.
getId
());
sb
.
append
(
sep
);
sb
.
append
(
"NA\n"
);
fw
.
write
(
sb
.
toString
());
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment