netatalk: dbd.h File Reference

netatalk 4.5.1
Free and Open Source Apple Filing Protocol (AFP) Server
Loading...
Searching...
No Matches
dbd.h File Reference
`#include <arpa/inet.h>`
`#include <atalk/cnid_bdb_private.h>`
`#include "dbif.h"`

Go to the source code of this file.

## Functions
int | add_cnid (DBD *dbd, struct cnid_dbd_rqst *rqst, struct cnid_dbd_rply *rply)
int | get_cnid (DBD *dbd, struct cnid_dbd_rply *rply)
int | dbd_add (DBD *dbd, struct cnid_dbd_rqst *, struct cnid_dbd_rply *)
int | dbd_lookup (DBD *dbd, struct cnid_dbd_rqst *, struct cnid_dbd_rply *)
| This returns the CNID corresponding to a particular file.
int | dbd_get (DBD *dbd, struct cnid_dbd_rqst *, struct cnid_dbd_rply *)
int | dbd_resolve (DBD *dbd, struct cnid_dbd_rqst *, struct cnid_dbd_rply *)
int | dbd_update (DBD *dbd, struct cnid_dbd_rqst *, struct cnid_dbd_rply *)
| takes the given cnid and updates the metadata.
int | dbd_delete (DBD *dbd, struct cnid_dbd_rqst *, struct cnid_dbd_rply *, int idx)
int | dbd_getstamp (DBD *dbd, struct cnid_dbd_rqst *, struct cnid_dbd_rply *)
int | dbd_rebuild_add (DBD *dbd, struct cnid_dbd_rqst *, struct cnid_dbd_rply *)
int | dbd_search (DBD *dbd, struct cnid_dbd_rqst *, struct cnid_dbd_rply *)
int | dbd_check_indexes (DBD *dbd, char *)

## Function Documentation

## ◆ add_cnid()

int add_cnid | ( | DBD * | dbd,
|  | struct cnid_dbd_rqst * | rqst,
|  | struct cnid_dbd_rply * | rply )

## ◆ dbd_add()

int dbd_add | ( | DBD * | dbd,
|  | struct cnid_dbd_rqst * | rqst,
|  | struct cnid_dbd_rply * | rply )

## ◆ dbd_check_indexes()

int dbd_check_indexes | ( | DBD * | dbd,
|  | char * | dbdir )

## ◆ dbd_delete()

int dbd_delete | ( | DBD * | dbd,
|  | struct cnid_dbd_rqst * | rqst,
|  | struct cnid_dbd_rply * | rply,
|  | int | idx )

## ◆ dbd_get()

int dbd_get | ( | DBD * | dbd,
|  | struct cnid_dbd_rqst * | rqst,
|  | struct cnid_dbd_rply * | rply )

Return CNID for a given did/name.

## ◆ dbd_getstamp()

int dbd_getstamp | ( | DBD * | dbd,
|  | struct cnid_dbd_rqst * | rqst,
|  | struct cnid_dbd_rply * | rply )

Return the unique stamp associated with this database

## ◆ dbd_lookup()

int dbd_lookup | ( | DBD * | dbd,
|  | struct cnid_dbd_rqst * | rqst,
|  | struct cnid_dbd_rply * | rply )

This returns the CNID corresponding to a particular file.

Note
  It will also fix up the database if there's a problem.

## ◆ dbd_rebuild_add()

int dbd_rebuild_add | ( | DBD * | dbd,
|  | struct cnid_dbd_rqst * | rqst,
|  | struct cnid_dbd_rply * | rply )

Enter all fields (including the CNID) into the database and update the current cnid, for emergency repairs.

## ◆ dbd_resolve()

int dbd_resolve | ( | DBD * | dbd,
|  | struct cnid_dbd_rqst * | rqst,
|  | struct cnid_dbd_rply * | rply )

Return the did/name pair corresponding to a CNID.

## ◆ dbd_search()

int dbd_search | ( | DBD * | dbd,
|  | struct cnid_dbd_rqst * | rqst,
|  | struct cnid_dbd_rply * | rply )

## ◆ dbd_update()

int dbd_update | ( | DBD * | dbd,
|  | struct cnid_dbd_rqst * | rqst,
|  | struct cnid_dbd_rply * | rply )

takes the given cnid and updates the metadata.

First, delete given CNID, then re-insert.

## ◆ get_cnid()

int get_cnid | ( | DBD * | dbd,
|  | struct cnid_dbd_rply * | rply )