Reflection of golang Foundation
Internal mechanism of variables
Variables in Go language are divided into two parts:
Type information: predefined meta information.Value information: it can change dynamically during program operation.
Reflection introduction
Reflection refers to the ability to access and modify the program itself during the running period of the program. W ...
Posted by rhysmeister on Tue, 12 Oct 2021 09:28:44 +0200
ebiten learning-infinite loop player
2021SC@SDUSC
Catalog
1. Preface
1. Description
2.ebiten package directory
3. Summary
2. Infinite Loop Audio
1. Package
2. Introducing packages
3. Start with main()
4.Layout method
5.Update logic
6.Draw drawing interface
7. Running results
8. Summary
3. Ending
1. Difficulties
2. Next time
1. Preface
1. Description
audio ...
Posted by johnnyblotter on Sun, 10 Oct 2021 18:09:07 +0200
Detailed explanation of C&Golang function call process
The previous article talked about the call instruction calling the sum function in main.
At this time, the CPU jumps to sum and starts to execute the following commands:
0x0000000000400526 <+0>:push %rbp 0x0000000000400527 <+1>:mov %rsp,%rbp 0x000000000040052a <+4>:mov %edi,-0x14(%rbp) 0x000000000040052d < ...
Posted by anf.etienne on Sat, 09 Oct 2021 08:03:08 +0200
Control of Concurrent Tasks for Golang's Road to Growth
Control of concurrent tasks
In the previous section, we learned about the common concurrency modes of goroutine, channel, and go. In this article, we will explain the control of concurrent tasks in the GoLanguage.
Non-blocking waitNon-blocking wait is often used to determine which channel data transfers faster. We use select to determine if ...
Posted by toolman on Fri, 08 Oct 2021 21:09:51 +0200
Go learning is over
Go learning is over
Google open sourceCompiled languageLanguage in the 21st century (2007)
0.HelloWord
Create a file named hello.go, where. Go is the suffix of the go type file.
package main
import "fmt"
func main(){
fmt.Printf("Hello World!");
}
Then open cmd and enter the directory of the file: enter go bulid hello.go
Under win ...
Posted by wgh on Wed, 06 Oct 2021 15:36:37 +0200
Use Golang to build gRPC service and provide it to. NetCore client calls
gRPC overview
RPC
When it comes to gRPC, I have to mention RPC. The so-called RPC(remote procedure call) framework actually provides A set of mechanisms to enable communication between applications. In short, the functions written on machine A can be called directly on machine B through the RPC Protocol.
It differs from http in that:
RPC ...
Posted by adavis on Wed, 06 Oct 2021 03:34:10 +0200
How to cheat Go Mod?
hi, Hello, I'm haohongfan.
Recently, when I was doing the cortex optimization of prometheus ecology, I encountered a problem of go mod. Let's share it here.
Why do I call the title: how to cheat Go mod? This is very interesting. We'll sell it here first, but it really breaks through the relevant features of Go mod. (well, Cao Da's Go mod ten ...
Posted by Jibberish on Fri, 24 Sep 2021 17:16:24 +0200
@zabbix (5.0) client and server deployment and installation
zabbix (5.0) deployment and installation
www.zabbix.com [official website]
1, zabbix client
1)agent2 New version adopted golang Language development client
2)agent2 The default is 10050 port, that is zabbix Port of the client
# Old client: ZABBIX agent
# New version client: zabbix-agent2
2, Client Deployment (zabbix-agent2 installat ...
Posted by Joeker on Tue, 21 Sep 2021 11:11:05 +0200
Go -- Interface Type
1. Interfaces
An interface is a type (defined by the type keyword)An interface defines the behavior specification of an object. Only the specification is defined and not implemented. Specific objects implement the specifications in detail.Interfaces limit the methods that structures must implement
1. Interface type
In the Go language, an ...
Posted by Ammar on Tue, 21 Sep 2021 00:24:07 +0200
[Go Tour 2] process control statement
1, for
Go has only one loop structure: for Cycle.
Basic for The loop consists of three parts separated by semicolons:
Initialization statement: executed before the first iterationConditional expressions: evaluate before each iterationPost statement: executed at the end of each iteration
The initialization statement is us ...
Posted by Fitzlegend on Mon, 20 Sep 2021 18:21:37 +0200