File: error.h

package info (click to toggle)
wireplumber 0.5.12-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 4,244 kB
  • sloc: ansic: 41,043; python: 391; sh: 62; makefile: 57; xml: 23
file content (45 lines) | stat: -rw-r--r-- 1,039 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/* WirePlumber
 *
 * Copyright © 2019 Collabora Ltd.
 *    @author George Kiagiadakis <george.kiagiadakis@collabora.com>
 *
 * SPDX-License-Identifier: MIT
 */

#ifndef __WP_ERROR_H__
#define __WP_ERROR_H__

#include <glib.h>
#include "defs.h"

G_BEGIN_DECLS

/*!
 * \brief A GError domain for errors that occurred within the context of the
 * WirePlumber library.
 * \ingroup wperror
 */
#define WP_DOMAIN_LIBRARY (wp_domain_library_quark ())
WP_API
GQuark wp_domain_library_quark (void);

/*!
 * \brief Error codes that can appear in a GError when the error domain
 * is WP_DOMAIN_LIBRARY
 * \ingroup wperror
 */
typedef enum {
  /*! an invariant check failed; this most likely
   *  indicates a programming error */
  WP_LIBRARY_ERROR_INVARIANT,
  /*! an unexpected/invalid argument was given */
  WP_LIBRARY_ERROR_INVALID_ARGUMENT,
  /*! an operation failed */
  WP_LIBRARY_ERROR_OPERATION_FAILED,
  /*! a required external service was unavailable */
  WP_LIBRARY_ERROR_SERVICE_UNAVAILABLE,
} WpLibraryErrorEnum;

G_END_DECLS

#endif