Groovy Documentation

org.linkedin.groovy.util.net
[Groovy] Class GroovyNetUtils

java.lang.Object
  org.linkedin.groovy.util.net.GroovyNetUtils

class GroovyNetUtils

Contains utilities for net

Authors:
ypujante@linkedin.com


Method Summary
static java.lang.String guessFilename(java.net.URI uri)

Method which tries to infer the filename from the uri.

static java.net.URI toURI(java.lang.Object s)

Converts the provided parameter into a URI... handle: File, strings, URI, URL, null

static java.net.URL toURL(java.lang.Object s)

Encapsulates the creation of a URL by first trying the normal way and if it fails, it falls back to the SingletonURLStreamHandlerFactory

 
Methods inherited from class java.lang.Object
java.lang.Object#wait(), java.lang.Object#wait(long), java.lang.Object#wait(long, int), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()
 

Method Detail

guessFilename

static java.lang.String guessFilename(java.net.URI uri)
Method which tries to infer the filename from the uri.


toURI

static java.net.URI toURI(java.lang.Object s)
Converts the provided parameter into a URI... handle: File, strings, URI, URL, null


toURL

static java.net.URL toURL(java.lang.Object s)
Encapsulates the creation of a URL by first trying the normal way and if it fails, it falls back to the SingletonURLStreamHandlerFactory
Returns:
the url


 

Groovy Documentation