Search in sources :

Example 41 with ContainerTypeDescription

use of org.eclipse.ecf.core.ContainerTypeDescription in project ecf by eclipse.

the class ContainerFactoryServiceDescriptionsTest method testAddNullDescription.

public void testAddNullDescription() {
    int prevSize = getFixture().getDescriptions().size();
    ContainerTypeDescription add = getFixture().addDescription(null);
    assertNull(add);
    assertTrue(getFixture().getDescriptions().size() == prevSize);
}
Also used : ContainerTypeDescription(org.eclipse.ecf.core.ContainerTypeDescription)

Example 42 with ContainerTypeDescription

use of org.eclipse.ecf.core.ContainerTypeDescription in project ecf by eclipse.

the class ContainerManagerServiceTest method testGetContainerDescriptionN.

public void testGetContainerDescriptionN() throws Exception {
    IContainer[] c = createContainers(10);
    assertNotNull(c);
    for (int i = 0; i < 10; i++) {
        ContainerTypeDescription description = containerManager.getContainerTypeDescription(c[i].getID());
        assertNotNull(description);
    }
}
Also used : ContainerTypeDescription(org.eclipse.ecf.core.ContainerTypeDescription) IContainer(org.eclipse.ecf.core.IContainer)

Example 43 with ContainerTypeDescription

use of org.eclipse.ecf.core.ContainerTypeDescription in project ecf by eclipse.

the class ContainerFactoryCreateTest method testContainerTypeDescriptionGetSupportedParemeterTypes.

public void testContainerTypeDescriptionGetSupportedParemeterTypes() {
    final ContainerTypeDescription desc = ContainerFactory.getDefault().getDescriptionByName(CONTAINER_TYPE_NAME);
    final Class[][] parameterTypes = desc.getSupportedParameterTypes();
    assertTrue(parameterTypes.length == 1);
    assertTrue(parameterTypes[0].length == 2);
    assertTrue(parameterTypes[0][0].equals(String.class));
    assertTrue(parameterTypes[0][1].equals(Class.class));
}
Also used : ContainerTypeDescription(org.eclipse.ecf.core.ContainerTypeDescription)

Example 44 with ContainerTypeDescription

use of org.eclipse.ecf.core.ContainerTypeDescription in project ecf by eclipse.

the class ContainerFactoryCreateTest method testCreateContainer6.

public void testCreateContainer6() throws Exception {
    final ContainerTypeDescription desc = ContainerFactory.getDefault().getDescriptionByName(CONTAINER_TYPE_NAME);
    assertNotNull(desc);
    final IContainer container = ContainerFactory.getDefault().createContainer(desc, IDFactory.getDefault().createGUID());
    assertNotNull(container);
}
Also used : ContainerTypeDescription(org.eclipse.ecf.core.ContainerTypeDescription) IContainer(org.eclipse.ecf.core.IContainer)

Example 45 with ContainerTypeDescription

use of org.eclipse.ecf.core.ContainerTypeDescription in project ecf by eclipse.

the class ContainerFactoryCreateTest method testCreateContainer3.

public void testCreateContainer3() throws Exception {
    final ContainerTypeDescription desc = ContainerFactory.getDefault().getDescriptionByName(CONTAINER_TYPE_NAME);
    assertNotNull(desc);
    final IContainer container = ContainerFactory.getDefault().createContainer(desc);
    assertNotNull(container);
}
Also used : ContainerTypeDescription(org.eclipse.ecf.core.ContainerTypeDescription) IContainer(org.eclipse.ecf.core.IContainer)

Aggregations

ContainerTypeDescription (org.eclipse.ecf.core.ContainerTypeDescription)54 IContainer (org.eclipse.ecf.core.IContainer)20 List (java.util.List)5 Namespace (org.eclipse.ecf.core.identity.Namespace)5 ExtensionRegistryRunnable (org.eclipse.ecf.core.util.ExtensionRegistryRunnable)5 ArrayList (java.util.ArrayList)3 Dictionary (java.util.Dictionary)3 Properties (java.util.Properties)3 IContainerManager (org.eclipse.ecf.core.IContainerManager)3 IRemoteServiceContainer (org.eclipse.ecf.remoteservice.IRemoteServiceContainer)3 URI (java.net.URI)2 URL (java.net.URL)2 Hashtable (java.util.Hashtable)2 ContainerConnectException (org.eclipse.ecf.core.ContainerConnectException)2 ID (org.eclipse.ecf.core.identity.ID)2 IConnectHandlerPolicy (org.eclipse.ecf.core.security.IConnectHandlerPolicy)2 RestClientContainer (org.eclipse.ecf.remoteservice.rest.client.RestClientContainer)2 RpcClientContainer (org.eclipse.ecf.remoteservice.rpc.client.RpcClientContainer)2 Bundle (org.osgi.framework.Bundle)2 ServiceFactory (org.osgi.framework.ServiceFactory)2