Class ReadAllQueryResultCollection
- java.lang.Object
-
- org.eclipse.persistence.jpa.rs.util.list.ReadAllQueryResultCollection
-
- All Implemented Interfaces:
PageableCollection<java.lang.Object>
public class ReadAllQueryResultCollection extends java.lang.Object implements PageableCollection<java.lang.Object>
This class is used to wrap collection of records returned by a JPA read all query and includes paging links.- Author:
- gonural
-
-
Constructor Summary
Constructors Constructor Description ReadAllQueryResultCollection()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addItem(java.lang.Object item)
Adds the item.void
addLink(org.eclipse.persistence.internal.jpa.rs.metadata.model.LinkV2 link)
Adds the link.java.lang.Integer
getCount()
Gets the total number of records in the current response.java.lang.Boolean
getHasMore()
Returns true if collection has morejava.util.List<java.lang.Object>
getItems()
java.lang.Integer
getLimit()
Gets the limit.java.util.List<org.eclipse.persistence.internal.jpa.rs.metadata.model.LinkV2>
getLinks()
Gets the links.java.lang.Integer
getOffset()
Gets the offset.void
setCount(java.lang.Integer count)
Sets the count.void
setHasMore(java.lang.Boolean hasMore)
Sets hasMorevoid
setItems(java.util.List<java.lang.Object> items)
void
setLimit(java.lang.Integer limit)
Sets the limit.void
setLinks(java.util.List<org.eclipse.persistence.internal.jpa.rs.metadata.model.LinkV2> links)
Sets the links.void
setOffset(java.lang.Integer offset)
Sets the offset.
-
-
-
Method Detail
-
getItems
public java.util.List<java.lang.Object> getItems()
- Specified by:
getItems
in interfacePageableCollection<java.lang.Object>
-
setItems
public void setItems(java.util.List<java.lang.Object> items)
- Specified by:
setItems
in interfacePageableCollection<java.lang.Object>
-
setHasMore
public void setHasMore(java.lang.Boolean hasMore)
Sets hasMore- Specified by:
setHasMore
in interfacePageableCollection<java.lang.Object>
- Parameters:
hasMore
- the new checks for more
-
getHasMore
public java.lang.Boolean getHasMore()
Returns true if collection has more- Specified by:
getHasMore
in interfacePageableCollection<java.lang.Object>
- Returns:
- the checks for more
-
getCount
public java.lang.Integer getCount()
Gets the total number of records in the current response.- Specified by:
getCount
in interfacePageableCollection<java.lang.Object>
- Returns:
- the count
-
setCount
public void setCount(java.lang.Integer count)
Sets the count.- Specified by:
setCount
in interfacePageableCollection<java.lang.Object>
- Parameters:
count
- the new count
-
getLimit
public java.lang.Integer getLimit()
Gets the limit.- Specified by:
getLimit
in interfacePageableCollection<java.lang.Object>
- Returns:
- the limit
-
setLimit
public void setLimit(java.lang.Integer limit)
Sets the limit.- Specified by:
setLimit
in interfacePageableCollection<java.lang.Object>
- Parameters:
limit
- the new limit
-
setOffset
public void setOffset(java.lang.Integer offset)
Sets the offset.- Specified by:
setOffset
in interfacePageableCollection<java.lang.Object>
- Parameters:
offset
- the new offset
-
getOffset
public java.lang.Integer getOffset()
Gets the offset.- Specified by:
getOffset
in interfacePageableCollection<java.lang.Object>
- Returns:
- the offset
-
getLinks
public java.util.List<org.eclipse.persistence.internal.jpa.rs.metadata.model.LinkV2> getLinks()
Gets the links.- Specified by:
getLinks
in interfacePageableCollection<java.lang.Object>
- Returns:
- the links
-
setLinks
public void setLinks(java.util.List<org.eclipse.persistence.internal.jpa.rs.metadata.model.LinkV2> links)
Sets the links.- Specified by:
setLinks
in interfacePageableCollection<java.lang.Object>
- Parameters:
links
- the new links
-
addLink
public void addLink(org.eclipse.persistence.internal.jpa.rs.metadata.model.LinkV2 link)
Adds the link.- Specified by:
addLink
in interfacePageableCollection<java.lang.Object>
- Parameters:
link
- the link
-
addItem
public void addItem(java.lang.Object item)
Adds the item.- Parameters:
item
- the item
-
-