Package com.microsoft.windowsazure.services.queue.models

Examples of com.microsoft.windowsazure.services.queue.models.UpdateMessageResult


        ClientResponse response = builder.put(ClientResponse.class,
                queueMessage);
        throwIfError(response);

        UpdateMessageResult result = new UpdateMessageResult();
        result.setPopReceipt(response.getHeaders().getFirst("x-ms-popreceipt"));
        result.setTimeNextVisible(dateMapper.parse(response.getHeaders()
                .getFirst("x-ms-time-next-visible")));
        return result;
    }
View Full Code Here


        // Act
        service.createMessage(TEST_QUEUE_FOR_MESSAGES_8, "message1");

        ListMessagesResult listResult1 = service
                .listMessages(TEST_QUEUE_FOR_MESSAGES_8);
        UpdateMessageResult updateResult = service.updateMessage(
                TEST_QUEUE_FOR_MESSAGES_8, listResult1.getQueueMessages()
                        .get(0).getMessageId(), listResult1.getQueueMessages()
                        .get(0).getPopReceipt(), "new text", 0);
        ListMessagesResult listResult2 = service
                .listMessages(TEST_QUEUE_FOR_MESSAGES_8);

        // Assert
        assertNotNull(updateResult);
        assertNotNull(updateResult.getPopReceipt());
        assertNotNull(updateResult.getTimeNextVisible());
        assertTrue(year2010.before(updateResult.getTimeNextVisible()));

        assertNotNull(listResult2);
        QueueMessage entry = listResult2.getQueueMessages().get(0);

        assertEquals(listResult1.getQueueMessages().get(0).getMessageId(),
View Full Code Here

TOP

Related Classes of com.microsoft.windowsazure.services.queue.models.UpdateMessageResult

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.