@@ -0,0 +1,2095 @@
+/**%0A *%0A * Copyright 2022 Florian Schmaus.%0A *%0A * Licensed under the Apache License, Version 2.0 (the %22License%22);%0A * you may not use this file except in compliance with the License.%0A * You may obtain a copy of the License at%0A *%0A *     http://www.apache.org/licenses/LICENSE-2.0%0A *%0A * Unless required by applicable law or agreed to in writing, software%0A * distributed under the License is distributed on an %22AS IS%22 BASIS,%0A * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.%0A * See the License for the specific language governing permissions and%0A * limitations under the License.%0A */%0Apackage org.jivesoftware.smack.full;%0A%0Aimport java.io.IOException;%0A%0Aimport org.jivesoftware.smack.SmackException;%0Aimport org.jivesoftware.smack.XMPPException;%0Aimport org.jivesoftware.smack.bosh.BOSHConfiguration;%0Aimport org.jivesoftware.smack.bosh.XMPPBOSHConnection;%0Aimport org.jivesoftware.smack.packet.Message;%0A%0Aimport org.jxmpp.jid.EntityBareJid;%0Aimport org.jxmpp.jid.impl.JidCreate;%0A%0Apublic class BoshConnectionTest %7B%0A%0A    public static void main(String%5B%5D args) throws XMPPException, SmackException, IOException, InterruptedException %7B%0A        String jidString = args%5B0%5D;%0A        EntityBareJid jid = JidCreate.entityBareFrom(jidString);%0A        String pass = args%5B1%5D;%0A%0A        // SmackConfiguration.DEBUG = true;%0A        BOSHConfiguration config = BOSHConfiguration.builder()%0A                        .setUsernameAndPassword(jid.getLocalpart(), pass)%0A                        .setXmppDomain(jid.asDomainBareJid())%0A                        .useHttps()%0A                        .setPort(5443)%0A                        .setFile(%22/bosh%22)%0A                        .build();%0A        XMPPBOSHConnection connection = new XMPPBOSHConnection(config);%0A%0A        connection.connect().login();%0A        Message message = connection.getStanzaFactory()%0A                        .buildMessageStanza()%0A                        .to(%22flo@geekplace.eu%22)%0A                        .setBody(%22Hi there 2%22)%0A                        .build();%0A        connection.sendStanza(message);%0A        connection.disconnect();%0A    %7D%0A%0A%7D%0A

Add BoshConnectionTest