Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/panjf2000/gnet
/ types & classes
Types & classes
122 in github.com/panjf2000/gnet
⨍
Functions
759
◇
Types & classes
122
↓ 1 callers
FuncType
RunnableFunc
RunnableFunc is an adapter to allow the use of ordinary function as a Runnable.
gnet.go:387
TypeAlias
Action
Action is an action that occurs after the completion of an event.
gnet.go:40
FuncType
AsyncCallback
AsyncCallback is a callback that will be invoked after the asynchronous function finishes. Note that the parameter gnet.Conn might have been already
gnet.go:306
Interface
AsyncTaskQueue
AsyncTaskQueue is a queue storing asynchronous tasks.
pkg/queue/queue.go:43
Struct
Buffer
Buffer is a circular buffer that implement io.ReaderWriter interface.
pkg/buffer/ring/ring_buffer.go:48
Struct
Buffer
Buffer combines ring-buffer and list-buffer. Ring-buffer is the top-priority buffer to store response data, gnet will only switch to list-buffer if th
pkg/buffer/elastic/elastic_ring_list_buffer.go:29
Struct
Buffer
Buffer is a linked list of node.
pkg/buffer/linkedlist/linked_list_buffer.go:35
Struct
BuiltinEventEngine
BuiltinEventEngine is a built-in implementation of EventHandler which feeds each method with an empty implementation, you can embed it within your cus
gnet.go:519
Struct
Client
Client of gnet.
client_unix.go:39
Struct
Client
client_windows.go:28
Interface
Conn
Conn is an interface of underlying connection.
gnet.go:424
Struct
Engine
Engine represents an engine context which provides some functions.
gnet.go:54
Interface
EventHandler
EventHandler represents the engine events' callbacks for the Run call. Each event has an Action return value that is used manage the state of the conn
gnet.go:486
Interface
EventLoop
EventLoop provides a set of methods for manipulating the event-loop.
gnet.go:401
TypeAlias
EventPriority
EventPriority is the priority of an event.
pkg/queue/queue.go:51
FuncType
Func
Func is the callback function executed by poller.
pkg/queue/queue.go:21
TypeAlias
GFD
GFD is a structure to store the fd, eventloop index, connStore indexes.
internal/gfd/gfd.go:50
TypeAlias
LoadBalancing
LoadBalancing represents the type of load-balancing algorithm.
load_balancer.go:25
Interface
Logger
Logger is used for logging formatted messages.
pkg/logging/logger.go:282
FuncType
Option
Option is a function that will set up option.
options.go:24
Struct
Option
Option is used for setting an option on socket.
pkg/socket/socket.go:28
Struct
Options
Options are configurations for the gnet application.
options.go:44
Struct
PollAttachment
PollAttachment is the user data which is about to be stored in "void *ptr" of epoll_data or "void *udata" of kevent.
pkg/netpoll/defs_poller.go:23
FuncType
PollEventHandler
PollEventHandler is the callback for I/O events notified by the poller.
pkg/netpoll/defs_poller.go:20
Struct
Poller
Poller represents a poller which is in charge of monitoring file-descriptors.
pkg/netpoll/poller_kqueue_ultimate.go:34
Struct
Poller
Poller represents a poller which is in charge of monitoring file-descriptors.
pkg/netpoll/poller_epoll_ultimate.go:34
Struct
Poller
Poller represents a poller which is in charge of monitoring file-descriptors.
pkg/netpoll/poller_epoll_default.go:35
Struct
Poller
Poller represents a poller which is in charge of monitoring file-descriptors.
pkg/netpoll/poller_kqueue_default.go:33
Struct
Pool
Pool represents ring-buffer pool. Distinct pools may be used for distinct types of byte buffers. Properly determined byte buffer types with their own
pkg/pool/ringbuffer/ringbuffer.go:49
Struct
Pool
Pool consists of 32 sync.Pool, representing byte slices of length from 0 to 32 in powers of 2.
pkg/pool/byteslice/byteslice.go:29
Interface
Reader
* type asyncCmdType uint8 const ( asyncCmdClose = iota + 1 asyncCmdWake asyncCmdWrite asyncCmdWritev ) type asyncCmd struct { fd gfd.GFD typ
gnet.go:232
Struct
RegisteredResult
RegisteredResult is the result of a Register call.
gnet.go:395
Struct
RingBuffer
RingBuffer is the elastic wrapper of ring.Buffer.
pkg/buffer/elastic/elastic_ring_buffer.go:26
Interface
Runnable
Runnable defines the common protocol of an execution on an event-loop. This interface should be implemented and passed to an event-loop in some way, t
gnet.go:381
Interface
Socket
Socket is a set of functions which manipulate the underlying file descriptor of a connection. Note that the methods in this interface are concurrency
gnet.go:312
TypeAlias
TCPSocketOpt
TCPSocketOpt is the type of TCP socket options.
options.go:35
Struct
Task
Task is a wrapper that contains function and its argument.
pkg/queue/queue.go:24
Interface
Writer
Writer is an interface that consists of a number of methods for writing that Conn must implement.
gnet.go:260
Struct
antsLogger
pkg/pool/goroutine/goroutine.go:49
Struct
args
pkg/math/math_test.go:6
Struct
asyncWriteHook
connection_unix.go:250
Struct
asyncWritevHook
connection_unix.go:271
Struct
baseLoadBalancer
baseLoadBalancer with base lb.
load_balancer.go:50
Struct
benchmarkServerGC
eventloop_unix_test.go:117
Struct
callSize
pkg/pool/ringbuffer/ringbuffer.go:142
TypeAlias
callSizes
pkg/pool/ringbuffer/ringbuffer.go:147
Struct
clientEvents
client_test.go:32
Struct
clientEventsForWake
client_test.go:587
Struct
clientReadOnEOF
client_test.go:770
Struct
clientSafeContextEvents
client_test.go:865
Struct
conn
connection_windows.go:54
Struct
conn
connection_unix.go:39
Struct
connContextKey
connContextKey is a key for net.Conn values in context.Context.
context.go:39
Struct
connHandler
client_test.go:26
Struct
connMatrix
conn_map.go:25
Struct
connMatrix
conn_matrix.go:25
Struct
connWithCallback
eventloop_unix.go:108
Struct
contextKey
contextKey is a key for Conn values in context.Context.
context.go:25
Struct
engine
engine_windows.go:29
Struct
engine
engine_unix.go:35
Struct
epollevent
pkg/netpoll/defs_linux_arm.go:9
Struct
epollevent
pkg/netpoll/defs_linux_arm64.go:8
Struct
epollevent
pkg/netpoll/defs_linux_ppc64le.go:8
Struct
epollevent
pkg/netpoll/defs_linux_s390x.go:9
Struct
epollevent
pkg/netpoll/defs_linux_riscv64.go:9
Struct
epollevent
pkg/netpoll/defs_linux_mips64x.go:9
Struct
epollevent
pkg/netpoll/defs_linux_ppc64.go:8
Struct
epollevent
pkg/netpoll/defs_linux_amd64.go:8
Struct
epollevent
pkg/netpoll/defs_linux_386.go:8
Struct
epollevent
pkg/netpoll/defs_linux_mipsx.go:9
Struct
eventList
pkg/netpoll/defs_poller_epoll.go:61
Struct
eventList
pkg/netpoll/defs_poller_kqueue.go:55
Struct
eventloop
eventloop_unix.go:42
Struct
eventloop
eventloop_windows.go:31
Struct
handleConn
conn_matrix_test.go:43
Struct
leastConnectionsLoadBalancer
leastConnectionsLoadBalancer with Least-Connections algorithm.
load_balancer.go:62
Struct
listener
listener_unix.go:34
Struct
listener
listener_windows.go:31
Interface
loadBalancer
loadBalancer is an interface which manipulates the event-loop set.
load_balancer.go:41
Struct
lockFreeQueue
lockFreeQueue is a simple, fast, and practical non-blocking and concurrent queue with no lock.
pkg/queue/lock_free_queue.go:86
TypeAlias
monotoneSeq
internal/gfd/gfd.go:41
Struct
netAddrContextKey
netAddrContextKey is a key for net.Addr values in context.Context.
context.go:53
Struct
netErr
connection_windows.go:35
Struct
node
pkg/queue/lock_free_queue.go:92
Struct
node
pkg/buffer/linkedlist/linked_list_buffer.go:25
Struct
openConn
connection_windows.go:49
Struct
prefixEncoder
pkg/logging/logger.go:126
Struct
roundRobinLoadBalancer
roundRobinLoadBalancer with Round-Robin algorithm.
load_balancer.go:56
Struct
safeCtxPayloadA
gnet_test.go:2745
Struct
safeCtxPayloadB
gnet_test.go:2746
Struct
serverEventsForWake
client_test.go:633
Struct
simServer
gnet_test.go:1740
Struct
sourceAddrHashLoadBalancer
sourceAddrHashLoadBalancer with Hash algorithm.
load_balancer.go:67
Struct
streamProxyServer
gnet_test.go:2165
Struct
tcpConn
connection_windows.go:40
Struct
testBadAddrServer
gnet_test.go:885
Struct
testBindToDeviceServer
os_unix_test.go:245
Struct
testClient
client_test.go:364
Struct
testCloseActionErrorServer
gnet_test.go:1089
Struct
testCloseActionOnOpenServer
gnet_test.go:1189
next →
1–100 of 122, ranked by callers