public class ThngService extends EvrythngServiceBase
/thngs endpoint of the EVRYTHNG Engine API.| Modifier and Type | Field and Description |
|---|---|
protected ActionDeserializer |
deserializer |
static String |
PATH_THNG |
static String |
PATH_THNG_ACTIONS |
static String |
PATH_THNG_ALL_ACTION |
static String |
PATH_THNG_ALL_ACTIONS |
static String |
PATH_THNG_LOCATION |
static String |
PATH_THNG_PROPERTIES |
static String |
PATH_THNG_PROPERTY |
static String |
PATH_THNG_REDIRECTOR |
static String |
PATH_THNG_REDIRECTOR_QR |
static String |
PATH_THNG_TYPED_ACTION |
static String |
PATH_THNG_TYPED_ACTIONS |
static String |
PATH_THNGS |
| Constructor and Description |
|---|
ThngService(ApiManager apiManager,
EvrythngJacksonModule evrythngJacksonModule) |
absoluteUri, delete, deleteMultiple, encodeBase64, get, getConfig, iterator, mqttUrl, onBuilderCreated, post, post, postAsynchronously, postMultipart, postMultipart, put, put, putMultipart, putMultipart, putMultiple, urlEncodePathPartpublic static final String PATH_THNGS
public static final String PATH_THNG
public static final String PATH_THNG_PROPERTIES
public static final String PATH_THNG_PROPERTY
public static final String PATH_THNG_LOCATION
public static final String PATH_THNG_REDIRECTOR
public static final String PATH_THNG_REDIRECTOR_QR
public static final String PATH_THNG_ACTIONS
public static final String PATH_THNG_ALL_ACTIONS
public static final String PATH_THNG_ALL_ACTION
public static final String PATH_THNG_TYPED_ACTIONS
public static final String PATH_THNG_TYPED_ACTION
protected ActionDeserializer deserializer
public ThngService(ApiManager apiManager, EvrythngJacksonModule evrythngJacksonModule)
public EvrythngApiBuilder.Builder<Thng> thngCreator(Thng thng) throws EvrythngClientException
thng - Thng instanceEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic final EvrythngApiBuilder.Builder<Iterator<org.pcollections.PVector<Thng>>> iterator() throws EvrythngClientException
Thngs, whether all, by filter, or by ids, in an iterative way.EvrythngApiBuilder.Builder.perPage(int) method, until all matching resources are returned.EvrythngClientException - in case server communication fails.public EvrythngApiBuilder.Builder<Thng> thngReader(String thngId) throws EvrythngClientException
Thng.
GET "/thngs/%s"
thngId - thng idEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Thng> thngUpdater(String thngId, Thng thng) throws EvrythngClientException
Thng.
PUT "/thngs/%s"
thngId - thng idthng - Thng instanceEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Long> thngsUpdater(Thng thng) throws EvrythngClientException
Thng. Select the Thngs to update using query parameters ?ids or ?filter.
PUT "/thngs"
thng - Thng instanceEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Boolean> thngDeleter(String thngId) throws EvrythngClientException
Thng.
DELETE "/thngs/%s"
thngId - thng idEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Long> thngsDeleter() throws EvrythngClientException
Thngs to delete using query parameters ?ids or ?filter.
DELETE "/thngs"
EvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Property<?>>> propertiesCreator(String thngId, List<Property<?>> properties) throws EvrythngClientException
thngId - thng idproperties - list of StringProperty instancesEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Property<?>>> propertiesReader(String thngId) throws EvrythngClientException
StringProperty resources from the referenced Thng.
thngId - thng idEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic final EvrythngApiBuilder.Builder<Iterator<org.pcollections.PVector<Property<?>>>> propertiesIterator(String thngId, String key) throws EvrythngClientException
EvrythngApiBuilder.Builder.perPage(int) method, until all matching resources are returned.EvrythngClientException - in case server communication fails.public EvrythngApiBuilder.Builder<Boolean> propertiesDeleter(String thngId) throws EvrythngClientException
thngId - thng idEvrythngApiBuilder.BuilderEvrythngClientException@Deprecated public EvrythngApiBuilder.Builder<List<Property<?>>> propertyReader(String thngId, String key) throws EvrythngClientException
propertiesIterator(String, String) instead.thngId - thng idkey - keyEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Property<?>>> propertyUpdater(String thngId, String key, Property<?> update) throws EvrythngClientException
thngId - thng idkey - keyupdate - property updateEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Property<?>>> propertyUpdater(String thngId, String key, String value, Long timestamp) throws EvrythngClientException
EvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Property<?>>> propertyUpdater(String thngId, String key, Number value, Long timestamp) throws EvrythngClientException
EvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Property<?>>> propertyUpdater(String thngId, String key, Boolean value, Long timestamp) throws EvrythngClientException
EvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Property<?>>> propertyUpdater(String thngId, String key, String value) throws EvrythngClientException
EvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Property<?>>> propertyUpdater(String thngId, String key, Number value) throws EvrythngClientException
EvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Property<?>>> propertyUpdater(String thngId, String key, Boolean value) throws EvrythngClientException
EvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Boolean> propertyDeleter(String thngId, String key) throws EvrythngClientException
thngId - thng idkey - keyEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Location>> locationReader(String thngId) throws EvrythngClientException
thngId - thng idEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Location>> locationUpdater(String thngId, Location location) throws EvrythngClientException
thngId - thng idlocation - Location instanceEvrythngApiBuilder.BuilderEvrythngClientExceptionlocationUpdater(String, List)public EvrythngApiBuilder.Builder<List<Location>> locationUpdater(String thngId, List<Location> locations) throws EvrythngClientException
thngId - thng idlocations - list of LocationEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Boolean> locationDeleter(String thngId) throws EvrythngClientException
thngId - thng idEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Redirector> redirectorCreator(String thngId, Redirector redirection) throws EvrythngClientException
thngId - thng idredirection - Redirector instanceEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Redirector> redirectorReader(String thngId) throws EvrythngClientException
thngId - thng idEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Boolean> redirectorDeleter(String thngId) throws EvrythngClientException
thngId - thng idEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Redirector> redirectorUpdater(String thngId, Redirector redirection) throws EvrythngClientException
thngId - thng idredirection - Redirector instanceEvrythngApiBuilder.BuilderEvrythngClientExceptionpublic <T extends Action> EvrythngApiBuilder.Builder<T> actionCreator(String thngId, T action) throws EvrythngClientException
EvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Action> actionAllCreator(String thngId, Action action) throws EvrythngClientException
EvrythngClientExceptionpublic <T extends Action> EvrythngApiBuilder.Builder<T> actionReader(String thngId, Class<T> actionClass, String actionId) throws EvrythngClientException
EvrythngClientExceptionpublic EvrythngApiBuilder.Builder<CustomAction> actionReader(String thngId, String customType, String actionId) throws EvrythngClientException
EvrythngClientExceptionpublic EvrythngApiBuilder.Builder<Action> actionReader(String thngId, String actionId) throws EvrythngClientException
EvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<Action>> actionsReader(String thngId) throws EvrythngClientException
EvrythngClientExceptionpublic <T extends Action> EvrythngApiBuilder.Builder<List<T>> actionsReader(String thngId, Class<T> actionClass) throws EvrythngClientException
EvrythngClientExceptionpublic EvrythngApiBuilder.Builder<List<CustomAction>> actionsReader(String thngId, String customType) throws EvrythngClientException
EvrythngClientExceptionprotected void checkCustomType(String customType)
Copyright © 2016 EVRYTHNG Ltd London / Zurich. All rights reserved.