GCC Code Coverage Report


Directory: ./
File: _build/libfprint/fp-enums.c
Date: 2025-03-01 04:11:53
Exec Total Coverage
Lines: 56 56 100.0%
Functions: 8 8 100.0%
Branches: 23 32 71.9%

Line Branch Exec Source
1
2 /* This file is generated by glib-mkenums, do not modify it. This code is licensed under the same license as the containing project. Note that it links to GLib, so must comply with the LGPL linking clauses. */
3
4 #include "fp-enums.h"
5 #include "fp-context.h"
6 #include "fp-device.h"
7 #include "fp-image-device.h"
8 #include "fp-image.h"
9 #include "fp-print.h"
10
11 #define C_ENUM(v) ((gint) v)
12 #define C_FLAGS(v) ((guint) v)
13
14 /* enumerations from "fp-device.h" */
15
16 GType
17 1 fp_device_type_get_type (void)
18 {
19 1 static gsize gtype_id = 0;
20 1 static const GEnumValue values[] = {
21 { C_ENUM (FP_DEVICE_TYPE_VIRTUAL), "FP_DEVICE_TYPE_VIRTUAL", "virtual" },
22 { C_ENUM (FP_DEVICE_TYPE_UDEV), "FP_DEVICE_TYPE_UDEV", "udev" },
23 { C_ENUM (FP_DEVICE_TYPE_USB), "FP_DEVICE_TYPE_USB", "usb" },
24 { 0, NULL, NULL }
25 };
26
2/4
✓ Branch 0 taken 1 times.
✗ Branch 1 not taken.
✓ Branch 2 taken 1 times.
✗ Branch 3 not taken.
1 if (g_once_init_enter (&gtype_id)) {
27 1 GType new_type = g_enum_register_static (g_intern_static_string ("FpDeviceType"), values);
28 1 g_once_init_leave (&gtype_id, new_type);
29 }
30 1 return (GType) gtype_id;
31 }
32
33 GType
34 116 fp_device_feature_get_type (void)
35 {
36 116 static gsize gtype_id = 0;
37 116 static const GFlagsValue values[] = {
38 { C_FLAGS (FP_DEVICE_FEATURE_NONE), "FP_DEVICE_FEATURE_NONE", "none" },
39 { C_FLAGS (FP_DEVICE_FEATURE_CAPTURE), "FP_DEVICE_FEATURE_CAPTURE", "capture" },
40 { C_FLAGS (FP_DEVICE_FEATURE_IDENTIFY), "FP_DEVICE_FEATURE_IDENTIFY", "identify" },
41 { C_FLAGS (FP_DEVICE_FEATURE_VERIFY), "FP_DEVICE_FEATURE_VERIFY", "verify" },
42 { C_FLAGS (FP_DEVICE_FEATURE_STORAGE), "FP_DEVICE_FEATURE_STORAGE", "storage" },
43 { C_FLAGS (FP_DEVICE_FEATURE_STORAGE_LIST), "FP_DEVICE_FEATURE_STORAGE_LIST", "storage-list" },
44 { C_FLAGS (FP_DEVICE_FEATURE_STORAGE_DELETE), "FP_DEVICE_FEATURE_STORAGE_DELETE", "storage-delete" },
45 { C_FLAGS (FP_DEVICE_FEATURE_STORAGE_CLEAR), "FP_DEVICE_FEATURE_STORAGE_CLEAR", "storage-clear" },
46 { C_FLAGS (FP_DEVICE_FEATURE_DUPLICATES_CHECK), "FP_DEVICE_FEATURE_DUPLICATES_CHECK", "duplicates-check" },
47 { C_FLAGS (FP_DEVICE_FEATURE_ALWAYS_ON), "FP_DEVICE_FEATURE_ALWAYS_ON", "always-on" },
48 { C_FLAGS (FP_DEVICE_FEATURE_UPDATE_PRINT), "FP_DEVICE_FEATURE_UPDATE_PRINT", "update-print" },
49 { 0, NULL, NULL }
50 };
51
3/4
✓ Branch 0 taken 58 times.
✓ Branch 1 taken 58 times.
✓ Branch 2 taken 58 times.
✗ Branch 3 not taken.
116 if (g_once_init_enter (&gtype_id)) {
52 58 GType new_type = g_flags_register_static (g_intern_static_string ("FpDeviceFeature"), values);
53 58 g_once_init_leave (&gtype_id, new_type);
54 }
55 116 return (GType) gtype_id;
56 }
57
58 GType
59 141 fp_scan_type_get_type (void)
60 {
61 141 static gsize gtype_id = 0;
62 141 static const GEnumValue values[] = {
63 { C_ENUM (FP_SCAN_TYPE_SWIPE), "FP_SCAN_TYPE_SWIPE", "swipe" },
64 { C_ENUM (FP_SCAN_TYPE_PRESS), "FP_SCAN_TYPE_PRESS", "press" },
65 { 0, NULL, NULL }
66 };
67
3/4
✓ Branch 0 taken 124 times.
✓ Branch 1 taken 17 times.
✓ Branch 2 taken 124 times.
✗ Branch 3 not taken.
141 if (g_once_init_enter (&gtype_id)) {
68 124 GType new_type = g_enum_register_static (g_intern_static_string ("FpScanType"), values);
69 124 g_once_init_leave (&gtype_id, new_type);
70 }
71 141 return (GType) gtype_id;
72 }
73
74 GType
75 2105 fp_temperature_get_type (void)
76 {
77 2105 static gsize gtype_id = 0;
78 2105 static const GEnumValue values[] = {
79 { C_ENUM (FP_TEMPERATURE_COLD), "FP_TEMPERATURE_COLD", "cold" },
80 { C_ENUM (FP_TEMPERATURE_WARM), "FP_TEMPERATURE_WARM", "warm" },
81 { C_ENUM (FP_TEMPERATURE_HOT), "FP_TEMPERATURE_HOT", "hot" },
82 { 0, NULL, NULL }
83 };
84
3/4
✓ Branch 0 taken 124 times.
✓ Branch 1 taken 1981 times.
✓ Branch 2 taken 124 times.
✗ Branch 3 not taken.
2105 if (g_once_init_enter (&gtype_id)) {
85 124 GType new_type = g_enum_register_static (g_intern_static_string ("FpTemperature"), values);
86 124 g_once_init_leave (&gtype_id, new_type);
87 }
88 2105 return (GType) gtype_id;
89 }
90
91 GType
92 22 fp_device_retry_get_type (void)
93 {
94 22 static gsize gtype_id = 0;
95 22 static const GEnumValue values[] = {
96 { C_ENUM (FP_DEVICE_RETRY_GENERAL), "FP_DEVICE_RETRY_GENERAL", "general" },
97 { C_ENUM (FP_DEVICE_RETRY_TOO_SHORT), "FP_DEVICE_RETRY_TOO_SHORT", "too-short" },
98 { C_ENUM (FP_DEVICE_RETRY_CENTER_FINGER), "FP_DEVICE_RETRY_CENTER_FINGER", "center-finger" },
99 { C_ENUM (FP_DEVICE_RETRY_REMOVE_FINGER), "FP_DEVICE_RETRY_REMOVE_FINGER", "remove-finger" },
100 { C_ENUM (FP_DEVICE_RETRY_TOO_FAST), "FP_DEVICE_RETRY_TOO_FAST", "too-fast" },
101 { 0, NULL, NULL }
102 };
103
3/4
✓ Branch 0 taken 17 times.
✓ Branch 1 taken 5 times.
✓ Branch 2 taken 17 times.
✗ Branch 3 not taken.
22 if (g_once_init_enter (&gtype_id)) {
104 17 GType new_type = g_enum_register_static (g_intern_static_string ("FpDeviceRetry"), values);
105 17 g_once_init_leave (&gtype_id, new_type);
106 }
107 22 return (GType) gtype_id;
108 }
109
110 GType
111 67 fp_device_error_get_type (void)
112 {
113 67 static gsize gtype_id = 0;
114 67 static const GEnumValue values[] = {
115 { C_ENUM (FP_DEVICE_ERROR_GENERAL), "FP_DEVICE_ERROR_GENERAL", "general" },
116 { C_ENUM (FP_DEVICE_ERROR_NOT_SUPPORTED), "FP_DEVICE_ERROR_NOT_SUPPORTED", "not-supported" },
117 { C_ENUM (FP_DEVICE_ERROR_NOT_OPEN), "FP_DEVICE_ERROR_NOT_OPEN", "not-open" },
118 { C_ENUM (FP_DEVICE_ERROR_ALREADY_OPEN), "FP_DEVICE_ERROR_ALREADY_OPEN", "already-open" },
119 { C_ENUM (FP_DEVICE_ERROR_BUSY), "FP_DEVICE_ERROR_BUSY", "busy" },
120 { C_ENUM (FP_DEVICE_ERROR_PROTO), "FP_DEVICE_ERROR_PROTO", "proto" },
121 { C_ENUM (FP_DEVICE_ERROR_DATA_INVALID), "FP_DEVICE_ERROR_DATA_INVALID", "data-invalid" },
122 { C_ENUM (FP_DEVICE_ERROR_DATA_NOT_FOUND), "FP_DEVICE_ERROR_DATA_NOT_FOUND", "data-not-found" },
123 { C_ENUM (FP_DEVICE_ERROR_DATA_FULL), "FP_DEVICE_ERROR_DATA_FULL", "data-full" },
124 { C_ENUM (FP_DEVICE_ERROR_DATA_DUPLICATE), "FP_DEVICE_ERROR_DATA_DUPLICATE", "data-duplicate" },
125 { C_ENUM (FP_DEVICE_ERROR_REMOVED), "FP_DEVICE_ERROR_REMOVED", "removed" },
126 { C_ENUM (FP_DEVICE_ERROR_TOO_HOT), "FP_DEVICE_ERROR_TOO_HOT", "too-hot" },
127 { 0, NULL, NULL }
128 };
129
3/4
✓ Branch 0 taken 57 times.
✓ Branch 1 taken 10 times.
✓ Branch 2 taken 57 times.
✗ Branch 3 not taken.
67 if (g_once_init_enter (&gtype_id)) {
130 57 GType new_type = g_enum_register_static (g_intern_static_string ("FpDeviceError"), values);
131 57 g_once_init_leave (&gtype_id, new_type);
132 }
133 67 return (GType) gtype_id;
134 }
135
136 /* enumerations from "fp-print.h" */
137
138 GType
139 190 fp_finger_get_type (void)
140 {
141 190 static gsize gtype_id = 0;
142 190 static const GEnumValue values[] = {
143 { C_ENUM (FP_FINGER_UNKNOWN), "FP_FINGER_UNKNOWN", "unknown" },
144 { C_ENUM (FP_FINGER_LEFT_THUMB), "FP_FINGER_LEFT_THUMB", "left-thumb" },
145 { C_ENUM (FP_FINGER_LEFT_INDEX), "FP_FINGER_LEFT_INDEX", "left-index" },
146 { C_ENUM (FP_FINGER_LEFT_MIDDLE), "FP_FINGER_LEFT_MIDDLE", "left-middle" },
147 { C_ENUM (FP_FINGER_LEFT_RING), "FP_FINGER_LEFT_RING", "left-ring" },
148 { C_ENUM (FP_FINGER_LEFT_LITTLE), "FP_FINGER_LEFT_LITTLE", "left-little" },
149 { C_ENUM (FP_FINGER_RIGHT_THUMB), "FP_FINGER_RIGHT_THUMB", "right-thumb" },
150 { C_ENUM (FP_FINGER_RIGHT_INDEX), "FP_FINGER_RIGHT_INDEX", "right-index" },
151 { C_ENUM (FP_FINGER_RIGHT_MIDDLE), "FP_FINGER_RIGHT_MIDDLE", "right-middle" },
152 { C_ENUM (FP_FINGER_RIGHT_RING), "FP_FINGER_RIGHT_RING", "right-ring" },
153 { C_ENUM (FP_FINGER_RIGHT_LITTLE), "FP_FINGER_RIGHT_LITTLE", "right-little" },
154 { C_ENUM (FP_FINGER_FIRST), "FP_FINGER_FIRST", "first" },
155 { C_ENUM (FP_FINGER_LAST), "FP_FINGER_LAST", "last" },
156 { 0, NULL, NULL }
157 };
158
3/4
✓ Branch 0 taken 70 times.
✓ Branch 1 taken 120 times.
✓ Branch 2 taken 70 times.
✗ Branch 3 not taken.
190 if (g_once_init_enter (&gtype_id)) {
159 70 GType new_type = g_enum_register_static (g_intern_static_string ("FpFinger"), values);
160 70 g_once_init_leave (&gtype_id, new_type);
161 }
162 190 return (GType) gtype_id;
163 }
164
165 GType
166 1409 fp_finger_status_flags_get_type (void)
167 {
168 1409 static gsize gtype_id = 0;
169 1409 static const GFlagsValue values[] = {
170 { C_FLAGS (FP_FINGER_STATUS_NONE), "FP_FINGER_STATUS_NONE", "none" },
171 { C_FLAGS (FP_FINGER_STATUS_NEEDED), "FP_FINGER_STATUS_NEEDED", "needed" },
172 { C_FLAGS (FP_FINGER_STATUS_PRESENT), "FP_FINGER_STATUS_PRESENT", "present" },
173 { 0, NULL, NULL }
174 };
175
3/4
✓ Branch 0 taken 124 times.
✓ Branch 1 taken 1285 times.
✓ Branch 2 taken 124 times.
✗ Branch 3 not taken.
1409 if (g_once_init_enter (&gtype_id)) {
176 124 GType new_type = g_flags_register_static (g_intern_static_string ("FpFingerStatusFlags"), values);
177 124 g_once_init_leave (&gtype_id, new_type);
178 }
179 1409 return (GType) gtype_id;
180 }
181
182 /* Generated data ends here */
183
184