Examples of IdentifyCommand


Examples of bluffinmuffin.protocol.commands.lobby.training.IdentifyCommand

    }
   
    public boolean identify(String name)
    {
        m_playerName = name;
        send(new IdentifyCommand(m_playerName));
        final StringTokenizer token = receiveCommand(IdentifyResponse.COMMAND_NAME);
        final IdentifyResponse response = new IdentifyResponse(token);
        return response.isOK();
    }
View Full Code Here

Examples of bluffinmuffin.protocol.commands.lobby.training.IdentifyCommand

        final StringTokenizer token = new StringTokenizer(line, "" + AbstractLobbyCommand.Delimitter);
        final String commandName = token.nextToken();
       
        if (commandName.equals(IdentifyCommand.COMMAND_NAME))
        {
            authentification(new IdentifyCommand(token));
        }
        else if (commandName.equals(DisconnectCommand.COMMAND_NAME))
        {
            disconnect(new DisconnectCommand(token));
        }
View Full Code Here

Examples of com.aragost.javahg.commands.IdentifyCommand

    public final String getCommandName() {
        return "identify";
    }

    public static IdentifyCommand on(Repository repository) {
        return new IdentifyCommand(repository);
    }
View Full Code Here

Examples of org.rhq.enterprise.communications.command.impl.identify.IdentifyCommand

     *
     * @throws Throwable
     */
    private boolean ping(RemoteCommunicator comm) {
        boolean ok = true; // assume we can ping; on error, we'll set this to false
        IdentifyCommand id_cmd = new IdentifyCommand();
        this.agent.getClientCommandSender().preprocessCommand(id_cmd);
        try {
            CommandResponse response = comm.sendWithoutCallbacks(id_cmd);
            // there is a special case when we might get a response back but it should be considered "server down".
            // that is: when the server replies with a NotProcessedException response
View Full Code Here

Examples of org.rhq.enterprise.communications.command.impl.identify.IdentifyCommand

    /**
     * @see AgentPromptCommand#execute(AgentMain, String[])
     */
    public boolean execute(AgentMain agent, String[] args) {
        Command command = new IdentifyCommand();
        PrintWriter out = agent.getOut();

        try {
            ClientCommandSender sender = agent.getClientCommandSender();

View Full Code Here

Examples of org.rhq.enterprise.communications.command.impl.identify.IdentifyCommand

        assert agent2.getConfiguration().getClientSenderSecuritySocketProtocol().equals("SSL");

        assert !agent1.getConfiguration().isClientSenderSecurityServerAuthMode();
        assert agent2.getConfiguration().isClientSenderSecurityServerAuthMode();

        IdentifyCommand command = new IdentifyCommand();
        CommandResponse cmdresponse;

        cmdresponse = agent1.getClientCommandSender().sendSynch(command);
        assert cmdresponse.isSuccessful() : "Should have been able to send - agent1 does not need to auth the server: "
            + cmdresponse;
View Full Code Here

Examples of org.rhq.enterprise.communications.command.impl.identify.IdentifyCommand

        assert agent1.getServiceContainer().getConfiguration().getConnectorSecurityClientAuthMode().equals(
            SSLSocketBuilder.CLIENT_AUTH_MODE_NEED);
        assert agent2.getServiceContainer().getConfiguration().getConnectorSecurityClientAuthMode().equals(
            SSLSocketBuilder.CLIENT_AUTH_MODE_WANT);

        IdentifyCommand command = new IdentifyCommand();
        CommandResponse cmdresponse;

        cmdresponse = agent1.getClientCommandSender().sendSynch(command);
        assert cmdresponse.isSuccessful() : "Should have been able to send - agent2 only 'wants' to auth clients, but is not required to: "
            + cmdresponse;
View Full Code Here

Examples of org.rhq.enterprise.communications.command.impl.identify.IdentifyCommand

        assert agent2.getServiceContainer().getConfiguration().getConnectorSecuritySocketProtocol().equals("SSL");

        assert agent1.getConfiguration().getClientSenderSecuritySocketProtocol().equals("SSL");
        assert agent2.getConfiguration().getClientSenderSecuritySocketProtocol().equals("SSL");

        IdentifyCommand command = new IdentifyCommand();
        CommandResponse cmdresponse;
        IdentifyCommandResponse response;

        cmdresponse = agent1.getClientCommandSender().sendSynch(command);
        assert cmdresponse.isSuccessful() : "Failed to send command from agent1 to agent2: " + cmdresponse;
View Full Code Here

Examples of org.rhq.enterprise.communications.command.impl.identify.IdentifyCommand

        assert agent2.getServiceContainer().getConfiguration().getConnectorSecuritySocketProtocol().equals("TLS");

        assert agent1.getConfiguration().getClientSenderSecuritySocketProtocol().equals("TLS");
        assert agent2.getConfiguration().getClientSenderSecuritySocketProtocol().equals("SSL");

        IdentifyCommand command = new IdentifyCommand();
        CommandResponse cmdresponse;
        IdentifyCommandResponse response;

        cmdresponse = agent1.getClientCommandSender().sendSynch(command);
        assert cmdresponse.isSuccessful() : "Failed to send command from agent1 to agent2: " + cmdresponse;
View Full Code Here

Examples of org.rhq.enterprise.communications.command.impl.identify.IdentifyCommand

    @Test(enabled = ENABLE_TESTS)
    public void testSendMessage() throws Exception {
        AgentMain agent1 = m_agent1Test.createAgent(true);
        AgentMain agent2 = m_agent2Test.createAgent(true);

        IdentifyCommand command = new IdentifyCommand();
        IdentifyCommandResponse response;

        response = (IdentifyCommandResponse) agent1.getClientCommandSender().sendSynch(command);
        assert response.isSuccessful() : "Failed to send command from agent1 to agent2";
        assert new InvokerLocator(response.getIdentification().getInvokerLocator()).getPort() == agent2
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.