Java Doc for URLStreamHandler.java in  » Apache-Harmony-Java-SE » java-package » java » net » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Apache Harmony Java SE » java package » java.net 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   java.net.URLStreamHandler

URLStreamHandler
abstract public class URLStreamHandler (Code)
The abstract superclass of all classes that implement Protocol Handler.




Method Summary
protected  booleanequals(URL url1, URL url2)
     Compares the two urls, and answers true if they represent the same URL.
protected  intgetDefaultPort()
     Return the default port.
protected  InetAddressgetHostAddress(URL url)
     Return the InetAddress for the host of the URL, or null.
protected  inthashCode(URL url)
     Answers a hash code for the URL object.
protected  booleanhostsEqual(URL url1, URL url2)
     Compares the two urls, and answers true if they have the same host components.
abstract protected  URLConnectionopenConnection(URL u)
     Establishes a connection to the resource specified by URL.
protected  URLConnectionopenConnection(URL u, Proxy proxy)
     The method is the same as openConnection(URL u) except that it uses the proxy to establish a connection to the URL.
protected  voidparseURL(URL u, String str, int start, int end)
     Parse the stringstr into URL using u's context.
protected  booleansameFile(URL url1, URL url2)
     Answers true if the urls refer to the same file.
protected  voidsetURL(URL u, String protocol, String host, int port, String file, String ref)
    
protected  voidsetURL(URL u, String protocol, String host, int port, String authority, String userInfo, String file, String query, String ref)
    
protected  StringtoExternalForm(URL url)
     Answers the string equivalent of an URL using HTTP parsinf format.



Method Detail
equals
protected boolean equals(URL url1, URL url2)(Code)
Compares the two urls, and answers true if they represent the same URL. Two URLs are equal if they have the same file, host, port, protocol, query, and ref components.
Parameters:
  url1 - URL the first URL to compare
Parameters:
  url2 - URL the second URL to compare true if the URLs are the same falseif the URLs are different
See Also:   URLStreamHandler.hashCode



getDefaultPort
protected int getDefaultPort()(Code)
Return the default port.



getHostAddress
protected InetAddress getHostAddress(URL url)(Code)
Return the InetAddress for the host of the URL, or null.



hashCode
protected int hashCode(URL url)(Code)
Answers a hash code for the URL object. int the hashcode for hashtable indexing



hostsEqual
protected boolean hostsEqual(URL url1, URL url2)(Code)
Compares the two urls, and answers true if they have the same host components. true if the hosts of the URLs are the samefalse if the hosts are different



openConnection
abstract protected URLConnection openConnection(URL u) throws IOException(Code)
Establishes a connection to the resource specified by URL. Since different protocols may have unique ways of connecting, it must be overwritten by the subclass. java.net.URLConnection
Parameters:
  u - java.net.URL
exception:
  IOException - thrown if an IO error occurs during connectionestablishment



openConnection
protected URLConnection openConnection(URL u, Proxy proxy) throws IOException(Code)
The method is the same as openConnection(URL u) except that it uses the proxy to establish a connection to the URL. Since different protocols may have different ways of connecting, it must be overwritten by the subclass. java.net.URLConnection
Parameters:
  u - java.net.URL
Parameters:
  proxy - the proxy which is used to make the connection
throws:
  IOException - thrown if an IO error occurs during connection establishment
throws:
  IllegalArgumentException - if any argument is null or the type of proxy is wrong.
throws:
  UnsupportedOperationException - if the protocol handler doesn't support this method.



parseURL
protected void parseURL(URL u, String str, int start, int end)(Code)
Parse the stringstr into URL using u's context. URL strings generally have the following format:
//www.company.com/java/file1.java#reference
The string is parsed in HTTP format. If the protocol has a different URL format this method must be overridden.
Parameters:
  u - java.net.URL The URL to receive parsed values.
Parameters:
  str - java.lang.String The string URL spec from which u is derived
Parameters:
  start - int The index in the string from which to begin parsing
Parameters:
  end - int The index to stop parsing
See Also:   URLStreamHandler.toExternalForm
See Also:   URL



sameFile
protected boolean sameFile(URL url1, URL url2)(Code)
Answers true if the urls refer to the same file. Compares the protocol, host, port and file components. boolean true if the same resource, false otherwise



setURL
protected void setURL(URL u, String protocol, String host, int port, String file, String ref)(Code)
Sets the fields of the URL with the supplied arguments
Parameters:
  u - java.net.URL The non-null URL to be set
Parameters:
  protocol - java.lang.String The protocol
Parameters:
  host - java.lang.String The host name
Parameters:
  port - int The port number
Parameters:
  file - java.lang.String The file component
Parameters:
  ref - java.lang.String The reference
See Also:   java.util.Set



setURL
protected void setURL(URL u, String protocol, String host, int port, String authority, String userInfo, String file, String query, String ref)(Code)
Sets the fields of the URL with the supplied arguments
Parameters:
  u - java.net.URL The non-null URL to be set
Parameters:
  protocol - java.lang.String The protocol
Parameters:
  host - java.lang.String The host name
Parameters:
  port - int The port number
Parameters:
  authority - java.lang.String The authority
Parameters:
  userInfo - java.lang.String The user info
Parameters:
  file - java.lang.String The file component
Parameters:
  query - java.lang.String The query
Parameters:
  ref - java.lang.String The reference
See Also:   java.util.Set



toExternalForm
protected String toExternalForm(URL url)(Code)
Answers the string equivalent of an URL using HTTP parsinf format. java.lang.String the string representation of this URL
Parameters:
  url - java.net.URL the url object to be processed
See Also:   URLStreamHandler.parseURL
See Also:   URL.toExternalForm



Methods inherited from java.lang.Object
protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object object)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final public Class<? extends Object> getClass()(Code)(Java Doc)
public int hashCode()(Code)(Java Doc)
final public void notify()(Code)(Java Doc)
final public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final public void wait(long millis, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait(long millis) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.