Package ch.ethz.iks.r_osgi.messages

Examples of ch.ethz.iks.r_osgi.messages.RequestBundleMessage


    if (networkChannel == null) {
      throw new RemoteOSGiException("Channel is closed."); //$NON-NLS-1$
    }

    // build the RequestBundleMessage
    final RequestBundleMessage req = new RequestBundleMessage();
    req.setServiceID(ref.getURI().getFragment());

    final DeliverBundlesMessage deliv = (DeliverBundlesMessage) sendAndWait(req);

    final byte[] bundleBytes = deliv.getDependencies()[0];
View Full Code Here


        m.setException(e);
        return m;
      }
    }
    case RemoteOSGiMessage.REQUEST_BUNDLE:
      final RequestBundleMessage reqB = (RequestBundleMessage) msg;

      try {
        final String serviceID = reqB.getServiceID();

        final RemoteServiceRegistration reg = getServiceRegistration(serviceID);

        final byte[] bytes = RemoteOSGiServiceImpl.getBundle(reg
            .getReference().getBundle());

        final DeliverBundlesMessage delB = new DeliverBundlesMessage();
        delB.setXID(reqB.getXID());
        delB.setDependencies(new byte[][] { bytes });
        return delB;
      } catch (IOException ioe) {
        ioe.printStackTrace();
        return null;
View Full Code Here

TOP

Related Classes of ch.ethz.iks.r_osgi.messages.RequestBundleMessage

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.