Learn Go: 9. Built in set - map

Learn what What is a map? How to create a map? Determine whether the key exists? How to get the map length? How to traverse a map? How to delete key / value pairs? Is map a reference type or a value type? concept map is an unordered set of key / value pairs, which is called dictionary, associative array, hash table and so on in other langua ...

Posted by hightechredneck on Tue, 28 Sep 2021 20:02:31 -0700

Learn Go: 8. Built in collection - Slicing

Learn what What is slicing? How do I create slices? How to get slice length and capacity? The relationship between slices and arrays? Operation slice specific elements? How are slice elements appended and removed? Is the slice a reference type or a value type? How do I copy slices? How do I create multidimensional slices? What is the slice st ...

Posted by Elemen7s on Tue, 28 Sep 2021 01:21:44 -0700

[security tools] talking about writing Java code audit tools

introduce The author is a senior student who is new to safety. If there are mistakes in the article, please point out! At first, it was considered to use pure matching, but this method is too strict, and the code written by programmers has various possible combinations Therefore, I tried to realize java lexical analysis and syntax analysis ...

Posted by tommyrulez on Mon, 27 Sep 2021 03:25:41 -0700

Learn Go: 2. Environment construction

I will explain the construction under Linux, Windows and Mac systems one by one, including the configuration of the editor. What to prepare? Go installation package: Win Go installation package,Linux Go package (binary),Mac Go package Git environment, Go downloads dependent packages with the help of GIT tools, which will not be explained here. ...

Posted by falcon8253 on Sun, 26 Sep 2021 19:01:36 -0700

Go golang Learning 7: Compiled as a library that can be invoked by C

Explain When you compile code using the go build or go install commands, you can use the -buildmode l to specify what file to generate. go build -buildmode=<mode> perhaps go install -buildmode=<mode> Use go help buildmode l to view all supported buildmodel options. -buildmode=archive Build the listed no ...

Posted by maybl8r03 on Sun, 26 Sep 2021 09:09:44 -0700

[Go open source treasure] Golang crawler | new tricks

Write in front Everyone may be tired of Python crawlers. Let's play with Golang crawlers! This article will be continuously updated! Mind map To get the original image or. xmind format, scan at the end of the text and reply to the Go crawler Golang provides the net/http package, which supports request and response natively ...

Posted by Cep on Tue, 21 Sep 2021 18:00:44 -0700

In depth analysis of macaron 2 Middleware in go web Framework

The article continues to look at how the framework executes handler and some other middleware Middleware format func(resp http.ResponseWriter, req *http.Request) func(ctx *macaron.Context)     func(resp http.ResponseWriter, req *http.Request,ctx *macaron.Context) Is it much more flexible than other web frameworks (* ~) ~ You can also custo ...

Posted by ArmyNation.Net on Tue, 21 Sep 2021 00:28:55 -0700

Learn to write down 6

function Start the function, which is almost beginning to enter the deep water of golang Function declaration In fact, when I started to write the first program using golang, I began to use the function, that is, the main function, but the simple main function has no parameter list and return value list. Unlike C language, the return value o ...

Posted by madmax on Mon, 20 Sep 2021 13:48:19 -0700

Golang practice record: using gin framework to realize forwarding function: forwarding using nginx

Recently, we need to implement a gadget to forward post requests to the specified back-end service. Because we always want to learn the gin framework, we use this framework to try. It is expected to produce several articles. This paper studies how to test the forwarding tool by using nginx container and back-end service. summary The forward ...

Posted by subkida on Mon, 20 Sep 2021 11:44:38 -0700

Kafka(Go) tutorial -- source code analysis of sarama client producer

From: month https://www.lixueduan.com Original text: https://www.lixueduan.com/post/kafka/06-sarama-producer/ This paper mainly analyzes the implementation principle of Kafka Go sarama client producer through the source code, including the specific steps of message distribution process, message packaging processing, and finally sending to Kaf ...

Posted by daz1034 on Mon, 20 Sep 2021 10:19:13 -0700