Package ar.com.fernandospr.wns

Examples of ar.com.fernandospr.wns.WnsService


        if (clientIdentifiers.isEmpty()) {
            return;
        }

        final WindowsVariant windowsVariant = (WindowsVariant) variant;
        WnsService wnsService = new WnsService(windowsVariant.getSid(), windowsVariant.getClientSecret(), true);

        //simple initial version just send toast message
        WnsToast toast =  new WnsToastBuilder().bindingTemplateToastText01(pushMessage.getMessage().getAlert()).build();
        try {
            Set<String> expiredClientIdentifiers = new HashSet<String>(clientIdentifiers.size());
            final List<WnsNotificationResponse> responses = wnsService.pushToast(new ArrayList<String>(clientIdentifiers), toast);
            for (WnsNotificationResponse response : responses) {
                if (response.code == HttpServletResponse.SC_GONE) {
                    expiredClientIdentifiers.add(response.channelUri);
                }
            }
View Full Code Here

TOP

Related Classes of ar.com.fernandospr.wns.WnsService

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.