git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'develop' into releases/Release_2_11_2_Branch
[jalview.git]
/
src
/
jalview
/
urls
/
IdentifiersUrlProvider.java
diff --git
a/src/jalview/urls/IdentifiersUrlProvider.java
b/src/jalview/urls/IdentifiersUrlProvider.java
index
07eb23e
..
850a230
100644
(file)
--- a/
src/jalview/urls/IdentifiersUrlProvider.java
+++ b/
src/jalview/urls/IdentifiersUrlProvider.java
@@
-75,7
+75,7
@@
public class IdentifiersUrlProvider extends UrlProviderImpl
* @return hashmap of identifiers.org data, keyed by MIRIAM id
*/
@SuppressWarnings("unchecked")
* @return hashmap of identifiers.org data, keyed by MIRIAM id
*/
@SuppressWarnings("unchecked")
-private HashMap<String, UrlLink> readIdentifiers(String idFileName)
+ private HashMap<String, UrlLink> readIdentifiers(String idFileName)
{
// identifiers.org data
HashMap<String, UrlLink> idData = new HashMap<>();
{
// identifiers.org data
HashMap<String, UrlLink> idData = new HashMap<>();
@@
-83,11
+83,12
@@
private HashMap<String, UrlLink> readIdentifiers(String idFileName)
String errorMessage = null;
try
{
String errorMessage = null;
try
{
- // NOTE: THIS WILL FAIL IN SWINGJS BECAUSE IT INVOLVES A FILE READER
-
+ // NOTE: THIS WILL FAIL IN SWINGJS BECAUSE IT INVOLVES A FILE READER
+
FileReader reader = new FileReader(idFileName);
String key = "";
FileReader reader = new FileReader(idFileName);
String key = "";
- Map<String, Object> obj = (Map<String, Object>) JSONUtils.parse(reader);
+ Map<String, Object> obj = (Map<String, Object>) JSONUtils
+ .parse(reader);
if (obj.containsKey(ID_ORG_KEY))
{
key = ID_ORG_KEY;
if (obj.containsKey(ID_ORG_KEY))
{
key = ID_ORG_KEY;
@@
-119,9
+120,11
@@
private HashMap<String, UrlLink> readIdentifiers(String idFileName)
} catch (IOException | ParseException e)
{
// unnecessary e.printStackTrace();
} catch (IOException | ParseException e)
{
// unnecessary e.printStackTrace();
- // Note how in JavaScript we can grab the first bytes from any file reader.
+ // Note how in JavaScript we can grab the first bytes from any file
+ // reader.
// Typical report here is "NetworkError" because the file does not exist.
// Typical report here is "NetworkError" because the file does not exist.
- // "https://." is coming from System.getProperty("user.home"), but this could
+ // "https://." is coming from System.getProperty("user.home"), but this
+ // could
// be set by the page developer to anything, of course.
errorMessage = e.toString();
idData.clear();
// be set by the page developer to anything, of course.
errorMessage = e.toString();
idData.clear();
@@
-129,7
+132,8
@@
private HashMap<String, UrlLink> readIdentifiers(String idFileName)
// BH 2018 -- added more valuable report
if (errorMessage != null)
{
// BH 2018 -- added more valuable report
if (errorMessage != null)
{
- System.err.println("IdentifiersUrlProvider: cannot read " + idFileName + ": " + errorMessage);
+ System.err.println("IdentifiersUrlProvider: cannot read " + idFileName
+ + ": " + errorMessage);
}
return idData;
}
}
return idData;
}