diff options
author | Sébastien Helleu <flashcode@flashtux.org> | 2022-07-20 13:16:35 +0200 |
---|---|---|
committer | Sébastien Helleu <flashcode@flashtux.org> | 2022-07-20 13:16:35 +0200 |
commit | b7441bd7a30e1fdee837fad9923d372b4b283374 (patch) | |
tree | 1a27579f0d8bfeed77a2377f9245d6b6d6553238 /doc/sr/weechat_plugin_api.sr.adoc | |
parent | 62e68f965f7bce87eb0bf61bb134de5a3d3b7507 (diff) | |
download | weechat-b7441bd7a30e1fdee837fad9923d372b4b283374.zip |
api: add arguments "index_start" and "index_end" in function string_rebuild_split_string
Diffstat (limited to 'doc/sr/weechat_plugin_api.sr.adoc')
-rw-r--r-- | doc/sr/weechat_plugin_api.sr.adoc | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/doc/sr/weechat_plugin_api.sr.adoc b/doc/sr/weechat_plugin_api.sr.adoc index c3a8e182b..b3abeb02c 100644 --- a/doc/sr/weechat_plugin_api.sr.adoc +++ b/doc/sr/weechat_plugin_api.sr.adoc @@ -1713,20 +1713,32 @@ weechat_string_free_split (argv); ==== string_rebuild_split_string -Изграђује стринг од подељеног стринга. +_Ажурирано у верзији 3.7._ + +// TRANSLATION MISSING +Rebuild a string with a split string, using optional separator and index of +first/last string to use. Прототип: [source,c] ---- char *weechat_string_rebuild_split_string (char **split_string, - const char *separator); + const char *separator, + int index_start, int index_end); ---- Аргументи: * _split_string_: стринг подељен функцијом <<_string_split,string_split>> -* _separator_: стринг који се користи за раздвајање стрингова +// TRANSLATION MISSING +* _separator_: string used to separate strings (can be NULL or empty string) +// TRANSLATION MISSING +* _index_start_: index of first string to use (≥ 0) +// TRANSLATION MISSING +* _index_end_: index of last string to use + (must be ≥ _index_start_; special value -1 can be used to use all arguments + until NULL is found) Повратна вредност: @@ -1739,7 +1751,7 @@ C пример: char **argv; int argc; argv = weechat_string_split ("abc def ghi", " ", 0, 0, &argc); -char *str = weechat_string_rebuild_split_string (argv, ";"); +char *str = weechat_string_rebuild_split_string (argv, ";", 0, -1); /* str == "abc;def;ghi" */ /* ... */ free (str); |