Examples of AtmosphereInterceptor


Examples of org.atmosphere.cpr.AtmosphereInterceptor

            try {
                atmosphere.init(vaadinServletConfig);

                // Ensure the client-side knows how to split the message stream
                // into individual messages when using certain transports
                AtmosphereInterceptor trackMessageSize = new TrackMessageSizeInterceptor();
                trackMessageSize.configure(atmosphere.getAtmosphereConfig());
                atmosphere.interceptor(trackMessageSize);
            } catch (ServletException e) {
                throw new ServiceException("Atmosphere init failed", e);
            }
        }
View Full Code Here

Examples of org.atmosphere.cpr.AtmosphereInterceptor

            String mapping = m.path();

            atmosphereConfig(m.atmosphereConfig(), framework);
            filters(m.broadcastFilters(), framework);

            AtmosphereInterceptor aa = listeners(m.listeners(), framework);
            if (aa != null) {
                l.add(aa);
            }

            AnnotationUtil.interceptors(framework, m.interceptors(), l);
View Full Code Here

Examples of org.atmosphere.cpr.AtmosphereInterceptor

    private static final Logger logger = LoggerFactory.getLogger(AtmosphereInterceptorServiceProcessor.class);

    @Override
    public void handle(final AtmosphereFramework framework, Class<AtmosphereInterceptor> annotatedClass) {
        try {
            final AtmosphereInterceptor a = (AtmosphereInterceptor) framework.newClassInstance(AtmosphereInterceptor.class, annotatedClass);
            framework.getAtmosphereConfig().startupHook(new AtmosphereConfig.StartupHook() {
                @Override
                public void started(AtmosphereFramework framework) {
                    framework.interceptor(a);
                }
View Full Code Here

Examples of org.atmosphere.cpr.AtmosphereInterceptor

            atmosphereConfig(a.atmosphereConfig(), framework);
            framework.setDefaultBroadcasterClassName(a.broadcaster().getName());
            filters(a.broadcastFilters(), framework);

            LinkedList<AtmosphereInterceptor> l = new LinkedList<AtmosphereInterceptor>();
            AtmosphereInterceptor aa = listeners(a.listeners(), framework);
            if (aa != null) {
                l.add(aa);
            }

            if (!a.servlet().isEmpty()) {
View Full Code Here

Examples of org.atmosphere.cpr.AtmosphereInterceptor

            Class<?>[] interceptors = a.interceptors();
            List<AtmosphereInterceptor> l = new LinkedList<AtmosphereInterceptor>();
            for (Class i : interceptors) {
                try {
                    AtmosphereInterceptor ai = (AtmosphereInterceptor) framework.newClassInstance(AtmosphereHandler.class, i);
                    l.add(ai);
                } catch (Throwable e) {
                    logger.warn("", e);
                }
            }

            if (a.path().contains("{")) {
                framework.interceptors().add(framework.newClassInstance(AtmosphereInterceptor.class, AtmosphereHandlerServiceInterceptor.class));
            }

            AtmosphereInterceptor aa = listeners(a.listeners(), framework);
            if (aa != null) {
                l.add(aa);
            }

            framework.sessionSupport(a.supportSession());
View Full Code Here

Examples of org.atmosphere.cpr.AtmosphereInterceptor

            framework.setDefaultBroadcasterClassName(m.broadcaster().getName());
            filters(m.broadcastFilters(), framework);

            final LinkedList<AtmosphereInterceptor> l = new LinkedList<AtmosphereInterceptor>();

            AtmosphereInterceptor aa = listeners(m.listeners(), framework);
            if (aa != null) {
                l.add(aa);
            }

            AnnotationUtil.interceptors(framework, m.interceptors(), l);
View Full Code Here

Examples of org.atmosphere.cpr.AtmosphereInterceptor

            List<AtmosphereInterceptor> l = new LinkedList<AtmosphereInterceptor>();

            atmosphereConfig(a.atmosphereConfig(), framework);
            filters(a.broadcastFilters(), framework);

            AtmosphereInterceptor aa = listeners(a.listeners(), framework);
            if (aa != null) {
                l.add(aa);
            }

            Object c = framework.newClassInstance(Object.class, aClass);
View Full Code Here

Examples of org.atmosphere.cpr.AtmosphereInterceptor

        try {
            atmosphere.init(service.getServlet().getServletConfig());

            // Ensure the client-side knows how to split the message stream
            // into individual messages when using certain transports
            AtmosphereInterceptor trackMessageSize = new TrackMessageSizeInterceptor();
            trackMessageSize.configure(atmosphere.getAtmosphereConfig());
            atmosphere.interceptor(trackMessageSize);
        } catch (ServletException e) {
            throw new ServiceException("Could not read atmosphere settings", e);
        }
    }
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.