STLSoft - ... Robust, Lightweight, Cross-platform, Template Software ... ATLSTL - Template Software for the Active Template Library COMSTL - The Standard Template Library meets the Component Object Model .netSTL - Standard Template Library meets the Microsoft.NET Common Language Runtime InetSTL - The Standard Template Library meets WinInet MFCSTL - Template Software for the Microsoft Foundation Classes UNIXSTL - Template Software for the UNIX Operating System WinSTL - where the Standard Template Library meets the Win32 API

Main Page   Modules   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

File-System Library (InetSTL)
[InetSTLFile-System Library]

This library provides facilities for defining and manipulating file-system objects for the WinInet API. More...

Compounds

class  basic_connection
 Represents an internet connection. More...

class  basic_findfile_sequence
 Presents an STL-like sequence interface over the items on the file-system. More...

class  basic_findfile_sequence_const_input_iterator
 Iterator type for the basic_findfile_sequence supporting the Input Iterator concept. More...

class  basic_findfile_sequence_value_type
 Value type for the basic_findfile_sequence. More...

class  basic_session
 Represents an internet session. More...

struct  filesystem_traits
 Traits for accessing the correct file-system functions for a given character type. More...

class  internet_exception
 The exception type thrown by throw_internet_exception_policy. More...

class  searchspec_sequence
 Provides multi-pattern functionality over a file-system search sequence class. More...

struct  throw_internet_exception_policy
 This type throws internet_exception. More...


Typedefs

typedef basic_connection<
is_char_a_t > 
connection_a
 Instantiation of the basic_connection template for the ANSI character type char.

typedef basic_connection<
is_char_w_t > 
connection_w
 Instantiation of the basic_connection template for the Unicode character type wchar_t.

typedef basic_connection<
TCHAR > 
connection
 Instantiation of the basic_connection template for the Win32 character type TCHAR.

typedef basic_findfile_sequence<
is_char_a_t, filesystem_traits<
is_char_a_t > > 
findfile_sequence_a
 Instantiation of the basic_findfile_sequence template for the ANSI character type char.

typedef basic_findfile_sequence<
is_char_w_t, filesystem_traits<
is_char_w_t > > 
findfile_sequence_w
 Instantiation of the basic_findfile_sequence template for the Unicode character type wchar_t.

typedef basic_findfile_sequence<
TCHAR, filesystem_traits<
TCHAR > > 
findfile_sequence
 Instantiation of the basic_findfile_sequence template for the Win32 character type TCHAR.

typedef basic_session< is_char_a_t > session_a
 Instantiation of the basic_session template for the ANSI character type char.

typedef basic_session< is_char_w_t > session_w
 Instantiation of the basic_session template for the Unicode character type wchar_t.

typedef basic_session< TCHAR > session
 Instantiation of the basic_session template for the Win32 character type TCHAR.


Functions

 basic_connection ()
 Default constructor.

 basic_connection (HINTERNET hsess, char_type const *server, INTERNET_PORT port, char_type const *userName, char_type const *password, is_dword_t service, is_dword_t flags, is_dword_t context=0)
 Create a connection with the given arguments.

 ~basic_connection ()
 Closes the connection, if open.

is_bool_t connect (HINTERNET hsess, char_type const *server, INTERNET_PORT port, char_type const *userName, char_type const *password, is_dword_t service, is_dword_t flags, is_dword_t context=0)
 Opens a connection with the given arguments.

void close ()
 Closes the connection, if open.

HINTERNET detach ()
 Removes the connection from this object, and returns the underlying WinInet handle to the caller, who must take responsibility for releasing it.

is_bool_t is_connected () const
 Indicates whether the object is managing an open connection.

is_dword_t last_error () const
 The last Win32/WinInet error associated with this connection object.

 operator HINTERNET ()
 Implicit conversion operator to a WinInet handle.

 basic_session ()
 Default constructor.

 basic_session (char_type const *pcszAgent, is_dword_t accessType=INTERNET_OPEN_TYPE_PRECONFIG, char_type const *pcszProxyName=NULL, char_type const *pcszProxyBypass=NULL, is_dword_t flags=0)
 Create a session with the given arguments.

 ~basic_session ()
 Closes the session, if open.

