2020-02-26 21:49:27 +00:00
|
|
|
package xmpp
|
|
|
|
|
|
|
|
import (
|
|
|
|
. "git.deuxfleurs.fr/Deuxfleurs/easybridge/connector"
|
|
|
|
)
|
|
|
|
|
2020-02-28 09:34:22 +00:00
|
|
|
const XMPP_PROTOCOL = "XMPP"
|
|
|
|
|
2020-02-26 21:49:27 +00:00
|
|
|
func init() {
|
2020-02-28 09:34:22 +00:00
|
|
|
Register(XMPP_PROTOCOL, Protocol{
|
2020-02-28 09:18:47 +00:00
|
|
|
NewConnector: func() Connector { return &XMPP{} },
|
|
|
|
Schema: ConfigSchema{
|
|
|
|
&ConfigEntry{
|
|
|
|
Name: "jid",
|
|
|
|
Description: "JID",
|
|
|
|
Required: true,
|
|
|
|
},
|
|
|
|
&ConfigEntry{
|
|
|
|
Name: "password",
|
|
|
|
Description: "Password",
|
|
|
|
Required: true,
|
|
|
|
IsPassword: true,
|
|
|
|
},
|
|
|
|
&ConfigEntry{
|
|
|
|
Name: "nickname",
|
|
|
|
Description: "Nickname in MUCs",
|
|
|
|
Required: true,
|
|
|
|
},
|
|
|
|
&ConfigEntry{
|
|
|
|
Name: "port",
|
|
|
|
Description: "Port",
|
|
|
|
IsNumeric: true,
|
|
|
|
Default: "5222",
|
|
|
|
},
|
|
|
|
&ConfigEntry{
|
|
|
|
Name: "ssl",
|
|
|
|
Description: "Use SSL",
|
|
|
|
IsBoolean: true,
|
|
|
|
Default: "true",
|
|
|
|
},
|
2020-02-26 21:49:27 +00:00
|
|
|
},
|
|
|
|
})
|
|
|
|
}
|