libdrc.h File Reference
Dar run configuration file interpreter library. More...
#include "libdarc.h"
Go to the source code of this file.
Functions | |
DLLIMPORT dar_drc * | dar_drc_parse_xml_file (const char *filename, const char *dtdfilepath, dar_sup_exception *exception) |
Parses dar run configuration from xml file. | |
DLLIMPORT dar_drc * | dar_drc_parse_xml_memory (const char *buffer, int size, const char *dtdfilepath, dar_sup_exception *exception) |
Parses dar run configuration from memory buffer. | |
DLLIMPORT bool | dar_drc_write_xml_file (const char *filename, dar_sup_exception *exception) |
Writes dar run configuration to file. | |
DLLIMPORT char * | dar_drc_write_xml_memory (dar_sup_exception *exception) |
Writes dar run configuration to newly assigned memory buffer. | |
DLLIMPORT dar_drc * | dar_drc_create (dar_drc *reference, dar_sup_spec *spec, dar_sup_storage *storage, dar_sup_flags *flags) |
Creates a drc object from archive description structures. | |
DLLIMPORT dar_sup_spec * | dar_drc_get_spec (dar_drc *ref) |
Retrieves a pointer to the dar_sup_spec structure describing the archive in a drc object. | |
DLLIMPORT dar_sup_storage * | dar_drc_get_storage (dar_drc *ref) |
Retrieves a pointer to the dar_sup_storage structure describing the archive in a drc object. | |
DLLIMPORT dar_sup_flags * | dar_drc_get_flags (dar_drc *ref) |
Retrieves a pointer to the dar_sup_flags structure describing the archive in a drc object. | |
DLLIMPORT char * | dar_drc_get_passphrase (dar_drc *ref) |
Retrieves stored passphrase from archive specification. | |
DLLIMPORT bool | dar_drc_set_passphrase (dar_drc *ref, char *passphrase) |
Replaces stored passphrase in the archive specification. | |
DLLIMPORT bool | dar_drc_has_reference (dar_drc *ref) |
Determines if a given drc object contains a reference archive specification. | |
DLLIMPORT dar_archive * | dar_drc_open_reference (dar_user_interaction_struct dialog, dar_drc *ref, dar_sup_exception *exception) |
Opens a reference archive from a stored specification. | |
DLLIMPORT char * | dar_drc_get_reference_passphrase (dar_drc *ref) |
Retrieves stored passphrase from reference archive specification. | |
DLLIMPORT bool | dar_drc_set_reference_passphrase (dar_drc *ref, char *passphrase) |
Replaces stored passphrase in the archive specification. | |
DLLIMPORT void | dar_drc_destroy (dar_drc *ref) |
Frees all memory for the drc object and the elements it contains. |
Detailed Description
Dar run configuration file interpreter library.Provides tools to parse Xml drc files.
Definition in file libdrc.h.
Function Documentation
|
Creates a drc object from archive description structures.
This function takes pointers to support structures. These structures will not be copied. Instead, the pointers will be stored directly in the drc object. Therefore, the structures must be allocated on the heap and must not be freed by the caller directly. They will be free and destroyed when
Definition at line 257 of file libdrc.c. References dar_drc_destroy(). |
|
Frees all memory for the drc object and the elements it contains.
All internal specification and support objects will be freed, so this function must not be called while Definition at line 208 of file libdrc.c. References dar_sup_spec_destroy(), and dar_sup_storage_destroy(). Referenced by dar_drc_create(), dar_drc_parse_xml_file(), and dar_drc_parse_xml_memory(). |
|
Retrieves a pointer to the
The |
|
Retrieves stored passphrase from archive specification. In some cases, it may be desirable to store a passphrase in a drc file. This can be valuable when creating session keys, which can then be encrypted before final storage. This function should be used to directly retrieve a copy of a passphrase in whatever form it is currently stored.
|
|
Retrieves stored passphrase from reference archive specification.
This is the counterpart to
|
|
Retrieves a pointer to the
The |
|
Retrieves a pointer to the
The |
|
Determines if a given drc object contains a reference archive specification.
Any archive opened from a drc file may be based on a reference archive. This function can be used to determine if a given archive stored in a drc object depends on a reference archive. That archive must be opened with
|
|
Opens a reference archive from a stored specification. Any archive opened from a drc file may be based on a reference archive. When an archive operation requires access to that reference archive, this function can be used to open that archive.
Definition at line 166 of file libdrc.c. References dar_op_archive_open(), LIBDAR_NOEXCEPT, and dar_sup_exception::type. |
|
Parses dar run configuration from xml file. All strings will be copied, originals must be freed by caller.
Definition at line 487 of file libdrc.c. References dar_drc_destroy(), LIBDAR_EMEMORY, LIBDAR_NOEXCEPT, LIBDAR_X_EINPUTSPEC, LIBDARC_EXCEPTION, and dar_sup_exception::type. |
|
Parses dar run configuration from memory buffer. All strings will be copied, originals must be freed by caller.
Definition at line 408 of file libdrc.c. References dar_drc_destroy(), LIBDAR_EMEMORY, LIBDAR_NOEXCEPT, LIBDAR_X_EINPUTSPEC, LIBDARC_EXCEPTION, and dar_sup_exception::type. |
|
Replaces stored passphrase in the archive specification. In some cases, it may be desirable to store a passphrase in a drc file. This can be valuable when creating session keys, which can then be encrypted before final storage. This function should be used to directly replace a copy of a passphrase to an encrypted or decrypted form.
|
|
Replaces stored passphrase in the archive specification.
This is the counterpart to
|
|
Writes dar run configuration to file.
Definition at line 388 of file libdrc.c. References LIBDAR_ELIBCALL, and LIBDARC_EXCEPTION. |