Documentation ¶
Overview ¶
Package policy is an implementation of policy.Manager feature.
Index ¶
- Variables
- type Config
- type Instance
- type Policy
- func (*Policy) Descriptor() ([]byte, []int)deprecated
- func (x *Policy) GetBuffer() *Policy_Buffer
- func (x *Policy) GetStats() *Policy_Stats
- func (x *Policy) GetTimeout() *Policy_Timeout
- func (*Policy) ProtoMessage()
- func (x *Policy) ProtoReflect() protoreflect.Message
- func (x *Policy) Reset()
- func (x *Policy) String() string
- func (p *Policy) ToCorePolicy() policy.Session
- type Policy_Buffer
- type Policy_Stats
- func (*Policy_Stats) Descriptor() ([]byte, []int)deprecated
- func (x *Policy_Stats) GetUserDownlink() bool
- func (x *Policy_Stats) GetUserUplink() bool
- func (*Policy_Stats) ProtoMessage()
- func (x *Policy_Stats) ProtoReflect() protoreflect.Message
- func (x *Policy_Stats) Reset()
- func (x *Policy_Stats) String() string
- type Policy_Timeout
- func (*Policy_Timeout) Descriptor() ([]byte, []int)deprecated
- func (x *Policy_Timeout) GetConnectionIdle() *Second
- func (x *Policy_Timeout) GetDownlinkOnly() *Second
- func (x *Policy_Timeout) GetHandshake() *Second
- func (x *Policy_Timeout) GetUplinkOnly() *Second
- func (*Policy_Timeout) ProtoMessage()
- func (x *Policy_Timeout) ProtoReflect() protoreflect.Message
- func (x *Policy_Timeout) Reset()
- func (x *Policy_Timeout) String() string
- type Second
- type SystemPolicy
- func (*SystemPolicy) Descriptor() ([]byte, []int)deprecated
- func (x *SystemPolicy) GetOverrideAccessLogDest() bool
- func (x *SystemPolicy) GetStats() *SystemPolicy_Stats
- func (*SystemPolicy) ProtoMessage()
- func (x *SystemPolicy) ProtoReflect() protoreflect.Message
- func (x *SystemPolicy) Reset()
- func (x *SystemPolicy) String() string
- func (p *SystemPolicy) ToCorePolicy() policy.System
- type SystemPolicy_Stats
- func (*SystemPolicy_Stats) Descriptor() ([]byte, []int)deprecated
- func (x *SystemPolicy_Stats) GetInboundDownlink() bool
- func (x *SystemPolicy_Stats) GetInboundUplink() bool
- func (x *SystemPolicy_Stats) GetOutboundDownlink() bool
- func (x *SystemPolicy_Stats) GetOutboundUplink() bool
- func (*SystemPolicy_Stats) ProtoMessage()
- func (x *SystemPolicy_Stats) ProtoReflect() protoreflect.Message
- func (x *SystemPolicy_Stats) Reset()
- func (x *SystemPolicy_Stats) String() string
Constants ¶
This section is empty.
Variables ¶
View Source
var File_app_policy_config_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Level map[uint32]*Policy `` /* 152-byte string literal not displayed */ System *SystemPolicy `protobuf:"bytes,2,opt,name=system,proto3" json:"system,omitempty"` // contains filtered or unexported fields }
func (*Config) Descriptor
deprecated
func (*Config) GetSystem ¶
func (x *Config) GetSystem() *SystemPolicy
func (*Config) ProtoMessage ¶
func (*Config) ProtoMessage()
func (*Config) ProtoReflect ¶
func (x *Config) ProtoReflect() protoreflect.Message
type Instance ¶
type Instance struct {
// contains filtered or unexported fields
}
Instance is an instance of Policy manager.
type Policy ¶
type Policy struct { Timeout *Policy_Timeout `protobuf:"bytes,1,opt,name=timeout,proto3" json:"timeout,omitempty"` Stats *Policy_Stats `protobuf:"bytes,2,opt,name=stats,proto3" json:"stats,omitempty"` Buffer *Policy_Buffer `protobuf:"bytes,3,opt,name=buffer,proto3" json:"buffer,omitempty"` // contains filtered or unexported fields }
func (*Policy) Descriptor
deprecated
func (*Policy) GetBuffer ¶
func (x *Policy) GetBuffer() *Policy_Buffer
func (*Policy) GetStats ¶
func (x *Policy) GetStats() *Policy_Stats
func (*Policy) GetTimeout ¶
func (x *Policy) GetTimeout() *Policy_Timeout
func (*Policy) ProtoMessage ¶
func (*Policy) ProtoMessage()
func (*Policy) ProtoReflect ¶
func (x *Policy) ProtoReflect() protoreflect.Message
func (*Policy) ToCorePolicy ¶
ToCorePolicy converts this Policy to policy.Session.
type Policy_Buffer ¶
type Policy_Buffer struct { // Buffer size per connection, in bytes. -1 for unlimited buffer. Connection int32 `protobuf:"varint,1,opt,name=connection,proto3" json:"connection,omitempty"` // contains filtered or unexported fields }
func (*Policy_Buffer) Descriptor
deprecated
func (*Policy_Buffer) Descriptor() ([]byte, []int)
Deprecated: Use Policy_Buffer.ProtoReflect.Descriptor instead.
func (*Policy_Buffer) GetConnection ¶
func (x *Policy_Buffer) GetConnection() int32
func (*Policy_Buffer) ProtoMessage ¶
func (*Policy_Buffer) ProtoMessage()
func (*Policy_Buffer) ProtoReflect ¶
func (x *Policy_Buffer) ProtoReflect() protoreflect.Message
func (*Policy_Buffer) Reset ¶
func (x *Policy_Buffer) Reset()
func (*Policy_Buffer) String ¶
func (x *Policy_Buffer) String() string
type Policy_Stats ¶
type Policy_Stats struct { UserUplink bool `protobuf:"varint,1,opt,name=user_uplink,json=userUplink,proto3" json:"user_uplink,omitempty"` UserDownlink bool `protobuf:"varint,2,opt,name=user_downlink,json=userDownlink,proto3" json:"user_downlink,omitempty"` // contains filtered or unexported fields }
func (*Policy_Stats) Descriptor
deprecated
func (*Policy_Stats) Descriptor() ([]byte, []int)
Deprecated: Use Policy_Stats.ProtoReflect.Descriptor instead.
func (*Policy_Stats) GetUserDownlink ¶
func (x *Policy_Stats) GetUserDownlink() bool
func (*Policy_Stats) GetUserUplink ¶
func (x *Policy_Stats) GetUserUplink() bool
func (*Policy_Stats) ProtoMessage ¶
func (*Policy_Stats) ProtoMessage()
func (*Policy_Stats) ProtoReflect ¶
func (x *Policy_Stats) ProtoReflect() protoreflect.Message
func (*Policy_Stats) Reset ¶
func (x *Policy_Stats) Reset()
func (*Policy_Stats) String ¶
func (x *Policy_Stats) String() string
type Policy_Timeout ¶
type Policy_Timeout struct { Handshake *Second `protobuf:"bytes,1,opt,name=handshake,proto3" json:"handshake,omitempty"` ConnectionIdle *Second `protobuf:"bytes,2,opt,name=connection_idle,json=connectionIdle,proto3" json:"connection_idle,omitempty"` UplinkOnly *Second `protobuf:"bytes,3,opt,name=uplink_only,json=uplinkOnly,proto3" json:"uplink_only,omitempty"` DownlinkOnly *Second `protobuf:"bytes,4,opt,name=downlink_only,json=downlinkOnly,proto3" json:"downlink_only,omitempty"` // contains filtered or unexported fields }
Timeout is a message for timeout settings in various stages, in seconds.
func (*Policy_Timeout) Descriptor
deprecated
func (*Policy_Timeout) Descriptor() ([]byte, []int)
Deprecated: Use Policy_Timeout.ProtoReflect.Descriptor instead.
func (*Policy_Timeout) GetConnectionIdle ¶
func (x *Policy_Timeout) GetConnectionIdle() *Second
func (*Policy_Timeout) GetDownlinkOnly ¶
func (x *Policy_Timeout) GetDownlinkOnly() *Second
func (*Policy_Timeout) GetHandshake ¶
func (x *Policy_Timeout) GetHandshake() *Second
func (*Policy_Timeout) GetUplinkOnly ¶
func (x *Policy_Timeout) GetUplinkOnly() *Second
func (*Policy_Timeout) ProtoMessage ¶
func (*Policy_Timeout) ProtoMessage()
func (*Policy_Timeout) ProtoReflect ¶
func (x *Policy_Timeout) ProtoReflect() protoreflect.Message
func (*Policy_Timeout) Reset ¶
func (x *Policy_Timeout) Reset()
func (*Policy_Timeout) String ¶
func (x *Policy_Timeout) String() string
type Second ¶
type Second struct { Value uint32 `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"` // contains filtered or unexported fields }
func (*Second) Descriptor
deprecated
func (*Second) ProtoMessage ¶
func (*Second) ProtoMessage()
func (*Second) ProtoReflect ¶
func (x *Second) ProtoReflect() protoreflect.Message
type SystemPolicy ¶
type SystemPolicy struct { Stats *SystemPolicy_Stats `protobuf:"bytes,1,opt,name=stats,proto3" json:"stats,omitempty"` OverrideAccessLogDest bool `` /* 129-byte string literal not displayed */ // contains filtered or unexported fields }
func (*SystemPolicy) Descriptor
deprecated
func (*SystemPolicy) Descriptor() ([]byte, []int)
Deprecated: Use SystemPolicy.ProtoReflect.Descriptor instead.
func (*SystemPolicy) GetOverrideAccessLogDest ¶
func (x *SystemPolicy) GetOverrideAccessLogDest() bool
func (*SystemPolicy) GetStats ¶
func (x *SystemPolicy) GetStats() *SystemPolicy_Stats
func (*SystemPolicy) ProtoMessage ¶
func (*SystemPolicy) ProtoMessage()
func (*SystemPolicy) ProtoReflect ¶
func (x *SystemPolicy) ProtoReflect() protoreflect.Message
func (*SystemPolicy) Reset ¶
func (x *SystemPolicy) Reset()
func (*SystemPolicy) String ¶
func (x *SystemPolicy) String() string
func (*SystemPolicy) ToCorePolicy ¶
func (p *SystemPolicy) ToCorePolicy() policy.System
ToCorePolicy converts this SystemPolicy to policy.System.
type SystemPolicy_Stats ¶
type SystemPolicy_Stats struct { InboundUplink bool `protobuf:"varint,1,opt,name=inbound_uplink,json=inboundUplink,proto3" json:"inbound_uplink,omitempty"` InboundDownlink bool `protobuf:"varint,2,opt,name=inbound_downlink,json=inboundDownlink,proto3" json:"inbound_downlink,omitempty"` OutboundUplink bool `protobuf:"varint,3,opt,name=outbound_uplink,json=outboundUplink,proto3" json:"outbound_uplink,omitempty"` OutboundDownlink bool `protobuf:"varint,4,opt,name=outbound_downlink,json=outboundDownlink,proto3" json:"outbound_downlink,omitempty"` // contains filtered or unexported fields }
func (*SystemPolicy_Stats) Descriptor
deprecated
func (*SystemPolicy_Stats) Descriptor() ([]byte, []int)
Deprecated: Use SystemPolicy_Stats.ProtoReflect.Descriptor instead.
func (*SystemPolicy_Stats) GetInboundDownlink ¶
func (x *SystemPolicy_Stats) GetInboundDownlink() bool
func (*SystemPolicy_Stats) GetInboundUplink ¶
func (x *SystemPolicy_Stats) GetInboundUplink() bool
func (*SystemPolicy_Stats) GetOutboundDownlink ¶
func (x *SystemPolicy_Stats) GetOutboundDownlink() bool
func (*SystemPolicy_Stats) GetOutboundUplink ¶
func (x *SystemPolicy_Stats) GetOutboundUplink() bool
func (*SystemPolicy_Stats) ProtoMessage ¶
func (*SystemPolicy_Stats) ProtoMessage()
func (*SystemPolicy_Stats) ProtoReflect ¶
func (x *SystemPolicy_Stats) ProtoReflect() protoreflect.Message
func (*SystemPolicy_Stats) Reset ¶
func (x *SystemPolicy_Stats) Reset()
func (*SystemPolicy_Stats) String ¶
func (x *SystemPolicy_Stats) String() string
Click to show internal directories.
Click to hide internal directories.