mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-03-21 01:55:49 +00:00
docs: add comments for all functions
This commit is contained in:
@@ -6,6 +6,8 @@ import (
|
||||
"github.com/mhsanaei/3x-ui/v2/util/json_util"
|
||||
)
|
||||
|
||||
// InboundConfig represents an Xray inbound configuration.
|
||||
// It defines how Xray accepts incoming connections including protocol, port, and settings.
|
||||
type InboundConfig struct {
|
||||
Listen json_util.RawMessage `json:"listen"` // listen cannot be an empty string
|
||||
Port int `json:"port"`
|
||||
@@ -16,6 +18,7 @@ type InboundConfig struct {
|
||||
Sniffing json_util.RawMessage `json:"sniffing"`
|
||||
}
|
||||
|
||||
// Equals compares two InboundConfig instances for deep equality.
|
||||
func (c *InboundConfig) Equals(other *InboundConfig) bool {
|
||||
if !bytes.Equal(c.Listen, other.Listen) {
|
||||
return false
|
||||
|
||||
Reference in New Issue
Block a user