You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
v2ray-core/vconfig.go

34 lines
752 B

9 years ago
package core
9 years ago
// User account that is used for connection to a VPoint
9 years ago
type VUser struct {
9 years ago
// The ID of this VUser. This ID is served as an access token.
// It is not necessary to be permanent.
9 years ago
id VID
9 years ago
}
9 years ago
// The next VPoint server in the connection chain.
type VNext struct {
// Address of VNext server, in the form of "IP:Port"
ServerAddress string
// User accounts for accessing VNext.
User []VUser
}
// The config for VPoint server.
9 years ago
type VConfig struct {
9 years ago
// Port of this VPoint server.
Port uint16
AllowedClients []VUser
ClientProtocol string
VNextList []VNext
9 years ago
}
type VConfigMarshaller interface {
9 years ago
Marshal(config VConfig) ([]byte, error)
9 years ago
}
type VConfigUnmarshaller interface {
9 years ago
Unmarshal(data []byte) (VConfig, error)
9 years ago
}