| Top |
GflsBytesRegionBuilderGflsBytesRegionBuilder — Builds GflsBytesRegion objects |
GflsBytesRegionBuilder *
gfls_bytes_region_builder_new (void);
[skip]
Since: 0.4
void gfls_bytes_region_builder_append (GflsBytesRegionBuilder *builder,gsize sub_region_length,gboolean is_part_of_region);
Appends a sub-region at the end.
If is_part_of_region
is FALSE it creates a hole.
Contiguous sub-regions of the same kind are merged and will thus be treated
as a single sub-region. So you can conveniently call this function several
times in a row with the same value for is_part_of_region
.
In order to create a GflsBytesRegion that will traverse a whole GBytes, it
is required to call this function the right amount of times, even if it ends
with a hole. See also gfls_bytes_region_match_bytes().
builder |
||
sub_region_length |
the length of the sub-region. Must not be equal to 0. |
|
is_part_of_region |
whether the sub-region is part of the region. |
Since: 0.4
gsize
gfls_bytes_region_builder_get_current_size
(GflsBytesRegionBuilder *builder);
Since: 0.4
GflsBytesRegion * gfls_bytes_region_builder_free (GflsBytesRegionBuilder *builder,gboolean free_data);
Creates a GflsBytesRegion and frees builder
.
[skip]
Since: 0.4