is_bool_t open (char_type const *pcszAgent, is_dword_t accessType=INTERNET_OPEN_TYPE_PRECONFIG, char_type const *pcszProxyName=NULL, char_type const *pcszProxyBypass=NULL, is_dword_t flags=0)
 Open a session with the given arguments.

void close ()
 Closes the session, if open.

HINTERNET detach ()
 Removes the session from this object, and returns the underlying WinInet handle to the caller, who must take responsibility for releasing it.

is_bool_t is_open () const
 Indicates whether the object is managing an open session.

 operator HINTERNET ()
 Implicit conversion operator to a WinInet handle.


Detailed Description

This library provides facilities for defining and manipulating file-system objects for the WinInet API.


Typedef Documentation

typedef basic_connection<TCHAR> connection
 

Instantiation of the basic_connection template for the Win32 character type TCHAR.

typedef basic_connection<is_char_a_t> connection_a
 

Instantiation of the basic_connection template for the ANSI character type char.

typedef basic_connection<is_char_w_t> connection_w
 

Instantiation of the basic_connection template for the Unicode character type wchar_t.

typedef basic_findfile_sequence<TCHAR, filesystem_traits<TCHAR> > findfile_sequence
 

Instantiation of the basic_findfile_sequence template for the Win32 character type TCHAR.

typedef basic_findfile_sequence<is_char_a_t, filesystem_traits<is_char_a_t> > findfile_sequence_a
 

Instantiation of the basic_findfile_sequence template for the ANSI character type char.

typedef basic_findfile_sequence<is_char_w_t, filesystem_traits<is_char_w_t> > findfile_sequence_w
 

Instantiation of the basic_findfile_sequence template for the Unicode character type wchar_t.

typedef basic_session<TCHAR> session
 

Instantiation of the basic_session template for the Win32 character type TCHAR.

typedef basic_session<is_char_a_t> session_a
 

Instantiation of the basic_session template for the ANSI character type char.

typedef basic_session<is_char_w_t> session_w
 

Instantiation of the basic_session template for the Unicode character type wchar_t.


Function Documentation

basic_connection HINTERNET    hsess,
char_type const *    server,
INTERNET_PORT    port,
char_type const *    userName,
char_type const *    password,
is_dword_t    service,
is_dword_t    flags,
is_dword_t    context = 0
[inline, explicit, inherited]
 

Create a connection with the given arguments.

Parameters:
hsess  A WinInet handle to the current session, obtained via InternetOpen() or the basic_session class
server  The name of the server to which to connect. May not be NULL
port  The number of the port to connect on
userName  The username for the connection. May be NULL
password  The password for the connection. May be NULL
service  The service to access. Either INTERNET_SERVICE_FTP or INTERNET_SERVICE_HTTP
flags  Service specific flags, e.g. INTERNET_FLAG_PASSIVE
context  Context used for callback functions
Note:
If the connection fails to open, the exception_policy_type function-call operator is called. If the policy throws an exception, then that exception is thrown. If the policy is "null exception" policy type, then the connection object will be constructed in a closed state.

basic_connection   [inline, inherited]
 

Default constructor.

Note:
No connection exists. Use connect() to open a connection

basic_session char_type const *    pcszAgent,
is_dword_t    accessType = INTERNET_OPEN_TYPE_PRECONFIG,
char_type const *    pcszProxyName = NULL,
char_type const *    pcszProxyBypass = NULL,
is_dword_t    flags = 0
[inline, explicit, inherited]
 

Create a session with the given arguments.

