mirror of
https://github.com/FluuxIO/go-xmpp.git
synced 2025-11-24 18:23:43 -08:00
Split out TransportConfiguration
This allows using the same transport configuration from both clients and components.
This commit is contained in:
committed by
Mickaël Rémond
parent
66e219844b
commit
96fccbd399
@@ -1,12 +1,15 @@
|
||||
package xmpp
|
||||
|
||||
import (
|
||||
"crypto/tls"
|
||||
"io"
|
||||
"os"
|
||||
)
|
||||
|
||||
type Config struct {
|
||||
// TransportConfiguration must not be modified after having been passed to NewClient. Any
|
||||
// changes made after connecting are ignored.
|
||||
TransportConfiguration
|
||||
|
||||
Address string
|
||||
Jid string
|
||||
parsedJid *Jid // For easier manipulation
|
||||
@@ -14,9 +17,6 @@ type Config struct {
|
||||
StreamLogger *os.File // Used for debugging
|
||||
Lang string // TODO: should default to 'en'
|
||||
ConnectTimeout int // Client timeout in seconds. Default to 15
|
||||
// tls.Config must not be modified after having been passed to NewClient. Any
|
||||
// changes made after connecting are ignored.
|
||||
TLSConfig *tls.Config
|
||||
// Insecure can be set to true to allow to open a session without TLS. If TLS
|
||||
// is supported on the server, we will still try to use it.
|
||||
Insecure bool
|
||||
|
||||
Reference in New Issue
Block a user