mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-09-10 14:11:58 +00:00
Compare commits
45 Commits
tas-restap
...
tas-restap
Author | SHA1 | Date | |
---|---|---|---|
|
439dd3771f | ||
|
df7ebe30b3 | ||
|
c482153183 | ||
|
cdbd153151 | ||
|
8564f9eace | ||
|
b5d7500ecc | ||
|
e875e1fbbe | ||
|
32179dc810 | ||
|
97ed056103 | ||
|
af97fd5d6a | ||
|
cef6e8fc7b | ||
|
31d0578a98 | ||
|
2e1ae3bb69 | ||
|
9af05df046 | ||
|
71801e9e5e | ||
|
52149bf292 | ||
|
6cb07e1b86 | ||
|
fa3df0987d | ||
|
fde20c948f | ||
|
9ea1336a18 | ||
|
b007740dd0 | ||
|
15b10ba605 | ||
|
8983a11d3d | ||
|
6fd482b492 | ||
|
0a0c90a230 | ||
|
109af6abff | ||
|
43532eebf5 | ||
|
5dc3424fe2 | ||
|
133670cd17 | ||
|
909e95685e | ||
|
91e7b0d66f | ||
|
cc40cf05a9 | ||
|
4629c20b51 | ||
|
ee88946b1c | ||
|
b1faf15806 | ||
|
367ad20fb7 | ||
|
80e770f2da | ||
|
e8cf525792 | ||
|
a594341bb5 | ||
|
058e8d6302 | ||
|
91fcbb0b59 | ||
|
830898c605 | ||
|
d214040bc8 | ||
|
1b071cb555 | ||
|
37e04ee2fc |
@@ -4,7 +4,7 @@
|
||||
<groupId>org.alfresco.tas</groupId>
|
||||
<artifactId>restapi</artifactId>
|
||||
<name>alfresco-tas-restapi</name>
|
||||
<version>1.107</version>
|
||||
<version>1.120</version>
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-super-pom</artifactId>
|
||||
@@ -28,10 +28,10 @@
|
||||
<suiteXmlFile>src/main/resources/shared-resources/testCount.xml</suiteXmlFile>
|
||||
<maven.build.sourceVersion>11</maven.build.sourceVersion>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<tas.utility.version>3.0.49</tas.utility.version>
|
||||
<rest-assured.version>5.1.1</rest-assured.version>
|
||||
<tas.utility.version>3.0.55</tas.utility.version>
|
||||
<rest-assured.version>5.2.0</rest-assured.version>
|
||||
<httpclient-osgi-version>4.5.6</httpclient-osgi-version>
|
||||
<jackson-databind.version>2.13.3</jackson-databind.version>
|
||||
<jackson-databind.version>2.13.4</jackson-databind.version>
|
||||
<maven-release.version>2.5.3</maven-release.version>
|
||||
<org.glassfish.version>1.1.4</org.glassfish.version>
|
||||
<commons-lang3.version>3.12.0</commons-lang3.version>
|
||||
@@ -67,7 +67,7 @@
|
||||
<connection>scm:git:https://github.com/Alfresco/alfresco-tas-restapi.git</connection>
|
||||
<developerConnection>scm:git:https://github.com/Alfresco/alfresco-tas-restapi.git</developerConnection>
|
||||
<url>https://github.com/Alfresco/alfresco-tas-restapi</url>
|
||||
<tag>v1.107</tag>
|
||||
<tag>v1.120</tag>
|
||||
</scm>
|
||||
|
||||
<issueManagement>
|
||||
@@ -312,7 +312,7 @@
|
||||
<dependency>
|
||||
<groupId>org.slf4j</groupId>
|
||||
<artifactId>slf4j-api</artifactId>
|
||||
<version>1.7.36</version>
|
||||
<version>2.0.1</version>
|
||||
</dependency>
|
||||
|
||||
<!-- swagger parser -->
|
||||
@@ -352,7 +352,7 @@
|
||||
<dependency>
|
||||
<groupId>org.mockito</groupId>
|
||||
<artifactId>mockito-core</artifactId>
|
||||
<version>4.2.0</version>
|
||||
<version>4.8.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
@@ -362,7 +362,7 @@
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-project-info-reports-plugin</artifactId>
|
||||
<version>3.4.0</version>
|
||||
<version>3.4.1</version>
|
||||
<reportSets>
|
||||
<reportSet>
|
||||
<reports>
|
||||
|
@@ -28,7 +28,5 @@ package org.alfresco.rest.core;
|
||||
import org.alfresco.rest.core.assertion.IModelAssertion;
|
||||
|
||||
public interface IRestModel<Model> extends IModelAssertion<Model> {
|
||||
|
||||
public Model onModel();
|
||||
|
||||
Model onModel();
|
||||
}
|
||||
|
@@ -30,14 +30,14 @@ import static org.alfresco.utility.report.log.Step.STEP;
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.assertion.IModelsCollectionAssertion;
|
||||
import org.alfresco.rest.core.assertion.ModelsCollectionAssertion;
|
||||
import org.alfresco.rest.exception.EmptyRestModelCollectionException;
|
||||
import org.alfresco.rest.model.RestPaginationModel;
|
||||
import org.alfresco.rest.model.RestSiteModelsCollection;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
/**
|
||||
* Map multiple entries of JSON response to a class <T>
|
||||
*
|
||||
@@ -119,7 +119,7 @@ public abstract class RestModels<Model, ModelCollection> implements IRestModelsC
|
||||
@Override
|
||||
public ModelsCollectionAssertion<RestModels<Model, ModelCollection>> assertThat()
|
||||
{
|
||||
return new ModelsCollectionAssertion<RestModels<Model, ModelCollection>>(this);
|
||||
return new ModelsCollectionAssertion<>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@@ -27,16 +27,21 @@ package org.alfresco.rest.core;
|
||||
|
||||
import static org.alfresco.utility.report.log.Step.STEP;
|
||||
|
||||
import org.springframework.http.HttpMethod;
|
||||
import java.util.MissingFormatArgumentException;
|
||||
import java.util.regex.Pattern;
|
||||
import java.util.stream.Collectors;
|
||||
import java.util.stream.IntStream;
|
||||
|
||||
import io.restassured.RestAssured;
|
||||
import org.springframework.http.HttpMethod;
|
||||
|
||||
/**
|
||||
* @author Paul Brodner
|
||||
*/
|
||||
public class RestRequest
|
||||
{
|
||||
private String body = "";
|
||||
private static final String TOKEN_REGEX = "\\{.*?}";
|
||||
private String body;
|
||||
private HttpMethod httpMethod;
|
||||
private String path;
|
||||
private Object[] pathParams;
|
||||
@@ -44,10 +49,7 @@ public class RestRequest
|
||||
|
||||
private RestRequest(HttpMethod httpMethod, String path, String... pathParams)
|
||||
{
|
||||
setHttpMethod(httpMethod);
|
||||
setPath(path);
|
||||
setPathParams(pathParams);
|
||||
STEP(toString());
|
||||
this(httpMethod, "", path, pathParams);
|
||||
}
|
||||
|
||||
private RestRequest(HttpMethod httpMethod, String body, String path, String... pathParams)
|
||||
@@ -56,7 +58,8 @@ public class RestRequest
|
||||
setPath(path);
|
||||
setPathParams(pathParams);
|
||||
setBody(body);
|
||||
STEP(toString());
|
||||
// Validate that the supplied path and pathParams are compatible.
|
||||
constructPath();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -114,6 +117,7 @@ public class RestRequest
|
||||
public void setPath(String path)
|
||||
{
|
||||
this.path = path;
|
||||
addQueryParamsIfNeeded();
|
||||
}
|
||||
|
||||
public Object[] getPathParams()
|
||||
@@ -124,6 +128,32 @@ public class RestRequest
|
||||
public void setPathParams(Object[] pathParams)
|
||||
{
|
||||
this.pathParams = pathParams;
|
||||
addQueryParamsIfNeeded();
|
||||
}
|
||||
|
||||
/**
|
||||
* Add query parameters to the path if needed.
|
||||
* <p>
|
||||
* e.g. For a path of "api/{fruit}" and params ["apple", "size=10", "colour=red"] then this will
|
||||
* update the path to be "api/{fruit}?{param0}&{param1}" so that the tokens will be populated by
|
||||
* RestAssured to make "api/apple?size=10&colour=red".
|
||||
*/
|
||||
private void addQueryParamsIfNeeded()
|
||||
{
|
||||
// Don't do anything if the path or path params haven't been set yet.
|
||||
if (path == null || path.length() == 0 || pathParams == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int groupCount = (int) Pattern.compile(TOKEN_REGEX).matcher(path).results().count();
|
||||
if (pathParams.length > groupCount)
|
||||
{
|
||||
// Add the remaining parameters to the URL query.
|
||||
String queryParams = IntStream.range(0, pathParams.length - groupCount)
|
||||
.mapToObj(index -> "{parameter" + index + "}")
|
||||
.collect(Collectors.joining("&"));
|
||||
path += (path.contains("?") ? "&" : "?") + queryParams;
|
||||
}
|
||||
}
|
||||
|
||||
public String getContentType()
|
||||
@@ -136,6 +166,10 @@ public class RestRequest
|
||||
this.contentType = contentType;
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
* @throws MissingFormatArgumentException If there are not enough pathParams for the path.
|
||||
*/
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
@@ -144,19 +178,13 @@ public class RestRequest
|
||||
.append(getHttpMethod())
|
||||
.append(" ")
|
||||
.append(RestAssured.baseURI)
|
||||
.append(":")
|
||||
.append("://")
|
||||
.append(RestAssured.port)
|
||||
.append("/")
|
||||
.append(RestAssured.basePath)
|
||||
.append("/");
|
||||
|
||||
String getPathFormatted = getPath();
|
||||
if(getPath().contains("{"))
|
||||
{
|
||||
getPathFormatted = getPath().replaceAll("\\{.*?}", "%s");
|
||||
getPathFormatted = String.format(getPathFormatted, getPathParams());
|
||||
}
|
||||
sb.append(getPathFormatted);
|
||||
|
||||
sb.append(constructPath());
|
||||
|
||||
if(!getBody().isEmpty())
|
||||
{
|
||||
@@ -168,4 +196,21 @@ public class RestRequest
|
||||
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* Populate the path with the pathParams.
|
||||
*
|
||||
* @return The path with tokens replaced with values.
|
||||
* @throws MissingFormatArgumentException If there are not enough pathParams for the path.
|
||||
*/
|
||||
private String constructPath()
|
||||
{
|
||||
String getPathFormatted = getPath();
|
||||
if(getPath().contains("{"))
|
||||
{
|
||||
getPathFormatted = getPath().replaceAll(TOKEN_REGEX, "%s");
|
||||
getPathFormatted = String.format(getPathFormatted, getPathParams());
|
||||
}
|
||||
return getPathFormatted;
|
||||
}
|
||||
}
|
||||
|
@@ -77,6 +77,7 @@ import org.alfresco.utility.dsl.DSLWrapper;
|
||||
import org.alfresco.utility.model.StatusModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
import org.alfresco.utility.model.UserModel;
|
||||
import org.apache.commons.lang3.ArrayUtils;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import org.apache.xml.serialize.OutputFormat;
|
||||
@@ -620,7 +621,16 @@ public class RestWrapper extends DSLWrapper<RestWrapper>
|
||||
*/
|
||||
protected Response sendRequest(RestRequest restRequest)
|
||||
{
|
||||
Response returnedResponse = null;
|
||||
// If there are unused parameters then include them in the request.
|
||||
String parameters = getParameters();
|
||||
if (parameters != null && !parameters.isEmpty())
|
||||
{
|
||||
restRequest.setPathParams(ArrayUtils.addAll(restRequest.getPathParams(), parameters));
|
||||
}
|
||||
|
||||
STEP(restRequest.toString());
|
||||
|
||||
Response returnedResponse;
|
||||
switch (restRequest.getHttpMethod())
|
||||
{
|
||||
case GET:
|
||||
@@ -629,7 +639,6 @@ public class RestWrapper extends DSLWrapper<RestWrapper>
|
||||
case DELETE:
|
||||
returnedResponse = onRequest().delete(restRequest.getPath(), restRequest.getPathParams()).andReturn();
|
||||
break;
|
||||
|
||||
case HEAD:
|
||||
returnedResponse = onRequest().head(restRequest.getPath(), restRequest.getPathParams()).andReturn();
|
||||
break;
|
||||
@@ -867,6 +876,8 @@ public class RestWrapper extends DSLWrapper<RestWrapper>
|
||||
}
|
||||
|
||||
/**
|
||||
* Get and clear the stored parameters.
|
||||
*
|
||||
* @return parameters that you could pass on the request ?param=value
|
||||
*/
|
||||
public String getParameters()
|
||||
|
@@ -4,30 +4,36 @@
|
||||
* %%
|
||||
* Copyright (C) 2005 - 2022 Alfresco Software Limited
|
||||
* %%
|
||||
* This file is part of the Alfresco software.
|
||||
* If the software was purchased under a paid Alfresco license, the terms of
|
||||
* the paid license agreement will prevail. Otherwise, the software is
|
||||
* This file is part of the Alfresco software.
|
||||
* If the software was purchased under a paid Alfresco license, the terms of
|
||||
* the paid license agreement will prevail. Otherwise, the software is
|
||||
* provided under the following open source license terms:
|
||||
*
|
||||
*
|
||||
* Alfresco is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
*
|
||||
* Alfresco is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU Lesser General Public License for more details.
|
||||
*
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public License
|
||||
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
*/
|
||||
package org.alfresco.rest.core.assertion;
|
||||
|
||||
public interface IModelAssertion<Model>
|
||||
public interface IModelAssertion<Model>
|
||||
{
|
||||
public ModelAssertion<Model> and();
|
||||
|
||||
public ModelAssertion<Model> assertThat();
|
||||
default ModelAssertion<Model> assertThat()
|
||||
{
|
||||
return new ModelAssertion<>(this);
|
||||
}
|
||||
|
||||
default ModelAssertion<Model> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
}
|
||||
|
@@ -31,5 +31,9 @@ public interface IModelsCollectionAssertion<ModelCollection> {
|
||||
|
||||
public ModelsCollectionAssertion assertThat();
|
||||
|
||||
public ModelCollection when();
|
||||
@SuppressWarnings("unchecked")
|
||||
default ModelCollection when()
|
||||
{
|
||||
return (ModelCollection) this;
|
||||
}
|
||||
}
|
||||
|
@@ -33,14 +33,16 @@ import java.util.LinkedList;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import com.fasterxml.jackson.core.JsonProcessingException;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import com.google.gson.Gson;
|
||||
import com.google.gson.JsonObject;
|
||||
|
||||
import io.restassured.path.json.JsonPath;
|
||||
import org.alfresco.utility.exception.TestConfigurationException;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
import org.testng.Assert;
|
||||
|
||||
import com.fasterxml.jackson.core.JsonProcessingException;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import io.restassured.path.json.JsonPath;
|
||||
|
||||
/**
|
||||
* Assertion on Rest Model
|
||||
* Just pass your rest model as constructor
|
||||
@@ -57,7 +59,7 @@ public class ModelAssertion<T>
|
||||
Assert.fail(String.format("Field {%s} was not found in returned response.",fieldNameToBeRetuned));
|
||||
}
|
||||
}
|
||||
private Object model;
|
||||
private final Object model;
|
||||
|
||||
public ModelAssertion(Object model)
|
||||
{
|
||||
@@ -66,10 +68,11 @@ public class ModelAssertion<T>
|
||||
|
||||
/**
|
||||
* Use this DSL for asserting particular fields of your model if your model
|
||||
* is like this (basic POJO) public class Person extends
|
||||
* ModelAssertion<Person> { private String id = "1234"; you can use assert
|
||||
* the id of this person as:
|
||||
* Person p = new Person(); p.assertField("id").is("1234")
|
||||
* is like this (basic POJO)
|
||||
* public class Person extends ModelAssertion<Person>
|
||||
* { private String id = "1234"; }
|
||||
* you can use assert the id of this person as:
|
||||
* Person p = new Person(); p.assertThat().field("id").is("1234")
|
||||
*
|
||||
* @param fieldName
|
||||
* @return
|
||||
@@ -120,6 +123,24 @@ public class ModelAssertion<T>
|
||||
return new AssertionItemVerbs(model, actualSize);
|
||||
}
|
||||
|
||||
/**
|
||||
* Use this method for asserting whole model with different model object. Method allows to ignore particular fields during the comparison.
|
||||
*
|
||||
* WARNING: For proper work model should implement {@code toString()} and {@code equals()} methods.
|
||||
*
|
||||
* @param expected - expected model.
|
||||
* @param ignoreFields - fields which should be ignored during assertion.
|
||||
* @return model.
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
public T isEqualTo(T expected, String... ignoreFields)
|
||||
{
|
||||
T modelCopy = createCopyIgnoringFields((T) model, ignoreFields);
|
||||
T expectedCopy = createCopyIgnoringFields(expected, ignoreFields);
|
||||
Assert.assertEquals(modelCopy, expectedCopy, String.format("Compared objects of type: %s are not equal!", model.getClass()));
|
||||
return (T) model;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get all fields declared from all classes hierarchy
|
||||
*
|
||||
@@ -144,6 +165,18 @@ public class ModelAssertion<T>
|
||||
return fields;
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
private T createCopyIgnoringFields(T model, String... ignoreFields)
|
||||
{
|
||||
Gson gson = new Gson();
|
||||
JsonObject jsonObject = gson.fromJson(gson.toJson(model), JsonObject.class);
|
||||
for (String ignoreField : ignoreFields)
|
||||
{
|
||||
jsonObject.remove(ignoreField);
|
||||
}
|
||||
return gson.fromJson(gson.toJson(jsonObject), (Class<? extends T>) model.getClass());
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL assertion on Rest Model fields
|
||||
*
|
||||
|
@@ -25,13 +25,13 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestAbstractClassModel extends TestModel implements IRestModel<RestAbstractClassModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
@@ -164,20 +164,4 @@ public class RestAbstractClassModel extends TestModel implements IRestModel<Rest
|
||||
{
|
||||
this.modelInfo = modelInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestAbstractClassModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestAbstractClassModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestAbstractClassModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
}
|
||||
|
@@ -25,14 +25,13 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
import java.util.Objects;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'Kristian.Dimitrov@hyland.com' on '2022-07-14 13:22' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -40,18 +39,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestActionBodyExecTemplateModel extends TestModel implements IRestModel<RestActionBodyExecTemplateModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestActionBodyExecTemplateModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestActionBodyExecTemplateModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestActionBodyExecTemplateModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestActionBodyExecTemplateModel model;
|
||||
|
||||
@@ -85,6 +72,29 @@ public class RestActionBodyExecTemplateModel extends TestModel implements IRestM
|
||||
public void setParams(Object params)
|
||||
{
|
||||
this.params = params;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
return "RestActionBodyExecTemplateModel{" + "actionDefinitionId='" + actionDefinitionId + '\'' + ", params=" + params + '}';
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o)
|
||||
{
|
||||
if (this == o)
|
||||
return true;
|
||||
if (o == null || getClass() != o.getClass())
|
||||
return false;
|
||||
RestActionBodyExecTemplateModel that = (RestActionBodyExecTemplateModel) o;
|
||||
return Objects.equals(actionDefinitionId, that.actionDefinitionId) && Objects.equals(params, that.params);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode()
|
||||
{
|
||||
return Objects.hash(actionDefinitionId, params);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -26,11 +26,12 @@
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestActionDefinitionModel extends TestModel implements IRestModel<RestActionDefinitionModel>
|
||||
{
|
||||
|
||||
@@ -125,18 +126,6 @@ public class RestActionDefinitionModel extends TestModel implements IRestModel<R
|
||||
this.parameterDefinitions = parameterDefinitions;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestActionDefinitionModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestActionDefinitionModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestActionDefinitionModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public RestActionDefinitionModel onModel()
|
||||
{
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author Cristina Axinte
|
||||
@@ -159,17 +158,4 @@ public class RestActivityModel extends TestModel implements IRestModel<RestActiv
|
||||
{
|
||||
this.activitySummary = activitySummary;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestActivityModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestActivityModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestActivityModel>(this);
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -25,13 +25,12 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.constants.UserRole;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
/**
|
||||
*
|
||||
* "activitySummary": {
|
||||
@@ -142,14 +141,4 @@ public class RestActivitySummaryModel extends TestModel implements IRestModel<Re
|
||||
{
|
||||
this.objectId = objectId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestActivitySummaryModel> and() {
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestActivitySummaryModel> assertThat() {
|
||||
return new ModelAssertion<RestActivitySummaryModel>(this);
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestAggregateModel extends TestModel implements IRestModel<RestAggregateModel>
|
||||
{
|
||||
@JsonProperty(value = "aggregate")
|
||||
@@ -65,16 +64,4 @@ public class RestAggregateModel extends TestModel implements IRestModel<RestAggr
|
||||
{
|
||||
this.average = average;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestAggregateModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestAggregateModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestAggregateModel>(this);
|
||||
}
|
||||
}
|
||||
|
@@ -31,12 +31,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'dedwards' on '2021-12-16 08:32' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -44,18 +43,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestArchiveContentRequestModel extends TestModel implements IRestModel<RestArchiveContentRequestModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestArchiveContentRequestModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestArchiveContentRequestModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestArchiveContentRequestModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestArchiveContentRequestModel model;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'aepure' on '2017-06-29 15:31' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -38,18 +37,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestAuditAppModel extends TestModel implements IRestModel<RestAuditAppModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestAuditAppModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestAuditAppModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestAuditAppModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestAuditAppModel model;
|
||||
|
||||
|
@@ -27,26 +27,13 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestAuditEntryModel extends TestModel implements IRestModel<RestAuditEntryModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestAuditEntryModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestAuditEntryModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestAuditEntryModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestAuditEntryModel model;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestCandidateModel extends TestModel implements IRestModel<RestCandidateModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
@@ -69,16 +68,4 @@ public class RestCandidateModel extends TestModel implements IRestModel<RestCand
|
||||
{
|
||||
this.candidateId = candidateId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestCandidateModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestCandidateModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestCandidateModel>(this);
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestCommentModel extends TestModel implements IRestModel<RestCommentModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
@@ -141,17 +140,4 @@ public class RestCommentModel extends TestModel implements IRestModel<RestCommen
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestCommentModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestCommentModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestCommentModel>(this);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -25,7 +25,9 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
@@ -40,8 +42,10 @@ import org.alfresco.utility.model.TestModel;
|
||||
"email": "qLZ41D2QnXQcqySNK09J@yahoo.com"
|
||||
}
|
||||
*/
|
||||
public class RestCompanyModel extends TestModel
|
||||
public class RestCompanyModel extends TestModel implements IRestModel<RestCompanyModel>
|
||||
{
|
||||
@JsonProperty (value = "entry")
|
||||
RestCompanyModel model;
|
||||
private String organization;
|
||||
private String address1;
|
||||
private String address2;
|
||||
@@ -51,16 +55,12 @@ public class RestCompanyModel extends TestModel
|
||||
private String fax;
|
||||
private String email;
|
||||
|
||||
public ModelAssertion<RestCompanyModel> assertThat()
|
||||
@Override
|
||||
public RestCompanyModel onModel()
|
||||
{
|
||||
return new ModelAssertion<RestCompanyModel>(this);
|
||||
return model;
|
||||
}
|
||||
|
||||
public ModelAssertion<RestCompanyModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
public String getOrganization()
|
||||
{
|
||||
return organization;
|
||||
@@ -140,5 +140,4 @@ public class RestCompanyModel extends TestModel
|
||||
{
|
||||
this.email = email;
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -26,13 +26,13 @@
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
import java.util.Objects;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'Kristian.Dimitrov@hyland.com' on '2022-07-13 15:53' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -40,18 +40,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestCompositeConditionDefinitionModel extends TestModel implements IRestModel<RestCompositeConditionDefinitionModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestCompositeConditionDefinitionModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestCompositeConditionDefinitionModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestCompositeConditionDefinitionModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestCompositeConditionDefinitionModel model;
|
||||
|
||||
@@ -120,6 +108,31 @@ public class RestCompositeConditionDefinitionModel extends TestModel implements
|
||||
public void setSimpleConditions(List<RestSimpleConditionDefinitionModel> simpleConditions)
|
||||
{
|
||||
this.simpleConditions = simpleConditions;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
return "RestCompositeConditionDefinitionModel{" + "inverted=" + inverted + ", booleanMode='" + booleanMode + '\'' + ", compositeConditions=" + compositeConditions
|
||||
+ ", simpleConditions=" + simpleConditions + '}';
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o)
|
||||
{
|
||||
if (this == o)
|
||||
return true;
|
||||
if (o == null || getClass() != o.getClass())
|
||||
return false;
|
||||
RestCompositeConditionDefinitionModel that = (RestCompositeConditionDefinitionModel) o;
|
||||
return inverted == that.inverted && Objects.equals(booleanMode, that.booleanMode) && Objects.equals(compositeConditions, that.compositeConditions) && Objects.equals(
|
||||
simpleConditions, that.simpleConditions);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode()
|
||||
{
|
||||
return Objects.hash(inverted, booleanMode, compositeConditions, simpleConditions);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -33,12 +33,11 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'dedwards' on '2021-12-16 08:32' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -46,18 +45,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestContentStorageInfoModel extends TestModel implements IRestModel<RestContentStorageInfoModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestContentStorageInfoModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestContentStorageInfoModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestContentStorageInfoModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestContentStorageInfoModel model;
|
||||
|
||||
|
@@ -28,31 +28,18 @@ package org.alfresco.rest.model;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.CustomAspectModel;
|
||||
import org.alfresco.utility.model.CustomAspectPropertiesModel;
|
||||
import org.testng.Assert;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
/**
|
||||
* @author Bogdan Bocancea
|
||||
*/
|
||||
public class RestCustomAspectModel extends CustomAspectModel implements IRestModel<RestCustomAspectModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestCustomAspectModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestCustomAspectModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestCustomAspectModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestCustomAspectModel model;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.CustomContentModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.CustomContentModel;
|
||||
|
||||
/**
|
||||
* @author Bogdan Bocancea
|
||||
*/
|
||||
@@ -39,18 +38,6 @@ public class RestCustomModel extends CustomContentModel implements IRestModel<Re
|
||||
@JsonProperty(value = "entry")
|
||||
RestCustomModel model;
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestCustomModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestCustomModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public RestCustomModel onModel()
|
||||
{
|
||||
|
@@ -25,14 +25,14 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.CustomAspectPropertiesModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author Bogdan Bocancea
|
||||
*/
|
||||
@@ -80,18 +80,6 @@ public class RestCustomTypeModel extends TestModel implements IRestModel<RestCus
|
||||
return model;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestCustomTypeModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestCustomTypeModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestCustomTypeModel>(this);
|
||||
}
|
||||
|
||||
public String getName()
|
||||
{
|
||||
return name;
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Handles single Deployment Entry JSON response
|
||||
* "entry": {
|
||||
@@ -108,16 +107,4 @@ public class RestDeploymentModel extends TestModel implements IRestModel<RestDep
|
||||
{
|
||||
this.deployedAt = deployedAt;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestDeploymentModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestDeploymentModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<>(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -25,26 +25,13 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestDiscoveryModel extends TestModel implements IRestModel<RestDiscoveryModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestDiscoveryModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestDiscoveryModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestDiscoveryModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestDiscoveryModel model;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/*
|
||||
* Handles responses for GET /downloads/{downloadId} and POST /downloads rest calls
|
||||
* E.g
|
||||
@@ -48,18 +47,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
public class RestDownloadsModel extends TestModel implements IRestModel<RestDownloadsModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestDownloadsModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestDownloadsModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestDownloadsModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestDownloadsModel model;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'aforascu' on '2018-01-10 16:02' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -38,18 +37,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestEntitlementsInfoModel extends TestModel implements IRestModel<RestEntitlementsInfoModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestEntitlementsInfoModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestEntitlementsInfoModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestEntitlementsInfoModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestEntitlementsInfoModel model;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestFavoriteSiteModel extends TestModel implements IRestModel<RestFavoriteSiteModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
@@ -52,16 +51,4 @@ public class RestFavoriteSiteModel extends TestModel implements IRestModel<RestF
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestFavoriteSiteModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestFavoriteSiteModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestFavoriteSiteModel>(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Handles single Folder JSON responses
|
||||
* Example:
|
||||
@@ -270,16 +269,4 @@ public class RestFileModel extends TestModel implements IRestModel<RestFileModel
|
||||
{
|
||||
this.path = path;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestFileModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestFileModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestFileModel>(this);
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Handles single Folder JSON responses
|
||||
* Example:
|
||||
@@ -217,16 +216,4 @@ public class RestFolderModel extends TestModel implements IRestModel<RestFolderM
|
||||
{
|
||||
this.path = path;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestFolderModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestFolderModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestFolderModel>(this);
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Handles single representation of a Start Form Model
|
||||
* * "entry": {
|
||||
@@ -133,20 +132,4 @@ public class RestFormModel extends TestModel implements IRestModel<RestFormModel
|
||||
{
|
||||
this.required = required;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestFormModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestFormModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestFormModel>(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -27,13 +27,12 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.rest.search.RestGenericMetricModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
/**
|
||||
* Generated by 'msuzuki' on '2017-05-15 13:08' from 'Alfresco Search REST API' swagger file
|
||||
* Generated from 'Alfresco Search REST API' swagger file
|
||||
@@ -41,18 +40,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestGenericBucketModel extends TestModel implements IRestModel<RestGenericBucketModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestGenericBucketModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestGenericBucketModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestGenericBucketModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestGenericBucketModel model;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestGroupMember extends TestModel implements IRestModel<RestGroupMember>
|
||||
{
|
||||
@JsonProperty(required = true)
|
||||
@@ -43,19 +42,6 @@ public class RestGroupMember extends TestModel implements IRestModel<RestGroupMe
|
||||
@JsonProperty(value = "entry")
|
||||
RestGroupMember model;
|
||||
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestGroupMember> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestGroupMember> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestGroupMember>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public RestGroupMember onModel()
|
||||
{
|
||||
|
@@ -27,12 +27,11 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestGroupsModel extends TestModel implements IRestModel<RestGroupsModel>
|
||||
{
|
||||
@JsonProperty(required = true)
|
||||
@@ -50,19 +49,6 @@ public class RestGroupsModel extends TestModel implements IRestModel<RestGroupsM
|
||||
@JsonProperty(value = "entry")
|
||||
RestGroupsModel model;
|
||||
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestGroupsModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestGroupsModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestGroupsModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public RestGroupsModel onModel()
|
||||
{
|
||||
|
@@ -27,12 +27,10 @@ package org.alfresco.rest.model;
|
||||
|
||||
import static org.alfresco.utility.report.log.Step.STEP;
|
||||
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.Utility;
|
||||
import org.testng.Assert;
|
||||
|
||||
import io.restassured.http.Headers;
|
||||
import io.restassured.response.ResponseBody;
|
||||
import org.alfresco.utility.Utility;
|
||||
import org.testng.Assert;
|
||||
|
||||
/**
|
||||
* Created by Claudia Agache on 10/13/2016.
|
||||
@@ -68,21 +66,6 @@ public class RestHtmlResponse
|
||||
Assert.assertFalse(body.toString().isEmpty(), "Body should not be empty.");
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public ModelAssertion<RestHtmlResponse> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestHtmlResponse>(this);
|
||||
}
|
||||
|
||||
public ModelAssertion<RestHtmlResponse> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
/**
|
||||
* Assetion that a html element with specific html path has the specified value
|
||||
*
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
*
|
||||
"entry": {
|
||||
@@ -130,16 +129,4 @@ public class RestItemModel extends TestModel implements IRestModel<RestItemModel
|
||||
{
|
||||
this.modifiedAt = modifiedAt;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestItemModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestItemModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestItemModel>(this);
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'aforascu' on '2018-01-10 16:02' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -38,18 +37,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestLicenseInfoModel extends TestModel implements IRestModel<RestLicenseInfoModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestLicenseInfoModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestLicenseInfoModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestLicenseInfoModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestLicenseInfoModel model;
|
||||
|
||||
|
@@ -25,14 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
/**
|
||||
* Generated by 'Kristian.Dimitrov@hyland.com' on '2022-07-13 15:53' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -40,18 +37,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestLinkedRuleSetBodyCreateModel extends TestModel implements IRestModel<RestLinkedRuleSetBodyCreateModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestLinkedRuleSetBodyCreateModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestLinkedRuleSetBodyCreateModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestLinkedRuleSetBodyCreateModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestLinkedRuleSetBodyCreateModel model;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'aforascu' on '2018-01-10 16:02' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -38,18 +37,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestModuleInfoModel extends TestModel implements IRestModel<RestModuleInfoModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestModuleInfoModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestModuleInfoModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestModuleInfoModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestModuleInfoModel model;
|
||||
|
||||
|
@@ -27,13 +27,12 @@ package org.alfresco.rest.model;
|
||||
|
||||
import static org.alfresco.utility.report.log.Step.STEP;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.UserModel;
|
||||
import org.testng.Assert;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
/**
|
||||
* Created by Cristina Axinte on 9/26/2016.
|
||||
*
|
||||
@@ -89,20 +88,4 @@ public class RestNetworkModel extends RestPersonNetworkModel implements IRestMod
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestNetworkModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestNetworkModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestNetworkModel>(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -25,30 +25,17 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'pbrodner' on '2016-12-19 14:12' from 'Alfresco Core REST API' swagger file
|
||||
* Base Path {@linkplain /alfresco/api/-default-/public/alfresco/versions/1}
|
||||
*/
|
||||
public class RestNetworkQuotaModel extends TestModel implements IRestModel<RestNetworkQuotaModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestNetworkQuotaModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestNetworkQuotaModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestNetworkQuotaModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestNetworkQuotaModel model;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestNodeAssocTargetModel extends TestModel implements IRestModel<RestNodeAssocTargetModel>
|
||||
{
|
||||
@JsonProperty(value = "aggregate")
|
||||
@@ -77,17 +76,4 @@ public class RestNodeAssocTargetModel extends TestModel implements IRestModel<Re
|
||||
{
|
||||
this.assocType = assocType;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestNodeAssocTargetModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestNodeAssocTargetModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestNodeAssocTargetModel>(this);
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -27,29 +27,16 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Created by Andrei Forascu on 30/08/2017.
|
||||
*/
|
||||
public class RestNodeAssociationModel extends TestModel implements IRestModel<RestNodeAssociationModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestNodeAssociationModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestNodeAssociationModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestNodeAssociationModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestNodeAssociationModel model;
|
||||
|
||||
|
@@ -25,29 +25,16 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Represents an association between two nodes
|
||||
*/
|
||||
public class RestNodeAssociationTypeModel extends TestModel implements IRestModel<RestNodeAssociationTypeModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestNodeAssociationTypeModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestNodeAssociationTypeModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestNodeAssociationTypeModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestNodeAssociationTypeModel model;
|
||||
|
||||
|
@@ -27,30 +27,17 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated from 'Alfresco Core REST API' swagger file
|
||||
* Base Path {@linkplain /alfresco/api/-default-/public/alfresco/versions/1}
|
||||
*/
|
||||
public class RestNodeBodyModel extends TestModel implements IRestModel<RestNodeBodyModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestNodeBodyModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestNodeBodyModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestNodeBodyModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestNodeBodyModel model;
|
||||
|
||||
|
@@ -25,26 +25,13 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestNodeChildAssociationModel extends TestModel implements IRestModel<RestNodeChildAssociationModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestNodeChildAssociationModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestNodeChildAssociationModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestNodeChildAssociationModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public RestNodeChildAssociationModel onModel()
|
||||
{
|
||||
|
@@ -27,30 +27,17 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated from 'Alfresco Core REST API' swagger file
|
||||
* Base Path {@linkplain /alfresco/api/-default-/public/alfresco/versions/1}
|
||||
*/
|
||||
public class RestNodeModel extends TestModel implements IRestModel<RestNodeModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestNodeModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestNodeModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestNodeModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestNodeModel model;
|
||||
|
||||
|
@@ -26,7 +26,6 @@
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.assertion.IModelAssertion;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
@@ -107,16 +106,4 @@ public class RestPaginationModel extends TestModel implements IModelAssertion<Re
|
||||
{
|
||||
this.maxItems = maxItems;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestPaginationModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestPaginationModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestParameterDefinitionModel extends TestModel implements IRestModel<RestParameterDefinitionModel>
|
||||
{
|
||||
private String name;
|
||||
@@ -113,18 +112,6 @@ public class RestParameterDefinitionModel extends TestModel implements IRestMode
|
||||
@JsonProperty(value = "entry")
|
||||
RestParameterDefinitionModel parameterDefinitionModel;
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestParameterDefinitionModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestParameterDefinitionModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestParameterDefinitionModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public RestParameterDefinitionModel onModel()
|
||||
{
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestPersonFavoritesModel extends TestModel implements IRestModel<RestPersonFavoritesModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
@@ -87,17 +86,4 @@ public class RestPersonFavoritesModel extends TestModel implements IRestModel<Re
|
||||
{
|
||||
this.createdAt = createdAt;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestPersonFavoritesModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestPersonFavoritesModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -28,36 +28,17 @@ package org.alfresco.rest.model;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.IModelAssertion;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
/**
|
||||
* Person Model implementation
|
||||
*/
|
||||
public class RestPersonModel extends TestModel implements IModelAssertion<RestPersonModel>, IRestModel<RestPersonModel>
|
||||
{
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestPersonModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestPersonModel>(this);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestPersonModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestPersonModel personModel;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Handles Pagination JSON
|
||||
*
|
||||
@@ -74,16 +73,4 @@ public class RestPreferenceModel extends TestModel implements IRestModel<RestPre
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestPreferenceModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestPreferenceModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestPreferenceModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Handles single Process Definition Entry JSON response
|
||||
* "entry": {
|
||||
@@ -169,18 +168,5 @@ public class RestProcessDefinitionModel extends TestModel implements IRestModel<
|
||||
{
|
||||
this.version = version;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestProcessDefinitionModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestProcessDefinitionModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestProcessDefinitionModel>(this);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -25,13 +25,12 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.IModelAssertion;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.ProcessModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
/**
|
||||
* Handles single Process Entry JSON response
|
||||
* "entry": {
|
||||
@@ -126,22 +125,6 @@ public class RestProcessModel extends ProcessModel implements IRestModel<RestPro
|
||||
this.startedAt = startedAt;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestProcessModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestProcessModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestProcessModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
public String getDurationInMs()
|
||||
{
|
||||
return durationInMs;
|
||||
|
@@ -25,13 +25,12 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.data.RandomData;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
public class RestProcessVariableModel extends TestModel implements IRestModel<RestProcessVariableModel>
|
||||
{
|
||||
private String name;
|
||||
@@ -93,18 +92,4 @@ public class RestProcessVariableModel extends TestModel implements IRestModel<Re
|
||||
public static RestProcessVariableModel getRandomProcessVariableModel(String variableType){
|
||||
return new RestProcessVariableModel(RandomData.getRandomName("name"), RandomData.getRandomName("value"), variableType);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestProcessVariableModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestProcessVariableModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestProcessVariableModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestRatingModel extends TestModel implements IRestModel<RestRatingModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
@@ -88,16 +87,4 @@ public class RestRatingModel extends TestModel implements IRestModel<RestRatingM
|
||||
{
|
||||
this.myRating = myRating;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRatingModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRatingModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -25,30 +25,19 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* @author cmocanu
|
||||
* Base Path
|
||||
* {@linkplain /alfresco/api/-default-/public/alfresco/versions/1}
|
||||
*/
|
||||
|
||||
public class RestRenditionInfoModel extends TestModel implements IRestModel<RestRenditionInfoModel> {
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRenditionInfoModel> and() {
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRenditionInfoModel> assertThat() {
|
||||
return new ModelAssertion<RestRenditionInfoModel>(this);
|
||||
}
|
||||
|
||||
public class RestRenditionInfoModel extends TestModel implements IRestModel<RestRenditionInfoModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
RestRenditionInfoModel model;
|
||||
|
||||
|
@@ -27,12 +27,11 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'aforascu' on '2018-01-10 16:02' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -40,18 +39,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestRepositoryInfoModel extends TestModel implements IRestModel<RestRepositoryInfoModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestRepositoryInfoModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestRepositoryInfoModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRepositoryInfoModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestRepositoryInfoModel model;
|
||||
|
||||
|
@@ -27,12 +27,11 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'msuzuki' on '2017-05-15 10:58' from 'Alfresco Search REST API' swagger file
|
||||
* Generated from 'Alfresco Search REST API' swagger file
|
||||
@@ -40,18 +39,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestRequestRangesModel extends TestModel implements IRestModel<RestRequestRangesModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestRequestRangesModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestRequestRangesModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRequestRangesModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestRequestRangesModel model;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'msuzuki' on '2017-02-28 16:04' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -38,18 +37,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestRequestSpellcheckModel extends TestModel implements IRestModel<RestRequestSpellcheckModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestRequestSpellcheckModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestRequestSpellcheckModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRequestSpellcheckModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestRequestSpellcheckModel model;
|
||||
|
||||
|
@@ -31,12 +31,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'dedwards' on '2021-12-16 08:32' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -44,18 +43,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestRestoreArchivedContentRequestModel extends TestModel implements IRestModel<RestRestoreArchivedContentRequestModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestRestoreArchivedContentRequestModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestRestoreArchivedContentRequestModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRestoreArchivedContentRequestModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestRestoreArchivedContentRequestModel model;
|
||||
|
||||
|
@@ -27,12 +27,11 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'Kristian.Dimitrov@hyland.com' on '2022-07-13 15:53' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -40,18 +39,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestRuleBodyModel extends TestModel implements IRestModel<RestRuleBodyModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestRuleBodyModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestRuleBodyModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRuleBodyModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestRuleBodyModel model;
|
||||
|
||||
|
@@ -26,13 +26,13 @@
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
import java.util.Objects;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'Kristian.Dimitrov@hyland.com' on '2022-07-13 15:53' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -40,18 +40,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestRuleModel extends TestModel implements IRestModel<RestRuleModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestRuleModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestRuleModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRuleModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestRuleModel model;
|
||||
|
||||
@@ -98,12 +86,10 @@ public class RestRuleModel extends TestModel implements IRestModel<RestRuleModel
|
||||
*/
|
||||
|
||||
private String errorScript;
|
||||
/**
|
||||
Whether the rule has been shared with more than one folder
|
||||
*/
|
||||
/** True if the rule set is linked to, or if the rule is inheritable and the rule set is inherited by a folder with inheriting enabled. */
|
||||
@JsonProperty
|
||||
private Boolean isShared;
|
||||
|
||||
@JsonProperty(required = true)
|
||||
private boolean shared;
|
||||
/**
|
||||
The set of triggers that cause the rule to be activated.
|
||||
* inbound - The rule should be activated when an item enters the folder
|
||||
@@ -200,14 +186,14 @@ If the field is omitted then the rule will apply to all nodes.
|
||||
this.errorScript = errorScript;
|
||||
}
|
||||
|
||||
public boolean getShared()
|
||||
public Boolean getIsShared()
|
||||
{
|
||||
return this.shared;
|
||||
return this.isShared;
|
||||
}
|
||||
|
||||
public void setShared(boolean shared)
|
||||
public void setIsShared(Boolean shared)
|
||||
{
|
||||
this.shared = shared;
|
||||
this.isShared = shared;
|
||||
}
|
||||
|
||||
public List<String> getTriggers()
|
||||
@@ -238,6 +224,34 @@ If the field is omitted then the rule will apply to all nodes.
|
||||
public void setActions(List<RestActionBodyExecTemplateModel> actions)
|
||||
{
|
||||
this.actions = actions;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
return "RestRuleModel{" + "id='" + id + '\'' + ", name='" + name + '\'' + ", description='" + description + '\'' + ", enabled=" + enabled + ", cascade=" + cascade
|
||||
+ ", asynchronous=" + asynchronous + ", errorScript='" + errorScript + '\'' + ", isShared=" + isShared + ", triggers=" + triggers + ", conditions=" + conditions
|
||||
+ ", actions=" + actions + '}';
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o)
|
||||
{
|
||||
if (this == o)
|
||||
return true;
|
||||
if (o == null || getClass() != o.getClass())
|
||||
return false;
|
||||
RestRuleModel ruleModel = (RestRuleModel) o;
|
||||
return enabled == ruleModel.enabled && cascade == ruleModel.cascade && asynchronous == ruleModel.asynchronous && Objects.equals(id, ruleModel.id) && Objects.equals(
|
||||
name, ruleModel.name) && Objects.equals(description, ruleModel.description) && Objects.equals(errorScript, ruleModel.errorScript) && Objects.equals(
|
||||
isShared, ruleModel.isShared) && Objects.equals(triggers, ruleModel.triggers) && Objects.equals(conditions, ruleModel.conditions) && Objects.equals(
|
||||
actions, ruleModel.actions);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode()
|
||||
{
|
||||
return Objects.hash(id, name, description, enabled, cascade, asynchronous, errorScript, isShared, triggers, conditions, actions);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -27,12 +27,11 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'Kristian.Dimitrov@hyland.com' on '2022-07-13 15:53' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -40,18 +39,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestRuleSetBodyUpdateModel extends TestModel implements IRestModel<RestRuleSetBodyUpdateModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestRuleSetBodyUpdateModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestRuleSetBodyUpdateModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRuleSetBodyUpdateModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestRuleSetBodyUpdateModel model;
|
||||
|
||||
|
@@ -0,0 +1,81 @@
|
||||
/*-
|
||||
* #%L
|
||||
* alfresco-tas-restapi
|
||||
* %%
|
||||
* Copyright (C) 2005 - 2022 Alfresco Software Limited
|
||||
* %%
|
||||
* This file is part of the Alfresco software.
|
||||
* If the software was purchased under a paid Alfresco license, the terms of
|
||||
* the paid license agreement will prevail. Otherwise, the software is
|
||||
* provided under the following open source license terms:
|
||||
*
|
||||
* Alfresco is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* Alfresco is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public License
|
||||
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
*/
|
||||
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'mpichura' on '2022-08-29 12:27' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
* Base Path {@linkplain /alfresco/api/-default-/public/alfresco/versions/1}
|
||||
*/
|
||||
public class RestRuleSetLinkModel extends TestModel implements IRestModel<RestRuleSetLinkModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
RestRuleSetLinkModel model;
|
||||
|
||||
@Override
|
||||
public RestRuleSetLinkModel onModel()
|
||||
{
|
||||
return model;
|
||||
}
|
||||
|
||||
/**
|
||||
Identifier for the folder node containing the rule set or the rule set node itself.
|
||||
*/
|
||||
|
||||
private String id;
|
||||
|
||||
public String getId()
|
||||
{
|
||||
return this.id;
|
||||
}
|
||||
|
||||
public void setId(String id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o)
|
||||
{
|
||||
if (this == o) return true;
|
||||
if (o == null || getClass() != o.getClass()) return false;
|
||||
RestRuleSetLinkModel that = (RestRuleSetLinkModel) o;
|
||||
return id.equals(that.id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode()
|
||||
{
|
||||
return Objects.hash(id);
|
||||
}
|
||||
}
|
@@ -25,10 +25,12 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
@@ -38,18 +40,6 @@ import org.alfresco.utility.model.TestModel;
|
||||
*/
|
||||
public class RestRuleSetModel extends TestModel implements IRestModel<RestRuleSetModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestRuleSetModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestRuleSetModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty (value = "entry")
|
||||
RestRuleSetModel model;
|
||||
|
||||
@@ -68,6 +58,14 @@ public class RestRuleSetModel extends TestModel implements IRestModel<RestRuleSe
|
||||
private String owningFolder;
|
||||
/** The reason why the rule set is included for the folder. */
|
||||
private String inclusionType;
|
||||
/** A list of node ids for folders that inherit this rule set. */
|
||||
private List<String> inheritedBy;
|
||||
/** A list of node ids for folders that link to this rule set. */
|
||||
private List<String> linkedToBy;
|
||||
/** Whether any folders inherit this rule set. */
|
||||
private Boolean isInherited;
|
||||
/** Whether any folders link to this rule set. */
|
||||
private Boolean isLinkedTo;
|
||||
|
||||
public String getId()
|
||||
{
|
||||
@@ -98,4 +96,73 @@ public class RestRuleSetModel extends TestModel implements IRestModel<RestRuleSe
|
||||
{
|
||||
this.inclusionType = inclusionType;
|
||||
}
|
||||
|
||||
public List<String> getInheritedBy()
|
||||
{
|
||||
return inheritedBy;
|
||||
}
|
||||
|
||||
public void setInheritedBy(List<String> inheritedBy)
|
||||
{
|
||||
this.inheritedBy = inheritedBy;
|
||||
}
|
||||
|
||||
public List<String> getLinkedToBy()
|
||||
{
|
||||
return linkedToBy;
|
||||
}
|
||||
|
||||
public void setLinkedToBy(List<String> linkedToBy)
|
||||
{
|
||||
this.linkedToBy = linkedToBy;
|
||||
}
|
||||
|
||||
public Boolean getInherited()
|
||||
{
|
||||
return isInherited;
|
||||
}
|
||||
|
||||
public void setInherited(Boolean inherited)
|
||||
{
|
||||
isInherited = inherited;
|
||||
}
|
||||
|
||||
public Boolean getLinkedTo()
|
||||
{
|
||||
return isLinkedTo;
|
||||
}
|
||||
|
||||
public void setLinkedTo(Boolean linkedTo)
|
||||
{
|
||||
isLinkedTo = linkedTo;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
return "RestRuleSetModel{id='" + id + "', owningFolder='" + owningFolder + "', inclusionType='" + inclusionType
|
||||
+ "', inheritedBy=" + inheritedBy + ", linkedToBy=" + linkedToBy + ", isInherited=" + isInherited
|
||||
+ ", isLinkedTo=" + isLinkedTo + "}";
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o)
|
||||
{
|
||||
if (this == o) return true;
|
||||
if (o == null || getClass() != o.getClass()) return false;
|
||||
RestRuleSetModel that = (RestRuleSetModel) o;
|
||||
return Objects.equals(id, that.id)
|
||||
&& Objects.equals(owningFolder, that.owningFolder)
|
||||
&& Objects.equals(inclusionType, that.inclusionType)
|
||||
&& Objects.equals(inheritedBy, that.inheritedBy)
|
||||
&& Objects.equals(linkedToBy, that.linkedToBy)
|
||||
&& Objects.equals(isInherited, that.isInherited)
|
||||
&& Objects.equals(isLinkedTo, that.isLinkedTo);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode()
|
||||
{
|
||||
return Objects.hash(id, owningFolder, inclusionType, inheritedBy, linkedToBy, isInherited, isLinkedTo);
|
||||
}
|
||||
}
|
||||
|
@@ -0,0 +1,101 @@
|
||||
/*-
|
||||
* #%L
|
||||
* alfresco-tas-restapi
|
||||
* %%
|
||||
* Copyright (C) 2005 - 2022 Alfresco Software Limited
|
||||
* %%
|
||||
* This file is part of the Alfresco software.
|
||||
* If the software was purchased under a paid Alfresco license, the terms of
|
||||
* the paid license agreement will prevail. Otherwise, the software is
|
||||
* provided under the following open source license terms:
|
||||
*
|
||||
* Alfresco is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* Alfresco is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public License
|
||||
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import java.util.Objects;
|
||||
import java.util.StringJoiner;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestRuleSettingsModel extends TestModel implements IRestModel<RestRuleSettingsModel>
|
||||
{
|
||||
@JsonProperty (value = "entry")
|
||||
private RestRuleSettingsModel model;
|
||||
private String key;
|
||||
@JsonProperty (required = true)
|
||||
private Object value;
|
||||
|
||||
@Override
|
||||
public RestRuleSettingsModel onModel()
|
||||
{
|
||||
return model;
|
||||
}
|
||||
|
||||
public String getKey()
|
||||
{
|
||||
return key;
|
||||
}
|
||||
|
||||
public void setKey(String key)
|
||||
{
|
||||
this.key = key;
|
||||
}
|
||||
|
||||
public Object getValue()
|
||||
{
|
||||
return value;
|
||||
}
|
||||
|
||||
public void setValue(Object value)
|
||||
{
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
return "RuleSetting{"
|
||||
+ new StringJoiner(", ")
|
||||
.add("key=" + key)
|
||||
.add("value=" + value.toString())
|
||||
.toString()
|
||||
+ "}";
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o)
|
||||
{
|
||||
if (this == o)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
if (!(o instanceof RestRuleSettingsModel))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
RestRuleSettingsModel that = (RestRuleSettingsModel) o;
|
||||
return Objects.equals(key, that.key) && Objects.equals(value, that.value);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode()
|
||||
{
|
||||
return Objects.hash(key, value);
|
||||
}
|
||||
}
|
@@ -27,12 +27,11 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated from 'Alfresco Core REST API' swagger file
|
||||
* Base Path {@linkplain /alfresco/api/-default-/public/alfresco/versions/1}
|
||||
@@ -61,18 +60,6 @@ public class RestSharedLinksModel extends TestModel implements IRestModel<RestSh
|
||||
return model;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSharedLinksModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestSharedLinksModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSharedLinksModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(required = true)
|
||||
private String modifiedAt;
|
||||
|
||||
|
@@ -25,14 +25,13 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
import java.util.Objects;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'Kristian.Dimitrov@hyland.com' on '2022-07-13 15:53' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -40,18 +39,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestSimpleConditionDefinitionModel extends TestModel implements IRestModel<RestSimpleConditionDefinitionModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestSimpleConditionDefinitionModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestSimpleConditionDefinitionModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSimpleConditionDefinitionModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestSimpleConditionDefinitionModel model;
|
||||
|
||||
@@ -128,6 +115,29 @@ Where a property is multivalued then the condition is true if it is satisfied by
|
||||
public void setParameter(String parameter)
|
||||
{
|
||||
this.parameter = parameter;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
return "RestSimpleConditionDefinitionModel{" + "field='" + field + '\'' + ", comparator='" + comparator + '\'' + ", parameter='" + parameter + '\'' + '}';
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o)
|
||||
{
|
||||
if (this == o)
|
||||
return true;
|
||||
if (o == null || getClass() != o.getClass())
|
||||
return false;
|
||||
RestSimpleConditionDefinitionModel that = (RestSimpleConditionDefinitionModel) o;
|
||||
return Objects.equals(field, that.field) && Objects.equals(comparator, that.comparator) && Objects.equals(parameter, that.parameter);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode()
|
||||
{
|
||||
return Objects.hash(field, comparator, parameter);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestSiteContainerModel extends TestModel implements IRestModel<RestSiteContainerModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
@@ -64,21 +63,4 @@ public class RestSiteContainerModel extends TestModel implements IRestModel<Rest
|
||||
{
|
||||
this.folderId = folderId;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestSiteContainerModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestSiteContainerModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSiteContainerModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
*
|
||||
* Handles Site Entry in Site Membership Information response
|
||||
@@ -93,22 +92,6 @@ public class RestSiteEntry extends TestModel implements IRestModel<RestSiteEntry
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestSiteEntry> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestSiteEntry>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSiteEntry> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public RestSiteEntry onModel()
|
||||
{
|
||||
|
@@ -25,15 +25,15 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import static org.alfresco.utility.report.log.Step.STEP;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.constants.UserRole;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
import org.testng.Assert;
|
||||
|
||||
import static org.alfresco.utility.report.log.Step.STEP;
|
||||
|
||||
public class RestSiteGroupModel extends TestModel implements IRestModel<RestSiteGroupModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
@@ -84,20 +84,4 @@ public class RestSiteGroupModel extends TestModel implements IRestModel<RestSite
|
||||
Assert.assertEquals(getRole(), role, "Site group role is not as expected.");
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestSiteGroupModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestSiteGroupModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSiteGroupModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
}
|
||||
|
@@ -27,14 +27,13 @@ package org.alfresco.rest.model;
|
||||
|
||||
import static org.alfresco.utility.report.log.Step.STEP;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.constants.UserRole;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
import org.testng.Assert;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
public class RestSiteMemberModel extends TestModel implements IRestModel<RestSiteMemberModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
@@ -98,20 +97,4 @@ public class RestSiteMemberModel extends TestModel implements IRestModel<RestSit
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestSiteMemberModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestSiteMemberModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSiteMemberModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
}
|
||||
|
@@ -25,13 +25,12 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
import org.testng.Assert;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
public class RestSiteMembershipRequestModel extends TestModel implements IRestModel<RestSiteMembershipRequestModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
@@ -104,21 +103,4 @@ public class RestSiteMembershipRequestModel extends TestModel implements IRestMo
|
||||
Assert.assertEquals(getMessage(), message, "Site membership request message is not correct");
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestSiteMembershipRequestModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestSiteMembershipRequestModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSiteMembershipRequestModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.SiteModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.SiteModel;
|
||||
|
||||
/**
|
||||
* Handles single Site JSON responses
|
||||
* Example:
|
||||
@@ -74,20 +73,4 @@ public class RestSiteModel extends SiteModel implements IRestModel<RestSiteModel
|
||||
{
|
||||
this.role = role;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestSiteModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestSiteModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSiteModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestSitePersonMembershipRequestModel extends TestModel implements IRestModel<RestSitePersonMembershipRequestModel>
|
||||
{
|
||||
private String id;
|
||||
@@ -110,20 +109,4 @@ public class RestSitePersonMembershipRequestModel extends TestModel implements I
|
||||
{
|
||||
this.modifiedAt = modifiedAt;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestSitePersonMembershipRequestModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestSitePersonMembershipRequestModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSitePersonMembershipRequestModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
}
|
||||
|
@@ -25,14 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
/**
|
||||
* Generated by 'tsalvado' on '2021-08-18 21:15' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -40,18 +37,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestStatusInfoModel extends TestModel implements IRestModel<RestStatusInfoModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestStatusInfoModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestStatusInfoModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestStatusInfoModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestStatusInfoModel model;
|
||||
|
||||
|
@@ -32,12 +32,11 @@
|
||||
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Base Path {@linkplain /alfresco/api/-default-/private/alfresco/versions/1}
|
||||
*
|
||||
@@ -108,18 +107,6 @@ public class RestSubscriberModel extends TestModel implements IRestModel<RestSub
|
||||
return model;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSubscriberModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestSubscriberModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSubscriberModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(required = true)
|
||||
private String createdAt;
|
||||
|
||||
|
@@ -32,12 +32,11 @@
|
||||
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Base Path {@linkplain /alfresco/api/-default-/private/alfresco/versions/1}
|
||||
*
|
||||
@@ -76,18 +75,6 @@ public class RestSyncNodeSubscriptionModel extends TestModel implements IRestMod
|
||||
return model;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSyncNodeSubscriptionModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestSyncNodeSubscriptionModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestSyncNodeSubscriptionModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(required = true)
|
||||
private String deviceSubscriptionId;
|
||||
|
||||
|
@@ -27,13 +27,12 @@ package org.alfresco.rest.model;
|
||||
|
||||
import static org.alfresco.utility.report.log.Step.STEP;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TagModel;
|
||||
import org.testng.Assert;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
/**
|
||||
* Handles single Tag Entry JSON response
|
||||
* "entry":
|
||||
@@ -64,24 +63,6 @@ public class RestTagModel extends TagModel implements IRestModel<RestTagModel>
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
public ModelAssertion<RestTagModel> and()
|
||||
{
|
||||
return new ModelAssertion<RestTagModel>(this);
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
public ModelAssertion<RestTagModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestTagModel>(this);
|
||||
}
|
||||
|
||||
public Integer getCount()
|
||||
{
|
||||
return count;
|
||||
|
@@ -25,13 +25,12 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
@JsonInclude(JsonInclude.Include.NON_NULL)
|
||||
public class RestTargetModel extends TestModel implements IRestModel<RestTargetModel>
|
||||
{
|
||||
@@ -106,20 +105,4 @@ public class RestTargetModel extends TestModel implements IRestModel<RestTargetM
|
||||
{
|
||||
this.file = file;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestTargetModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestTargetModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestTargetModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -25,13 +25,12 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TaskModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TaskModel;
|
||||
|
||||
/**
|
||||
* Handles single Task JSON response
|
||||
* Example:
|
||||
@@ -185,22 +184,6 @@ public class RestTaskModel extends TaskModel implements IRestModel<RestTaskModel
|
||||
this.state = state;
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestTaskModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestTaskModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestTaskModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
public Integer getPriorityTask()
|
||||
{
|
||||
return priorityTask;
|
||||
|
@@ -25,30 +25,17 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated from 'Alfresco Authentication REST API' swagger file
|
||||
* Base Path {@linkplain /alfresco/api/-default-/public/authentication/versions/1}
|
||||
*/
|
||||
public class RestTicketBodyModel extends TestModel implements IRestModel<RestTicketBodyModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestTicketBodyModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestTicketBodyModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestTicketBodyModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestTicketBodyModel model;
|
||||
|
||||
|
@@ -25,30 +25,17 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated from 'Alfresco Authentication REST API' swagger file
|
||||
* Base Path {@linkplain /alfresco/api/-default-/public/authentication/versions/1}
|
||||
*/
|
||||
public class RestTicketModel extends TestModel implements IRestModel<RestTicketModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestTicketModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestTicketModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestTicketModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestTicketModel model;
|
||||
|
||||
|
@@ -25,13 +25,12 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.data.RandomData;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
/**
|
||||
* Handles a single Variable JSON response
|
||||
* Example:
|
||||
@@ -111,23 +110,6 @@ public class RestVariableModel extends TestModel implements IRestModel<RestVaria
|
||||
return new RestVariableModel(scope, RandomData.getRandomName("name"), type, RandomData.getRandomName("value"));
|
||||
}
|
||||
|
||||
/**
|
||||
* DSL for assertion on this rest model
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ModelAssertion<RestVariableModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestVariableModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestVariableModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public RestVariableModel onModel()
|
||||
{
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.model;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'aforascu' on '2018-01-10 16:02' from 'Alfresco Content Services REST API' swagger file
|
||||
* Generated from 'Alfresco Content Services REST API' swagger file
|
||||
@@ -38,18 +37,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestVersionInfoModel extends TestModel implements IRestModel<RestVersionInfoModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestVersionInfoModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestVersionInfoModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestVersionInfoModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestVersionInfoModel model;
|
||||
|
||||
|
@@ -27,27 +27,13 @@ package org.alfresco.rest.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestVersionModel extends TestModel implements IRestModel<RestVersionModel>
|
||||
{
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestVersionModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestVersionModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestVersionModel>(this);
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestVersionModel model;
|
||||
|
||||
|
@@ -25,30 +25,17 @@
|
||||
*/
|
||||
package org.alfresco.rest.model.body;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
public class RestNodeLockBodyModel extends TestModel implements IRestModel<RestNodeLockBodyModel>
|
||||
{
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestNodeLockBodyModel model;
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestNodeLockBodyModel> and()
|
||||
{
|
||||
return new ModelAssertion<RestNodeLockBodyModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestNodeLockBodyModel> assertThat()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public RestNodeLockBodyModel onModel()
|
||||
{
|
||||
|
@@ -26,8 +26,11 @@
|
||||
|
||||
package org.alfresco.rest.requests;
|
||||
|
||||
import static org.alfresco.rest.requests.RuleSettings.IS_INHERITANCE_ENABLED;
|
||||
|
||||
import javax.json.JsonArrayBuilder;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.IOException;
|
||||
|
||||
import io.restassured.http.ContentType;
|
||||
@@ -51,6 +54,7 @@ import org.alfresco.rest.model.RestRatingModel;
|
||||
import org.alfresco.rest.model.RestRatingModelsCollection;
|
||||
import org.alfresco.rest.model.RestRenditionInfoModel;
|
||||
import org.alfresco.rest.model.RestRenditionInfoModelCollection;
|
||||
import org.alfresco.rest.model.RestRuleSetLinkModel;
|
||||
import org.alfresco.rest.model.RestRuleSetModel;
|
||||
import org.alfresco.rest.model.RestRuleSetModelsCollection;
|
||||
import org.alfresco.rest.model.RestTagModel;
|
||||
@@ -78,19 +82,19 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
public Node(RestWrapper restWrapper)
|
||||
{
|
||||
super(restWrapper);
|
||||
super(restWrapper);
|
||||
}
|
||||
|
||||
public Node(RepoTestModel repoModel, RestWrapper restWrapper)
|
||||
{
|
||||
super(restWrapper);
|
||||
this.repoModel = repoModel;
|
||||
Utility.checkObjectIsInitialized(this.repoModel.getNodeRef(), "repoModel.getNodeRef()");
|
||||
super(restWrapper);
|
||||
this.repoModel = repoModel;
|
||||
Utility.checkObjectIsInitialized(this.repoModel.getNodeRef(), "repoModel.getNodeRef()");
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Retrieve details for a specific node using GET call on "nodes/{nodeId}"
|
||||
*
|
||||
*
|
||||
* @param nodeId
|
||||
* @return
|
||||
* @throws JsonToModelConversionException
|
||||
@@ -103,7 +107,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Retrieve comments for a specific node using GET call on "nodes/{nodeId}/comments"
|
||||
*
|
||||
*
|
||||
* @param nodeId
|
||||
* @return
|
||||
* @throws JsonToModelConversionException
|
||||
@@ -116,7 +120,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Publish one new comment on a specific node using POST call on "nodes/{nodeId}/comments"
|
||||
*
|
||||
*
|
||||
* @param node
|
||||
* @param commentContent
|
||||
* @return
|
||||
@@ -138,7 +142,7 @@ public class Node extends ModelRequest<Node>
|
||||
public RestCommentModelsCollection addComments(String... comments)
|
||||
{
|
||||
JsonArrayBuilder array = JsonBodyGenerator.defineJSONArray();
|
||||
for(String comment: comments)
|
||||
for (String comment : comments)
|
||||
{
|
||||
array.add(JsonBodyGenerator.defineJSON().add("content", comment));
|
||||
}
|
||||
@@ -149,7 +153,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Update a comment for a specific node using PUT call on nodes/{nodeId}/comments/{commentId}
|
||||
*
|
||||
*
|
||||
* @param nodeId
|
||||
* @param commentId
|
||||
* @param commentContent
|
||||
@@ -167,7 +171,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Delete a comment for a specific node using DELETE call on nodes/{nodeId}/comments/{commentId}
|
||||
*
|
||||
*
|
||||
* @param nodeId
|
||||
* @param commentId
|
||||
* @return
|
||||
@@ -181,101 +185,99 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Like a document using POST call on "nodes/{nodeId}/ratings"
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public RestRatingModel likeDocument()
|
||||
{
|
||||
String postBody = JsonBodyGenerator.likeRating(true);
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, postBody, "nodes/{nodeId}/ratings", repoModel.getNodeRef());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
String postBody = JsonBodyGenerator.likeRating(true);
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, postBody, "nodes/{nodeId}/ratings", repoModel.getNodeRef());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
}
|
||||
|
||||
public RestRatingModel dislikeDocument()
|
||||
{
|
||||
String postBody = JsonBodyGenerator.likeRating(false);
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, postBody, "nodes/{nodeId}/ratings", repoModel.getNodeRef());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
String postBody = JsonBodyGenerator.likeRating(false);
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, postBody, "nodes/{nodeId}/ratings", repoModel.getNodeRef());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
* POST call on "nodes/{nodeId}/ratings" using an invalid rating body
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public RestRatingModel addInvalidRating(String jsonBody)
|
||||
{
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, jsonBody, "nodes/{nodeId}/ratings", repoModel.getNodeRef());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, jsonBody, "nodes/{nodeId}/ratings", repoModel.getNodeRef());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Add five star rate to a document using POST call on "nodes/{nodeId}/ratings"
|
||||
*
|
||||
*
|
||||
* @param stars
|
||||
* @return
|
||||
*/
|
||||
public RestRatingModel rateStarsToDocument(int stars)
|
||||
{
|
||||
String postBody = JsonBodyGenerator.fiveStarRating(stars);
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, postBody, "nodes/{nodeId}/ratings", repoModel.getNodeRef());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
String postBody = JsonBodyGenerator.fiveStarRating(stars);
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, postBody, "nodes/{nodeId}/ratings", repoModel.getNodeRef());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve node ratings using GET call on "nodes/{nodeId}/ratings"
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public RestRatingModelsCollection getRatings()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/ratings?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
return restWrapper.processModels(RestRatingModelsCollection.class, request);
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/ratings?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
return restWrapper.processModels(RestRatingModelsCollection.class, request);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Delete like rating using DELETE call on "nodes/{nodeId}/ratings/{ratingId}"
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public void deleteLikeRating()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.DELETE, "nodes/{nodeId}/ratings/{ratingId}", repoModel.getNodeRef(), "likes");
|
||||
restWrapper.processEmptyModel(request);
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.DELETE, "nodes/{nodeId}/ratings/{ratingId}", repoModel.getNodeRef(), "likes");
|
||||
restWrapper.processEmptyModel(request);
|
||||
}
|
||||
|
||||
/**
|
||||
* Try to delete invalid rating using DELETE call on "nodes/{nodeId}/ratings/{ratingId}"
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public void deleteInvalidRating(String rating)
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.DELETE, "nodes/{nodeId}/ratings/{ratingId}", repoModel.getNodeRef(), rating);
|
||||
restWrapper.processEmptyModel(request);
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.DELETE, "nodes/{nodeId}/ratings/{ratingId}", repoModel.getNodeRef(), rating);
|
||||
restWrapper.processEmptyModel(request);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
* Get like rating of a document using GET call on "nodes/{nodeId}/ratings/{ratingId}"
|
||||
*/
|
||||
public RestRatingModel getLikeRating()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/ratings/{ratingId}?{parameters}", repoModel.getNodeRef(), "likes", restWrapper.getParameters());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/ratings/{ratingId}?{parameters}", repoModel.getNodeRef(), "likes", restWrapper.getParameters());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete fivestar rating using DELETE call on "nodes/{nodeId}/ratings/{ratingId}"
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public void deleteFiveStarRating()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.DELETE, "nodes/{nodeId}/ratings/{ratingId}", repoModel.getNodeRef(), "fiveStar");
|
||||
restWrapper.processEmptyModel(request);
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.DELETE, "nodes/{nodeId}/ratings/{ratingId}", repoModel.getNodeRef(), "fiveStar");
|
||||
restWrapper.processEmptyModel(request);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -285,8 +287,8 @@ public class Node extends ModelRequest<Node>
|
||||
*/
|
||||
public RestRatingModel getFiveStarRating()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/ratings/{ratingId}?{parameters}", repoModel.getNodeRef(), "fiveStar", restWrapper.getParameters());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/ratings/{ratingId}?{parameters}", repoModel.getNodeRef(), "fiveStar", restWrapper.getParameters());
|
||||
return restWrapper.processModel(RestRatingModel.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -313,17 +315,17 @@ public class Node extends ModelRequest<Node>
|
||||
public RestTagModelsCollection addTags(String... tags)
|
||||
{
|
||||
String postBody = "[";
|
||||
for(String tag: tags)
|
||||
for (String tag : tags)
|
||||
{
|
||||
postBody += JsonBodyGenerator.keyValueJson("tag", tag) + ",";
|
||||
}
|
||||
postBody = postBody.substring(0, postBody.length()-1) + "]";
|
||||
postBody = postBody.substring(0, postBody.length() - 1) + "]";
|
||||
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, postBody, "nodes/{nodeId}/tags", repoModel.getNodeRef());
|
||||
return restWrapper.processModels(RestTagModelsCollection.class, request);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Deletes a tag for a specific content node using DELETE call on nodes/{nodeId}/tags/{tagId}
|
||||
*
|
||||
@@ -340,7 +342,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Get node tags using GET call on 'nodes/{nodeId}/tags'
|
||||
*
|
||||
*
|
||||
* @param tag
|
||||
* @return
|
||||
*/
|
||||
@@ -352,33 +354,33 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Create new nodes using POST call on 'nodes/{nodeId}/children
|
||||
*
|
||||
*
|
||||
* @param node
|
||||
* @return
|
||||
*/
|
||||
*/
|
||||
public RestNodeModel createNode(RestNodeBodyModel node)
|
||||
{
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, node.toJson(), "nodes/{nodeId}/children?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
return restWrapper.processModel(RestNodeModel.class, request);
|
||||
{
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, node.toJson(), "nodes/{nodeId}/children?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
return restWrapper.processModel(RestNodeModel.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create new nodes using POST call on 'nodes/{nodeId}/children
|
||||
*
|
||||
* You need to specify first the multipart call {@link RestWrapper#usingMultipartFile(java.io.File)}
|
||||
*
|
||||
*
|
||||
* <code>usingMultipartFile(new File("your-local-file.txt")).withCoreAPI().usingNode(ContentModel.my()).createNode();</code>
|
||||
* @return
|
||||
*/
|
||||
public RestNodeModel createNode()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.POST, "nodes/{nodeId}/children", repoModel.getNodeRef());
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.POST, "nodes/{nodeId}/children", repoModel.getNodeRef());
|
||||
return restWrapper.processModel(RestNodeModel.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve content for a specific node using GET call on "nodes/{nodeId}/content"
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public RestResponse getNodeContent()
|
||||
@@ -389,7 +391,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Retrieve content for a specific node using GET call on "nodes/{nodeId}/content"
|
||||
*
|
||||
*
|
||||
* @return
|
||||
* @param nodeId
|
||||
*/
|
||||
@@ -401,14 +403,14 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Create node rendition using POST call on '/nodes/{nodeId}/renditions'
|
||||
*
|
||||
*
|
||||
* @param renditionId id of rendition to be created
|
||||
* @return
|
||||
*/
|
||||
public void createNodeRendition(String renditionId)
|
||||
{
|
||||
String postBody = JsonBodyGenerator.keyValueJson("id", renditionId);
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, postBody, "nodes/{nodeId}/renditions", repoModel.getNodeRef());
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, postBody, "nodes/{nodeId}/renditions", repoModel.getNodeRef());
|
||||
restWrapper.processEmptyModel(request);
|
||||
}
|
||||
|
||||
@@ -423,8 +425,8 @@ public class Node extends ModelRequest<Node>
|
||||
{
|
||||
String postBody = JsonBodyGenerator.keyValueJson("id", renditionId);
|
||||
RestRequest request = RestRequest
|
||||
.requestWithBody(HttpMethod.POST, postBody, "nodes/{nodeId}/versions/{versionId}/renditions",
|
||||
repoModel.getNodeRef(), versionId);
|
||||
.requestWithBody(HttpMethod.POST, postBody, "nodes/{nodeId}/versions/{versionId}/renditions",
|
||||
repoModel.getNodeRef(), versionId);
|
||||
restWrapper.processEmptyModel(request);
|
||||
}
|
||||
|
||||
@@ -448,13 +450,13 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Get node rendition using GET call on '/nodes/{nodeId}/renditions/{renditionId}
|
||||
*
|
||||
*
|
||||
* @param renditionId id of rendition to be retrieved
|
||||
* @return
|
||||
*/
|
||||
*/
|
||||
public RestRenditionInfoModel getNodeRendition(String renditionId)
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/renditions/{renditionId}", repoModel.getNodeRef(), renditionId);
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/renditions/{renditionId}", repoModel.getNodeRef(), renditionId);
|
||||
return restWrapper.processModel(RestRenditionInfoModel.class, request);
|
||||
}
|
||||
|
||||
@@ -468,20 +470,20 @@ public class Node extends ModelRequest<Node>
|
||||
public RestRenditionInfoModel getNodeVersionRendition(String renditionId, String versionId)
|
||||
{
|
||||
RestRequest request = RestRequest
|
||||
.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/versions/{versionId}/renditions/{renditionId}",
|
||||
repoModel.getNodeRef(), versionId, renditionId);
|
||||
.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/versions/{versionId}/renditions/{renditionId}",
|
||||
repoModel.getNodeRef(), versionId, renditionId);
|
||||
return restWrapper.processModel(RestRenditionInfoModel.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get node rendition using GET call on 'nodes/{nodeId}/renditions/{renditionId} Please note that it retries to get
|
||||
* the renditions response several times because on the alfresco server the rendition can take a while to be created.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public RestRenditionInfoModel getNodeRenditionUntilIsCreated(String renditionId)
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/renditions/{renditionId}",repoModel.getNodeRef(), renditionId);
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/renditions/{renditionId}", repoModel.getNodeRef(), renditionId);
|
||||
RestRenditionInfoModel renditions = restWrapper.processModel(RestRenditionInfoModel.class, request);
|
||||
int retry = 0;
|
||||
if (Integer.valueOf(restWrapper.getStatusCode()).equals(HttpStatus.OK.value()))
|
||||
@@ -504,7 +506,7 @@ public class Node extends ModelRequest<Node>
|
||||
*/
|
||||
public RestRenditionInfoModel getNodeVersionRenditionUntilIsCreated(String renditionId, String versionId)
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/versions/{versionId}/renditions/{renditionId}",repoModel.getNodeRef(), versionId, renditionId);
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/versions/{versionId}/renditions/{renditionId}", repoModel.getNodeRef(), versionId, renditionId);
|
||||
RestRenditionInfoModel renditions = restWrapper.processModel(RestRenditionInfoModel.class, request);
|
||||
int retry = 0;
|
||||
if (Integer.valueOf(restWrapper.getStatusCode()).equals(HttpStatus.OK.value()))
|
||||
@@ -518,13 +520,13 @@ public class Node extends ModelRequest<Node>
|
||||
}
|
||||
return renditions;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get node rendition content using GET call on
|
||||
* 'nodes/{nodeId}/renditions/{renditionId}/content Please note that it
|
||||
* retries to get the renditions response several times because on the
|
||||
* alfresco server the rendition can take a while to be created.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public RestResponse getNodeRenditionContentUntilIsCreated(String renditionId)
|
||||
@@ -555,7 +557,7 @@ public class Node extends ModelRequest<Node>
|
||||
public RestResponse getNodeVersionRenditionContentUntilIsCreated(String renditionId, String versionId)
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/versions/{versionId}/renditions/{renditionId}/content", repoModel.getNodeRef(),
|
||||
versionId, renditionId);
|
||||
versionId, renditionId);
|
||||
RestResponse response = restWrapper.process(request);
|
||||
int retry = 0;
|
||||
while (Integer.valueOf(response.getStatusCode()).equals(HttpStatus.NOT_FOUND.value()) && retry < Utility.retryCountSeconds)
|
||||
@@ -590,7 +592,7 @@ public class Node extends ModelRequest<Node>
|
||||
public RestResponse getNodeVersionRenditionContent(String renditionId, String versionId)
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/versions/{versionId}/renditions/{renditionId}/content", repoModel.getNodeRef(),
|
||||
versionId, renditionId);
|
||||
versionId, renditionId);
|
||||
return restWrapper.process(request);
|
||||
}
|
||||
|
||||
@@ -614,7 +616,7 @@ public class Node extends ModelRequest<Node>
|
||||
public RestRenditionInfoModelCollection getNodeVersionRenditionsInfo(String versionId)
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/versions/{versionId}/renditions?{parameters}", repoModel.getNodeRef(),
|
||||
versionId, restWrapper.getParameters());
|
||||
versionId, restWrapper.getParameters());
|
||||
return restWrapper.processModels(RestRenditionInfoModelCollection.class, request);
|
||||
}
|
||||
|
||||
@@ -632,18 +634,18 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Get a node's children using GET call 'nodes/{nodeId}/children
|
||||
*
|
||||
*
|
||||
* @return a collection of nodes
|
||||
*/
|
||||
public RestNodeModelsCollection listChildren()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/children?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/children?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
return restWrapper.processModels(RestNodeModelsCollection.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
* Move a node to a target folder
|
||||
*
|
||||
*
|
||||
* @param moveBody a {@link RestNodeBodyMoveCopyModel} containing at least the target parent id
|
||||
* @return the moved node's new information
|
||||
*/
|
||||
@@ -669,7 +671,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Lock a specific node using POST call on "nodes/{nodeId}/lock"
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public RestNodeModel lockNode(RestNodeLockBodyModel lockBody)
|
||||
@@ -680,7 +682,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Unlock a specific node using POST call on "nodes/{nodeId}/unlock"
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public RestNodeModel unlockNode()
|
||||
@@ -699,7 +701,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Update a specific node using PUT call on "nodes/{nodeId}"
|
||||
*
|
||||
*
|
||||
* @param putBody
|
||||
* @return
|
||||
*/
|
||||
@@ -709,10 +711,10 @@ public class Node extends ModelRequest<Node>
|
||||
request.setContentType("UTF-8");
|
||||
return restWrapper.processModel(RestNodeModel.class, request);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Retrieve targets for a specific node using GET call on "nodes/{nodeId}/targets
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public RestNodeAssociationModelCollection getNodeTargets()
|
||||
@@ -723,20 +725,20 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Create new target nodes using POST call on '/nodes/{nodeId}/targets'
|
||||
*
|
||||
*
|
||||
* @param target
|
||||
* @return
|
||||
*/
|
||||
public RestNodeAssocTargetModel createTargetForNode(RestNodeAssocTargetModel target)
|
||||
{
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, target.toJson(), "nodes/{nodeId}/targets?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
return restWrapper.processModel(RestNodeAssocTargetModel.class, request);
|
||||
{
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, target.toJson(), "nodes/{nodeId}/targets?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
return restWrapper.processModel(RestNodeAssocTargetModel.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete a target for a specific node using DELETE call on
|
||||
* nodes/{nodeId}/targets/{targetId}
|
||||
*
|
||||
*
|
||||
* @param target
|
||||
*/
|
||||
public void deleteTarget(RestNodeAssocTargetModel target)
|
||||
@@ -748,7 +750,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Get sources for a specific node using GET call on GET /nodes/{nodeId}/sources
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public RestNodeAssociationModelCollection getNodeSources()
|
||||
@@ -759,7 +761,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Updates the content of the node with identifier nodeId using PUT call "/nodes/{nodeId}/content"
|
||||
*
|
||||
*
|
||||
* @param nodeContent
|
||||
* @return
|
||||
*/
|
||||
@@ -768,7 +770,7 @@ public class Node extends ModelRequest<Node>
|
||||
try
|
||||
{
|
||||
restWrapper.usingContentType(ContentType.BINARY);
|
||||
String body = Files.readFile(nodeContent);
|
||||
String body = Files.readFile(new FileInputStream(nodeContent));
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.PUT, body, "nodes/{nodeId}/content?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
request.setContentType("UTF-8");
|
||||
restWrapper.usingContentType(ContentType.JSON);
|
||||
@@ -782,7 +784,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Copies the node nodeId to the parent folder node targetParentId using POST call "nodes/{nodeId}/copy"
|
||||
*
|
||||
*
|
||||
* @param postBody
|
||||
* @return
|
||||
*/
|
||||
@@ -792,32 +794,32 @@ public class Node extends ModelRequest<Node>
|
||||
return restWrapper.processModel(RestNodeModel.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
/**
|
||||
* Get a node's parents using GET call 'nodes/{nodeId}/parents
|
||||
*
|
||||
*
|
||||
* @return a collection of nodes
|
||||
*/
|
||||
public RestNodeAssociationModelCollection getParents()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/parents?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/parents?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
return restWrapper.processModels(RestNodeAssociationModelCollection.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get a node's secondary children using GET call 'nodes/{nodeId}/secondary-children
|
||||
*
|
||||
*
|
||||
* @return a collection of nodes
|
||||
*/
|
||||
public RestNodeAssociationModelCollection getSecondaryChildren()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/secondary-children?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/secondary-children?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
return restWrapper.processModels(RestNodeAssociationModelCollection.class, request);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create secondary children association using POST call 'nodes/{nodeId}/secondary-children
|
||||
* Use a list of secondary children nodes
|
||||
*
|
||||
*
|
||||
* @return a collection of nodes
|
||||
*/
|
||||
public RestNodeChildAssocModelCollection createSecondaryChildren(String secondaryChildren)
|
||||
@@ -828,7 +830,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Delete secondary children using DELETE call 'nodes/{nodeId}/secondary-children/{childId}
|
||||
*
|
||||
*
|
||||
* @return a collection of nodes
|
||||
*/
|
||||
public void deleteSecondaryChild(RestNodeAssociationModel child)
|
||||
@@ -839,7 +841,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Gets the version history as an ordered list for the specified nodeId using GET call 'nodes/{nodeId}/versions
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public RestVersionModelsCollection listVersionHistory()
|
||||
@@ -850,7 +852,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Delete the version identified by versionId for nodeId using DELETE call 'nodes/{nodeId}versions/{versionId}
|
||||
*
|
||||
*
|
||||
* @param versionId
|
||||
*/
|
||||
public void deleteNodeVersion(String versionId)
|
||||
@@ -861,7 +863,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Gets the version information versionId for node nodeId using GET call 'nodes/{nodeId}/versions/{versionId}
|
||||
*
|
||||
*
|
||||
* @param versionId
|
||||
* @return
|
||||
*/
|
||||
@@ -873,7 +875,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Gets the content for versionId of node nodeId using GET call 'nodes/{nodeId}/versions/{versionId}/content
|
||||
*
|
||||
*
|
||||
* @param versionId
|
||||
* @return
|
||||
*/
|
||||
@@ -885,7 +887,7 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
/**
|
||||
* Revert the version identified by versionId and nodeId to the node using POST call 'nodes/{nodeId}/versions/{versionId}/revert
|
||||
*
|
||||
*
|
||||
* @param versionId
|
||||
* @param postBody
|
||||
* @return
|
||||
@@ -922,9 +924,9 @@ public class Node extends ModelRequest<Node>
|
||||
|
||||
public RestActionDefinitionModelsCollection getActionDefinitions()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/action-definitions?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "nodes/{nodeId}/action-definitions?{parameters}", repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
return restWrapper.processModels(RestActionDefinitionModelsCollection.class, request);
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -987,8 +989,8 @@ public class Node extends ModelRequest<Node>
|
||||
public ContentStorageInformation usingStorageInfo(String contentPropName)
|
||||
{
|
||||
return new ContentStorageInformation(restWrapper)
|
||||
.withNodeId(repoModel.getNodeRef())
|
||||
.withContentPropName(contentPropName);
|
||||
.withNodeId(repoModel.getNodeRef())
|
||||
.withContentPropName(contentPropName);
|
||||
}
|
||||
|
||||
public ContentStorageInformation usingVersionStorageInfo(String contentPropName, String versionId)
|
||||
@@ -1018,8 +1020,8 @@ public class Node extends ModelRequest<Node>
|
||||
*/
|
||||
public RestRuleSetModelsCollection getListOfRuleSets()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, RULE_SETS_URI + "?{parameters}",
|
||||
repoModel.getNodeRef(), restWrapper.getParameters());
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, RULE_SETS_URI,
|
||||
repoModel.getNodeRef());
|
||||
return restWrapper.processModels(RestRuleSetModelsCollection.class, request);
|
||||
}
|
||||
|
||||
@@ -1031,8 +1033,8 @@ public class Node extends ModelRequest<Node>
|
||||
*/
|
||||
public RestRuleSetModel getRuleSet(String ruleSetId)
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, RULE_SET_BY_ID + "?{parameters}",
|
||||
repoModel.getNodeRef(), ruleSetId, restWrapper.getParameters());
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, RULE_SET_BY_ID,
|
||||
repoModel.getNodeRef(), ruleSetId);
|
||||
return restWrapper.processModel(RestRuleSetModel.class, request);
|
||||
}
|
||||
|
||||
@@ -1043,8 +1045,26 @@ public class Node extends ModelRequest<Node>
|
||||
*/
|
||||
public RestRuleSetModel getDefaultRuleSet()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, RULE_SET_BY_ID + "?{parameters}",
|
||||
repoModel.getNodeRef(), "-default-", restWrapper.getParameters());
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, RULE_SET_BY_ID,
|
||||
repoModel.getNodeRef(), "-default-");
|
||||
return restWrapper.processModel(RestRuleSetModel.class, request);
|
||||
}
|
||||
|
||||
public RuleSettings usingRuleSetting(String ruleSettingKey)
|
||||
{
|
||||
return new RuleSettings(restWrapper)
|
||||
.withNodeId(repoModel.getNodeRef())
|
||||
.withRuleSettingKey(ruleSettingKey);
|
||||
}
|
||||
|
||||
public RuleSettings usingIsInheritanceEnabledRuleSetting()
|
||||
{
|
||||
return usingRuleSetting(IS_INHERITANCE_ENABLED);
|
||||
}
|
||||
|
||||
public RestRuleSetLinkModel createRuleLink(RestRuleSetLinkModel body)
|
||||
{
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, body.toJson(), "nodes/{nodeId}/rule-set-links", repoModel.getNodeRef());
|
||||
return restWrapper.processModel(RestRuleSetLinkModel.class, request);
|
||||
}
|
||||
}
|
||||
|
@@ -0,0 +1,75 @@
|
||||
/*-
|
||||
* #%L
|
||||
* alfresco-tas-restapi
|
||||
* %%
|
||||
* Copyright (C) 2005 - 2022 Alfresco Software Limited
|
||||
* %%
|
||||
* This file is part of the Alfresco software.
|
||||
* If the software was purchased under a paid Alfresco license, the terms of
|
||||
* the paid license agreement will prevail. Otherwise, the software is
|
||||
* provided under the following open source license terms:
|
||||
*
|
||||
* Alfresco is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* Alfresco is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public License
|
||||
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
*/
|
||||
/*
|
||||
* Copyright 2022 Alfresco Software, Ltd. All rights reserved.
|
||||
* License rights for this program may be obtained from Alfresco Software, Ltd.
|
||||
* pursuant to a written agreement and any use of this program without such an
|
||||
* agreement is prohibited.
|
||||
*/
|
||||
package org.alfresco.rest.requests;
|
||||
|
||||
import org.alfresco.rest.core.RestRequest;
|
||||
import org.alfresco.rest.core.RestWrapper;
|
||||
import org.alfresco.rest.model.RestRuleSettingsModel;
|
||||
import org.springframework.http.HttpMethod;
|
||||
|
||||
public class RuleSettings extends ModelRequest<FolderRules>
|
||||
{
|
||||
public static final String IS_INHERITANCE_ENABLED = "-isInheritanceEnabled-";
|
||||
private static final String BASE_PATH = "nodes/{nodeId}/rule-settings/{ruleSettingKey}";
|
||||
|
||||
private String nodeId;
|
||||
private String ruleSettingKey;
|
||||
|
||||
public RuleSettings(RestWrapper restWrapper)
|
||||
{
|
||||
super(restWrapper);
|
||||
}
|
||||
|
||||
public RuleSettings withNodeId(String nodeId)
|
||||
{
|
||||
this.nodeId = nodeId;
|
||||
return this;
|
||||
}
|
||||
|
||||
public RuleSettings withRuleSettingKey(String ruleSettingKey)
|
||||
{
|
||||
this.ruleSettingKey = ruleSettingKey;
|
||||
return this;
|
||||
}
|
||||
|
||||
public RestRuleSettingsModel retrieveSetting()
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, BASE_PATH, nodeId, ruleSettingKey);
|
||||
return restWrapper.processModel(RestRuleSettingsModel.class, request);
|
||||
}
|
||||
|
||||
public RestRuleSettingsModel updateSetting(RestRuleSettingsModel ruleSettingsModel)
|
||||
{
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.PUT, ruleSettingsModel.toJson(), BASE_PATH, nodeId, ruleSettingKey);
|
||||
return restWrapper.processModel(RestRuleSettingsModel.class, request);
|
||||
}
|
||||
}
|
@@ -54,7 +54,6 @@ public class Sync extends ModelRequest<RestPrivateAPI>
|
||||
RestSyncNodeSubscriptionModel subscription;
|
||||
String requestSyncURL = "subscribers/{deviceSubscriptionId}/subscriptions/{nodeSubscriptionId}/sync";
|
||||
String syncSetURL = requestSyncURL + "/{syncId}";
|
||||
String params = "?{parameters}";
|
||||
|
||||
public Sync(RestSyncNodeSubscriptionModel subscription, RestWrapper restWrapper)
|
||||
{
|
||||
@@ -82,7 +81,7 @@ public class Sync extends ModelRequest<RestPrivateAPI>
|
||||
|
||||
String postBody = JsonBodyGenerator.defineJSON().add("changes", array.build()).add("clientVersion", clientVersion).build().toString();
|
||||
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, postBody, requestSyncURL + params, this.subscriber, nodeSubscriptionModel.getId(),
|
||||
RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, postBody, requestSyncURL, this.subscriber, nodeSubscriptionModel.getId(),
|
||||
restWrapper.getParameters());
|
||||
|
||||
// This step is necessary for this request. Without it, empty json response is returned
|
||||
@@ -94,7 +93,7 @@ public class Sync extends ModelRequest<RestPrivateAPI>
|
||||
|
||||
public RestWrapper endSync(RestSyncNodeSubscriptionModel nodeSubscriptionModel, RestSyncSetRequestModel sync)
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.DELETE, syncSetURL + params, this.subscriber, nodeSubscriptionModel.getId(),
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.DELETE, syncSetURL, this.subscriber, nodeSubscriptionModel.getId(),
|
||||
sync.getSyncId(), restWrapper.getParameters());
|
||||
|
||||
restWrapper.processEmptyModel(request);
|
||||
@@ -111,7 +110,7 @@ public class Sync extends ModelRequest<RestPrivateAPI>
|
||||
*/
|
||||
public RestSyncSetGetModel getSync(RestSyncNodeSubscriptionModel nodeSubscriptionModel, RestSyncSetRequestModel sync)
|
||||
{
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, syncSetURL + params, this.subscriber, nodeSubscriptionModel.getId(), sync.getSyncId(),
|
||||
RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, syncSetURL, this.subscriber, nodeSubscriptionModel.getId(), sync.getSyncId(),
|
||||
restWrapper.getParameters());
|
||||
|
||||
RestSyncSetGetModel model = restWrapper.processModelWithoutEntryObject(RestSyncSetGetModel.class, request);
|
||||
|
@@ -44,7 +44,6 @@
|
||||
package org.alfresco.rest.search;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
@@ -102,24 +101,10 @@ public class FacetFieldBucket extends TestModel implements IRestModel<FacetField
|
||||
this.filterQuery = filterQuery;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<FacetFieldBucket> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<FacetFieldBucket> assertThat()
|
||||
{
|
||||
return new ModelAssertion<FacetFieldBucket>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public FacetFieldBucket onModel()
|
||||
{
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.search;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Represents a facet interval.
|
||||
*/
|
||||
@@ -87,16 +86,4 @@ public class FacetInterval extends TestModel implements IRestModel<FacetInterval
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<FacetInterval> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<FacetInterval> assertThat()
|
||||
{
|
||||
return new ModelAssertion<FacetInterval>(this);
|
||||
}
|
||||
}
|
||||
|
@@ -49,7 +49,7 @@ import org.alfresco.utility.model.TestModel;
|
||||
* Pojo to represent facet query.
|
||||
* {"query": "content.size:[o TO 102400]", "label": "small"},
|
||||
**/
|
||||
public class FacetQuery extends TestModel //implements IRestModel<FacetQuery>
|
||||
public class FacetQuery extends TestModel
|
||||
{
|
||||
|
||||
private String query;
|
||||
@@ -93,22 +93,4 @@ public class FacetQuery extends TestModel //implements IRestModel<FacetQuery>
|
||||
{
|
||||
this.group = group;
|
||||
}
|
||||
|
||||
/* @Override
|
||||
public ModelAssertion<FacetQuery> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
@Override
|
||||
public ModelAssertion<FacetQuery> assertThat()
|
||||
{
|
||||
return new ModelAssertion<FacetQuery>(this);
|
||||
}
|
||||
@Override
|
||||
public FacetQuery onModel()
|
||||
{
|
||||
return null;
|
||||
}*/
|
||||
|
||||
|
||||
}
|
||||
|
@@ -46,7 +46,6 @@ package org.alfresco.rest.search;
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
/**
|
||||
* Pojo which represents the search response that includes the highlighting info.
|
||||
@@ -76,16 +75,6 @@ public class ResponseHighLightModel extends TestModel implements IRestModel<Resp
|
||||
this.snippets = snippets;
|
||||
}
|
||||
@Override
|
||||
public ModelAssertion<ResponseHighLightModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
@Override
|
||||
public ModelAssertion<ResponseHighLightModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<ResponseHighLightModel>(this);
|
||||
}
|
||||
@Override
|
||||
public ResponseHighLightModel onModel()
|
||||
{
|
||||
return model;
|
||||
|
@@ -27,12 +27,11 @@ package org.alfresco.rest.search;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'gethin' on '2017-03-17 13:23' from 'Alfresco Search REST API' swagger file
|
||||
* Generated from 'Alfresco Search REST API' swagger file
|
||||
@@ -40,18 +39,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestGenericBucketModel extends TestModel implements IRestModel<RestGenericBucketModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestGenericBucketModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestGenericBucketModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestGenericBucketModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestGenericBucketModel model;
|
||||
|
||||
|
@@ -27,12 +27,11 @@ package org.alfresco.rest.search;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'gethin' on '2017-03-17 12:44' from 'Alfresco Search REST API' swagger file
|
||||
* Generated from 'Alfresco Search REST API' swagger file
|
||||
@@ -40,18 +39,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestGenericFacetResponseModel extends TestModel implements IRestModel<RestGenericFacetResponseModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestGenericFacetResponseModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestGenericFacetResponseModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestGenericFacetResponseModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestGenericFacetResponseModel model;
|
||||
|
||||
|
@@ -25,12 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.search;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.rest.core.assertion.ModelAssertion;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'gethin' on '2017-03-17 13:23' from 'Alfresco Search REST API' swagger file
|
||||
* Generated from 'Alfresco Search REST API' swagger file
|
||||
@@ -38,18 +37,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
*/
|
||||
public class RestGenericMetricModel extends TestModel implements IRestModel<RestGenericMetricModel>
|
||||
{
|
||||
@Override
|
||||
public ModelAssertion<RestGenericMetricModel> assertThat()
|
||||
{
|
||||
return new ModelAssertion<RestGenericMetricModel>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelAssertion<RestGenericMetricModel> and()
|
||||
{
|
||||
return assertThat();
|
||||
}
|
||||
|
||||
@JsonProperty(value = "entry")
|
||||
RestGenericMetricModel model;
|
||||
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user