Revision: 14450
          http://gate.svn.sourceforge.net/gate/?rev=14450&view=rev
Author:   valyt
Date:     2011-10-28 10:43:11 +0000 (Fri, 28 Oct 2011)
Log Message:
-----------
removed unneccessary casting.

Modified Paths:
--------------
    
gate/trunk/plugins/Ontology/src/gate/creole/ontology/impl/AbstractOntologyImpl.java

Modified: 
gate/trunk/plugins/Ontology/src/gate/creole/ontology/impl/AbstractOntologyImpl.java
===================================================================
--- 
gate/trunk/plugins/Ontology/src/gate/creole/ontology/impl/AbstractOntologyImpl.java
 2011-10-28 10:35:30 UTC (rev 14449)
+++ 
gate/trunk/plugins/Ontology/src/gate/creole/ontology/impl/AbstractOntologyImpl.java
 2011-10-28 10:43:11 UTC (rev 14450)
@@ -1890,13 +1890,10 @@
           }
           InputStream is;
           try {
-            if(location.getProtocol().equals("http")) {
-              HttpURLConnection conn = 
(HttpURLConnection)location.openConnection();
-              conn.addRequestProperty("accept", 
"application/rdf+xml,application/xml;q=0.5,*/*;q=0.1");
-              is = conn.getInputStream();
-            } else {
-              is = location.openStream();  
-            }
+            URLConnection conn = location.openConnection();
+            conn.addRequestProperty("accept", 
+                "application/rdf+xml,application/xml;q=0.5,*/*;q=0.1");
+            is = conn.getInputStream();
           } catch (IOException ex) {
             throw new GateOntologyException(
                 "Problem opening the URL " + location +

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
The demand for IT networking professionals continues to grow, and the
demand for specialized networking skills is growing even more rapidly.
Take a complimentary Learning@Cisco Self-Assessment and learn 
about Cisco certifications, training, and career opportunities. 
http://p.sf.net/sfu/cisco-dev2dev
_______________________________________________
GATE-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gate-cvs

Reply via email to