Package com.almende.eve.state

Examples of com.almende.eve.state.State.containsKey()


   */
  private ArrayNode getConns(final String agentId) throws IOException {
    final State state = agentHost.getStateFactory().get(agentId);
   
    ArrayNode conns = null;
    if (state.containsKey(CONNKEY)) {
      conns = (ArrayNode) JOM.getInstance().readTree(
          state.get(CONNKEY, String.class));
    }
    return conns;
  }
View Full Code Here


  @Override
  public String getAgentUrl(String agentId) {
    try {
      State state = agentFactory.getStateFactory().get(agentId);
      ArrayNode conns = null;
      if (state.containsKey("_XMPP_Connections")) {
        conns = (ArrayNode) JOM.getInstance().readTree(
            (String) state.get("_XMPP_Connections"));
      }
      if (conns != null) {
        for (JsonNode conn : conns) {
View Full Code Here

  final public void disconnect(String agentId) {
   
    try {
      State state = agentFactory.getStateFactory().get(agentId);
      ArrayNode conns = null;
      if (state.containsKey("_XMPP_Connections")) {
        conns = (ArrayNode) JOM.getInstance().readTree(
            (String) state.get("_XMPP_Connections"));
      }
      if (conns != null) {
        for (JsonNode conn : conns) {
View Full Code Here

 
  @Override
  public void reconnect(String agentId) throws Exception {
    State state = agentFactory.getStateFactory().get(agentId);
    ArrayNode conns = null;
    if (state.containsKey("_XMPP_Connections")) {
      conns = (ArrayNode) JOM.getInstance().readTree(
          (String) state.get("_XMPP_Connections"));
    }

    if (conns != null) {
View Full Code Here

  private ArrayNode getConns(String agentId) throws IOException,
      JSONRPCException {
    State state = agentHost.getStateFactory().get(agentId);
   
    ArrayNode conns = null;
    if (state.containsKey(CONNKEY)) {
      conns = (ArrayNode) JOM.getInstance().readTree(state.get(CONNKEY,String.class));
    }
    return conns;
  }
 
View Full Code Here

   */
  private ArrayNode getConns(final String agentId) throws IOException {
    final State state = agentHost.getStateFactory().get(agentId);
   
    ArrayNode conns = null;
    if (state.containsKey(CONNKEY)) {
      conns = (ArrayNode) JOM.getInstance().readTree(
          state.get(CONNKEY, String.class));
    }
    return conns;
  }
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.