GCC Code Coverage Report


Directory: ./
File: _build/libfprint/fp-enums.c
Date: 2024-05-04 14:54:39
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 3 taken 1 times.
✗ Branch 4 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 110 fp_device_feature_get_type (void)
35 {
36 110 static gsize gtype_id = 0;
37 110 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 55 times.
✓ Branch 1 taken 55 times.
✓ Branch 3 taken 55 times.
✗ Branch 4 not taken.
110 if (g_once_init_enter (&gtype_id)) {
52 55 GType new_type = g_flags_register_static (g_intern_static_string ("FpDeviceFeature"), values);
53 55 g_once_init_leave (&gtype_id, new_type);
54 }
55 110 return (GType) gtype_id;
56 }
57
58 GType
59 137 fp_scan_type_get_type (void)
60 {
61 137 static gsize gtype_id = 0;
62 137 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 120 times.
✓ Branch 1 taken 17 times.
✓ Branch 3 taken 120 times.
✗ Branch 4 not taken.
137 if (g_once_init_enter (&gtype_id)) {
68 120 GType new_type = g_enum_register_static (g_intern_static_string ("FpScanType"), values);
69 120 g_once_init_leave (&gtype_id, new_type);
70 }
71 137 return (GType) gtype_id;
72 }
73
74 GType
75 2003 fp_temperature_get_type (void)
76 {
77 2003 static gsize gtype_id = 0;
78 2003 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 120 times.
✓ Branch 1 taken 1883 times.
✓ Branch 3 taken 120 times.
✗ Branch 4 not taken.
2003 if (g_once_init_enter (&gtype_id)) {
85 120 GType new_type = g_enum_register_static (g_intern_static_string ("FpTemperature"), values);
86 120 g_once_init_leave (&gtype_id, new_type);
87 }
88 2003 return (GType) gtype_id;
89 }
90
91 GType
92 21 fp_device_retry_get_type (void)
93 {
94 21 static gsize gtype_id = 0;
95 21 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 { 0, NULL, NULL }
101 };
102
3/4
✓ Branch 0 taken 17 times.
✓ Branch 1 taken 4 times.
✓ Branch 3 taken 17 times.
✗ Branch 4 not taken.
21 if (g_once_init_enter (&gtype_id)) {
103 17 GType new_type = g_enum_register_static (g_intern_static_string ("FpDeviceRetry"), values);
104 17 g_once_init_leave (&gtype_id, new_type);
105 }
106 21 return (GType) gtype_id;
107 }
108
109 GType
110 65 fp_device_error_get_type (void)
111 {
112 65 static gsize gtype_id = 0;
113 65 static const GEnumValue values[] = {
114 { C_ENUM(FP_DEVICE_ERROR_GENERAL), "FP_DEVICE_ERROR_GENERAL", "general" },
115 { C_ENUM(FP_DEVICE_ERROR_NOT_SUPPORTED), "FP_DEVICE_ERROR_NOT_SUPPORTED", "not-supported" },
116 { C_ENUM(FP_DEVICE_ERROR_NOT_OPEN), "FP_DEVICE_ERROR_NOT_OPEN", "not-open" },
117 { C_ENUM(FP_DEVICE_ERROR_ALREADY_OPEN), "FP_DEVICE_ERROR_ALREADY_OPEN", "already-open" },
118 { C_ENUM(FP_DEVICE_ERROR_BUSY), "FP_DEVICE_ERROR_BUSY", "busy" },
119 { C_ENUM(FP_DEVICE_ERROR_PROTO), "FP_DEVICE_ERROR_PROTO", "proto" },
120 { C_ENUM(FP_DEVICE_ERROR_DATA_INVALID), "FP_DEVICE_ERROR_DATA_INVALID", "data-invalid" },
121 { C_ENUM(FP_DEVICE_ERROR_DATA_NOT_FOUND), "FP_DEVICE_ERROR_DATA_NOT_FOUND", "data-not-found" },
122 { C_ENUM(FP_DEVICE_ERROR_DATA_FULL), "FP_DEVICE_ERROR_DATA_FULL", "data-full" },
123 { C_ENUM(FP_DEVICE_ERROR_DATA_DUPLICATE), "FP_DEVICE_ERROR_DATA_DUPLICATE", "data-duplicate" },
124 { C_ENUM(FP_DEVICE_ERROR_REMOVED), "FP_DEVICE_ERROR_REMOVED", "removed" },
125 { C_ENUM(FP_DEVICE_ERROR_TOO_HOT), "FP_DEVICE_ERROR_TOO_HOT", "too-hot" },
126 { 0, NULL, NULL }
127 };
128
3/4
✓ Branch 0 taken 55 times.
✓ Branch 1 taken 10 times.
✓ Branch 3 taken 55 times.
✗ Branch 4 not taken.
65 if (g_once_init_enter (&gtype_id)) {
129 55 GType new_type = g_enum_register_static (g_intern_static_string ("FpDeviceError"), values);
130 55 g_once_init_leave (&gtype_id, new_type);
131 }
132 65 return (GType) gtype_id;
133 }
134
135 /* enumerations from "fp-print.h" */
136
137 GType
138 174 fp_finger_get_type (void)
139 {
140 174 static gsize gtype_id = 0;
141 174 static const GEnumValue values[] = {
142 { C_ENUM(FP_FINGER_UNKNOWN), "FP_FINGER_UNKNOWN", "unknown" },
143 { C_ENUM(FP_FINGER_LEFT_THUMB), "FP_FINGER_LEFT_THUMB", "left-thumb" },
144 { C_ENUM(FP_FINGER_LEFT_INDEX), "FP_FINGER_LEFT_INDEX", "left-index" },
145 { C_ENUM(FP_FINGER_LEFT_MIDDLE), "FP_FINGER_LEFT_MIDDLE", "left-middle" },
146 { C_ENUM(FP_FINGER_LEFT_RING), "FP_FINGER_LEFT_RING", "left-ring" },
147 { C_ENUM(FP_FINGER_LEFT_LITTLE), "FP_FINGER_LEFT_LITTLE", "left-little" },
148 { C_ENUM(FP_FINGER_RIGHT_THUMB), "FP_FINGER_RIGHT_THUMB", "right-thumb" },
149 { C_ENUM(FP_FINGER_RIGHT_INDEX), "FP_FINGER_RIGHT_INDEX", "right-index" },
150 { C_ENUM(FP_FINGER_RIGHT_MIDDLE), "FP_FINGER_RIGHT_MIDDLE", "right-middle" },
151 { C_ENUM(FP_FINGER_RIGHT_RING), "FP_FINGER_RIGHT_RING", "right-ring" },
152 { C_ENUM(FP_FINGER_RIGHT_LITTLE), "FP_FINGER_RIGHT_LITTLE", "right-little" },
153 { C_ENUM(FP_FINGER_FIRST), "FP_FINGER_FIRST", "first" },
154 { C_ENUM(FP_FINGER_LAST), "FP_FINGER_LAST", "last" },
155 { 0, NULL, NULL }
156 };
157
3/4
✓ Branch 0 taken 67 times.
✓ Branch 1 taken 107 times.
✓ Branch 3 taken 67 times.
✗ Branch 4 not taken.
174 if (g_once_init_enter (&gtype_id)) {
158 67 GType new_type = g_enum_register_static (g_intern_static_string ("FpFinger"), values);
159 67 g_once_init_leave (&gtype_id, new_type);
160 }
161 174 return (GType) gtype_id;
162 }
163
164 GType
165 1160 fp_finger_status_flags_get_type (void)
166 {
167 1160 static gsize gtype_id = 0;
168 1160 static const GFlagsValue values[] = {
169 { C_FLAGS(FP_FINGER_STATUS_NONE), "FP_FINGER_STATUS_NONE", "none" },
170 { C_FLAGS(FP_FINGER_STATUS_NEEDED), "FP_FINGER_STATUS_NEEDED", "needed" },
171 { C_FLAGS(FP_FINGER_STATUS_PRESENT), "FP_FINGER_STATUS_PRESENT", "present" },
172 { 0, NULL, NULL }
173 };
174
3/4
✓ Branch 0 taken 120 times.
✓ Branch 1 taken 1040 times.
✓ Branch 3 taken 120 times.
✗ Branch 4 not taken.
1160 if (g_once_init_enter (&gtype_id)) {
175 120 GType new_type = g_flags_register_static (g_intern_static_string ("FpFingerStatusFlags"), values);
176 120 g_once_init_leave (&gtype_id, new_type);
177 }
178 1160 return (GType) gtype_id;
179 }
180
181 /* Generated data ends here */
182
183