Parameters:
pcszAgent  The name of the user agent, e.g. "Acme Internet Browser"
accessType  The type of access required, e.g. INTERNET_OPEN_TYPE_DIRECT, INTERNET_OPEN_TYPE_PRECONFIG. Defaults to INTERNET_OPEN_TYPE_PRECONFIG
pcszProxyName  The name of the proxy server to use. Defaults to NULL
pcszProxyBypass  List of names not be routed by the proxy. Defaults to NULL
flags  Flags altering behaviour of the session initialisation.
Note:
If the session fails to initialise, the exception_policy_type function-call operator is called. If the policy throws an exception, then that exception is thrown. If the policy is "null exception" policy type, then the session object will be constructed in a closed state.

basic_session   [inline, inherited]
 

Default constructor.

Note:
A session is created with default arguments
Note:
If the session fails to initialise, the exception_policy_type function-call operator is called. If the policy throws an exception, then that exception is thrown. If the policy is "null exception" policy type, then the session object will be constructed in a closed state.

void close   [inline, inherited]
 

Closes the session, if open.

void close   [inline, inherited]
 

Closes the connection, if open.

is_bool_t connect HINTERNET    hsess,
char_type const *    server,
INTERNET_PORT    port,
char_type const *    userName,
char_type const *    password,
is_dword_t    service,
is_dword_t    flags,
is_dword_t    context = 0
[inline, inherited]
 

Opens a connection with the given arguments.

Parameters:
hsess  A WinInet handle to the current session, obtained via InternetOpen() or the basic_session class
server  The name of the server to which to connect. May not be NULL
port  The number of the port to connect on
userName  The username for the connection. May be NULL
password  The password for the connection. May be NULL
service  The service to access. Either INTERNET_SERVICE_FTP or INTERNET_SERVICE_HTTP
flags  Service specific flags, e.g. INTERNET_FLAG_PASSIVE
context  Context used for callback functions
Note:
If the connection fails to open, the exception_policy_type function-call operator is called. If the policy throws an exception, then that exception is thrown. If the policy is "null exception" policy type, then the connection object will be left in a closed state.

HINTERNET detach   [inline, inherited]
 

Removes the session from this object, and returns the underlying WinInet handle to the caller, who must take responsibility for releasing it.

HINTERNET detach   [inline, inherited]
 

Removes the connection from this object, and returns the underlying WinInet handle to the caller, who must take responsibility for releasing it.

is_bool_t is_connected   [inline, inherited]
 

Indicates whether the object is managing an open connection.

is_bool_t is_open   [inline, inherited]
 

Indicates whether the object is managing an open session.

is_dword_t last_error   [inline, inherited]
 

The last Win32/WinInet error associated with this connection object.

is_bool_t open char_type const *    pcszAgent,
is_dword_t    accessType = INTERNET_OPEN_TYPE_PRECONFIG,
char_type const *    pcszProxyName = NULL,
char_type const *    pcszProxyBypass = NULL,
is_dword_t    flags = 0
[inline, inherited]
 

Open a session with the given arguments.

Parameters:
pcszAgent  The name of the user agent, e.g. "Acme Internet Browser"
accessType  The type of access required, e.g. INTERNET_OPEN_TYPE_DIRECT, INTERNET_OPEN_TYPE_PRECONFIG. Defaults to INTERNET_OPEN_TYPE_PRECONFIG
pcszProxyName  The name of the proxy server to use. Defaults to NULL
pcszProxyBypass  List of names not be routed by the proxy. Defaults to NULL
flags  Flags altering behaviour of the session initialisation.
Note:
If the session fails to initialise, the exception_policy_type function-call operator is called. If the policy throws an exception, then that exception is thrown. If the policy is "null exception" policy type, then the session object will be left in a closed state.

operator HINTERNET   [inline, inherited]
 

Implicit conversion operator to a WinInet handle.

operator HINTERNET   [inline, inherited]
 

Implicit conversion operator to a WinInet handle.

~basic_connection   [inline, inherited]
 

Closes the connection, if open.

~basic_session   [inline, inherited]
 

Closes the session, if open.


STLSoft Libraries documentation © Synesis Software Pty Ltd, 2001-2004