Table of Contents

Class UrlUtil

Namespace
iText.IO.Util
Assembly
itext.io.dll

This file is a helper class for internal usage only. Be aware that its API and functionality may be changed in future.

public static class UrlUtil
Inheritance
UrlUtil
Inherited Members

Methods

GetFileUriString(string)

This method gets uri string from a file.

public static string GetFileUriString(string filename)

Parameters

filename string

a given filename

Returns

string

a uri string

GetInputStreamOfFinalConnection(Uri)

Gets the input stream of connection related to last redirected url. You should manually close input stream after calling this method to not hold any open resources.

public static Stream GetInputStreamOfFinalConnection(Uri url)

Parameters

url Uri

an initial URL.

Returns

Stream

an input stream of connection related to the last redirected url.

GetNormalizedFileUriString(string)

This method gets normalized uri string from a file.

public static string GetNormalizedFileUriString(string filename)

Parameters

filename string

a given filename

Returns

string

a normalized uri string

OpenStream(Uri)

public static Stream OpenStream(Uri url)

Parameters

url Uri

Returns

Stream

ToAbsoluteURI(Uri)

Get the entire URI string which is properly encoded.

public static string ToAbsoluteURI(Uri uri)

Parameters

uri Uri

URI which convert to encoded string

Returns

string

URI string representation

ToNormalizedURI(FileInfo)

This method makes a normalized URI from a given file.

public static Uri ToNormalizedURI(FileInfo file)

Parameters

file FileInfo

a given file

Returns

Uri

a valid Uri

ToNormalizedURI(string)

This method makes a normalized URI from a given filename.

public static Uri ToNormalizedURI(string filename)

Parameters

filename string

a given filename

Returns

Uri

a valid Uri

ToURL(string)

This method makes a valid URL from a given filename.

public static Uri ToURL(string filename)

Parameters

filename string

a given filename

Returns

Uri

a valid URL