Package com.saasovation.common.notification

Examples of com.saasovation.common.notification.NotificationLogReader$NotificationReaderIterator


        ClientRequest request = new ClientRequest(url);
        ClientResponse<String> response = request.get(String.class);
        String serializedNotifications = response.getEntity();
        System.out.println(serializedNotifications);

        NotificationLogReader log =
                new NotificationLogReader(serializedNotifications);

        assertFalse(log.isArchived());
        assertNotNull(log.id());

        for (NotificationReader notification : log) {

            String typeName = notification.typeName();
View Full Code Here


        ClientRequest request = new ClientRequest(url);
        ClientResponse<String> response = request.get(String.class);
        String serializedNotifications = response.getEntity();
        System.out.println(serializedNotifications);

        NotificationLogReader log =
                new NotificationLogReader(serializedNotifications);

        assertFalse(log.isArchived());
        assertNotNull(log.id());

        boolean found = false;

        for (NotificationReader notification : log) {
            String typeName = notification.typeName();
View Full Code Here

        ClientRequest request = new ClientRequest(url);
        ClientResponse<String> response = request.get(String.class);
        String serializedNotifications = response.getEntity();
        System.out.println(serializedNotifications);

        NotificationLogReader log =
                new NotificationLogReader(serializedNotifications);

        assertFalse(log.isArchived());
        assertNotNull(log.id());

        boolean found = false;

        for (NotificationReader notification : log) {
            String typeName = notification.typeName();
View Full Code Here

        ClientRequest request = new ClientRequest(url);
        ClientResponse<String> response = request.get(String.class);
        String serializedNotifications = response.getEntity();
        System.out.println(serializedNotifications);

        NotificationLogReader log = new NotificationLogReader(serializedNotifications);

        assertFalse(log.isArchived());
        assertNotNull(log.id());
        assertFalse(log.hasNext());
        assertTrue(log.hasSelf());
        assertTrue(log.hasPrevious());

        int count = 0;

        while (log.hasPrevious()) {
            ++count;

            Link previous = log.previous();

            request = new ClientRequest(previous.getHref());
            response = request.get(String.class);
            serializedNotifications = response.getEntity();

            //System.out.println(serializedNotifications);

            log = new NotificationLogReader(serializedNotifications);

            assertTrue(log.isArchived());
            assertNotNull(log.id());
            assertTrue(log.hasNext());
            assertTrue(log.hasSelf());
        }

        assertTrue(count >= 1);
    }
View Full Code Here

TOP

Related Classes of com.saasovation.common.notification.NotificationLogReader$NotificationReaderIterator

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.