Package org.eclipse.ecf.osgi.services.remoteserviceadmin

Examples of org.eclipse.ecf.osgi.services.remoteserviceadmin.EndpointDescription


    if (!(event instanceof RemoteServiceAdmin.RemoteServiceAdminEvent))
      return;
    RemoteServiceAdmin.RemoteServiceAdminEvent rsaEvent = (RemoteServiceAdmin.RemoteServiceAdminEvent) event;

    int eventType = event.getType();
    EndpointDescription endpointDescription = rsaEvent
        .getEndpointDescription();

    switch (eventType) {
    case RemoteServiceAdminEvent.EXPORT_REGISTRATION:
      advertiseEndpointDescription(endpointDescription);
View Full Code Here


      org.osgi.service.remoteserviceadmin.EndpointDescription endpoint,
      String matchedFilter) {
    if (matchedFilter.equals(osgiLocalEndpointListenerScope)) {
      advertiseEndpointDescription(endpoint);
    } else if (matchedFilter.equals(osgiNonLocalEndpointListenerScope)) {
      EndpointDescription ed = convertEndpointDescriptionFromOSGiToECF(endpoint);
      if (ed != null) {
        handleECFEndpointAdded(ed);
      }
    } else if (matchedFilter.equals(ecfNonLocalEndpointListenerScope)) {
      handleECFEndpointAdded((EndpointDescription) endpoint);
View Full Code Here

    if (ecfNS == null)
      return null;

    newProps.put(RemoteConstants.ENDPOINT_CONTAINER_ID_NAMESPACE, ecfNS);

    return new EndpointDescription(newProps);
  }
View Full Code Here

      org.osgi.service.remoteserviceadmin.EndpointDescription endpoint,
      String matchedFilter) {
    if (matchedFilter.equals(osgiLocalEndpointListenerScope)) {
      unadvertiseEndpointDescription(endpoint);
    } else if (matchedFilter.equals(osgiNonLocalEndpointListenerScope)) {
      EndpointDescription ed = convertEndpointDescriptionFromOSGiToECF(endpoint);
      if (ed != null)
        handleECFEndpointRemoved(ed);
    } else if (matchedFilter.equals(ecfNonLocalEndpointListenerScope)) {
      handleECFEndpointRemoved((EndpointDescription) endpoint);
    } else if (matchedFilter.equals(ecfLocalEndpointListenerScope)) {
View Full Code Here

    // Add required OSGi properties
    addRequiredOSGiProperties(props);
    createECFRemoteServiceId(props);
    // Add extra properties
    addExtraProperties(props);
    return new EndpointDescription(props);
  }
View Full Code Here

    // Add full OSGi properties
    addOptionalOSGiProperties(props);
    // required ECF properties
    // Add extra properties
    addExtraProperties(props);
    return new EndpointDescription(props);
  }
View Full Code Here

    Map<String,Object> props = new HashMap<String,Object>();
    // Add only ECF properties
    // no OSGi properties
    createECFRemoteServiceId(props);
    // This should throw a runtime exception
    return new EndpointDescription(props);
  }
View Full Code Here

    // Add full OSGi properties
    addOptionalOSGiProperties(props);
   
    // No ECF required properties
    // This should throw a runtime exception
    return new EndpointDescription(props);
  }
View Full Code Here

    endpointDescriptionFactory = new DiscoveredEndpointDescriptionFactory();
    Assert.isNotNull(endpointDescriptionFactory);
  }
 
  public void testCreateRequiredEndpointDescriptionFromServiceInfo() throws Exception {
    EndpointDescription published = createRequiredEndpointDescription();
    assertNotNull(published);
    IServiceInfo serviceInfo = createServiceInfoForDiscovery(published);
    assertNotNull(serviceInfo);
    org.osgi.service.remoteserviceadmin.EndpointDescription received = createEndpointDescriptionFromDiscovery(serviceInfo);
    assertNotNull(received);
    assertTrue(published.equals(received));
  }
View Full Code Here

    assertNotNull(received);
    assertTrue(published.equals(received));
  }

  public void testCreateFullEndpointDescriptionFromServiceInfo() throws Exception {
    EndpointDescription published = createFullEndpointDescription();
    assertNotNull(published);
    IServiceInfo serviceInfo = createServiceInfoForDiscovery(published);
    assertNotNull(serviceInfo);
    org.osgi.service.remoteserviceadmin.EndpointDescription received = createEndpointDescriptionFromDiscovery(serviceInfo);
    assertNotNull(received);
    assertTrue(published.equals(received));
  }
View Full Code Here

TOP

Related Classes of org.eclipse.ecf.osgi.services.remoteserviceadmin.EndpointDescription

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.