Package org.apache.xbean.finder

Examples of org.apache.xbean.finder.IAnnotationFinder.findAnnotatedClasses()


                for (final ConnectionDefinition definition : definitions) {
                    processConnectionDescription(connector.getResourceAdapter(), definition, cls);
                }
            }

            classes = finder.findAnnotatedClasses(ConnectionDefinition.class);
            for (final Class<?> cls : classes) {
                final ConnectionDefinition connectionDefinitionAnnotation = cls.getAnnotation(ConnectionDefinition.class);
                processConnectionDescription(connector.getResourceAdapter(), connectionDefinitionAnnotation, cls);
            }
View Full Code Here


            if (messageAdapter == null) {
                messageAdapter = new MessageAdapter();
                inboundResourceAdapter.setMessageAdapter(messageAdapter);
            }

            classes = finder.findAnnotatedClasses(Activation.class);
            for (final Class<?> cls : classes) {
                MessageListener messageListener = null;
                final Activation activationAnnotation = cls.getAnnotation(Activation.class);

                final List<MessageListener> messageListeners = messageAdapter.getMessageListener();
View Full Code Here

                        messageAdapter.addMessageListener(new MessageListener(listener.getName(), cls.getName()));
                    }
                }
            }

            classes = finder.findAnnotatedClasses(AdministeredObject.class);
            final List<AdminObject> adminObjects = connector.getResourceAdapter().getAdminObject();
            for (final Class<?> cls : classes) {
                final AdministeredObject administeredObjectAnnotation = cls.getAnnotation(AdministeredObject.class);
                final Class[] adminObjectInterfaces = administeredObjectAnnotation.adminObjectInterfaces();
View Full Code Here

                }
            }

            final IAnnotationFinder finder = webModule.getFinder();
            final List<Class> classes = new ArrayList<Class>();
            classes.addAll(finder.findAnnotatedClasses(WebService.class));
            classes.addAll(finder.findAnnotatedClasses(WebServiceProvider.class));

            for (final Class<?> webServiceClass : classes) {
                // If this class is also annotated @Stateless or @Singleton, we should skip it
                if (webServiceClass.isAnnotationPresent(Singleton.class) || webServiceClass.isAnnotationPresent(Stateless.class)) {
View Full Code Here

            }

            final IAnnotationFinder finder = webModule.getFinder();
            final List<Class> classes = new ArrayList<Class>();
            classes.addAll(finder.findAnnotatedClasses(WebService.class));
            classes.addAll(finder.findAnnotatedClasses(WebServiceProvider.class));

            for (final Class<?> webServiceClass : classes) {
                // If this class is also annotated @Stateless or @Singleton, we should skip it
                if (webServiceClass.isAnnotationPresent(Singleton.class) || webServiceClass.isAnnotationPresent(Stateless.class)) {
                    webModule.getEjbWebServices().add(webServiceClass.getName());
View Full Code Here

                assemblyDescriptor = new AssemblyDescriptor();
                ejbModule.getEjbJar().setAssemblyDescriptor(assemblyDescriptor);
            }

            startupLogger.debug("Searching for annotated application exceptions (see OPENEJB-980)");
            final List<Class<?>> appExceptions = finder.findAnnotatedClasses(ApplicationException.class);
            for (final Class<?> exceptionClass : appExceptions) {
                startupLogger.debug("...handling " + exceptionClass);
                final ApplicationException annotation = exceptionClass.getAnnotation(ApplicationException.class);
                if (assemblyDescriptor.getApplicationException(exceptionClass) == null) {
                    startupLogger.debug("...adding " + exceptionClass + " with rollback=" + annotation.rollback());
View Full Code Here

                                packageNames = packageName.split(",");
                            }

                            // no need of meta currently since JPA providers doesn't support it
                            final List<Class<?>> classes = new ArrayList<Class<?>>();
                            classes.addAll(finder.findAnnotatedClasses(Entity.class));
                            classes.addAll(finder.findAnnotatedClasses(Embeddable.class));
                            classes.addAll(finder.findAnnotatedClasses(MappedSuperclass.class));
                            final List<String> existingClasses = pu.getClazz();
                            for (final Class<?> clazz : classes) {
                                final String name = clazz.getName();
View Full Code Here

                            }

                            // no need of meta currently since JPA providers doesn't support it
                            final List<Class<?>> classes = new ArrayList<Class<?>>();
                            classes.addAll(finder.findAnnotatedClasses(Entity.class));
                            classes.addAll(finder.findAnnotatedClasses(Embeddable.class));
                            classes.addAll(finder.findAnnotatedClasses(MappedSuperclass.class));
                            final List<String> existingClasses = pu.getClazz();
                            for (final Class<?> clazz : classes) {
                                final String name = clazz.getName();
                                if (existingClasses.contains(name)) {
View Full Code Here

                            // no need of meta currently since JPA providers doesn't support it
                            final List<Class<?>> classes = new ArrayList<Class<?>>();
                            classes.addAll(finder.findAnnotatedClasses(Entity.class));
                            classes.addAll(finder.findAnnotatedClasses(Embeddable.class));
                            classes.addAll(finder.findAnnotatedClasses(MappedSuperclass.class));
                            final List<String> existingClasses = pu.getClazz();
                            for (final Class<?> clazz : classes) {
                                final String name = clazz.getName();
                                if (existingClasses.contains(name)) {
                                    continue;
View Full Code Here

                assemblyDescriptor = new AssemblyDescriptor();
                ejbModule.getEjbJar().setAssemblyDescriptor(assemblyDescriptor);
            }

            startupLogger.debug("Searching for annotated application exceptions (see OPENEJB-980)");
            final List<Class<?>> appExceptions = finder.findAnnotatedClasses(ApplicationException.class);
            for (final Class<?> exceptionClass : appExceptions) {
                startupLogger.debug("...handling " + exceptionClass);
                final ApplicationException annotation = exceptionClass.getAnnotation(ApplicationException.class);
                if (assemblyDescriptor.getApplicationException(exceptionClass) == null) {
                    startupLogger.debug("...adding " + exceptionClass + " with rollback=" + annotation.rollback());
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.