Remove prefix 'V' in struct names

This commit is contained in:
V2Ray committed 2015-09-12 22:11:54 +02:00
1 parent cc3fdb6ef4
commit 51670b223d
27 files changed
+201 -201

No files matched your search

+28
View File
@@ -0,0 +1,28 @@
package core
import (
"encoding/json"
)
// User is the user account that is used for connection to a Point
type User struct {
Id ID `json:"id"` // The ID of this User.
}
type ConnectionConfig struct {
Protocol string `json:"protocol"`
File string `json:"file"`
}
// Config is the config for Point server.
type Config struct {
Port uint16 `json:"port"` // Port of this Point server.
InboundConfig ConnectionConfig `json:"inbound"`
OutboundConfig ConnectionConfig `json:"outbound"`
}
func LoadConfig(rawConfig []byte) (Config, error) {
config := Config{}
err := json.Unmarshal(rawConfig, &config)
return config, err
}