Skip to content

Class Ase::ResourceCrawler

ClassList > Ase > ResourceCrawler

Helper to crawl hierarchical resources.

  • #include <api.hh>

Inherits the following classes: Ase::Object

Inherited by the following classes: Ase::FileCrawler

Public Types

Type Name
typedef std::pair< String, String > String2

Public Attributes

Type Name
Member<&ResourceCrawler::entries_ > entries
The entries in the current folder, UTF-8 encoded.
Member<&ResourceCrawler::folder_ > folder
The folder currently being browsed, UTF-8 encoded.

Public Functions

Type Name
virtual String2 assign (const String & utf8path, bool existingfile=false) = 0
virtual Resource canonify (const String & utf8cwd, const String & utf8fragment, bool constraindir, bool constrainfile) = 0
Return absolute path, slash-terminated if directory, constrain to existing paths.
virtual Resource current_folder () = 0
Describe current folder.
virtual ResourceS list_entries () = 0
List entries of a folder.

Public Functions inherited from Ase::Emittable

See Ase::Emittable

Type Name
virtual void emit_event (const String & type, const String & detail, const ValueR fields={}) = 0
virtual void emit_notify (const String & detail) = 0
void js_trigger (const String & eventselector, JsTrigger callback)
virtual ASE_USE_RESULT Connection on_event (const String & eventselector, const EventHandler & eventhandler) = 0

Protected Functions

Type Name
ResourceCrawler ()
virtual bool entries_ (const ResourceS * n, ResourceS * q) = 0
virtual bool folder_ (const Resource * n, Resource * q) = 0

Protected Functions inherited from Ase::Object

See Ase::Object

Type Name
virtual ~Object () = 0

Protected Functions inherited from Ase::VirtualBase

See Ase::VirtualBase

Type Name
virtual ~VirtualBase () noexcept = 0

Public Types Documentation

typedef String2

using Ase::ResourceCrawler::String2 =  std::pair<String,String>;

Public Attributes Documentation

variable entries

Member<&ResourceCrawler::entries_> Ase::ResourceCrawler::entries;

variable folder

Member<&ResourceCrawler::folder_> Ase::ResourceCrawler::folder;

Public Functions Documentation

function assign

virtual String2 Ase::ResourceCrawler::assign (
    const String & utf8path,
    bool existingfile=false
) = 0

Move to a different path.


function canonify

virtual Resource Ase::ResourceCrawler::canonify (
    const String & utf8cwd,
    const String & utf8fragment,
    bool constraindir,
    bool constrainfile
) = 0

function current_folder

virtual Resource Ase::ResourceCrawler::current_folder () = 0

function list_entries

virtual ResourceS Ase::ResourceCrawler::list_entries () = 0

Protected Functions Documentation

function ResourceCrawler

explicit Ase::ResourceCrawler::ResourceCrawler () 

function entries_

virtual bool Ase::ResourceCrawler::entries_ (
    const ResourceS * n,
    ResourceS * q
) = 0

function folder_

virtual bool Ase::ResourceCrawler::folder_ (
    const Resource * n,
    Resource * q
) = 0


The documentation for this class was generated from the following file /__w/anklang/anklang/ase/api.hh