Split client module into api and core.
This commit is contained in:
Родитель
66e5c8e954
Коммит
940f342e30
|
@ -1,6 +1,6 @@
|
|||
# Azure Digital Twins - Java support collection
|
||||
|
||||
This projects aims to provide modules and samples for leveraging [Azure Digital Twins](https://docs.microsoft.com/en-us/azure/digital-twins/about-digital-twins) service from Java based applications. The project is community maintained and will provide generic Java components as well as off-the-shelf Spring Boot integration and auto configuration.
|
||||
This projects aims to provide modules and samples for leveraging [Azure Digital Twins](https://docs.microsoft.com/en-us/azure/digital-twins/about-digital-twins) service from Java based applications. The project is community maintained and will provide generic Java components as well as off-the-shelf Spring Boot integration with auto configuration.
|
||||
|
||||
[![Build status](https://dev.azure.com/kaiatms/Twins-Event-Ingress/_apis/build/status/ADT%20Java%20collection%20-%20MASTER%20build)](https://dev.azure.com/kaiatms/Twins-Event-Ingress/_build/latest?definitionId=20) [![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=com.microsoft.twins%3Aazure-digital-twins-java&metric=alert_status)](https://sonarcloud.io/dashboard?id=com.microsoft.twins%3Aazure-digital-twins-java) [![Reliability Rating](https://sonarcloud.io/api/project_badges/measure?project=com.microsoft.twins%3Aazure-digital-twins-java&metric=reliability_rating)](https://sonarcloud.io/dashboard?id=com.microsoft.twins%3Aazure-digital-twins-java) [![Security Rating](https://sonarcloud.io/api/project_badges/measure?project=com.microsoft.twins%3Aazure-digital-twins-java&metric=security_rating)](https://sonarcloud.io/dashboard?id=com.microsoft.twins%3Aazure-digital-twins-java)
|
||||
|
||||
|
|
|
@ -17,8 +17,9 @@
|
|||
<packaging>pom</packaging>
|
||||
|
||||
<modules>
|
||||
<module>twin-management-client-api</module>
|
||||
<module>twin-management-client-core</module>
|
||||
<module>twin-management-client-autoconfigure</module>
|
||||
<module>twin-management-client-starter</module>
|
||||
</modules>
|
||||
</modules>
|
||||
</project>
|
|
@ -0,0 +1,37 @@
|
|||
<!--
|
||||
|
||||
Copyright (c) Microsoft Corporation. Licensed under the MIT License.
|
||||
|
||||
-->
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.microsoft.twins</groupId>
|
||||
<artifactId>twin-management-client</artifactId>
|
||||
<version>0.1.0-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>twin-management-client-api</artifactId>
|
||||
<name>Twin Management Client :: Api</name>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>io.github.openfeign</groupId>
|
||||
<artifactId>feign-core</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.github.openfeign</groupId>
|
||||
<artifactId>feign-jackson</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.validation</groupId>
|
||||
<artifactId>validation-api</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
</project>
|
|
@ -8,12 +8,11 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.BlobMetadataRetrieve;
|
||||
import com.microsoft.twins.model.DeviceCreate;
|
||||
import com.microsoft.twins.model.DeviceRetrieve;
|
||||
import com.microsoft.twins.model.DeviceUpdate;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.ExtendedPropertyCreate;
|
||||
import com.microsoft.twins.model.KeyStoreRetrieve;
|
||||
import com.microsoft.twins.model.Location;
|
||||
|
@ -24,7 +23,7 @@ import feign.Param;
|
|||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface DevicesApi extends TwinsApiClient.Api {
|
||||
public interface DevicesApi {
|
||||
/**
|
||||
* Creates a device
|
||||
*
|
|
@ -7,8 +7,7 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.EndpointCreate;
|
||||
import com.microsoft.twins.model.EndpointRetrieve;
|
||||
import com.microsoft.twins.model.EventTypesEnum;
|
||||
|
@ -17,7 +16,7 @@ import feign.Param;
|
|||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface EndpointsApi extends TwinsApiClient.Api {
|
||||
public interface EndpointsApi {
|
||||
/**
|
||||
* Creates an endpoint
|
||||
*
|
|
@ -7,8 +7,7 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.KeyStoreCreate;
|
||||
import com.microsoft.twins.model.KeyStoreRetrieve;
|
||||
import com.microsoft.twins.model.KeyStoreUpdate;
|
||||
|
@ -19,7 +18,7 @@ import feign.Param;
|
|||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface KeyStoresApi extends TwinsApiClient.Api {
|
||||
public interface KeyStoresApi {
|
||||
/**
|
||||
* Creates a key store
|
||||
*
|
||||
|
@ -33,9 +32,9 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Creates a key store
|
||||
*
|
||||
* @param name (optional)
|
||||
* @param name (optional)
|
||||
* @param description (optional)
|
||||
* @param spaceId (optional)
|
||||
* @param spaceId (optional)
|
||||
* @return UUID
|
||||
*/
|
||||
@RequestLine("POST /api/v1.0/keystores")
|
||||
|
@ -65,7 +64,7 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Deletes the given key
|
||||
*
|
||||
* @param id The store identifier (required)
|
||||
* @param id The store identifier (required)
|
||||
* @param key The key identifier (required)
|
||||
*/
|
||||
@RequestLine("DELETE /api/v1.0/keystores/{id}/keys/{key}")
|
||||
|
@ -75,8 +74,8 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Gets a token for the specified device using the specified key
|
||||
*
|
||||
* @param id The key store identifier (required)
|
||||
* @param key The key identifier (required)
|
||||
* @param id The key store identifier (required)
|
||||
* @param key The key identifier (required)
|
||||
* @param deviceMac The device to generate the token for (required)
|
||||
* @return String
|
||||
*/
|
||||
|
@ -94,15 +93,15 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
* {@link KeyStoresGenerateTokenFromKeyByIdQueryParams} class that allows for building up this map
|
||||
* in a fluent style.
|
||||
*
|
||||
* @param id The key store identifier (required)
|
||||
* @param key The key identifier (required)
|
||||
* @param id The key store identifier (required)
|
||||
* @param key The key identifier (required)
|
||||
* @param queryParams Map of query parameters as name-value pairs
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>deviceMac - The device to generate the token for (required)</li>
|
||||
* </ul>
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>deviceMac - The device to generate the token for (required)</li>
|
||||
* </ul>
|
||||
* @return String
|
||||
*
|
||||
*/
|
||||
|
@ -127,7 +126,7 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Gets a token for the specified device for the last valid key.
|
||||
*
|
||||
* @param id The identifier (required)
|
||||
* @param id The identifier (required)
|
||||
* @param deviceMac The device to generate the token for (required)
|
||||
* @return String
|
||||
*/
|
||||
|
@ -145,14 +144,14 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
* {@link KeyStoresGenerateTokenFromLastKeyQueryParams} class that allows for building up this map
|
||||
* in a fluent style.
|
||||
*
|
||||
* @param id The identifier (required)
|
||||
* @param id The identifier (required)
|
||||
* @param queryParams Map of query parameters as name-value pairs
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>deviceMac - The device to generate the token for (required)</li>
|
||||
* </ul>
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>deviceMac - The device to generate the token for (required)</li>
|
||||
* </ul>
|
||||
* @return String
|
||||
*
|
||||
*/
|
||||
|
@ -177,9 +176,9 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Retrieves key stores
|
||||
*
|
||||
* @param spaceId Optional filter on parent space id (optional)
|
||||
* @param spaceId Optional filter on parent space id (optional)
|
||||
* @param includes Comma separated list of what to include, for example \"Space,Keys\".
|
||||
* Defaults to None (optional)
|
||||
* Defaults to None (optional)
|
||||
* @return java.util.List<KeyStoreRetrieve>
|
||||
*/
|
||||
@RequestLine("GET /api/v1.0/keystores?spaceId={spaceId}&includes={includes}")
|
||||
|
@ -196,14 +195,14 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
* allows for building up this map in a fluent style.
|
||||
*
|
||||
* @param queryParams Map of query parameters as name-value pairs
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>spaceId - Optional filter on parent space id (optional)</li>
|
||||
* <li>includes - Comma separated list of what to include, for example
|
||||
* \"Space,Keys\". Defaults to None (optional)</li>
|
||||
* </ul>
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>spaceId - Optional filter on parent space id (optional)</li>
|
||||
* <li>includes - Comma separated list of what to include, for example
|
||||
* \"Space,Keys\". Defaults to None (optional)</li>
|
||||
* </ul>
|
||||
* @return java.util.List<KeyStoreRetrieve>
|
||||
*
|
||||
*/
|
||||
|
@ -233,15 +232,14 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Retrieves a key store
|
||||
*
|
||||
* @param id The identifier (required)
|
||||
* @param id The identifier (required)
|
||||
* @param includes Comma separated list of what to include, for example \"Space,Keys\".
|
||||
* Defaults to None (optional)
|
||||
* Defaults to None (optional)
|
||||
* @return KeyStoreRetrieve
|
||||
*/
|
||||
@RequestLine("GET /api/v1.0/keystores/{id}?includes={includes}")
|
||||
@Headers({"Accept: */*",})
|
||||
KeyStoreRetrieve keyStoresRetrieveById(@Param("id") UUID id,
|
||||
@Param("includes") String includes);
|
||||
KeyStoreRetrieve keyStoresRetrieveById(@Param("id") UUID id, @Param("includes") String includes);
|
||||
|
||||
/**
|
||||
* Retrieves a key store
|
||||
|
@ -252,15 +250,15 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
* {@link KeyStoresRetrieveByIdQueryParams} class that allows for building up this map in a fluent
|
||||
* style.
|
||||
*
|
||||
* @param id The identifier (required)
|
||||
* @param id The identifier (required)
|
||||
* @param queryParams Map of query parameters as name-value pairs
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>includes - Comma separated list of what to include, for example
|
||||
* \"Space,Keys\". Defaults to None (optional)</li>
|
||||
* </ul>
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>includes - Comma separated list of what to include, for example
|
||||
* \"Space,Keys\". Defaults to None (optional)</li>
|
||||
* </ul>
|
||||
* @return KeyStoreRetrieve
|
||||
*
|
||||
*/
|
||||
|
@ -285,7 +283,7 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Retrieves the given key
|
||||
*
|
||||
* @param id The key store identifier (required)
|
||||
* @param id The key store identifier (required)
|
||||
* @param key The key identifier (required)
|
||||
* @return SecurityKeyRetrieve
|
||||
*/
|
||||
|
@ -317,7 +315,7 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
* Updates a key store
|
||||
*
|
||||
* @param body The store information (required)
|
||||
* @param id The identifier (required)
|
||||
* @param id The identifier (required)
|
||||
*/
|
||||
@RequestLine("PATCH /api/v1.0/keystores/{id}")
|
||||
@Headers({"Accept: */*",})
|
||||
|
@ -326,8 +324,8 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Updates a key store
|
||||
*
|
||||
* @param id The identifier (required)
|
||||
* @param name (optional)
|
||||
* @param id The identifier (required)
|
||||
* @param name (optional)
|
||||
* @param description (optional)
|
||||
*/
|
||||
@RequestLine("PATCH /api/v1.0/keystores/{id}")
|
||||
|
@ -339,19 +337,18 @@ public interface KeyStoresApi extends TwinsApiClient.Api {
|
|||
* Updates the given key
|
||||
*
|
||||
* @param body The key data (required)
|
||||
* @param id The store identifier (required)
|
||||
* @param key The key identifier (required)
|
||||
* @param id The store identifier (required)
|
||||
* @param key The key identifier (required)
|
||||
*/
|
||||
@RequestLine("PATCH /api/v1.0/keystores/{id}/keys/{key}")
|
||||
@Headers({"Accept: */*",})
|
||||
void keyStoresUpdateKey(SecurityKeyUpdate body, @Param("id") UUID id,
|
||||
@Param("key") Integer key);
|
||||
void keyStoresUpdateKey(SecurityKeyUpdate body, @Param("id") UUID id, @Param("key") Integer key);
|
||||
|
||||
/**
|
||||
* Updates the given key
|
||||
*
|
||||
* @param id The store identifier (required)
|
||||
* @param key The key identifier (required)
|
||||
* @param id The store identifier (required)
|
||||
* @param key The key identifier (required)
|
||||
* @param status (optional)
|
||||
*/
|
||||
@RequestLine("PATCH /api/v1.0/keystores/{id}/keys/{key}")
|
|
@ -7,10 +7,9 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.ConditionCreate;
|
||||
import com.microsoft.twins.model.ConditionUpdate;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.MatcherCreate;
|
||||
import com.microsoft.twins.model.MatcherEvaluationResults;
|
||||
import com.microsoft.twins.model.MatcherRetrieve;
|
||||
|
@ -20,7 +19,7 @@ import feign.Param;
|
|||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface MatchersApi extends TwinsApiClient.Api {
|
||||
public interface MatchersApi {
|
||||
/**
|
||||
* Creates a matcher
|
||||
*
|
||||
|
@ -34,11 +33,11 @@ public interface MatchersApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Creates a matcher
|
||||
*
|
||||
* @param name (optional)
|
||||
* @param description (optional)
|
||||
* @param name (optional)
|
||||
* @param description (optional)
|
||||
* @param friendlyName (optional)
|
||||
* @param conditions (optional)
|
||||
* @param spaceId (optional)
|
||||
* @param conditions (optional)
|
||||
* @param spaceId (optional)
|
||||
* @return UUID
|
||||
*/
|
||||
@RequestLine("POST /api/v1.0/matchers")
|
||||
|
@ -59,8 +58,8 @@ public interface MatchersApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Evaluates the matcher for a sensor
|
||||
*
|
||||
* @param id Matcher identifier (required)
|
||||
* @param sensorId Sensor identifier (required)
|
||||
* @param id Matcher identifier (required)
|
||||
* @param sensorId Sensor identifier (required)
|
||||
* @param enableLogging If true, return verbose logs for the evaluation (optional)
|
||||
* @return MatcherEvaluationResults
|
||||
*/
|
||||
|
@ -77,16 +76,15 @@ public interface MatchersApi extends TwinsApiClient.Api {
|
|||
* query parameters, especially when used with the {@link MatchersEvaluateQueryParams} class that
|
||||
* allows for building up this map in a fluent style.
|
||||
*
|
||||
* @param id Matcher identifier (required)
|
||||
* @param sensorId Sensor identifier (required)
|
||||
* @param id Matcher identifier (required)
|
||||
* @param sensorId Sensor identifier (required)
|
||||
* @param queryParams Map of query parameters as name-value pairs
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>enableLogging - If true, return verbose logs for the evaluation
|
||||
* (optional)</li>
|
||||
* </ul>
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>enableLogging - If true, return verbose logs for the evaluation (optional)</li>
|
||||
* </ul>
|
||||
* @return MatcherEvaluationResults
|
||||
*
|
||||
*/
|
||||
|
@ -112,16 +110,16 @@ public interface MatchersApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Retrieves matchers
|
||||
*
|
||||
* @param ids Optional ';' delimited list of ids (optional)
|
||||
* @param names Optional ';' delimited list of names (optional)
|
||||
* @param includes Comma separated list of what to include, for example
|
||||
* \"Space,Condition\". Defaults to None (optional)
|
||||
* @param spaceId Optionally filter on objects based on their location in the topology
|
||||
* relative to the specified spaceId (optional)
|
||||
* @param traverse None (the default) for the specified spaceId only, Down for space and
|
||||
* descendants, Up for spaceId and ancestors, Any for both (optional)
|
||||
* @param minLevel Optional filter on minimum level, inclusive (optional)
|
||||
* @param maxLevel Optional filter on maximum level, inclusive (optional)
|
||||
* @param ids Optional ';' delimited list of ids (optional)
|
||||
* @param names Optional ';' delimited list of names (optional)
|
||||
* @param includes Comma separated list of what to include, for example
|
||||
* \"Space,Condition\". Defaults to None (optional)
|
||||
* @param spaceId Optionally filter on objects based on their location in the topology relative to
|
||||
* the specified spaceId (optional)
|
||||
* @param traverse None (the default) for the specified spaceId only, Down for space and
|
||||
* descendants, Up for spaceId and ancestors, Any for both (optional)
|
||||
* @param minLevel Optional filter on minimum level, inclusive (optional)
|
||||
* @param maxLevel Optional filter on maximum level, inclusive (optional)
|
||||
* @param minRelative Specify if min level is absolute or relative (optional)
|
||||
* @param maxRelative Specify if max level is absolute or relative (optional)
|
||||
* @return java.util.List<MatcherRetrieve>
|
||||
|
@ -143,26 +141,23 @@ public interface MatchersApi extends TwinsApiClient.Api {
|
|||
* allows for building up this map in a fluent style.
|
||||
*
|
||||
* @param queryParams Map of query parameters as name-value pairs
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>ids - Optional ';' delimited list of ids (optional)</li>
|
||||
* <li>names - Optional ';' delimited list of names (optional)</li>
|
||||
* <li>includes - Comma separated list of what to include, for example
|
||||
* \"Space,Condition\". Defaults to None (optional)</li>
|
||||
* <li>spaceId - Optionally filter on objects based on their location in the
|
||||
* topology relative to the specified spaceId (optional)</li>
|
||||
* <li>traverse - None (the default) for the specified spaceId only, Down for
|
||||
* space and descendants, Up for spaceId and ancestors, Any for both
|
||||
* (optional)</li>
|
||||
* <li>minLevel - Optional filter on minimum level, inclusive (optional)</li>
|
||||
* <li>maxLevel - Optional filter on maximum level, inclusive (optional)</li>
|
||||
* <li>minRelative - Specify if min level is absolute or relative
|
||||
* (optional)</li>
|
||||
* <li>maxRelative - Specify if max level is absolute or relative
|
||||
* (optional)</li>
|
||||
* </ul>
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>ids - Optional ';' delimited list of ids (optional)</li>
|
||||
* <li>names - Optional ';' delimited list of names (optional)</li>
|
||||
* <li>includes - Comma separated list of what to include, for example
|
||||
* \"Space,Condition\". Defaults to None (optional)</li>
|
||||
* <li>spaceId - Optionally filter on objects based on their location in the topology
|
||||
* relative to the specified spaceId (optional)</li>
|
||||
* <li>traverse - None (the default) for the specified spaceId only, Down for space and
|
||||
* descendants, Up for spaceId and ancestors, Any for both (optional)</li>
|
||||
* <li>minLevel - Optional filter on minimum level, inclusive (optional)</li>
|
||||
* <li>maxLevel - Optional filter on maximum level, inclusive (optional)</li>
|
||||
* <li>minRelative - Specify if min level is absolute or relative (optional)</li>
|
||||
* <li>maxRelative - Specify if max level is absolute or relative (optional)</li>
|
||||
* </ul>
|
||||
* @return java.util.List<MatcherRetrieve>
|
||||
*
|
||||
*/
|
||||
|
@ -224,7 +219,7 @@ public interface MatchersApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Retrieves a matcher
|
||||
*
|
||||
* @param id Matcher identifier (required)
|
||||
* @param id Matcher identifier (required)
|
||||
* @param includes Comma separated list of what to include (optional)
|
||||
* @return MatcherRetrieve
|
||||
*/
|
||||
|
@ -241,14 +236,14 @@ public interface MatchersApi extends TwinsApiClient.Api {
|
|||
* {@link MatchersRetrieveByIdQueryParams} class that allows for building up this map in a fluent
|
||||
* style.
|
||||
*
|
||||
* @param id Matcher identifier (required)
|
||||
* @param id Matcher identifier (required)
|
||||
* @param queryParams Map of query parameters as name-value pairs
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>includes - Comma separated list of what to include (optional)</li>
|
||||
* </ul>
|
||||
* <p>
|
||||
* The following elements may be specified in the query map:
|
||||
* </p>
|
||||
* <ul>
|
||||
* <li>includes - Comma separated list of what to include (optional)</li>
|
||||
* </ul>
|
||||
* @return MatcherRetrieve
|
||||
*
|
||||
*/
|
||||
|
@ -272,7 +267,7 @@ public interface MatchersApi extends TwinsApiClient.Api {
|
|||
* Update a matcher
|
||||
*
|
||||
* @param body The matcher information (required)
|
||||
* @param id Matcher identifier (required)
|
||||
* @param id Matcher identifier (required)
|
||||
*/
|
||||
@RequestLine("PATCH /api/v1.0/matchers/{id}")
|
||||
@Headers({"Accept: */*",})
|
||||
|
@ -281,11 +276,11 @@ public interface MatchersApi extends TwinsApiClient.Api {
|
|||
/**
|
||||
* Update a matcher
|
||||
*
|
||||
* @param id Matcher identifier (required)
|
||||
* @param name (optional)
|
||||
* @param description (optional)
|
||||
* @param id Matcher identifier (required)
|
||||
* @param name (optional)
|
||||
* @param description (optional)
|
||||
* @param friendlyName (optional)
|
||||
* @param conditions (optional)
|
||||
* @param conditions (optional)
|
||||
*/
|
||||
@RequestLine("PATCH /api/v1.0/matchers/{id}")
|
||||
@Headers({"Accept: */*",})
|
|
@ -6,8 +6,7 @@ package com.microsoft.twins.api;
|
|||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.OntologyRetrieve;
|
||||
import com.microsoft.twins.model.OntologyUpdate;
|
||||
import feign.Headers;
|
||||
|
@ -15,7 +14,7 @@ import feign.Param;
|
|||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface OntologiesApi extends TwinsApiClient.Api {
|
||||
public interface OntologiesApi {
|
||||
/**
|
||||
* Gets a list of ontologies
|
||||
*
|
|
@ -7,17 +7,17 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.ExtendedPropertyKeyCreate;
|
||||
import com.microsoft.twins.model.ExtendedPropertyKeyRetrieve;
|
||||
import com.microsoft.twins.model.ExtendedPropertyKeyUpdate;
|
||||
import com.microsoft.twins.model.ScopeEnum;
|
||||
import feign.Headers;
|
||||
import feign.Param;
|
||||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface PropertyKeysApi extends TwinsApiClient.Api {
|
||||
public interface PropertyKeysApi {
|
||||
/**
|
||||
* Creates a property key
|
||||
*
|
||||
|
@ -138,7 +138,7 @@ public interface PropertyKeysApi extends TwinsApiClient.Api {
|
|||
return this;
|
||||
}
|
||||
|
||||
public PropertyKeysDeleteBySpaceQueryParams scope(final String value) {
|
||||
public PropertyKeysDeleteBySpaceQueryParams scope(final ScopeEnum value) {
|
||||
put("scope", EncodingUtils.encode(value));
|
||||
return this;
|
||||
}
|
||||
|
@ -214,7 +214,7 @@ public interface PropertyKeysApi extends TwinsApiClient.Api {
|
|||
* method in a fluent style.
|
||||
*/
|
||||
public static class PropertyKeysRetrieveQueryParams extends HashMap<String, Object> {
|
||||
public PropertyKeysRetrieveQueryParams scope(final String value) {
|
||||
public PropertyKeysRetrieveQueryParams scope(final ScopeEnum value) {
|
||||
put("scope", EncodingUtils.encode(value));
|
||||
return this;
|
||||
}
|
|
@ -7,8 +7,7 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.SpaceResourceCreate;
|
||||
import com.microsoft.twins.model.SpaceResourceRetrieve;
|
||||
import com.microsoft.twins.model.SpaceResourceUpdate;
|
||||
|
@ -18,7 +17,7 @@ import feign.Param;
|
|||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface ResourcesApi extends TwinsApiClient.Api {
|
||||
public interface ResourcesApi {
|
||||
/**
|
||||
* Creates a resource
|
||||
*
|
|
@ -7,8 +7,7 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.RoleAssignmentCreate;
|
||||
import com.microsoft.twins.model.RoleAssignmentRetrieve;
|
||||
import feign.Headers;
|
||||
|
@ -16,7 +15,7 @@ import feign.Param;
|
|||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface RoleAssignmentsApi extends TwinsApiClient.Api {
|
||||
public interface RoleAssignmentsApi {
|
||||
/**
|
||||
* Checks permissions for a given path, user, domain, tenant id, accessType and resource type
|
||||
*
|
|
@ -7,8 +7,7 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.ExtendedPropertyCreate;
|
||||
import com.microsoft.twins.model.Location;
|
||||
import com.microsoft.twins.model.MatcherRetrieve;
|
||||
|
@ -21,7 +20,7 @@ import feign.Param;
|
|||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface SensorsApi extends TwinsApiClient.Api {
|
||||
public interface SensorsApi {
|
||||
/**
|
||||
* Creates a sensor
|
||||
*
|
|
@ -8,9 +8,8 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.BlobMetadataRetrieve;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.ExtendedPropertyCreate;
|
||||
import com.microsoft.twins.model.KeyStoreRetrieve;
|
||||
import com.microsoft.twins.model.Location;
|
||||
|
@ -26,7 +25,7 @@ import feign.Param;
|
|||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface SpacesApi extends TwinsApiClient.Api {
|
||||
public interface SpacesApi {
|
||||
/**
|
||||
* Creates a space
|
||||
*
|
||||
|
@ -367,8 +366,8 @@ public interface SpacesApi extends TwinsApiClient.Api {
|
|||
*/
|
||||
@RequestLine("GET /api/v1.0/spaces?ids={ids}&name={name}&types={types}&subtypes={subtypes}&statuses={statuses}&useParentSpace={useParentSpace}&userUpn={userUpn}&sensorDataTypes={sensorDataTypes}&includes={includes}&propertyKey={propertyKey}&propertyValue={propertyValue}&propertyValueSearchType={propertyValueSearchType}&spaceId={spaceId}&traverse={traverse}&minLevel={minLevel}&maxLevel={maxLevel}&minRelative={minRelative}&maxRelative={maxRelative}")
|
||||
@Headers({"Accept: */*",})
|
||||
List<SpaceRetrieveWithChildren> spacesRetrieve(@Param("ids") UUID ids,
|
||||
@Param("name") String name, @Param("types") String types, @Param("subtypes") String subtypes,
|
||||
List<SpaceRetrieveWithChildren> spacesRetrieve(@Param("ids") UUID ids, @Param("name") String name,
|
||||
@Param("types") String types, @Param("subtypes") String subtypes,
|
||||
@Param("statuses") String statuses, @Param("useParentSpace") Boolean useParentSpace,
|
||||
@Param("userUpn") String userUpn, @Param("sensorDataTypes") String sensorDataTypes,
|
||||
@Param("includes") String includes, @Param("propertyKey") String propertyKey,
|
||||
|
@ -790,8 +789,7 @@ public interface SpacesApi extends TwinsApiClient.Api {
|
|||
*/
|
||||
@RequestLine("GET /api/v1.0/spaces/{id}/keystore?includes={includes}")
|
||||
@Headers({"Accept: */*",})
|
||||
KeyStoreRetrieve spacesRetrieveKeyStore(@Param("id") UUID id,
|
||||
@Param("includes") String includes);
|
||||
KeyStoreRetrieve spacesRetrieveKeyStore(@Param("id") UUID id, @Param("includes") String includes);
|
||||
|
||||
/**
|
||||
* Gets the first keystore by walking up the spaces hierarchy
|
|
@ -4,13 +4,12 @@
|
|||
package com.microsoft.twins.api;
|
||||
|
||||
import java.util.List;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.IEnumEntity;
|
||||
import com.microsoft.twins.model.RoleDefinitionRetrieve;
|
||||
import feign.Headers;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface SystemApi extends TwinsApiClient.Api {
|
||||
public interface SystemApi {
|
||||
/**
|
||||
* Retrieve all supported device statuses
|
||||
*
|
|
@ -7,9 +7,8 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.CategoryEnum;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.ExtendedTypeCreate;
|
||||
import com.microsoft.twins.model.ExtendedTypeRetrieve;
|
||||
import com.microsoft.twins.model.ExtendedTypeUpdate;
|
||||
|
@ -18,7 +17,7 @@ import feign.Param;
|
|||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface TypesApi extends TwinsApiClient.Api {
|
||||
public interface TypesApi {
|
||||
/**
|
||||
* Creates an extended type
|
||||
*
|
|
@ -8,15 +8,14 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.UserDefinedFunctionRetrieve;
|
||||
import feign.Headers;
|
||||
import feign.Param;
|
||||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface UserDefinedFunctionsApi extends TwinsApiClient.Api {
|
||||
public interface UserDefinedFunctionsApi {
|
||||
/**
|
||||
* Creates a udf This is a multi-part request. For more information, see doc examples. Key value
|
||||
* pairs specified in the Content-Disposition header in the udf-chunk of the multipart request
|
||||
|
@ -72,10 +71,10 @@ public interface UserDefinedFunctionsApi extends TwinsApiClient.Api {
|
|||
@RequestLine("GET /api/v1.0/userdefinedfunctions?names={names}&ids={ids}&includes={includes}&spaceId={spaceId}&traverse={traverse}&minLevel={minLevel}&maxLevel={maxLevel}&minRelative={minRelative}&maxRelative={maxRelative}")
|
||||
@Headers({"Accept: */*",})
|
||||
List<UserDefinedFunctionRetrieve> userDefinedFunctionsRetrieve(@Param("names") String names,
|
||||
@Param("ids") UUID ids, @Param("includes") String includes,
|
||||
@Param("spaceId") String spaceId, @Param("traverse") String traverse,
|
||||
@Param("minLevel") Integer minLevel, @Param("maxLevel") Integer maxLevel,
|
||||
@Param("minRelative") Boolean minRelative, @Param("maxRelative") Boolean maxRelative);
|
||||
@Param("ids") UUID ids, @Param("includes") String includes, @Param("spaceId") String spaceId,
|
||||
@Param("traverse") String traverse, @Param("minLevel") Integer minLevel,
|
||||
@Param("maxLevel") Integer maxLevel, @Param("minRelative") Boolean minRelative,
|
||||
@Param("maxRelative") Boolean maxRelative);
|
||||
|
||||
/**
|
||||
* Gets a list of udfs
|
|
@ -8,9 +8,8 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import com.microsoft.twins.EncodingUtils;
|
||||
import com.microsoft.twins.TwinsApiClient;
|
||||
import com.microsoft.twins.model.BlobMetadataRetrieve;
|
||||
import com.microsoft.twins.model.EncodingUtils;
|
||||
import com.microsoft.twins.model.ExtendedPropertyCreate;
|
||||
import com.microsoft.twins.model.Location;
|
||||
import com.microsoft.twins.model.UserCreateWithSpace;
|
||||
|
@ -21,7 +20,7 @@ import feign.Param;
|
|||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
public interface UsersApi extends TwinsApiClient.Api {
|
||||
public interface UsersApi {
|
||||
/**
|
||||
* Creates a blob This is a multi-part request. For more information, see sample app or doc
|
||||
* examples. Key value pairs specified in the Content-Disposition header in the blob-chunk of the
|
|
@ -1,7 +1,7 @@
|
|||
/**
|
||||
* Copyright (c) Microsoft Corporation. Licensed under the MIT License.
|
||||
*/
|
||||
package com.microsoft.twins;
|
||||
package com.microsoft.twins.model;
|
||||
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.URLEncoder;
|
Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше
Загрузка…
Ссылка в новой задаче