link_resolver Class Reference

#include <link_resolver.h>

Inheritance diagram for link_resolver:

service_base

List of all members.

Public Types

typedef link_resolver t_interface_entrypoint
typedef link_resolver t_interface
typedef service_base t_interface_parent

Public Member Functions

virtual bool is_our_path (const char *p_path, const char *p_extension)=0
virtual void resolve (service_ptr_t< file > p_filehint, const char *p_path, pfc::string_base &p_out, abort_callback &p_abort)=0

Static Public Member Functions

static bool g_find (service_ptr_t< link_resolver > &p_out, const char *p_path)

Static Public Attributes

static const GUID class_guid


Detailed Description

Interface for resolving different sorts of link files. Utilized by mechanisms that convert filesystem path into list of playable locations. For security reasons, link may only point to playable object path, not to a playlist or another link.

Member Typedef Documentation

Reimplemented from service_base.


Member Function Documentation

virtual bool link_resolver::is_our_path ( const char *  p_path,
const char *  p_extension 
) [pure virtual]

Tests whether specified file is supported by this link_resolver service.

Parameters:
p_path Path of file being queried.
p_extension Extension of file being queried. This is provided for performance reasons, path already includes it.

virtual void link_resolver::resolve ( service_ptr_t< file >  p_filehint,
const char *  p_path,
pfc::string_base p_out,
abort_callback &  p_abort 
) [pure virtual]

Resolves a link file. Before this is called, path must be accepted by is_our_path().

Parameters:
p_filehint Optional file interface to use. If null/empty, implementation should open file by itself.
p_path Path of link file to resolve.
p_out Receives path the link is pointing to.
p_abort abort_callback object signaling user aborting the operation.

static bool link_resolver::g_find ( service_ptr_t< link_resolver > &  p_out,
const char *  p_path 
) [static]

Helper function; finds link_resolver interface that supports specified link file.

Parameters:
p_out Receives link_resolver interface on success.
p_path Path of file to query.
Returns:
True on success, false on failure (no interface that supports specified path could be found).


Member Data Documentation

const GUID link_resolver::class_guid [static]

Initial value:

 
{ 0x3296219b, 0xeba5, 0x4c32, { 0xa1, 0x93, 0xc9, 0xbb, 0x17, 0x48, 0x1, 0xda } }


The documentation for this class was generated from the following files:

Generated on Fri Apr 25 18:49:45 2008 for foobar2000 SDK by  doxygen 1.5.5