MCPcopy Create free account
hub / github.com/pion/dtls / buildServerConfig

Function buildServerConfig

options.go:180–191  ·  view source on GitHub ↗

buildServerConfig builds a Config for server from the provided options.

(opts ...ServerOption)

Source from the content-addressed store, hash-verified

178
179// buildServerConfig builds a Config for server from the provided options.
180func buildServerConfig(opts ...ServerOption) (*Config, error) {
181 cfg := &dtlsConfig{}
182 cfg.applyDefaults()
183
184 for _, opt := range opts {
185 if err := opt.applyServer(cfg); err != nil {
186 return nil, err
187 }
188 }
189
190 return cfg.toConfig(), nil
191}
192
193// buildClientConfig builds a Config for client from the provided options.
194func buildClientConfig(opts ...ClientOption) (*Config, error) {

Calls 3

applyDefaultsMethod · 0.95
toConfigMethod · 0.95
applyServerMethod · 0.65

Used in the wild real call sites across dependent graphs

searching dependent graphs…