config.go 393 B

123456789101112131415161718192021222324
  1. package config
  2. type Type string
  3. const (
  4. TypeInbound = Type("inbound")
  5. TypeOutbound = Type("outbound")
  6. )
  7. type ConnectionConfig interface {
  8. Protocol() string
  9. Settings(configType Type) interface{}
  10. }
  11. type LogConfig interface {
  12. AccessLog() string
  13. }
  14. type PointConfig interface {
  15. Port() uint16
  16. LogConfig() LogConfig
  17. InboundConfig() ConnectionConfig
  18. OutboundConfig() ConnectionConfig
  19. }