Example #1
0
func init() {
	proxyconfig.RegisterOutboundConfig("vmess",
		func(data []byte) (interface{}, error) {
			rawConfig := new(Config)
			if err := json.Unmarshal(data, rawConfig); err != nil {
				return nil, err
			}
			return rawConfig, nil
		})
}
Example #2
0
func init() {
	config.RegisterOutboundConfig("freedom",
		func(data []byte) (interface{}, error) {
			return new(Config), nil
		})
}