Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Devrim Gunyel
core
Commits
1015d8b7
Commit
1015d8b7
authored
Sep 06, 2018
by
Piotr Gawron
Browse files
support for vmh miriam types
parent
3783c589
Changes
2
Hide whitespace changes
Inline
Side-by-side
CHANGELOG
View file @
1015d8b7
minerva
(
12.1.0
~
beta
.0
)
experimental
;
urgency
=
medium
*
Small
improvement
:
miriam
support
for
VMH
reaction
and
VMH
metabolite
--
Piotr
Gawron
<
piotr
.
gawron
@
uni
.
lu
>
Wed
,
05
Sep
2018
17
:
00
:
00
+
0200
minerva
(
12.1.0
~
beta
.0
)
experimental
;
urgency
=
medium
*
Small
improvement
:
option
to
remove
additional
overlays
generated
by
custom
semantic
zoom
...
...
model/src/main/java/lcsb/mapviewer/model/map/MiriamType.java
View file @
1015d8b7
...
...
@@ -464,6 +464,22 @@ public enum MiriamType {
new
String
[]
{},
//
new
Class
<?>[]
{},
null
),
/**
* VMH reaction
*/
VMH_REACTION
(
"VMH reaction"
,
//
"http://vmh.uni.lu/"
,
//
new
String
[]
{
"urn:miriam:vmhreaction"
,
"http://identifiers.org/vmhreaction/"
},
//
new
Class
<?>[]
{
Reaction
.
class
},
null
),
/**
* VMH reaction
*/
VMH_METABOLITE
(
"VMH reaction"
,
//
"http://vmh.uni.lu/"
,
//
new
String
[]
{
"urn:miriam:vmhmetabolite"
,
"http://identifiers.org/vmhmetabolite/"
},
//
new
Class
<?>[]
{
Chemical
.
class
},
null
),
/**
* Wikidata: https://www.wikidata.org/.
*/
...
...
@@ -710,7 +726,7 @@ public enum MiriamType {
* @return {@link MiriamData} from miriam uri
*/
public
static
MiriamData
getMiriamByUri
(
String
miriamUri
)
{
// this hack is due to CellDesigner issue (CellDesigner incorectly handle
// this hack is due to CellDesigner issue (CellDesigner incor
r
ectly handle
// with identifiers that have ":" inside resource ":" inside resource with
// "%3A" and also the last ":"
miriamUri
=
miriamUri
.
replace
(
"%3A"
,
":"
);
...
...
@@ -725,6 +741,11 @@ public enum MiriamType {
foundType
=
type
;
foundUri
=
uri
;
}
}
else
if
(
miriamUri
.
startsWith
(
uri
)
&&
uri
.
endsWith
(
"/"
))
{
if
(
uri
.
length
()
>
foundUri
.
length
())
{
foundType
=
type
;
foundUri
=
uri
;
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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