123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596 |
- // Copyright © 2019 - 2020 Oscar Campos <oscar.campos@thepimpam.com>
- // Copyright © 2017 - William Edwards
- //
- // Licensed under the Apache License, Version 2.0 (the "License");
- // you may not use this file except in compliance with the License.
- // You may obtain a copy of the License at
- //
- // http://www.apache.org/licenses/LICENSE-2.0
- //
- // Unless required by applicable law or agreed to in writing, software
- // distributed under the License is distributed on an "AS IS" BASIS,
- // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- // See the License for the specific language governing permissions and
- // limitations under the License.
- package gdnative
- // ==================================================================
- // This file was autogenerated by PimPam GDNative-Go binding tools
- // Please do not modify this file, any change will be lost
- // ==================================================================
- /*
- #include "gdnative.gen.h"
- #include <gdnative/string.h>
- // Include all headers for now. TODO: Look up all the required
- // headers we need to import based on the method arguments and return types.
- #include <gdnative/aabb.h>
- #include <gdnative/array.h>
- #include <gdnative/basis.h>
- #include <gdnative/color.h>
- #include <gdnative/dictionary.h>
- #include <gdnative/gdnative.h>
- #include <gdnative/node_path.h>
- #include <gdnative/plane.h>
- #include <gdnative/pool_arrays.h>
- #include <gdnative/quat.h>
- #include <gdnative/rect2.h>
- #include <gdnative/rid.h>
- #include <gdnative/string.h>
- #include <gdnative/string_name.h>
- #include <gdnative/transform.h>
- #include <gdnative/transform2d.h>
- #include <gdnative/variant.h>
- #include <gdnative/vector2.h>
- #include <gdnative/vector3.h>
- #include <gdnative_api_struct.gen.h>
- */
- import "C"
- import "unsafe"
- // NewEmptyString will return a pointer to an empty
- // initialized String. This is primarily used in
- // conjunction with MethodBindPtrCall.
- func NewEmptyString() Pointer {
- var obj C.godot_string
- return Pointer{base: unsafe.Pointer(&obj)}
- }
- // NewPointerFromString will return an unsafe pointer to the given
- // object. This is primarily used in conjunction with MethodBindPtrCall.
- func NewPointerFromString(obj String) Pointer {
- return Pointer{base: unsafe.Pointer(obj.getBase())}
- }
- // NewStringFromPointer will return a String from the
- // given unsafe pointer. This is primarily used in conjunction with MethodBindPtrCall.
- func NewStringFromPointer(ptr Pointer) String {
- base := (*C.godot_string)(ptr.getBase())
- utfStr := C.go_godot_string_utf8(GDNative.api, base)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- type String string
- func (s String) getBase() *C.godot_string {
- return stringAsGodotString(string(s))
- }
- // OperatorIndex godot_string_operator_index [[godot_string * p_self] [const godot_int p_idx]] const wchar_t *
- func (gdt *String) OperatorIndex(idx Int) WcharT {
- arg0 := gdt.getBase()
- arg1 := idx.getBase()
- ret := C.go_godot_string_operator_index(GDNative.api, arg0, arg1)
- return newWcharT(ret)
- }
- // OperatorIndexConst godot_string_operator_index_const [[const godot_string * p_self] [const godot_int p_idx]] wchar_t
- func (gdt *String) OperatorIndexConst(idx Int) WcharT {
- arg0 := gdt.getBase()
- arg1 := idx.getBase()
- ret := C.go_godot_string_operator_index_const(GDNative.api, arg0, arg1)
- return newWcharT(&ret)
- }
- // WideStr godot_string_wide_str [[const godot_string * p_self]] const wchar_t *
- func (gdt *String) WideStr() WcharT {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_wide_str(GDNative.api, arg0)
- return newWcharT(ret)
- }
- // OperatorEqual godot_string_operator_equal [[const godot_string * p_self] [const godot_string * p_b]] godot_bool
- func (gdt *String) OperatorEqual(b String) Bool {
- arg0 := gdt.getBase()
- arg1 := b.getBase()
- ret := C.go_godot_string_operator_equal(GDNative.api, arg0, arg1)
- return Bool(ret)
- }
- // OperatorLess godot_string_operator_less [[const godot_string * p_self] [const godot_string * p_b]] godot_bool
- func (gdt *String) OperatorLess(b String) Bool {
- arg0 := gdt.getBase()
- arg1 := b.getBase()
- ret := C.go_godot_string_operator_less(GDNative.api, arg0, arg1)
- return Bool(ret)
- }
- // OperatorPlus godot_string_operator_plus [[const godot_string * p_self] [const godot_string * p_b]] godot_string
- func (gdt *String) OperatorPlus(b String) String {
- arg0 := gdt.getBase()
- arg1 := b.getBase()
- ret := C.go_godot_string_operator_plus(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Length godot_string_length [[const godot_string * p_self]] godot_int
- func (gdt *String) Length() Int {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_length(GDNative.api, arg0)
- return Int(ret)
- }
- // CasecmpTo godot_string_casecmp_to [[const godot_string * p_self] [const godot_string * p_str]] signed char
- func (gdt *String) CasecmpTo(str String) SignedChar {
- arg0 := gdt.getBase()
- arg1 := str.getBase()
- ret := C.go_godot_string_casecmp_to(GDNative.api, arg0, arg1)
- return SignedChar(ret)
- }
- // NocasecmpTo godot_string_nocasecmp_to [[const godot_string * p_self] [const godot_string * p_str]] signed char
- func (gdt *String) NocasecmpTo(str String) SignedChar {
- arg0 := gdt.getBase()
- arg1 := str.getBase()
- ret := C.go_godot_string_nocasecmp_to(GDNative.api, arg0, arg1)
- return SignedChar(ret)
- }
- // NaturalnocasecmpTo godot_string_naturalnocasecmp_to [[const godot_string * p_self] [const godot_string * p_str]] signed char
- func (gdt *String) NaturalnocasecmpTo(str String) SignedChar {
- arg0 := gdt.getBase()
- arg1 := str.getBase()
- ret := C.go_godot_string_naturalnocasecmp_to(GDNative.api, arg0, arg1)
- return SignedChar(ret)
- }
- // BeginsWith godot_string_begins_with [[const godot_string * p_self] [const godot_string * p_string]] godot_bool
- func (gdt *String) BeginsWith(str String) Bool {
- arg0 := gdt.getBase()
- arg1 := str.getBase()
- ret := C.go_godot_string_begins_with(GDNative.api, arg0, arg1)
- return Bool(ret)
- }
- // BeginsWithCharArray godot_string_begins_with_char_array [[const godot_string * p_self] [const char * p_char_array]] godot_bool
- func (gdt *String) BeginsWithCharArray(charArray Char) Bool {
- arg0 := gdt.getBase()
- arg1 := charArray.getBase()
- ret := C.go_godot_string_begins_with_char_array(GDNative.api, arg0, arg1)
- return Bool(ret)
- }
- // Bigrams godot_string_bigrams [[const godot_string * p_self]] godot_array
- func (gdt *String) Bigrams() Array {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_bigrams(GDNative.api, arg0)
- return Array{base: &ret}
- }
- // EndsWith godot_string_ends_with [[const godot_string * p_self] [const godot_string * p_string]] godot_bool
- func (gdt *String) EndsWith(str String) Bool {
- arg0 := gdt.getBase()
- arg1 := str.getBase()
- ret := C.go_godot_string_ends_with(GDNative.api, arg0, arg1)
- return Bool(ret)
- }
- // Find godot_string_find [[const godot_string * p_self] [godot_string p_what]] godot_int
- func (gdt *String) Find(what String) Int {
- arg0 := gdt.getBase()
- arg1 := what.getBase()
- ret := C.go_godot_string_find(GDNative.api, arg0, *arg1)
- return Int(ret)
- }
- // FindFrom godot_string_find_from [[const godot_string * p_self] [godot_string p_what] [godot_int p_from]] godot_int
- func (gdt *String) FindFrom(what String, from Int) Int {
- arg0 := gdt.getBase()
- arg1 := what.getBase()
- arg2 := from.getBase()
- ret := C.go_godot_string_find_from(GDNative.api, arg0, *arg1, arg2)
- return Int(ret)
- }
- // Findmk godot_string_findmk [[const godot_string * p_self] [const godot_array * p_keys]] godot_int
- func (gdt *String) Findmk(keys Array) Int {
- arg0 := gdt.getBase()
- arg1 := keys.getBase()
- ret := C.go_godot_string_findmk(GDNative.api, arg0, arg1)
- return Int(ret)
- }
- // FindmkFrom godot_string_findmk_from [[const godot_string * p_self] [const godot_array * p_keys] [godot_int p_from]] godot_int
- func (gdt *String) FindmkFrom(keys Array, from Int) Int {
- arg0 := gdt.getBase()
- arg1 := keys.getBase()
- arg2 := from.getBase()
- ret := C.go_godot_string_findmk_from(GDNative.api, arg0, arg1, arg2)
- return Int(ret)
- }
- // FindmkFromInPlace godot_string_findmk_from_in_place [[const godot_string * p_self] [const godot_array * p_keys] [godot_int p_from] [godot_int * r_key]] godot_int
- func (gdt *String) FindmkFromInPlace(keys Array, from Int, key Int) Int {
- arg0 := gdt.getBase()
- arg1 := keys.getBase()
- arg2 := from.getBase()
- arg3 := key.getBase()
- ret := C.go_godot_string_findmk_from_in_place(GDNative.api, arg0, arg1, arg2, &arg3)
- return Int(ret)
- }
- // Findn godot_string_findn [[const godot_string * p_self] [godot_string p_what]] godot_int
- func (gdt *String) Findn(what String) Int {
- arg0 := gdt.getBase()
- arg1 := what.getBase()
- ret := C.go_godot_string_findn(GDNative.api, arg0, *arg1)
- return Int(ret)
- }
- // FindnFrom godot_string_findn_from [[const godot_string * p_self] [godot_string p_what] [godot_int p_from]] godot_int
- func (gdt *String) FindnFrom(what String, from Int) Int {
- arg0 := gdt.getBase()
- arg1 := what.getBase()
- arg2 := from.getBase()
- ret := C.go_godot_string_findn_from(GDNative.api, arg0, *arg1, arg2)
- return Int(ret)
- }
- // FindLast godot_string_find_last [[const godot_string * p_self] [godot_string p_what]] godot_int
- func (gdt *String) FindLast(what String) Int {
- arg0 := gdt.getBase()
- arg1 := what.getBase()
- ret := C.go_godot_string_find_last(GDNative.api, arg0, *arg1)
- return Int(ret)
- }
- // Format godot_string_format [[const godot_string * p_self] [const godot_variant * p_values]] godot_string
- func (gdt *String) Format(values Variant) String {
- arg0 := gdt.getBase()
- arg1 := values.getBase()
- ret := C.go_godot_string_format(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // FormatWithCustomPlaceholder godot_string_format_with_custom_placeholder [[const godot_string * p_self] [const godot_variant * p_values] [const char * p_placeholder]] godot_string
- func (gdt *String) FormatWithCustomPlaceholder(values Variant, placeholder Char) String {
- arg0 := gdt.getBase()
- arg1 := values.getBase()
- arg2 := placeholder.getBase()
- ret := C.go_godot_string_format_with_custom_placeholder(GDNative.api, arg0, arg1, arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // HexToInt godot_string_hex_to_int [[const godot_string * p_self]] godot_int
- func (gdt *String) HexToInt() Int {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_hex_to_int(GDNative.api, arg0)
- return Int(ret)
- }
- // HexToIntWithoutPrefix godot_string_hex_to_int_without_prefix [[const godot_string * p_self]] godot_int
- func (gdt *String) HexToIntWithoutPrefix() Int {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_hex_to_int_without_prefix(GDNative.api, arg0)
- return Int(ret)
- }
- // Insert godot_string_insert [[const godot_string * p_self] [godot_int p_at_pos] [godot_string p_string]] godot_string
- func (gdt *String) Insert(atPos Int, str String) String {
- arg0 := gdt.getBase()
- arg1 := atPos.getBase()
- arg2 := str.getBase()
- ret := C.go_godot_string_insert(GDNative.api, arg0, arg1, *arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // IsNumeric godot_string_is_numeric [[const godot_string * p_self]] godot_bool
- func (gdt *String) IsNumeric() Bool {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_is_numeric(GDNative.api, arg0)
- return Bool(ret)
- }
- // IsSubsequenceOf godot_string_is_subsequence_of [[const godot_string * p_self] [const godot_string * p_string]] godot_bool
- func (gdt *String) IsSubsequenceOf(str String) Bool {
- arg0 := gdt.getBase()
- arg1 := str.getBase()
- ret := C.go_godot_string_is_subsequence_of(GDNative.api, arg0, arg1)
- return Bool(ret)
- }
- // IsSubsequenceOfi godot_string_is_subsequence_ofi [[const godot_string * p_self] [const godot_string * p_string]] godot_bool
- func (gdt *String) IsSubsequenceOfi(str String) Bool {
- arg0 := gdt.getBase()
- arg1 := str.getBase()
- ret := C.go_godot_string_is_subsequence_ofi(GDNative.api, arg0, arg1)
- return Bool(ret)
- }
- // Lpad godot_string_lpad [[const godot_string * p_self] [godot_int p_min_length]] godot_string
- func (gdt *String) Lpad(minLength Int) String {
- arg0 := gdt.getBase()
- arg1 := minLength.getBase()
- ret := C.go_godot_string_lpad(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // LpadWithCustomCharacter godot_string_lpad_with_custom_character [[const godot_string * p_self] [godot_int p_min_length] [const godot_string * p_character]] godot_string
- func (gdt *String) LpadWithCustomCharacter(minLength Int, character String) String {
- arg0 := gdt.getBase()
- arg1 := minLength.getBase()
- arg2 := character.getBase()
- ret := C.go_godot_string_lpad_with_custom_character(GDNative.api, arg0, arg1, arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Match godot_string_match [[const godot_string * p_self] [const godot_string * p_wildcard]] godot_bool
- func (gdt *String) Match(wildcard String) Bool {
- arg0 := gdt.getBase()
- arg1 := wildcard.getBase()
- ret := C.go_godot_string_match(GDNative.api, arg0, arg1)
- return Bool(ret)
- }
- // Matchn godot_string_matchn [[const godot_string * p_self] [const godot_string * p_wildcard]] godot_bool
- func (gdt *String) Matchn(wildcard String) Bool {
- arg0 := gdt.getBase()
- arg1 := wildcard.getBase()
- ret := C.go_godot_string_matchn(GDNative.api, arg0, arg1)
- return Bool(ret)
- }
- // PadDecimals godot_string_pad_decimals [[const godot_string * p_self] [godot_int p_digits]] godot_string
- func (gdt *String) PadDecimals(digits Int) String {
- arg0 := gdt.getBase()
- arg1 := digits.getBase()
- ret := C.go_godot_string_pad_decimals(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // PadZeros godot_string_pad_zeros [[const godot_string * p_self] [godot_int p_digits]] godot_string
- func (gdt *String) PadZeros(digits Int) String {
- arg0 := gdt.getBase()
- arg1 := digits.getBase()
- ret := C.go_godot_string_pad_zeros(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // ReplaceFirst godot_string_replace_first [[const godot_string * p_self] [godot_string p_key] [godot_string p_with]] godot_string
- func (gdt *String) ReplaceFirst(key String, with String) String {
- arg0 := gdt.getBase()
- arg1 := key.getBase()
- arg2 := with.getBase()
- ret := C.go_godot_string_replace_first(GDNative.api, arg0, *arg1, *arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Replace godot_string_replace [[const godot_string * p_self] [godot_string p_key] [godot_string p_with]] godot_string
- func (gdt *String) Replace(key String, with String) String {
- arg0 := gdt.getBase()
- arg1 := key.getBase()
- arg2 := with.getBase()
- ret := C.go_godot_string_replace(GDNative.api, arg0, *arg1, *arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Replacen godot_string_replacen [[const godot_string * p_self] [godot_string p_key] [godot_string p_with]] godot_string
- func (gdt *String) Replacen(key String, with String) String {
- arg0 := gdt.getBase()
- arg1 := key.getBase()
- arg2 := with.getBase()
- ret := C.go_godot_string_replacen(GDNative.api, arg0, *arg1, *arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Rfind godot_string_rfind [[const godot_string * p_self] [godot_string p_what]] godot_int
- func (gdt *String) Rfind(what String) Int {
- arg0 := gdt.getBase()
- arg1 := what.getBase()
- ret := C.go_godot_string_rfind(GDNative.api, arg0, *arg1)
- return Int(ret)
- }
- // Rfindn godot_string_rfindn [[const godot_string * p_self] [godot_string p_what]] godot_int
- func (gdt *String) Rfindn(what String) Int {
- arg0 := gdt.getBase()
- arg1 := what.getBase()
- ret := C.go_godot_string_rfindn(GDNative.api, arg0, *arg1)
- return Int(ret)
- }
- // RfindFrom godot_string_rfind_from [[const godot_string * p_self] [godot_string p_what] [godot_int p_from]] godot_int
- func (gdt *String) RfindFrom(what String, from Int) Int {
- arg0 := gdt.getBase()
- arg1 := what.getBase()
- arg2 := from.getBase()
- ret := C.go_godot_string_rfind_from(GDNative.api, arg0, *arg1, arg2)
- return Int(ret)
- }
- // RfindnFrom godot_string_rfindn_from [[const godot_string * p_self] [godot_string p_what] [godot_int p_from]] godot_int
- func (gdt *String) RfindnFrom(what String, from Int) Int {
- arg0 := gdt.getBase()
- arg1 := what.getBase()
- arg2 := from.getBase()
- ret := C.go_godot_string_rfindn_from(GDNative.api, arg0, *arg1, arg2)
- return Int(ret)
- }
- // Rpad godot_string_rpad [[const godot_string * p_self] [godot_int p_min_length]] godot_string
- func (gdt *String) Rpad(minLength Int) String {
- arg0 := gdt.getBase()
- arg1 := minLength.getBase()
- ret := C.go_godot_string_rpad(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // RpadWithCustomCharacter godot_string_rpad_with_custom_character [[const godot_string * p_self] [godot_int p_min_length] [const godot_string * p_character]] godot_string
- func (gdt *String) RpadWithCustomCharacter(minLength Int, character String) String {
- arg0 := gdt.getBase()
- arg1 := minLength.getBase()
- arg2 := character.getBase()
- ret := C.go_godot_string_rpad_with_custom_character(GDNative.api, arg0, arg1, arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Similarity godot_string_similarity [[const godot_string * p_self] [const godot_string * p_string]] godot_real
- func (gdt *String) Similarity(str String) Real {
- arg0 := gdt.getBase()
- arg1 := str.getBase()
- ret := C.go_godot_string_similarity(GDNative.api, arg0, arg1)
- return Real(ret)
- }
- // Sprintf godot_string_sprintf [[const godot_string * p_self] [const godot_array * p_values] [godot_bool * p_error]] godot_string
- func (gdt *String) Sprintf(values Array, error Bool) String {
- arg0 := gdt.getBase()
- arg1 := values.getBase()
- arg2 := error.getBase()
- ret := C.go_godot_string_sprintf(GDNative.api, arg0, arg1, &arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Substr godot_string_substr [[const godot_string * p_self] [godot_int p_from] [godot_int p_chars]] godot_string
- func (gdt *String) Substr(from Int, chars Int) String {
- arg0 := gdt.getBase()
- arg1 := from.getBase()
- arg2 := chars.getBase()
- ret := C.go_godot_string_substr(GDNative.api, arg0, arg1, arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // ToDouble godot_string_to_double [[const godot_string * p_self]] double
- func (gdt *String) ToDouble() Double {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_to_double(GDNative.api, arg0)
- return Double(ret)
- }
- // ToFloat godot_string_to_float [[const godot_string * p_self]] godot_real
- func (gdt *String) ToFloat() Real {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_to_float(GDNative.api, arg0)
- return Real(ret)
- }
- // ToInt godot_string_to_int [[const godot_string * p_self]] godot_int
- func (gdt *String) ToInt() Int {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_to_int(GDNative.api, arg0)
- return Int(ret)
- }
- // CamelcaseToUnderscore godot_string_camelcase_to_underscore [[const godot_string * p_self]] godot_string
- func (gdt *String) CamelcaseToUnderscore() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_camelcase_to_underscore(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // CamelcaseToUnderscoreLowercased godot_string_camelcase_to_underscore_lowercased [[const godot_string * p_self]] godot_string
- func (gdt *String) CamelcaseToUnderscoreLowercased() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_camelcase_to_underscore_lowercased(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Capitalize godot_string_capitalize [[const godot_string * p_self]] godot_string
- func (gdt *String) Capitalize() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_capitalize(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // HexToInt64 godot_string_hex_to_int64 [[const godot_string * p_self]] int64_t
- func (gdt *String) HexToInt64() Int64T {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_hex_to_int64(GDNative.api, arg0)
- return Int64T(ret)
- }
- // HexToInt64WithPrefix godot_string_hex_to_int64_with_prefix [[const godot_string * p_self]] int64_t
- func (gdt *String) HexToInt64WithPrefix() Int64T {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_hex_to_int64_with_prefix(GDNative.api, arg0)
- return Int64T(ret)
- }
- // ToInt64 godot_string_to_int64 [[const godot_string * p_self]] int64_t
- func (gdt *String) ToInt64() Int64T {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_to_int64(GDNative.api, arg0)
- return Int64T(ret)
- }
- // GetSliceCount godot_string_get_slice_count [[const godot_string * p_self] [godot_string p_splitter]] godot_int
- func (gdt *String) GetSliceCount(splitter String) Int {
- arg0 := gdt.getBase()
- arg1 := splitter.getBase()
- ret := C.go_godot_string_get_slice_count(GDNative.api, arg0, *arg1)
- return Int(ret)
- }
- // GetSlice godot_string_get_slice [[const godot_string * p_self] [godot_string p_splitter] [godot_int p_slice]] godot_string
- func (gdt *String) GetSlice(splitter String, slice Int) String {
- arg0 := gdt.getBase()
- arg1 := splitter.getBase()
- arg2 := slice.getBase()
- ret := C.go_godot_string_get_slice(GDNative.api, arg0, *arg1, arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // GetSlicec godot_string_get_slicec [[const godot_string * p_self] [wchar_t p_splitter] [godot_int p_slice]] godot_string
- func (gdt *String) GetSlicec(splitter WcharT, slice Int) String {
- arg0 := gdt.getBase()
- arg1 := splitter.getBase()
- arg2 := slice.getBase()
- ret := C.go_godot_string_get_slicec(GDNative.api, arg0, *arg1, arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Split godot_string_split [[const godot_string * p_self] [const godot_string * p_splitter]] godot_array
- func (gdt *String) Split(splitter String) Array {
- arg0 := gdt.getBase()
- arg1 := splitter.getBase()
- ret := C.go_godot_string_split(GDNative.api, arg0, arg1)
- return Array{base: &ret}
- }
- // SplitAllowEmpty godot_string_split_allow_empty [[const godot_string * p_self] [const godot_string * p_splitter]] godot_array
- func (gdt *String) SplitAllowEmpty(splitter String) Array {
- arg0 := gdt.getBase()
- arg1 := splitter.getBase()
- ret := C.go_godot_string_split_allow_empty(GDNative.api, arg0, arg1)
- return Array{base: &ret}
- }
- // SplitFloats godot_string_split_floats [[const godot_string * p_self] [const godot_string * p_splitter]] godot_array
- func (gdt *String) SplitFloats(splitter String) Array {
- arg0 := gdt.getBase()
- arg1 := splitter.getBase()
- ret := C.go_godot_string_split_floats(GDNative.api, arg0, arg1)
- return Array{base: &ret}
- }
- // SplitFloatsAllowsEmpty godot_string_split_floats_allows_empty [[const godot_string * p_self] [const godot_string * p_splitter]] godot_array
- func (gdt *String) SplitFloatsAllowsEmpty(splitter String) Array {
- arg0 := gdt.getBase()
- arg1 := splitter.getBase()
- ret := C.go_godot_string_split_floats_allows_empty(GDNative.api, arg0, arg1)
- return Array{base: &ret}
- }
- // SplitFloatsMk godot_string_split_floats_mk [[const godot_string * p_self] [const godot_array * p_splitters]] godot_array
- func (gdt *String) SplitFloatsMk(splitters Array) Array {
- arg0 := gdt.getBase()
- arg1 := splitters.getBase()
- ret := C.go_godot_string_split_floats_mk(GDNative.api, arg0, arg1)
- return Array{base: &ret}
- }
- // SplitFloatsMkAllowsEmpty godot_string_split_floats_mk_allows_empty [[const godot_string * p_self] [const godot_array * p_splitters]] godot_array
- func (gdt *String) SplitFloatsMkAllowsEmpty(splitters Array) Array {
- arg0 := gdt.getBase()
- arg1 := splitters.getBase()
- ret := C.go_godot_string_split_floats_mk_allows_empty(GDNative.api, arg0, arg1)
- return Array{base: &ret}
- }
- // SplitInts godot_string_split_ints [[const godot_string * p_self] [const godot_string * p_splitter]] godot_array
- func (gdt *String) SplitInts(splitter String) Array {
- arg0 := gdt.getBase()
- arg1 := splitter.getBase()
- ret := C.go_godot_string_split_ints(GDNative.api, arg0, arg1)
- return Array{base: &ret}
- }
- // SplitIntsAllowsEmpty godot_string_split_ints_allows_empty [[const godot_string * p_self] [const godot_string * p_splitter]] godot_array
- func (gdt *String) SplitIntsAllowsEmpty(splitter String) Array {
- arg0 := gdt.getBase()
- arg1 := splitter.getBase()
- ret := C.go_godot_string_split_ints_allows_empty(GDNative.api, arg0, arg1)
- return Array{base: &ret}
- }
- // SplitIntsMk godot_string_split_ints_mk [[const godot_string * p_self] [const godot_array * p_splitters]] godot_array
- func (gdt *String) SplitIntsMk(splitters Array) Array {
- arg0 := gdt.getBase()
- arg1 := splitters.getBase()
- ret := C.go_godot_string_split_ints_mk(GDNative.api, arg0, arg1)
- return Array{base: &ret}
- }
- // SplitIntsMkAllowsEmpty godot_string_split_ints_mk_allows_empty [[const godot_string * p_self] [const godot_array * p_splitters]] godot_array
- func (gdt *String) SplitIntsMkAllowsEmpty(splitters Array) Array {
- arg0 := gdt.getBase()
- arg1 := splitters.getBase()
- ret := C.go_godot_string_split_ints_mk_allows_empty(GDNative.api, arg0, arg1)
- return Array{base: &ret}
- }
- // SplitSpaces godot_string_split_spaces [[const godot_string * p_self]] godot_array
- func (gdt *String) SplitSpaces() Array {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_split_spaces(GDNative.api, arg0)
- return Array{base: &ret}
- }
- // ToLower godot_string_to_lower [[const godot_string * p_self]] godot_string
- func (gdt *String) ToLower() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_to_lower(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // ToUpper godot_string_to_upper [[const godot_string * p_self]] godot_string
- func (gdt *String) ToUpper() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_to_upper(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // GetBasename godot_string_get_basename [[const godot_string * p_self]] godot_string
- func (gdt *String) GetBasename() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_get_basename(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // GetExtension godot_string_get_extension [[const godot_string * p_self]] godot_string
- func (gdt *String) GetExtension() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_get_extension(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Left godot_string_left [[const godot_string * p_self] [godot_int p_pos]] godot_string
- func (gdt *String) Left(pos Int) String {
- arg0 := gdt.getBase()
- arg1 := pos.getBase()
- ret := C.go_godot_string_left(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // OrdAt godot_string_ord_at [[const godot_string * p_self] [godot_int p_idx]] wchar_t
- func (gdt *String) OrdAt(idx Int) WcharT {
- arg0 := gdt.getBase()
- arg1 := idx.getBase()
- ret := C.go_godot_string_ord_at(GDNative.api, arg0, arg1)
- return newWcharT(&ret)
- }
- // PlusFile godot_string_plus_file [[const godot_string * p_self] [const godot_string * p_file]] godot_string
- func (gdt *String) PlusFile(file String) String {
- arg0 := gdt.getBase()
- arg1 := file.getBase()
- ret := C.go_godot_string_plus_file(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Right godot_string_right [[const godot_string * p_self] [godot_int p_pos]] godot_string
- func (gdt *String) Right(pos Int) String {
- arg0 := gdt.getBase()
- arg1 := pos.getBase()
- ret := C.go_godot_string_right(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // StripEdges godot_string_strip_edges [[const godot_string * p_self] [godot_bool p_left] [godot_bool p_right]] godot_string
- func (gdt *String) StripEdges(left Bool, right Bool) String {
- arg0 := gdt.getBase()
- arg1 := left.getBase()
- arg2 := right.getBase()
- ret := C.go_godot_string_strip_edges(GDNative.api, arg0, arg1, arg2)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // StripEscapes godot_string_strip_escapes [[const godot_string * p_self]] godot_string
- func (gdt *String) StripEscapes() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_strip_escapes(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Erase godot_string_erase [[godot_string * p_self] [godot_int p_pos] [godot_int p_chars]] void
- func (gdt *String) Erase(pos Int, chars Int) {
- arg0 := gdt.getBase()
- arg1 := pos.getBase()
- arg2 := chars.getBase()
- C.go_godot_string_erase(GDNative.api, arg0, arg1, arg2)
- }
- // Ascii godot_string_ascii [[const godot_string * p_self]] godot_char_string
- func (gdt *String) Ascii() CharString {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_ascii(GDNative.api, arg0)
- return CharString{base: &ret}
- }
- // AsciiExtended godot_string_ascii_extended [[const godot_string * p_self]] godot_char_string
- func (gdt *String) AsciiExtended() CharString {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_ascii_extended(GDNative.api, arg0)
- return CharString{base: &ret}
- }
- // Utf8 godot_string_utf8 [[const godot_string * p_self]] godot_char_string
- func (gdt *String) Utf8() CharString {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_utf8(GDNative.api, arg0)
- return CharString{base: &ret}
- }
- // ParseUtf8 godot_string_parse_utf8 [[godot_string * p_self] [const char * p_utf8]] godot_bool
- func (gdt *String) ParseUtf8(utf8 Char) Bool {
- arg0 := gdt.getBase()
- arg1 := utf8.getBase()
- ret := C.go_godot_string_parse_utf8(GDNative.api, arg0, arg1)
- return Bool(ret)
- }
- // ParseUtf8WithLen godot_string_parse_utf8_with_len [[godot_string * p_self] [const char * p_utf8] [godot_int p_len]] godot_bool
- func (gdt *String) ParseUtf8WithLen(utf8 Char, len Int) Bool {
- arg0 := gdt.getBase()
- arg1 := utf8.getBase()
- arg2 := len.getBase()
- ret := C.go_godot_string_parse_utf8_with_len(GDNative.api, arg0, arg1, arg2)
- return Bool(ret)
- }
- // Hash godot_string_hash [[const godot_string * p_self]] uint32_t
- func (gdt *String) Hash() Uint32T {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_hash(GDNative.api, arg0)
- return Uint32T(ret)
- }
- // Hash64 godot_string_hash64 [[const godot_string * p_self]] uint64_t
- func (gdt *String) Hash64() Uint64T {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_hash64(GDNative.api, arg0)
- return Uint64T(ret)
- }
- // Md5Buffer godot_string_md5_buffer [[const godot_string * p_self]] godot_pool_byte_array
- func (gdt *String) Md5Buffer() PoolByteArray {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_md5_buffer(GDNative.api, arg0)
- return PoolByteArray{base: &ret}
- }
- // Md5Text godot_string_md5_text [[const godot_string * p_self]] godot_string
- func (gdt *String) Md5Text() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_md5_text(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Sha256Buffer godot_string_sha256_buffer [[const godot_string * p_self]] godot_pool_byte_array
- func (gdt *String) Sha256Buffer() PoolByteArray {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_sha256_buffer(GDNative.api, arg0)
- return PoolByteArray{base: &ret}
- }
- // Sha256Text godot_string_sha256_text [[const godot_string * p_self]] godot_string
- func (gdt *String) Sha256Text() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_sha256_text(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // Empty godot_string_empty [[const godot_string * p_self]] godot_bool
- func (gdt *String) Empty() Bool {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_empty(GDNative.api, arg0)
- return Bool(ret)
- }
- // GetBaseDir godot_string_get_base_dir [[const godot_string * p_self]] godot_string
- func (gdt *String) GetBaseDir() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_get_base_dir(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // GetFile godot_string_get_file [[const godot_string * p_self]] godot_string
- func (gdt *String) GetFile() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_get_file(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // IsAbsPath godot_string_is_abs_path [[const godot_string * p_self]] godot_bool
- func (gdt *String) IsAbsPath() Bool {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_is_abs_path(GDNative.api, arg0)
- return Bool(ret)
- }
- // IsRelPath godot_string_is_rel_path [[const godot_string * p_self]] godot_bool
- func (gdt *String) IsRelPath() Bool {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_is_rel_path(GDNative.api, arg0)
- return Bool(ret)
- }
- // IsResourceFile godot_string_is_resource_file [[const godot_string * p_self]] godot_bool
- func (gdt *String) IsResourceFile() Bool {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_is_resource_file(GDNative.api, arg0)
- return Bool(ret)
- }
- // PathTo godot_string_path_to [[const godot_string * p_self] [const godot_string * p_path]] godot_string
- func (gdt *String) PathTo(path String) String {
- arg0 := gdt.getBase()
- arg1 := path.getBase()
- ret := C.go_godot_string_path_to(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // PathToFile godot_string_path_to_file [[const godot_string * p_self] [const godot_string * p_path]] godot_string
- func (gdt *String) PathToFile(path String) String {
- arg0 := gdt.getBase()
- arg1 := path.getBase()
- ret := C.go_godot_string_path_to_file(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // SimplifyPath godot_string_simplify_path [[const godot_string * p_self]] godot_string
- func (gdt *String) SimplifyPath() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_simplify_path(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // CEscape godot_string_c_escape [[const godot_string * p_self]] godot_string
- func (gdt *String) CEscape() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_c_escape(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // CEscapeMultiline godot_string_c_escape_multiline [[const godot_string * p_self]] godot_string
- func (gdt *String) CEscapeMultiline() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_c_escape_multiline(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // CUnescape godot_string_c_unescape [[const godot_string * p_self]] godot_string
- func (gdt *String) CUnescape() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_c_unescape(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // HttpEscape godot_string_http_escape [[const godot_string * p_self]] godot_string
- func (gdt *String) HttpEscape() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_http_escape(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // HttpUnescape godot_string_http_unescape [[const godot_string * p_self]] godot_string
- func (gdt *String) HttpUnescape() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_http_unescape(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // JsonEscape godot_string_json_escape [[const godot_string * p_self]] godot_string
- func (gdt *String) JsonEscape() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_json_escape(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // WordWrap godot_string_word_wrap [[const godot_string * p_self] [godot_int p_chars_per_line]] godot_string
- func (gdt *String) WordWrap(charsPerLine Int) String {
- arg0 := gdt.getBase()
- arg1 := charsPerLine.getBase()
- ret := C.go_godot_string_word_wrap(GDNative.api, arg0, arg1)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // XmlEscape godot_string_xml_escape [[const godot_string * p_self]] godot_string
- func (gdt *String) XmlEscape() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_xml_escape(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // XmlEscapeWithQuotes godot_string_xml_escape_with_quotes [[const godot_string * p_self]] godot_string
- func (gdt *String) XmlEscapeWithQuotes() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_xml_escape_with_quotes(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // XmlUnescape godot_string_xml_unescape [[const godot_string * p_self]] godot_string
- func (gdt *String) XmlUnescape() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_xml_unescape(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // PercentDecode godot_string_percent_decode [[const godot_string * p_self]] godot_string
- func (gdt *String) PercentDecode() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_percent_decode(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // PercentEncode godot_string_percent_encode [[const godot_string * p_self]] godot_string
- func (gdt *String) PercentEncode() String {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_percent_encode(GDNative.api, arg0)
- utfStr := C.go_godot_string_utf8(GDNative.api, &ret)
- char := C.go_godot_char_string_get_data(GDNative.api, &utfStr)
- goStr := C.GoString(char)
- C.go_godot_char_string_destroy(GDNative.api, &utfStr)
- return String(goStr)
- }
- // IsValidFloat godot_string_is_valid_float [[const godot_string * p_self]] godot_bool
- func (gdt *String) IsValidFloat() Bool {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_is_valid_float(GDNative.api, arg0)
- return Bool(ret)
- }
- // IsValidHexNumber godot_string_is_valid_hex_number [[const godot_string * p_self] [godot_bool p_with_prefix]] godot_bool
- func (gdt *String) IsValidHexNumber(withPrefix Bool) Bool {
- arg0 := gdt.getBase()
- arg1 := withPrefix.getBase()
- ret := C.go_godot_string_is_valid_hex_number(GDNative.api, arg0, arg1)
- return Bool(ret)
- }
- // IsValidHtmlColor godot_string_is_valid_html_color [[const godot_string * p_self]] godot_bool
- func (gdt *String) IsValidHtmlColor() Bool {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_is_valid_html_color(GDNative.api, arg0)
- return Bool(ret)
- }
- // IsValidIdentifier godot_string_is_valid_identifier [[const godot_string * p_self]] godot_bool
- func (gdt *String) IsValidIdentifier() Bool {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_is_valid_identifier(GDNative.api, arg0)
- return Bool(ret)
- }
- // IsValidInteger godot_string_is_valid_integer [[const godot_string * p_self]] godot_bool
- func (gdt *String) IsValidInteger() Bool {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_is_valid_integer(GDNative.api, arg0)
- return Bool(ret)
- }
- // IsValidIpAddress godot_string_is_valid_ip_address [[const godot_string * p_self]] godot_bool
- func (gdt *String) IsValidIpAddress() Bool {
- arg0 := gdt.getBase()
- ret := C.go_godot_string_is_valid_ip_address(GDNative.api, arg0)
- return Bool(ret)
- }
- // Destroy godot_string_destroy [[godot_string * p_self]] void
- func (gdt *String) Destroy() {
- arg0 := gdt.getBase()
- C.go_godot_string_destroy(GDNative.api, arg0)
- }
- // NewEmptyCharString will return a pointer to an empty
- // initialized CharString. This is primarily used in
- // conjunction with MethodBindPtrCall.
- func NewEmptyCharString() Pointer {
- var obj C.godot_char_string
- return Pointer{base: unsafe.Pointer(&obj)}
- }
- // NewPointerFromCharString will return an unsafe pointer to the given
- // object. This is primarily used in conjunction with MethodBindPtrCall.
- func NewPointerFromCharString(obj CharString) Pointer {
- return Pointer{base: unsafe.Pointer(obj.getBase())}
- }
- // NewCharStringFromPointer will return a CharString from the
- // given unsafe pointer. This is primarily used in conjunction with MethodBindPtrCall.
- func NewCharStringFromPointer(ptr Pointer) CharString {
- return CharString{base: (*C.godot_char_string)(ptr.getBase())}
- }
- // CharString data structure wrapper
- type CharString struct {
- base *C.godot_char_string
- }
- // returns the wrapped C base data type for this type
- func (gdt CharString) getBase() *C.godot_char_string {
- return gdt.base
- }
|