1UDEV_DEVICE_HAS_TAG(3)        udev_device_has_tag       UDEV_DEVICE_HAS_TAG(3)
2
3
4

NAME

6       udev_device_has_tag, udev_device_get_devlinks_list_entry,
7       udev_device_get_properties_list_entry, udev_device_get_tags_list_entry,
8       udev_device_get_sysattr_list_entry, udev_device_get_property_value,
9       udev_device_get_sysattr_value, udev_device_set_sysattr_value - Retrieve
10       or set device attributes
11

SYNOPSIS

13       #include <libudev.h>
14
15       struct udev_list_entry
16                                                                   *udev_device_get_devlinks_list_entry(struct udev_device *udev_device);
17
18       struct udev_list_entry
19                                                                     *udev_device_get_properties_list_entry(struct udev_device *udev_device);
20
21       struct udev_list_entry
22                                                               *udev_device_get_tags_list_entry(struct udev_device *udev_device);
23
24       struct udev_list_entry
25                                                                  *udev_device_get_sysattr_list_entry(struct udev_device *udev_device);
26
27       const char
28                                                  *udev_device_get_property_value(struct udev_device *udev_device,
29                                                  const char *key);
30
31       int udev_device_has_tag(struct udev_device *udev_device,
32                               const char *tag);
33
34       const char
35                                                 *udev_device_get_sysattr_value(struct udev_device *udev_device,
36                                                 const char *sysattr);
37
38       int udev_device_set_sysattr_value(struct udev_device *udev_device,
39                                         const char *sysattr,
40                                         const char *value);
41

RETURN VALUE

43       On success, udev_device_get_devlinks_list_entry(),
44       udev_device_get_properties_list_entry(),
45       udev_device_get_tags_list_entry() and
46       udev_device_get_sysattr_list_entry() return a pointer to the first
47       entry of the retrieved list. If that list is empty, or if an error
48       occurred, NULL is returned.
49
50       On success, udev_device_get_property_value() and
51       udev_device_get_sysattr_value() return a pointer to a constant string
52       of the requested value. On error, NULL is returned.
53
54       On success, udev_device_set_sysattr_value() returns an integer greater
55       than, or equal to, 0. On failure, a negative error code is returned.
56
57       On success, udev_device_has_tag() returns 1 or 0, depending on whether
58       the device has the given tag or not. On failure, a negative error code
59       is returned.
60

SEE ALSO

62       udev_new(3), udev_device_new_from_syspath(3),
63       udev_device_get_syspath(3), udev_enumerate_new(3),
64       udev_monitor_new_from_netlink(3), udev_list_entry(3), systemd(1),
65
66
67
68systemd 239                                             UDEV_DEVICE_HAS_TAG(3)
Impressum