The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Zeal::Docset - Class representing a Dash/Zeal docset

SYNOPSIS

  use Zeal::Docset;

DESCRIPTION

Dash is an offline API documentation browser. Zeal::Docset is a class representing a Dash/Zeal docset.

Available methods:

Zeal::Docset->new($path)

Create a Zeal::Docset object from a given docset. $path should be the path to a something.docset directory.

$ds->path

The path to the docset folder.

$ds->plist

A hashref with the contents of Info.plist.

$ds->dbh

A DBI database handle to the docSet.dsidx index.

$ds->name

The name of this docset. Equivalent to $ds->plist->{CFBundleName}

$ds->id

The identifier of this docset. Equivalent to $ds->plist->{CFBundleIdentifier}

$ds->family

The family this docset belongs to. Dash uses this as the keyword for restricting searches to a particular family of docsets. Equivalent to $ds->plist->{DocSetPlatformFamily}

$ds->fetch($path)

Internal method for fetching the HTML content of a document. $path is either the path to the document relative to $ds->path or a HTTP URL.

$ds->query($cond)

In list context, return all documents (Zeal::Document instances) matching $cond. In scalar context, return one such document. $cond is a SQL LIKE condition.

$ds->get($cond)

The HTML content of one document that matches $cond. $cond is a SQL LIKE condition.

This method is shorthand for $ds->query($cond)->fetch.

$ds->list

The list of all documents (Zeal::Document instances) in this docset.

SEE ALSO

Zeal, http://kapeli.com/dash, http://zealdocs.org

AUTHOR

Marius Gavrilescu, <marius@ieval.ro>

COPYRIGHT AND LICENSE

Copyright (C) 2014 by Marius Gavrilescu

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.20.1 or, at your option, any later version of Perl 5 you may have available.