Merged 5.2.N (5.2.2) to HEAD (5.2)

137073 gjames: Merged searchrep (5.2.1) to 5.2.N (5.2.1)
      136944 gjames: SEARCH-451: Switching to the new pivot format


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@137588 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Andrei Rebegea
2017-06-15 11:17:40 +00:00
parent eb83300ad8
commit a9549c55e2
3 changed files with 113 additions and 49 deletions

View File

@@ -28,21 +28,31 @@ package org.alfresco.rest.api.search.model;
import org.codehaus.jackson.annotate.JsonCreator;
import org.codehaus.jackson.annotate.JsonProperty;
import java.util.Collections;
import java.util.List;
/**
* POJO class representing Pivot
*/
public class Pivot
{
private final String key;
private final List<Pivot> pivots;
@JsonCreator
public Pivot(@JsonProperty("key") String key)
public Pivot(@JsonProperty("key") String key, @JsonProperty("pivots") List<Pivot> pivots)
{
this.key = key;
this.pivots = pivots == null? Collections.emptyList():pivots;
}
public String getKey()
{
return key;
}
public List<Pivot> getPivots()
{
return pivots;
}
}