Documentation ¶
Index ¶
- Constants
- func NewRandomInstanceID() string
- type App
- type CastRequest
- type InfoResponse
- type OptionFunc
- func WithAddress(addr string) OptionFunc
- func WithAllowedOrigins(origins ...string) OptionFunc
- func WithApps(apps ...App) OptionFunc
- func WithAppsEnabled(enabled bool) OptionFunc
- func WithDefaultApp(defaultApp string) OptionFunc
- func WithInstanceID(id string) OptionFunc
- func WithServiceDiscoveryEnabled(enabled bool) OptionFunc
- func WithTLSAddress(addr string) OptionFunc
- func WithTLSCertificate(cert *tls.Certificate) OptionFunc
- func WithUpperLayerDir(dir string) OptionFunc
- type Options
- type Server
- type StatusResponse
Constants ¶
View Source
const ( MDNSService = "_arcast._http._tcp" MDNSDomain = "local." )
Variables ¶
This section is empty.
Functions ¶
func NewRandomInstanceID ¶
func NewRandomInstanceID() string
Types ¶
type CastRequest ¶
type CastRequest struct {
URL string `json:"url" validate:"required"`
}
type InfoResponse ¶
type OptionFunc ¶
type OptionFunc func(opts *Options)
func WithAddress ¶
func WithAddress(addr string) OptionFunc
func WithAllowedOrigins ¶
func WithAllowedOrigins(origins ...string) OptionFunc
func WithApps ¶
func WithApps(apps ...App) OptionFunc
func WithAppsEnabled ¶
func WithAppsEnabled(enabled bool) OptionFunc
func WithDefaultApp ¶
func WithDefaultApp(defaultApp string) OptionFunc
func WithInstanceID ¶
func WithInstanceID(id string) OptionFunc
func WithServiceDiscoveryEnabled ¶
func WithServiceDiscoveryEnabled(enabled bool) OptionFunc
func WithTLSAddress ¶
func WithTLSAddress(addr string) OptionFunc
func WithTLSCertificate ¶
func WithTLSCertificate(cert *tls.Certificate) OptionFunc
func WithUpperLayerDir ¶
func WithUpperLayerDir(dir string) OptionFunc
type Options ¶
type Options struct { InstanceID string Address string TLSAddress string TLSCertificate *tls.Certificate EnableServiceDiscovery bool EnableApps bool DefaultApp string AllowedOrigins []string Apps []App UpperLayerDir string }
func NewOptions ¶
func NewOptions(funcs ...OptionFunc) *Options
Source Files ¶
Click to show internal directories.
Click to hide internal directories.