* ============LICENSE_START=======================================================
* simulators
* ================================================================================
- * Copyright (C) 2017-2020 AT&T Intellectual Property. All rights reserved.
+ * Copyright (C) 2017-2021 AT&T Intellectual Property. All rights reserved.
* Modifications Copyright (C) 2019 Nordix Foundation.
+ * Modifications Copyright (C) 2020 Wipro Limited.
+ * Modifications Copyright (C) 2022 CTC, Inc. and others.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
import javax.ws.rs.DELETE;
import javax.ws.rs.GET;
import javax.ws.rs.POST;
+import javax.ws.rs.PUT;
import javax.ws.rs.Path;
import javax.ws.rs.PathParam;
import javax.ws.rs.Produces;
import lombok.Setter;
import org.onap.policy.common.utils.resources.ResourceUtils;
import org.onap.policy.so.SoRequest;
+import org.onap.policy.so.SoRequest3gpp;
@Path("/")
public class SoSimulatorJaxRs {
}
}
+ @PUT
+ @Path("/3gppservices/v7/modify")
+ @Consumes(MediaType.APPLICATION_JSON)
+ @Produces("application/json")
+ public String soPost3gpp(@ApiParam(required = true) SoRequest3gpp request) {
+ return ResourceUtils.getResourceAsString("org/onap/policy/simulators/so/so.3gpp.success.json");
+ }
+
+ @PUT
+ @Path("/infra/serviceIntent/v1/modify")
+ @Consumes(MediaType.APPLICATION_JSON)
+ @Produces("application/json")
+ public String soPostModifyCll(@ApiParam(required = true) SoRequest3gpp request) {
+ return ResourceUtils.getResourceAsString("org/onap/policy/simulators/so/so.cll.success.json");
+ }
+
private String makeStarted() {
- String requestId = UUID.randomUUID().toString();
+ var requestId = UUID.randomUUID().toString();
- String response = ResourceUtils.getResourceAsString("org/onap/policy/simulators/so/so.started.json");
+ var response = ResourceUtils.getResourceAsString("org/onap/policy/simulators/so/so.started.json");
incomplete.add(requestId);
}
private String makeImmediateComplete() {
- String response = ResourceUtils.getResourceAsString("org/onap/policy/simulators/so/so.immediate.success.json");
+ var response = ResourceUtils.getResourceAsString("org/onap/policy/simulators/so/so.immediate.success.json");
return response.replace(REPLACE_ME, UUID.randomUUID().toString());
}
private String makeComplete(String requestId) {
- String response = ResourceUtils.getResourceAsString("org/onap/policy/simulators/so/so.complete.success.json");
+ var response = ResourceUtils.getResourceAsString("org/onap/policy/simulators/so/so.complete.success.json");
return response.replace(REPLACE_ME, requestId);
}
private String makeStillRunning(String requestId) {
- String response = ResourceUtils.getResourceAsString("org/onap/policy/simulators/so/so.still.running.json");
+ var response = ResourceUtils.getResourceAsString("org/onap/policy/simulators/so/so.still.running.json");
return response.replace(REPLACE_ME, requestId);
}
}