Package org.cybergarage.upnp.control

Examples of org.cybergarage.upnp.control.ActionResponse


    else
      deviceActionControlRecieved(new ActionRequest(ctlReq), service);
  }

  private void invalidActionControlRecieved(ControlRequest ctlReq) {
    ControlResponse actRes = new ActionResponse();
    actRes.setFaultResponse(UPnPStatus.INVALID_ACTION);
    ctlReq.post(actRes);
  }
View Full Code Here


    actRes.setFaultResponse(UPnPStatus.INVALID_ACTION);
    ctlReq.post(actRes);
  }

  private void invalidArgumentsControlRecieved(ControlRequest ctlReq) {
    ControlResponse actRes = new ActionResponse();
    actRes.setFaultResponse(UPnPStatus.INVALID_ARGS);
    ctlReq.post(actRes);
  }
View Full Code Here

  public boolean performActionListener(ActionRequest actionReq)
  {
    ActionListener listener = (ActionListener)getActionListener();
    if (listener == null)
      return false;
    ActionResponse actionRes = new ActionResponse();
    setStatus(UPnPStatus.INVALID_ACTION);
    clearOutputAgumentValues();
    if (listener.actionControlReceived(this) == true) {
      actionRes.setResponse(this);
    }
    else {
      UPnPStatus upnpStatus = getStatus();
      actionRes.setFaultResponse(upnpStatus.getCode(), upnpStatus.getDescription());
    }
    if (Debug.isOn() == true)
      actionRes.print();
    actionReq.post(actionRes);
    return true;
  }
View Full Code Here

    ArgumentList actionInputArgList = getInputArgumentList();   
    ActionRequest ctrlReq = new ActionRequest();
    ctrlReq.setRequest(this, actionInputArgList);
    if (Debug.isOn() == true)
      ctrlReq.print();
    ActionResponse ctrlRes = ctrlReq.post();
    if (Debug.isOn() == true)
      ctrlRes.print();
    setControlResponse(ctrlRes);
    // Thanks for Dimas <cyberrate@users.sourceforge.net> and Stefano Lenzi <kismet-sl@users.sourceforge.net> (07/09/04)
    int statCode = ctrlRes.getStatusCode();
    setStatus(statCode);
    if (ctrlRes.isSuccessful() == false)
      return false;
    ArgumentList outArgList = ctrlRes.getResponse();
        try {
            actionArgList.setResArgs(outArgList);
        } catch (IllegalArgumentException ex){
            setStatus(UPnPStatus.INVALID_ARGS,"Action succesfully delivered but invalid arguments returned.");
            return false;
View Full Code Here

TOP

Related Classes of org.cybergarage.upnp.control.ActionResponse

Copyright © 2018 www.massapicom. 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.