Examples of sendCommand()


Examples of org.apache.commons.net.smtp.SMTPClient.sendCommand()

    public void testAddressBracketsEnforcementEnabled() throws Exception {
        finishSetUp(m_testConfiguration);
        SMTPClient smtpProtocol = new SMTPClient();
        smtpProtocol.connect("127.0.0.1", m_smtpListenerPort);

        smtpProtocol.sendCommand("ehlo", InetAddress.getLocalHost().toString());

        smtpProtocol.sendCommand("mail from:", "test@localhost");
        assertEquals("reject", 501, smtpProtocol.getReplyCode());
        smtpProtocol.sendCommand("mail from:", "<test@localhost>");
        assertEquals("accept", 250, smtpProtocol.getReplyCode());
View Full Code Here

Examples of org.apache.commons.net.smtp.SMTPClient.sendCommand()

        SMTPClient smtpProtocol = new SMTPClient();
        smtpProtocol.connect("127.0.0.1", m_smtpListenerPort);

        smtpProtocol.sendCommand("ehlo", InetAddress.getLocalHost().toString());

        smtpProtocol.sendCommand("mail from:", "test@localhost");
        assertEquals("reject", 501, smtpProtocol.getReplyCode());
        smtpProtocol.sendCommand("mail from:", "<test@localhost>");
        assertEquals("accept", 250, smtpProtocol.getReplyCode());

        smtpProtocol.sendCommand("rcpt to:", "mail@sample.com");
View Full Code Here

Examples of org.apache.commons.net.smtp.SMTPClient.sendCommand()

        smtpProtocol.sendCommand("ehlo", InetAddress.getLocalHost().toString());

        smtpProtocol.sendCommand("mail from:", "test@localhost");
        assertEquals("reject", 501, smtpProtocol.getReplyCode());
        smtpProtocol.sendCommand("mail from:", "<test@localhost>");
        assertEquals("accept", 250, smtpProtocol.getReplyCode());

        smtpProtocol.sendCommand("rcpt to:", "mail@sample.com");
        assertEquals("reject", 501, smtpProtocol.getReplyCode());
        smtpProtocol.sendCommand("rcpt to:", "<mail@sample.com>");
View Full Code Here

Examples of org.apache.commons.net.smtp.SMTPClient.sendCommand()

        smtpProtocol.sendCommand("mail from:", "test@localhost");
        assertEquals("reject", 501, smtpProtocol.getReplyCode());
        smtpProtocol.sendCommand("mail from:", "<test@localhost>");
        assertEquals("accept", 250, smtpProtocol.getReplyCode());

        smtpProtocol.sendCommand("rcpt to:", "mail@sample.com");
        assertEquals("reject", 501, smtpProtocol.getReplyCode());
        smtpProtocol.sendCommand("rcpt to:", "<mail@sample.com>");
        assertEquals("accept", 250, smtpProtocol.getReplyCode());

        smtpProtocol.quit();
View Full Code Here

Examples of org.apache.commons.net.smtp.SMTPSClient.sendCommand()

           
            SMTPSClient client = createClient();
            client.connect(address.getAddress().getHostAddress(), address.getPort());
            assertTrue(SMTPReply.isPositiveCompletion(client.getReplyCode()));
           
            client.sendCommand("EHLO localhost");
            assertTrue(SMTPReply.isPositiveCompletion(client.getReplyCode()));
           
            boolean startTLSAnnounced = false;
            for (String reply: client.getReplyStrings()) {
                if (reply.toUpperCase(Locale.UK).endsWith("STARTTLS")) {
View Full Code Here

Examples of org.apache.twill.api.TwillController.sendCommand()

    // Make sure we see the right instance IDs
    Assert.assertEquals(Sets.newHashSet(0, 1), getInstances(discoverables));

    // Kill server with instanceId = 0
    controller.sendCommand(FailureRunnable.class.getSimpleName(), Command.Builder.of("kill0").build());

    // Make sure the runnable is killed.
    Assert.assertTrue(YarnTestUtils.waitForSize(discoverables, 1, 60));

    // Wait for the restart
View Full Code Here

Examples of org.openhab.core.events.EventPublisher.sendCommand()

            Item item = registry.getItemByPattern(itemName);
            if(args.length>1) {
              String commandName = args[1];
              Command command = TypeParser.parseCommand(item.getAcceptedCommandTypes(), commandName);
              if(command!=null) {
                publisher.sendCommand(itemName, command);
                console.println("Command has been sent successfully.");
              } else {
                console.println("Error: Command '" + commandName +
                    "' is not valid for item '" + itemName + "'");
                console.print("Valid command types are: ( ");
View Full Code Here

Examples of org.twdata.maven.cli.CliClientProjectComponent.sendCommand()

    }

    public void actionPerformed(AnActionEvent e) {
        Project project = (Project) e.getDataContext().getData(DataConstants.PROJECT);
        CliClientProjectComponent comp = project.getComponent(CliClientProjectComponent.class);
        comp.sendCommand(index);
    }
}
View Full Code Here

Examples of org.xilaew.jampl.CLI.sendCommand()

    // System.err.println(buff);
    // }
    // };
    // };
    // errorThread.start();
    cli.sendCommand("option solver ilogcp;");
    cli.sendCommand("model output/assignment.mod;");
    cli.sendCommand("data output/assignment0.dat;");
    cli.sendCommand("solve;");
    cli.sendCommand("show;");
    cli.sendCommand("display a, return, x;");
View Full Code Here

Examples of sos.net.SOSFTP.sendCommand()

          }
          if (strPreFtpCommands.length() > 0) {
            String[] strA = strPreFtpCommands.split(";");
            for (String strCmd : strA) {
              this.getLogger().debug("..try to send [" + strCmd + "] to the Server ");
              sosftp.sendCommand(strCmd);
              this.getLogger().debug(FTP_SERVER_REPLY + strCmd + conClosingBracketWithColon + ftpClient.getReplyString());
            }
          }

          if (strControlEncoding.length() > 0) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.