Lines Matching refs:contents

1753                 const char *contents,
1763 assert(contents);
1768 if (!signature_is_single(contents, true))
1778 if (!startswith(c->signature + c->index + 1, contents))
1781 nindex = c->index + 1 + strlen(contents);
1790 e = strextend(&c->signature, CHAR_TO_STR(SD_BUS_TYPE_ARRAY), contents, NULL);
1800 alignment = bus_gvariant_get_alignment(contents);
1808 r = bus_gvariant_is_fixed_size(contents);
1819 alignment = bus_type_get_alignment(contents[0]);
1852 const char *contents) {
1856 assert(contents);
1858 if (!signature_is_single(contents, false))
1861 if (*contents == SD_BUS_TYPE_DICT_ENTRY_BEGIN)
1892 l = strlen(contents);
1898 memcpy((uint8_t*) a + 1, contents, l + 1);
1910 const char *contents,
1919 assert(contents);
1923 if (!signature_is_valid(contents, false))
1929 l = strlen(contents);
1932 !startswith(c->signature + c->index + 1, contents) ||
1943 e = strextend(&c->signature, CHAR_TO_STR(SD_BUS_TYPE_STRUCT_BEGIN), contents, CHAR_TO_STR(SD_BUS_TYPE_STRUCT_END), NULL);
1955 alignment = bus_gvariant_get_alignment(contents);
1962 r = bus_gvariant_is_fixed_size(contents);
1969 /* Align contents to 8 byte boundary */
1983 const char *contents,
1991 assert(contents);
1995 if (!signature_is_pair(contents))
2004 l = strlen(contents);
2007 !startswith(c->signature + c->index + 1, contents) ||
2016 alignment = bus_gvariant_get_alignment(contents);
2023 r = bus_gvariant_is_fixed_size(contents);
2030 /* Align contents to 8 byte boundary */
2041 const char *contents) {
2052 assert_return(contents, -EINVAL);
2063 signature = strdup(contents);
2075 r = bus_message_open_array(m, c, contents, &array_size, &begin, &need_offsets);
2077 r = bus_message_open_variant(m, c, contents);
2079 r = bus_message_open_struct(m, c, contents, &begin, &need_offsets);
2081 r = bus_message_open_dict_entry(m, c, contents, &begin, &need_offsets);
3612 const char *contents,
3624 assert(contents);
3630 if (!signature_is_single(contents, true))
3639 if (!startswith(c->signature + c->index + 1, contents))
3654 alignment = bus_type_get_alignment(contents[0]);
3671 } else if (bus_gvariant_is_fixed_size(contents)) {
3674 *item_size = bus_gvariant_get_size(contents);
3726 c->index += 1 + strlen(contents);
3734 const char *contents,
3744 assert(contents);
3747 if (!signature_is_single(contents, false))
3750 if (*contents == SD_BUS_TYPE_DICT_ENTRY_BEGIN)
3764 k = strlen(contents);
3776 if (memcmp((uint8_t*) q+1, contents, k))
3794 if (!streq(q, contents))
3954 const char *contents,
3963 assert(contents);
3976 /* gvariant with contents */
3977 return build_struct_offsets(m, contents, c->item_size, item_size, offsets, n_offsets);
3985 const char *contents,
3995 assert(contents);
4000 if (!signature_is_valid(contents, false))
4006 l = strlen(contents);
4009 !startswith(c->signature + c->index + 1, contents) ||
4013 r = enter_struct_or_dict_entry(m, c, contents, item_size, offsets, n_offsets);
4026 const char *contents,
4036 assert(contents);
4038 if (!signature_is_pair(contents))
4047 l = strlen(contents);
4050 !startswith(c->signature + c->index + 1, contents) ||
4054 r = enter_struct_or_dict_entry(m, c, contents, item_size, offsets, n_offsets);
4066 const char *contents) {
4077 assert_return(type != 0 || !contents, -EINVAL);
4079 if (type == 0 || !contents) {
4091 if (contents && !streq(contents, cc))
4095 contents = cc;
4128 signature = strdup(contents);
4136 r = bus_message_enter_array(m, c, contents, &array_size, &item_size, &offsets, &n_offsets);
4138 r = bus_message_enter_variant(m, c, contents, &item_size);
4140 r = bus_message_enter_struct(m, c, contents, &item_size, &offsets, &n_offsets);
4142 r = bus_message_enter_dict_entry(m, c, contents, &item_size, &offsets, &n_offsets);
4247 _public_ int sd_bus_message_peek_type(sd_bus_message *m, char *type, const char **contents) {
4263 if (contents)
4264 *contents = NULL;
4272 if (contents) {
4287 *contents = c->peeked_signature = sig;
4299 if (contents) {
4313 *contents = c->peeked_signature = sig;
4323 if (contents) {
4361 *contents = c->peeked_signature;
4378 *contents = q;
4393 if (contents)
4394 *contents = NULL;
4447 n_struct = strlen(types); /* length of current struct contents signature */
4728 const char *contents;
4731 r = sd_bus_message_peek_type(m, &x, &contents);
4738 r = sd_bus_message_enter_container(m, SD_BUS_TYPE_VARIANT, contents);
4742 r = sd_bus_message_skip(m, contents);
5634 const char *contents;
5637 r = sd_bus_message_peek_type(m, &type, &contents);
5645 !(type == SD_BUS_TYPE_ARRAY && STR_IN_SET(contents, "s", "o", "g")))
5650 *_contents = contents;
5681 const char *contents;
5688 r = bus_message_get_arg_skip(m, i, &type, &contents);
5694 if (!STR_IN_SET(contents, "s", "o", "g"))
5740 const char *contents;
5755 r = sd_bus_message_peek_type(source, &type, &contents);
5765 r = sd_bus_message_enter_container(source, type, contents);
5769 r = sd_bus_message_open_container(m, type, contents);
5809 _public_ int sd_bus_message_verify_type(sd_bus_message *m, char type, const char *contents) {
5817 assert_return(!contents || signature_is_valid(contents, true), -EINVAL);
5818 assert_return(type || contents, -EINVAL);
5819 assert_return(!contents || !type || bus_type_is_container(type), -EINVAL);
5828 if (contents && !streq_ptr(contents, c))