MCPcopy Create free account
hub / github.com/apache/arrow / garrow_replace_substring_options_class_init

Function garrow_replace_substring_options_class_init

c_glib/arrow-glib/compute.cpp:9247–9308  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9245}
9246
9247static void
9248garrow_replace_substring_options_class_init(GArrowReplaceSubstringOptionsClass *klass)
9249{
9250 auto gobject_class = G_OBJECT_CLASS(klass);
9251
9252 gobject_class->set_property = garrow_replace_substring_options_set_property;
9253 gobject_class->get_property = garrow_replace_substring_options_get_property;
9254
9255 arrow::compute::ReplaceSubstringOptions options;
9256
9257 GParamSpec *spec;
9258 /**
9259 * GArrowReplaceSubstringOptions:pattern:
9260 *
9261 * Pattern to match, literal, or regular expression depending on which kernel is used.
9262 *
9263 * Since: 23.0.0
9264 */
9265 spec = g_param_spec_string(
9266 "pattern",
9267 "Pattern",
9268 "Pattern to match, literal, or regular expression depending on which kernel is used",
9269 options.pattern.c_str(),
9270 static_cast<GParamFlags>(G_PARAM_READWRITE));
9271 g_object_class_install_property(gobject_class,
9272 PROP_REPLACE_SUBSTRING_OPTIONS_PATTERN,
9273 spec);
9274
9275 /**
9276 * GArrowReplaceSubstringOptions:replacement:
9277 *
9278 * String to replace the pattern with.
9279 *
9280 * Since: 23.0.0
9281 */
9282 spec = g_param_spec_string("replacement",
9283 "Replacement",
9284 "String to replace the pattern with",
9285 options.replacement.c_str(),
9286 static_cast<GParamFlags>(G_PARAM_READWRITE));
9287 g_object_class_install_property(gobject_class,
9288 PROP_REPLACE_SUBSTRING_OPTIONS_REPLACEMENT,
9289 spec);
9290
9291 /**
9292 * GArrowReplaceSubstringOptions:max-replacements:
9293 *
9294 * Max number of substrings to replace (-1 means unbounded).
9295 *
9296 * Since: 23.0.0
9297 */
9298 spec = g_param_spec_int64("max-replacements",
9299 "Max Replacements",
9300 "Max number of substrings to replace (-1 means unbounded)",
9301 -1,
9302 G_MAXINT64,
9303 options.max_replacements,
9304 static_cast<GParamFlags>(G_PARAM_READWRITE));

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected