Package org.atmosphere.annotation

Examples of org.atmosphere.annotation.Broadcast


             * --- the action invoker will marshall the embedded entity
             */
            return view;
        }
       
        Broadcast broadcastAnnotation = ctx.getActionAnnotation(Broadcast.class);
        if (broadcastAnnotation != null) {
           
            List<ClusterBroadcastFilter> clusterBroadcastFilters =
                    new ArrayList<ClusterBroadcastFilter>();
           
            Cluster clusterAnnotation = ctx.getActionAnnotation(Cluster.class);
            if (clusterAnnotation != null) {
                Class<? extends ClusterBroadcastFilter>[] clusterFilters = clusterAnnotation.value();
                for (Class<? extends ClusterBroadcastFilter> c : clusterFilters) {
                    try {
                        ClusterBroadcastFilter cbf = c.newInstance();
                        InjectorProvider.getInjector().inject(cbf);
                        cbf.setUri(clusterAnnotation.name());
                        clusterBroadcastFilters.add(cbf);
                    } catch (Throwable t) {
                        logger.warn("Invalid ClusterBroadcastFilter", t);
                    }
                }
            }
           
            view = doBroadcast(entity, req, config, clusterBroadcastFilters,
                    broadcastAnnotation.delay(), 0,
                    broadcastAnnotation.filters(),
                    broadcastAnnotation.writeEntity(), null,
                    broadcastAnnotation.resumeOnBroadcast());
        }
       
        Asynchronous asyncAnnotation = ctx.getActionAnnotation(Asynchronous.class);
        if (asyncAnnotation != null) {
            doAsynchronous();
View Full Code Here

TOP

Related Classes of org.atmosphere.annotation.Broadcast

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.