Mentions légales du service
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
Alignment API
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
moex
Alignment API
Commits
2d861692
Commit
2d861692
authored
11 years ago
by
Jérôme Euzenat
Browse files
Options
Downloads
Patches
Plain Diff
- improved prefix generation (added # in the end of needing URIs)
parent
c3e085d3
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
src/fr/inrialpes/exmo/align/impl/renderer/JSONRendererVisitor.java
+4
-3
4 additions, 3 deletions
...rialpes/exmo/align/impl/renderer/JSONRendererVisitor.java
with
4 additions
and
3 deletions
src/fr/inrialpes/exmo/align/impl/renderer/JSONRendererVisitor.java
+
4
−
3
View file @
2d861692
/*
/*
* $Id$
* $Id$
*
*
* Copyright (C) INRIA, 2012
* Copyright (C) INRIA, 2012
, 2014
*
*
* This program is free software; you can redistribute it and/or modify
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* it under the terms of the GNU Lesser General Public License as published by
...
@@ -80,8 +80,8 @@ import fr.inrialpes.exmo.align.impl.edoal.EDOALCell;
...
@@ -80,8 +80,8 @@ import fr.inrialpes.exmo.align.impl.edoal.EDOALCell;
import
fr.inrialpes.exmo.align.impl.edoal.EDOALVisitor
;
import
fr.inrialpes.exmo.align.impl.edoal.EDOALVisitor
;
/**
/**
* Renders an alignment in JSON (and
practically
in JSON-LD)
* Renders an alignment in JSON (and
in fact
in JSON-LD)
*
http://json-ld.org/spec/latest
/json-ld
-syntax
/
*
IETF RFC 7159 + http://www.w3.org/TR
/json-ld/
*
*
* application/json <========= media type available
* application/json <========= media type available
*
*
...
@@ -127,6 +127,7 @@ public class JSONRendererVisitor extends IndentedRendererVisitor implements Alig
...
@@ -127,6 +127,7 @@ public class JSONRendererVisitor extends IndentedRendererVisitor implements Alig
for
(
String
[]
ext
:
align
.
getExtensions
()
)
{
for
(
String
[]
ext
:
align
.
getExtensions
()
)
{
String
prefix
=
ext
[
0
];
String
prefix
=
ext
[
0
];
String
name
=
ext
[
1
];
String
name
=
ext
[
1
];
if
(
!
(
prefix
.
endsWith
(
"#"
)
||
prefix
.
endsWith
(
"/"
)
)
)
prefix
+=
"#"
;
String
tag
=
nslist
.
get
(
prefix
);
String
tag
=
nslist
.
get
(
prefix
);
if
(
tag
==
null
)
{
if
(
tag
==
null
)
{
tag
=
"ns"
+
gen
++;
tag
=
"ns"
+
gen
++;
...
...
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