DhLink

DhLink

Functions

Types and Values

Object Hierarchy

    GBoxed
    ╰── DhLink

Description

Functions

dh_link_new ()

DhLink *
dh_link_new (DhLinkType type,
             const gchar *base,
             const gchar *id,
             const gchar *name,
             DhLink *book,
             DhLink *page,
             const gchar *filename);

Create a new DhLink object.

If type is one of DH_LINK_TYPE_BOOK or DH_LINK_TYPE_PAGE then the book and page links have to be provided.

Parameters

type

the type of the content the link is pointing to

 

base

the base path of the link

 

id

the id of the link

 

name

the name of the link

 

book

the link to the associated book or NULL.

[nullable]

page

the link to the associated page or NULL.

[nullable]

filename

the filename of the link

 

Returns

a new DhLink object


dh_link_free ()

void
dh_link_free (DhLink *link);

dh_link_compare ()

gint
dh_link_compare (gconstpointer a,
                 gconstpointer b);

Compare the link a and b .

Parameters

a

a DhLink object.

[type DhLink]

b

the DhLink to compare.

[type DhLink]

Returns

an integer less than, equal to, or greater than zero, if a is <, == or > than b .


dh_link_ref ()

DhLink *
dh_link_ref (DhLink *link);

Increase the reference count of link .

Parameters

link

a DhLink object

 

Returns

the link object.

[transfer full]


dh_link_unref ()

void
dh_link_unref (DhLink *link);

Decrease the reference count of link .

Parameters

link

a DhLink object

 

dh_link_get_name ()

const gchar *
dh_link_get_name (DhLink *link);

Get the name of the link.

Parameters

link

a DhLink object

 

Returns

the name of the link


dh_link_get_book_name ()

const gchar *
dh_link_get_book_name (DhLink *link);

Get the book name the link is pointing to.

Parameters

link

a DhLink object

 

Returns

the book name the link is pointing to


dh_link_get_page_name ()

const gchar *
dh_link_get_page_name (DhLink *link);

Get the page name the link is pointing to.

Parameters

link

a DhLink object

 

Returns

the page name the link is pointing to


dh_link_get_file_name ()

const gchar *
dh_link_get_file_name (DhLink *link);

Get the file name of the link.

Parameters

link

a DhLink object

 

Returns

the file name of the link


dh_link_get_book_id ()

const gchar *
dh_link_get_book_id (DhLink *link);

Get the book id the link is pointing to.

Parameters

link

a DhLink object

 

Returns

the book id the link is pointing to


dh_link_get_uri ()

gchar *
dh_link_get_uri (DhLink *link);

Get the uri of the link.

Parameters

link

a DhLink object

 

Returns

the uri of the link


dh_link_get_flags ()

DhLinkFlags
dh_link_get_flags (DhLink *link);

Get the flags of the link.

Parameters

link

a DhLink object

 

Returns

the flags of the link


dh_link_set_flags ()

void
dh_link_set_flags (DhLink *link,
                   DhLinkFlags flags);

Set the flags of the link.

Parameters

link

a DhLink object

 

flags

the new flags of the link

 

dh_link_get_link_type ()

DhLinkType
dh_link_get_link_type (DhLink *link);

Get the type of the link.

Parameters

link

a DhLink object

 

Returns

the type of the link


dh_link_get_type_as_string ()

const gchar *
dh_link_get_type_as_string (DhLink *link);

Get the link type name.

Parameters

link

a DhLink object

 

Returns

the link type name translated in the current language

Types and Values

DhLink

typedef struct _DhLink DhLink;

enum DhLinkType

The type of the content the link points to.

Members

DH_LINK_TYPE_BOOK

a book

 

DH_LINK_TYPE_PAGE

a page

 

DH_LINK_TYPE_KEYWORD

a keyword

 

DH_LINK_TYPE_FUNCTION

a function

 

DH_LINK_TYPE_STRUCT

a struct

 

DH_LINK_TYPE_MACRO

a macro

 

DH_LINK_TYPE_ENUM

an enum

 

DH_LINK_TYPE_TYPEDEF

a typedef

 

DH_LINK_TYPE_PROPERTY

a property

 

DH_LINK_TYPE_SIGNAL

a signal

 

enum DhLinkFlags

Members

DH_LINK_FLAGS_NONE

no flag set

 

DH_LINK_FLAGS_DEPRECATED

deprecated link