Package org.cybergarage.upnp.control

Examples of org.cybergarage.upnp.control.QueryResponse


  public boolean performQueryListener(QueryRequest queryReq)
  {
    QueryListener listener = getQueryListener();
    if (listener == null)
      return false;
    QueryResponse queryRes = new QueryResponse();
    StateVariable retVar = new StateVariable();
    retVar.set(this);
    retVar.setValue("");
    retVar.setStatus(UPnPStatus.INVALID_VAR);
    if (listener.queryControlReceived(retVar) == true) {
      queryRes.setResponse(retVar);
    }
    else {
      UPnPStatus upnpStatus = retVar.getStatus();
      queryRes.setFaultResponse(upnpStatus.getCode(), upnpStatus.getDescription());
    }
    queryReq.post(queryRes);
    return true;
  }
View Full Code Here


  {
    QueryRequest queryReq = new QueryRequest();
    queryReq.setRequest(this);
    if (Debug.isOn() == true)
      queryReq.print();
    QueryResponse queryRes = queryReq.post();
    if (Debug.isOn() == true)
      queryRes.print();
    setQueryResponse(queryRes);
    // Thanks for Dimas <cyberrate@users.sourceforge.net> and Stefano Lenzi <kismet-sl@users.sourceforge.net> (07/09/04)
    if (queryRes.isSuccessful() == false) {
      setValue(queryRes.getReturnValue());
      return false;
    }
    setValue(queryRes.getReturnValue());
    return true;
  }
View Full Code Here

TOP

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

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.