Examples of ServiceDescriptor


Examples of org.olat.core.service.ServiceDescriptor

  /* (non-Javadoc)
   * @see org.olat.core.service.ServiceRegistry#validateDependencies()
   */
  public void validateDependencies() {
    Exception e = null;
    ServiceDescriptor sd = null;
    for (int i = 0; e == null && i < serviceDescriptors.size(); i++) {
      // access the interface class of each service to verify that it can be reached by the classloader
      sd = serviceDescriptors.get(i);
      e = validateService(sd);
      if (e == null) {
        Tracing.logInfo("SERVICE OK:" + sd.getServiceClassName()+" v"+sd.getMajorVersion()+"."+sd.getMinorVersion()+" description: "+sd.getDescription(), this.getClass());
      }
    }
   
    if (e != null) {
      throw new AssertException("invalid service: name '"+sd.getServiceClassName()+"' , spring exception = "+e);
    }
  }
View Full Code Here

Examples of org.openengsb.core.api.descriptor.ServiceDescriptor

        when(
            bundleContext.getServiceReferences(Domain.class.getName(),
                String.format("(%s=%s)", org.osgi.framework.Constants.SERVICE_PID, "test")))
            .thenReturn(new ServiceReference[]{ ref });

        ServiceDescriptor serviceDescriptor = Mockito.mock(ServiceDescriptor.class);
        Mockito.when(serviceDescriptor.getId()).thenReturn("ManagerId");
        Mockito.when(serviceDescriptor.getName()).thenReturn(new PassThroughLocalizableString("ServiceName"));
        Mockito.when(serviceDescriptor.getDescription()).thenReturn(
            new PassThroughLocalizableString("ServiceDescription"));

        if (!serviceListExpanded) {
            expandServiceListTree();
        }
View Full Code Here

Examples of org.qi4j.api.service.ServiceDescriptor

            @Override
            public boolean visitEnter( Object visited ) throws RuntimeException
            {
                if (visited instanceof ServiceDescriptor)
                {
                    ServiceDescriptor serviceDescriptor = (ServiceDescriptor) visited;
                    Assert.assertTrue( serviceDescriptor.isInstantiateOnStartup() );
                    Assert.assertTrue( serviceDescriptor.visibility() == Visibility.layer );
                    return false;
                } else if (visited instanceof EntityDescriptor)
                {
                    EntityDescriptor entityDescriptor = (EntityDescriptor) visited;
                    Assert.assertTrue( entityDescriptor.visibility() == Visibility.application );
View Full Code Here

Examples of org.qi4j.api.service.ServiceDescriptor

        }

    public <T> T getConfigurationInstance( ServiceComposite serviceComposite, UnitOfWork uow )
        throws InstantiationException
    {
        ServiceDescriptor serviceModel = api.getServiceDescriptor( serviceComposite );

        String identity = serviceComposite.identity().get();
        T configuration;
        try
        {
            configuration = uow.get( serviceModel.<T>configurationType(), identity );
            uow.pause();
        }
        catch( NoSuchEntityException e )
        {
            return (T) initializeConfigurationInstance( serviceComposite, uow, serviceModel, identity );
View Full Code Here

Examples of org.rhq.core.clientapi.descriptor.plugin.ServiceDescriptor

        PluginDescriptor p = new PluginDescriptor();
        p.setName("Postgres");
        p.setDisplayName("Postgres");
        p.setPackage("org.rhq.plugins.postgres");

        ServiceDescriptor table = new ServiceDescriptor();
        table.setName("Table");
        table.setClazz("org.rhq.plugins.postgres.TableServiceComponent");

        p.getServices().add(table);

        JAXBContext jaxbContext = JAXBContext.newInstance(DescriptorPackages.PC_PLUGIN);
View Full Code Here

Examples of org.rhq.core.clientapi.descriptor.plugin.ServiceDescriptor

    }

    protected ConfigurationDefinition loadServiceDescriptor(String serviceName) throws InvalidPluginDescriptorException {
        List<ServiceDescriptor> services = pluginDescriptor.getServices();

        ServiceDescriptor serviceDescriptor = findService(serviceName, services);
        assert serviceDescriptor != null : "Service descriptor for service [" + serviceName
            + "] not found in plugin descriptor";

        return ConfigurationMetadataParser.parse("null", serviceDescriptor.getResourceConfiguration());
    }
View Full Code Here

Examples of org.rhq.core.clientapi.descriptor.plugin.ServiceDescriptor

         ResourceDescriptor.Subcategories subCategoriesDescriptor = server2.getSubcategories();
         assert subCategoriesDescriptor == null : "Unexpected subcategories element: " + server2.getName();
         assert server2.getSubCategory().equals("applications");

         List<ServiceDescriptor> services = pluginDescriptor.getServices();
         ServiceDescriptor service1 = services.get(0);
         assert service1.getName().equals("testService");
         assert service1.getSubCategory().equals("applications");
     }
View Full Code Here

Examples of org.rhq.core.clientapi.descriptor.plugin.ServiceDescriptor

        //locate the services
        List<ServiceDescriptor> services = pluginDescriptor.getServices();

        //locate the specific entry
        ServiceDescriptor serviceDescriptor = findServiceEntry(serviceName, services);

        assert serviceDescriptor != null : "Service descriptor not found in test plugin descriptor";

        //? Validate the returned value?
        return ConfigurationMetadataParser.parse("null", serviceDescriptor.getResourceConfiguration());
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.