github.com/iEvan-lhr/exciting-tool@v0.0.0-20230504054234-8e983f73cdd2/README.md (about) 1 # exciting-tool 2 3 [](https://opensource.org/licenses/Apache-2.0) 4 5 [English](./README.md) | [简体中文](./README-CN.md) 6 7 Excing-Tool is an ideal omnidirectional GO toolkit. The content involved includes: string processing (stitching, conversion, etc.), the log traversal of the structure (example), the automatic stitching and processing of the native SQL, and the more Convenient Map (under development), JSON parsing, HTTP request sending, and so on. 8 9 ## Remark information 10 11 The author does not guarantee to update the content in time, but will try his best to improve the document to help users use it. 12 13 Welcome everyone to help me :heart::heart::heart: 14 15 ## important hint ⚠⚠⚠⚠⚠ 16 17 ☠ Need GO version 1.18 or more ☠ 18 19 ☀ You can use the code of the Lowversion branch in the low version ☀ 20 21 Some functions may be unsafe, and some functions are only modified based on the GO native bag. Therefore, please pay attention to the use of some functions in actual use. I will mark as much as possible where possible problems may occur. 22 23 ## HOW TO USE 24 25 ```bash 26 go get https://github.com/iEvan-lhr/exciting-tool 27 ``` 28 29 ## full-featured String 30 31 Use the following code to construct a full -featured String 32 33 ```bash 34 tools.Make(str) 35 ``` 36 Common Functions 37 38 ✔The following functions support the use of String, full -featured String, [] byte as the parameters 39 40 ```plain 41 42 Function: 43 Index(str any) The next bid search, while supporting the Rune type retrieval 44 Append(join any) Add content to the string to support adding 45 all basic types and extension basic types 46 (including int, float, BOOL, int32, int16, string, str, byte, [] byte ...). 47 Can be added (PS: pointer is passed in) 48 Make(obj any) If the structure is used to construct and the structure 49 does not implement the String () method, 50 the full attribute printing will be performed. 51 The example is as follows: 52 ----------User---------- 53 Id:23132 54 Username:foo 55 Password:bar 56 Identity:324213 57 QrCode:982j32 58 DenKey:ansssss 59 TalkingKey:qwesad 60 ----------END---------- 61 FirstUpper() 62 FirstLower() 63 Check(str any) 64 RemoveLastStr(lens) 65 RemoveIndexStr(lens) 66 Spilt(str any) 67 CheckIsNull() 68 69 ``` 70 71 ## Error treatment 72 73 ```plain 74 75 Function: 76 ReturnValueByTwo() The return value after the automatic processing, 77 if the error is not empty, will panic(err) 78 ReturnValue() The return value after the automatic processing, 79 if the error is not empty, will log(err) 80 ExecGoFunc() The error task that can be automatically defined in the asynchronous 81 execution method internally is the asynchronous 82 execution of the error task that may occur 83 ExecError() 84 PanicError() 85 logError() 86 87 ```