Examples of ODataFeed


Examples of org.apache.olingo.odata2.api.ep.feed.ODataFeed

  @Test
  public void innerFeedNoMediaResourceWithCallbackContainsNextLinkAndCount() throws Exception {
    ODataEntry outerEntry =
        prepareAndExecuteEntry(BUILDING_WITH_INLINE_ROOMS_NEXTLINK_AND_COUNT, "Buildings", DEFAULT_PROPERTIES);

    ODataFeed innerRoomFeed = (ODataFeed) outerEntry.getProperties().get("nb_Rooms");
    assertNotNull(innerRoomFeed);

    List<ODataEntry> rooms = innerRoomFeed.getEntries();
    assertNotNull(rooms);
    assertEquals(1, rooms.size());

    FeedMetadata roomsMetadata = innerRoomFeed.getFeedMetadata();
    assertEquals(Integer.valueOf(1), roomsMetadata.getInlineCount());
    assertEquals("nextLink", roomsMetadata.getNextLink());

  }
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.