deliverable 3.1.b: big iot api design - second...

343
BIG IoT – Bridging the Interoperability Gap of the Internet of Things Deliverable 3.1.b: BIG IoT API Design - Second Release Version 1.0 Delivery Date: 30.09.2017 This project has received funding from the European Union’s Horizon 2020 research and in- novation program under grant agreement No 688038.

Upload: others

Post on 22-May-2020

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

BIG IoT – Bridging the Interoperability Gap of the Internet of Things

Deliverable 3.1.b:

BIG IoT API Design - Second Release

Version 1.0

Delivery Date: 30.09.2017

This project has received funding from the European Union’s Horizon 2020 research and in-

novation program under grant agreement No 688038.

Page 2: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

DELIVERABLE 3.1.B: BIG IOT API DESIGN - SECOND RELEASE D.3.1.B

© 2017 2

Document Information

Responsible Person and Affiliation Siemens AG:

Andreas Ziller

Due Date / Delivery Date 30.09.2017

State Final Version

Reviewers Ernest Teniente (UPC)

Karina Rehfeldt (TUC)

Version 1.0

Confidentiality Public

Version Description of Changes Date of Resolution

0.1 Draft sent to reviewers 01.09.2017

0.9 RC sent to reviewers 17.09.2017

1.0 Document to be submitted 30.09.2017

List of Authors

Organization Authors Main organizations’ contributions

Bosch Stefan Schmid, Denis Kramer Chapter 2, 3

Econais Costas Pipilas Section 4.5

Siemens Andreas Ziller, Arne Bröring Chapter 1, 3, 4, 5

Page 3: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

DELIVERABLE 3.1.B: BIG IOT API DESIGN - SECOND RELEASE D.3.1.B

© 2017 3

Abbreviations

Abbreviation Meaning

A1 Access Interface #1

API Advanced Programming Interface

BCN Barcelona (pilot)

BIG IoT Project title: Bridging the Interoperability Gap of the Internet of Things

DOA Description of Action

HTTP Hypertext Transfer Protocol

ID Identifier

IoT Internet of Things

IP Internet Protocol

ISO International Organization for Standardization

JAR Java Archive

JSON JavaScript Object Notation

MQTT Message Queue Telemetry Support

MS Milestone

NAT Network Address Translation

NG Northern Germany (pilot)

OD Offering Description

OGC Open Geospatial Consortium

P1 Programming Interface #1

P2 Programming Interface #2

P3 Programming Interface #1

PIE Piedmont (pilot)

RDF Resource Description Framework

REST Representational State Transfer

Page 4: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

DELIVERABLE 3.1.B: BIG IOT API DESIGN - SECOND RELEASE D.3.1.B

© 2017 4

SDK Software Development Kit

SES Sensor Event Service

SOS Sensor Observation Service

SPARQL SPAQRL Protocol and RDF Query Language

SPS Sensor Planning Service

SWE Sensor Web Enablement

TCP Transmission Control Protocol

UI User Interface

URI Uniform Resource Identifier

URL Uniform Resource Locator

Page 5: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 5

Table of Contents

Summary.................................................................................................................................................. 8

1. Introduction ...................................................................................................................................... 9

1.1. Motivation ..................................................................................................................................... 9

1.2. Relation to other Deliverables ..................................................................................................... 10

2. BIG IoT API in context of the High-Level Architecture ..................................................................... 13

2.1. Core Concepts of the BIG IoT Architecture ................................................................................. 13

2.2. BIG IoT Architecture Overview .................................................................................................... 15

2.3. Interfaces and Interactions ......................................................................................................... 17

3. BIG IoT API Tutorial ......................................................................................................................... 19

3.1. Installation of the Tooling ........................................................................................................... 19

3.2. Setting up an Example ................................................................................................................. 20

3.3. BIG IoT from a Provider's Perspective ......................................................................................... 29

3.4. BIG IoT from a Consumer's Perspective ...................................................................................... 33

4. BIG IoT API Mechanisms ................................................................................................................. 47

4.1. Operations of BIG IoT Offerings .................................................................................................. 47

4.2. API mechanisms for Integration Mode 1 ..................................................................................... 48

4.3. API mechanisms for Integration Mode 2 ..................................................................................... 48

4.4. API mechanisms for Integration Mode 3 ..................................................................................... 63

4.5. API mechanisms for Integration Mode 4 ..................................................................................... 67

5. Conclusion & Outlook ..................................................................................................................... 70

References ............................................................................................................................................. 72

Appendix A UML Class Diagrams ............................................................................................................ 73

Appendix B BIG IoT API Documentation ................................................................................................. 77

Page 6: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 6

List of Figures

Figure 1 Relation of deliverables .............................................................................................. 11

Figure 2 Core architecture concepts and terminology ............................................................. 14

Figure 3 Building block view on BIG IoT architecture ............................................................... 16

Figure 4 Install Buildship Gradle Integration ............................................................................ 21

Figure 5 Eclipse Oxygen with fresh, empty workspace ............................................................ 22

Figure 6 Importing a Gradle project ......................................................................................... 23

Figure 7 Import Gradle Project Wizard .................................................................................... 23

Figure 8 Import Gradle Project Wizard - Setting project root directory ................................... 24

Figure 9 Dialog during Gradle build .......................................................................................... 24

Figure 10 Having the BIG IoT API imported in Eclipse .............................................................. 25

Figure 11 Login button on Marketplace ................................................................................... 26

Figure 12 Marketplace ............................................................................................................. 26

Figure 13 Add a provider .......................................................................................................... 27

Figure 14 Enter a provider name .............................................................................................. 27

Figure 15 Your screen after you created a provider ................................................................. 28

Figure 16 Add the provider ID .................................................................................................. 29

Figure 17 Typical workflow in integration mode 2 ................................................................... 49

Figure 18 Deployment example ............................................................................................... 50

Figure 19 Sequence diagram for offering access in integration mode 2 .................................. 51

Figure 20 Blocking call .............................................................................................................. 53

Figure 21 Non-blocking call ...................................................................................................... 54

Figure 22 Synchronous and asynchronous feeds ..................................................................... 58

Figure 23 Feeds in integration modes 1 and 3 ......................................................................... 59

Figure 24 Feeds in integration modes 2 ................................................................................... 59

Figure 25 Retrofitting synchronous feeds ................................................................................ 60

Figure 26 Retrofitting asynchronous feeds .............................................................................. 61

Page 7: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 7

Figure 27 Typical workflow in integration mode 3 ................................................................... 64

Figure 28 Proxy service integration in integration mode 4 ...................................................... 68

Figure 29 Integration mode 4 interactions ............................................................................... 69

Figure 30 Focus consumer ....................................................................................................... 73

Figure 31 Focus offering query ................................................................................................. 74

Figure 32 Focus offering ........................................................................................................... 75

Figure 33 Focus provider .......................................................................................................... 76

List of Tables

Table 1 Tools used for development of providers and consumers .......................................... 20

Table 2 A1-ACCESS specification .............................................................................................. 55

Table 3 A1-FEED specification .................................................................................................. 63

Table 4 API characteristics relevant for integration mode 3 .................................................... 67

Page 8: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 8

Summary

The deliverable D3.1.b is second version of the technical report for the BIG IoT API. It describes

the design and the underlying mechanisms of the BIG API. Furthermore, it gives a developer-

oriented tutorial for the utilization for the API functions.

The second version includes multiple changes since the initial version. So, the high-level ar-

chitecture (chapter 2) is updated with respect to recent findings in work package 2. The tuto-

rial chapter 3 is updated to cover the most recent version 0.9.4 of the BIG API. It includes an

improved start to end real world example for setting up a provider as well as a consumer

instance. The new lib support of integration mode 3 is now included chapter 4. In addition,

the conceptual mechanisms have been complemented with recent findings plus the chapter

is restructured in order to improve readability. The appendix is updated to the specification

of the most recent API version 0.9.4.

Page 9: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 9

1. Introduction

This chapter introduces to this deliverable, motivates the topic, and defines its scope.

1.1. Motivation

The idea of an Internet of Things is no more a futuristic vision, but indeed an increasing com-

mercial reality that reaches to various application domains ranging from quantified self and

smart home applications, over smarter cities and eHealth systems, to Industry 4.0. Dozens of

IoT platforms are upcoming. These include cloud solutions, such as Evrythng [1], ThingWorx

[2], Xively [3], or Yaler [4], but also on premise solutions such as Bosch’s IoT Suite [5], as well

as thematically or geographically focused platforms, such as the Smart Data platform for the

Piedmont region [6]. However, up to now, these IoT platforms failed to form vibrant IoT eco-

systems.

Currently, there is no vibrant collaborative IoT ecosystem, since the number of stakeholders

involved in IoT ecosystems (e.g., IoT platform providers, service and application providers) is

large, the market entry barriers are high, and the potential gain is low for a single stakeholder.

Providers of platforms and services require a simple, established way to offer access to their

resources. Marketplaces that enable providers to monetize access to the resources offered

by their platforms and services are not yet available. Once these marketplaces are estab-

lished, developers will be able to easily build IoT services and applications and build their

products around these. Revenue streams can then be shared across all contributing entities

(i.e., IoT platform and service providers). A key task of a marketplace is to provide extended

functionalities to enable the advertising, dynamic discovery, automated orchestration, and

negotiation of services to facilitate their usage.

However, before such marketplaces can bring their effect, a serious market barrier needs to

be tackled: the missing interoperability. The fragmentation of the IoT and the lack of interop-

erability prevent the emergence of broadly accepted IoT ecosystems [7]. A recent McKinsey

study [8] estimates that a 40% share of the potential economic value of the IoT directly de-

pends on interoperability between IoT platforms. Today, we are dealing with various vertically

oriented and mostly closed systems. Architectures for IoT are built on heterogeneous stand-

ards (e.g., IETF CoAP [9], OASIS MQTT [10], OMA LWM2M [11], OGC SWE [12], or OneM2M

[13]) or even proprietary interfaces. As a result, most existing and emerging IoT platforms

offer heterogeneous ways for accessing IoT resources.

Page 10: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 10

This causes interoperability problems when overarching, cross-platform, and cross-domain

applications are to be built, and eventually prevents the emergence of vibrant IoT ecosys-

tems. Additionally, it leads to barriers for business opportunities, especially for small innova-

tive enterprises, which cannot afford to offer their solution across multiple platforms. They

can only provide applications and services for a small number of platforms, e.g., a traffic in-

formation application for an IoT platform of a specific city. This lack of interoperability results

in lost business opportunities and prevents innovative business ideas.

In order to address these shortcomings in today's IoT landscape, the BIG IoT project has de-

veloped an architecture as a foundation for building IoT ecosystems (see D2.4). It overcomes

the above described hurdles through (1) a common API, (2) semantic descriptions of re-

sources and services, as well as (3) a marketplace as a nucleus of the ecosystem. This will

allow new services by combining data from multiple platforms (e.g., parking information from

various smart city platforms). In addition, platforms from multiple domains (e.g. home and

city) and regions will be combined, such that applications can utilize all relevant information

and work seamlessly across regions (e.g. the same smart parking application works on top of

a smart city platform in Berlin, in Barcelona and in London).

The scope of this document is the specification of the BIG IoT API. This BIG IoT API can be seen

from two complementary perspectives, as (1) a programming API implemented as libraries

(libs) of an SDK and (2) a web API. Both perspectives are covered in this document. The pro-

gramming API is provided to developers in order to facilitate the implementation of applica-

tions or the provision of platforms and services. The web API defines protocols and encodings

for actual message exchange to implement the various interactions and workflows designed.

Thereby, the programming API abstracts from the underlying communication protocols de-

fined in the web API.

Parts of this deliverable (mainly section 3) will be used as online documentation, which will

be accessible to developers. For an easy understanding, those parts are written in a tutorial-

style. This documentation will facilitate the onboarding of external developers joining through

an open call and it will generally help to grow the BIG IoT ecosystem.

1.2. Relation to other Deliverables

The tasks of WP3 and WP4 are highly interrelated, however, their deliverables have each their

own, clear responsibilities. They address the technical concepts for BIG IoT. The outcomes are

evaluated in the pilots and demonstrators of WP5.

Page 11: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 11

Figure 1 follows the general BIG IoT architecture description in D2.4 and illustrates at hand of

this architecture the scope of each of the different deliverables of the tasks 3.1, 3.2, 4.1, 4.2,

and 4.3.

Figure 1 Relation of deliverables

D3.1 covers the description of the BIG IoT API. This entails a specification of the web API (e.g.,

interaction model, and encodings) as well as description of the programmatic API that is im-

plemented as part of consumer and Provider Lib of the SDK.

Page 12: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 12

D4.1 describes the architecture of the BIG IoT Marketplace. This includes the general design,

the workflows of interactions, the GraphQL-based API of the marketplace, as well as the user

interface of the portal to utilize the marketplace. Also contained in this deliverable is a de-

scription on how to map between the GraphQL API of the marketplace frontend and its

SPARQL based triple store backend.

D3.2 describes the model and schema of the core semantic model of BIG IoT. This semantic

model is used as a basis for (1) the offering description to define the capabilities of offerings

provided by IoT platforms or services, and (2) the underlying data model of the BIG IoT Mar-

ketplace.

D4.2 builds up on the core semantic model of D3.2 and defines the application domain model,

which specifies a vocabulary of terms that can be used in offering descriptions, and in the

triple store of the marketplace.

D4.3 addresses the orchestration and composition of the offerings of BIG IoT providers (i.e.,

platforms or services). A composition of offerings can be specified by defining a Recipe. The

semantic model and examples of such recipes is the scope of this deliverable.

Page 13: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 13

2. BIG IoT API in context of the High-Level Architecture

This section introduces the high-level architecture of BIG IoT with the goal to explain the con-

text for the BIG IoT API discussion. The full specification of the BIG IoT Architecture - Release

1 is provided in Deliverable D2.4.b.

2.1. Core Concepts of the BIG IoT Architecture

This section summarizes the underlying concepts of the BIG IoT architecture and the interac-

tions between them, namely offerings, (offering) providers and consumers, and the interac-

tions of registering and discovering offerings via a marketplace, and accessing the resources

offered by a provider (see Figure 2).

An offering encompasses a set of IoT resources, typically a set of related information (e.g.

low-level sensor data like temperature or aggregate information across a region) or functions

(e.g. actuation tasks like open a gate or computational functions like compute a route), that

are offered on a marketplace.

Providers register their offerings on a marketplace and provide access to the offered re-

sources via the BIG IoT API. A provider can be either a platform or a service instance that

offers available resources, i.e., some information or access to functions that it wants to share

or trade on the marketplace (e.g. an IoT platform of a parking loT provider). Consumers dis-

cover and subscribe to offerings of interest via a marketplace in order to access the resources.

A consumer can be either an application or a service instance that requires access to IoT re-

sources in order to implement an intended service or function (e.g., a smart parking service

provided by the city).

In technical terms, a provider registers its offerings on the marketplace by providing an offer-

ing description for each offering. An offering can for example entail parking information for a

city and include data such as a geo location or address of the parking lot, the type of lot (e.g.

garage or on-street), available spots, occupied spots, etc. In order to increase interoperability

between different IoT platforms, the offering description is provided in a machine interpret-

able manner. All relevant communication metadata is provided on how the offering can be

accessed (e.g., endpoint URL, which HTTP method, etc.). As a default vocabulary set, the of-

fering description includes a local identifier (unique to a provider), a name of the offering,

and the input and output data expected/provided from/to a consumer when the offering is

Page 14: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 14

accessed. The description may also include information about the region (e.g. the city or spa-

tial extent) where the resources relate to, the price for accessing the resources, the license of

the data provided, the access control list, etc.

Figure 2 Core architecture concepts and terminology

Consumers discover offerings of interest on the marketplace by providing an (offering) query.

The query entails a specification of the type of offerings the consumer is interested in. For

example, a consumer can provide a description of the desired resources (such as type of park-

ing information), and also define the maximum price, the desired license types, the region,

etc. Upon a discovery request, the marketplace identifies all matching offerings and returns

them to the consumer. The consumer can then choose the offerings of interest and subscribe

to those on the marketplace. Since the discovery can take place at run-time, a consumer is

able to identify and subscribe to newly offered resources as they emerge. Finally, to limit the

data to be transmit upon accessing an offering, a consumer can also provide a filter in the

request.

Page 15: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 15

A BIG IoT Application can also be created by instantiating a Recipe with offerings on a mar-

ketplace that fulfil the Recipe ingredient requirements. A semantic description is created for

a Recipe instance with the offerings selected during instantiation. On a marketplace, there

can be many offerings from diverse IoT platforms or services that match to Recipe ingredient

requirements. In such cases, the user can select an offering based on its spatial constraints or

price, recommendations, licensing information etc. Therefore, a Recipe once created can be

used multiple times to create applications customised to a user, with matching offerings from

diverse IoT platforms and services.

2.2. BIG IoT Architecture Overview

This section provides an overview of the BIG IoT architecture.

2.2.1. High-level Architecture Building Blocks

As shown in Figure 3, we distinguish the following five core building blocks:

1. BIG IoT enabled platform – this IoT platform implements (as a provider) the BIG IoT

API, to register offerings on a BIG IoT Marketplace, and grants BIG IoT Services or Ap-

plications (as consumers) access to the offered resources.

2. BIG IoT Application – this application software implements and uses the BIG IoT API,

(as a consumer) to discover offerings on a BIG IoT Marketplace, and to access the re-

sources provided by one or more BIG IoT Services or Platforms (as providers).

3. BIG IoT Service – this IoT service implements and uses the BIG IoT API to register of-

ferings on a BIG IoT Marketplace (as a provider) and/or to discover and access offer-

ings provided via a BIG IoT Marketplace (as a consumer).

4. BIG IoT Marketplace – this composite system consists of sub-components: The mar-

ketplace API serves as an entry point for all communications and interactions with the

marketplace; the Identity Management Service (IdM) which authenticates and author-

izes providers and consumers; the eXchange, which allows registration and discovery

of offerings using semantic technologies; the Web Portal for users of the marketplace;

and the Charging Service, which collects accounting information.

5. BIG IoT Lib (SDK) – this is an implementation of the BIG IoT API that supports service

and application developers. The BIG IoT Lib consists of a Provider Lib and a Consumer

Lib part. It translates function calls from the respective application or service logic, or

the platform code into interactions with the marketplace, or peer-services or -plat-

Page 16: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 16

forms. The Provider Lib allows a platform or service to authenticate itself on a mar-

ketplace and to register offerings. The Consumer Lib allows an application or service

to authenticate itself on a marketplace, to discover available offerings based on se-

mantic queries, and to subscribe to offerings of interest. The use of semantic technol-

ogies enables the eXchange to perform semantic matching even in case providers and

consumers use different semantic models or formats, as long as a common meta-

model defines the relations/mapping between the different semantic models and

converters for the different semantic formats are supported.

Figure 3 Building block view on BIG IoT architecture

The architecture supports the following platform integration modes in order to meet the ar-

chitectural requirements defined in deliverable D2.3.b:

Page 17: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 17

Mode 1: the platform developer uses the Programming Interface P1 provided by the

Provider Lib to programmatically extend an existing or new IoT platform.

Mode 2: the provider develops and operates a BIG IoT Gateway Service, which handles

all BIG IoT related interactions and translates the relevant requests into calls sup-

ported by the existing platform (Integration Interface I1).

Mode 3: the provider develops and operates a BIG IoT Management Service, which

handles the interactions with the marketplace. It integrates with the legacy platform

by implementing the Integration Interface I2. Access to the resource offerings is pro-

vided directly by the legacy platform, based on the already available interface.

Mode 4: the provider develops and operates a BIG IoT Proxy Service, which handles

the interactions with the marketplace and offers the Access Interface A1. The proxy

service acts as an “always-available” proxy on behalf of a typically constrained device-

level platform. The proxy stores and offers information that are provided by a (con-

strained) platform and is able to queue access requests (e.g. tasks) to functions until

the platform re-connects to the proxy and pulls new tasks.

2.3. Interfaces and Interactions

Besides the core components, Figure 3 also depicts the relevant interfaces of the architecture.

The Programming Interfaces P1 and P2, provided by the BIG IoT Lib, are offered to developers

to connect their components with the marketplace and other entities. For easy integration of

constrained device-level platforms, a special BIG IoT Lib is provided, which allows developers

to easily interact with the BIG IoT Proxy Service (via the Programming Interface P3).

The BIG IoT Marketplace provides six interfaces to allow interactions with its services. The M1

interface is used by the provider and consumer instances to authenticate themselves on the

marketplace at start-up. Upon successful authentication, the Provider or Consumer Libs will

obtain the required credentials for any further communication and interaction with the mar-

ketplace. The M2 interface is used by providers to register/deregister offerings, while the M3

interface is used by consumers to discover offerings on the marketplace. Once a registration

request is received, the BIG IoT eXchange validates the offerings and stores them in a seman-

tic database. To subscribe/unsubscribe to offerings, consumers use the M4 interface. With a

subscription, a consumer indicates its intent to access the offered resources, and provides its

consent with respect to the offering's license, price, etc. Once an offering is subscribed, the

eXchange provides the unique credentials to the consumer for accessing this offering on the

Page 18: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 18

provider end. In case the offering has expired or has been updated by the provider, the eX-

change revokes the subscription and indicates the cause in the response. The M5 interface is

used by consumers and providers to send accounting information in regular time intervals to

the Accounting Service. Charging models (e.g. per request or per byte) can differ between

offerings, and are specified by a provider in the offering description. The M6 Interface is used

by the Consumer Lib to report access service level measurement results and access failures

to the BIG IoT Marketplace. The marketplace interfaces M1-M4 are used accordingly by the

Web Portal.

The Access Interface A1 is the interface via which a consumer gets access to resources offered

by a provider. Depending on the Provider Lib implementation, it will support different access

means. All Provider Libs shall support the HTTP-based request/response access. Optionally,

a Provider Lib can also support other protocols (e.g. WebSockets, MQTT) and/or other access

paradigms (e.g. streaming).

Page 19: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 19

3. BIG IoT API Tutorial

This section gives developers a quick introduction to the utilization of the BIG IoT API. It is

written in a language addressing developers directly. This tutorial shall be part of the BIG IoT

API documentation which will be used by the BIG IoT Open Call partners.

Using the BIG IoT SDK it is easy to dive into the BIG IoT ecosystem. It is a Java SDK allowing

providers to register and manage their offerings and consumers to access offerings from the

BIG IoT Marketplace. The SDK can be retrieved and integrated into existing code as a Maven

or Gradle dependency from the BIG IoT Nexus repository.

This tutorial provides a general walkthrough for the BIG IoT Lib. We split this tutorial into

different sections: The first part will provide a simple example with a provider and a consumer

to get you started. It shows how to bring an existing IoT platforms into the BIG IoT ecosystem.

The example platform is a simple IoT platform which offers parking data in Barcelona and

makes it public on the BIG IoT Marketplace. The second part will show how to use the BIG IoT

Consumer Library to access this data from a service developer's perspective. The last part will

describe advanced features of the BIG IoT Lib.

3.1. Installation of the Tooling

In order to try the examples or to get started for development, you have to setup your devel-

opment environment. If you want to follow this example, it helps you a lot if you have installed

the tools from the table below. Of course you can you use your own tooling, but if you are

not sure, just get exactly the version from the “We used …” column.

You have to install … We used … You’ll find it under …

Windows 7

Web Browser Chrome

Firefox

https://www.google.de/chrome

https://www.mozilla.org/firefox

Git The Git distribution of git-scm.com

(v2.11.0 )

https://git-scm.com/

Page 20: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 20

Java Java SE Development Kit 8 (JDK 8) http://www.oracle.com/technet-

work/java/javase/downloads/in-

dex.html

Eclipse Eclipse Oxygen (v4.7.0) or

Eclipse Neon.1a (v4.6.1) or

in the distribution

“Eclipse IDE for Java EE Developers”

If you install with eclipse installer,

make sure you select the right distri-

bution!

http://www.eclipse.org

Gradle The Eclipse plugin “Buildship Gradle

Integration 1.0”

In Eclipse: go to “Help”

“Eclipse Marketplace”. Search

for “buildship”

Table 1 Tools used for development of providers and consumers

3.2. Setting up an Example

If you want to try the tutorial by yourself, you can download our example projects source

code package (https://github.com/BIG-IoT/example-projects), which gives you a

quick start. It contains multiple examples. We’ll use in this tutorial: java-example-consumer

and java-example-provider.

Now, execute the following steps:

cd <your Eclipse workspace folder> (e.g. C:\Users\andreas\workspace)

git clone https://github.com/BIG-IoT/example-projects

Page 21: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 21

Figure 4 Install Buildship Gradle Integration

The BIG IoT examples come as a Gradle project. If you haven’t done yet, you have to install

Gradle. We had good experience using the Eclipse plugin “buildship”. So, in Eclipse menu bar

choose “Help” “Eclipse Marketplace”. Search for “buildship”, search and install “Buildship

Gradle Integration”. You have to accept the license conditions; Eclipse is restarted after that.

Page 22: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 22

Figure 5 Eclipse Oxygen with fresh, empty workspace

We recommend that you start from a fresh workspace. This is the case if you just installed

Eclipse else just switch to a new workspace.

In order to setup the BIG IoT examples as new Java project, proceed as follows:

Choose “File” “Import”.

Page 23: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 23

Figure 6 Importing a Gradle project

Select “Gradle\Gradle Project”.

Figure 7 Import Gradle Project Wizard

Page 24: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 24

Hit “Next”

Figure 8 Import Gradle Project Wizard - Setting project root directory

In the “Project root directory” text field, set the folder where the example sources are located

(here C:\Users\andreas\workspace\example-projects)). It takes a while until all de-

pendencies are retrieved via Gradle.

In the following, you probably receive the following question:

Figure 9 Dialog during Gradle build

Page 25: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 25

Choose “Overwrite”.

Figure 10 Having the BIG IoT API imported in Eclipse

3.2.1. Try an Example Demo

Before you can start the demo, you have to create a provider and a consumer first. Therefore

open a web browser and go to https://market.big-iot.org.

Page 26: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 26

Figure 11 Login button on Marketplace

There you find a yellow login button in the lower left corner. Click it and authenticate with

your Google or GitHub account. Then, you’ll find the text “New Organization”. Click it and

create your organization. Now, you should see a screen similar to this

Figure 12 Marketplace

Page 27: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 27

As you can see my organization has the name “Rain Cloud”. Now, we have to create a provider

for the demo. Therefore, click on “My Providers” and then on “+ Provider”

Figure 13 Add a provider

Find a good name for your provider and hit “Save”.

Figure 14 Enter a provider name

Page 28: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 28

Figure 15 Your screen after you created a provider

Now, it is important, that you transfer the credentials to your example code.

This is a two-step process. First we copy the Provider ID to the clipboard.

Therefore click on “Copy ID to Clipboard”. Then switch to eclipse and open the

provider example. It is located in in the sub-project java-example-provider below

src/main/java/org/bigiot/examples/ExampleProvider.java.

There, you have to paste the ID as the value of PROVIDER_ID as in the screenshot below.

Page 29: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 29

Figure 16 Add the provider ID

Now, you have to insert the provider secret. Switch back to your browser window with the

marketplace and click on “Load Provider Secret” and then click again on “Copy Secret to Clip-

board”. Switch back to Eclipse and paste it between the exclamation marks as value for

PROVIDER_SECRET.

Now, you start the example provider: Select the file ExampleProvider.java in the “Project

Explorer”, in the menu bar hit “Run” “Run as” “Java Application”. Accept the firewall

dialogue. The provider is now running, it offers a parking availability service, which is regis-

tered in the background and deployed as a web service on your machine.

Before you can something interesting in the console, you have to start the consumer too.

Therefore, you have to create also a consumer at the marketplace and transfer the credentials

to the code. The steps are similar to creating a provider. So, it doesn’t make sense to explain

it here again. Just switch back to your web browser and start the same process, now, by click-

ing on “My Consumers”. The credentials have to be inserted in ExampleConsumer.java,

which is below the directory then java-example-consumer.

Now, start the Consumer and see what happens. Enjoy!

3.3. BIG IoT from a Provider's Perspective

Let’s go through the steps of developing the example parking provider. Assuming, you have

developed an IoT platform for parking data. How do you connect your platform to the BIG IoT

Marketplace?

Page 30: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 30

Using the BIG IoT Provider Lib, you can offer your data on the BIG IoT Marketplace via offer-

ings. In order to achieve that, the Provider Lib has the following main functionalities:

Registration of offerings

Activation and deactivation of offerings

Renewing offerings

Providing access callbacks

3.3.1. Creating a Provider Object and Authenticate at the Marketplace

Before you can register your parking sensor data on the marketplace as an offering, you need

to authenticate with the marketplace.

Authentication

String MARKETPLACE_URL = "https://market.big-iot.org";

String PROVIDER_ID = "TestOrganization-DemoProvider";

String PROVIDER_SECRET = "****";

ProviderSpark provider = new ProviderSpark(PROVIDER_ID, MARKETPLACE_URL, "localhost", 9020);

provider.authenticate(PROVIDER_SECRET);

First of all, you create a Provider instance, passing a Provider ID and a Marketplace URL

you want to connect to. In our example, we use a ProviderSpark object, which is an easy

way to create a provider with an embedded Spark webserver. The webserver is started on the

given URL and port, in this case localhost on port 9020. However, you can also use the

standard Provider class, and connect it to an existing webserver (Tomcat, Jetty, etc.). When

creating a provider at the marketplace, you receive a unique ID and a token. You pass this

data to the provider objects authenticate function in order to finish your authentication on

the marketplace. The Provider object will be used for all subsequent interactions with the

marketplace.

3.3.2. Create an Offering

Now, that you are authenticated you can create an offering for your park data. The next code

block shows how you can use the Offering class to do this:

Page 31: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 31

Offering Creation

RegistrableOfferingDescription offeringDescription = provider

.createOfferingDescription("parking_info_offering")

.withInformation( new Information("Parking Information", new RDFType("schema:parking")))

.addInputData("longitude", new RDFType("schema:longitude"), ValueType.NUMBER)

.addInputData("latitude", new RDFType("schema:latitude"), ValueType.NUMBER)

.addOutputData("longitude", new RDFType("schema:longitude"), ValueType.NUMBER)

.addOutputData("latitude", new RDFType("schema:latitude"), ValueType.NUMBER)

.addOutputData("status", new RDFType("datex:parkingSpaceStatus"), ValueType.TEXT)

.inRegion(Region.city("Barcelona"))

.withPrice(Euros.amount(0.001))

.withPricingModel(PricingModel.PER_ACCESS)

.withLicenseType(LicenseType.OPEN_DATA_LICENSE)

// Below is actually Offering specific

.withAccessRequestHandler(accessCallbackParking);

The OfferingDescription class provides a builder method that lets you easily create a new

offering. For your offering to be visible on the marketplace, you have to provide a name for

it. Also it is important to define a type for the offering so that consumers can automatically

find it (see Consumer section). This information is encapsulated in the Information object.

Additionally, you can define input parameters that can be set by your service’s consumers

when accessing your platform. Here, we provide an example how to add a location based

filter as an input element to your offering. You provide the output of your offering through

the addOutputData method which are the parking spot coordinates and the parking spot

status in this example. The consumer of your data will have the possibility to query for data

within a specific area and radius. He will retrieve data that conforms to the schema of the

type http://schema.org/parking.

Both input and output elements use the RDFType class which makes it easy to semantically

annotate your data. This is very important for consumers to find your offerings, so be thought-

ful with your annotations! Providing a region, a price, a license type and an endpoint com-

pletes the offering description. The endpoint defines the access method and URL to your plat-

form. Using the withAccessRequestHandler method, you specify an access callback (see

chapter 3.3.4) that will be called automatically, once a consumer accesses your offering.

Page 32: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 32

3.3.3. Registration of Offerings

Now that you created the offering description, it should be registered on the Marketplace so

that other developers can find it. You will use the register method for that:

Register offering

RegisteredOffering offeringId = offeringDescription.register();

3.3.4. Implementing the Access Callback

Every time someone uses your offering, the BIG IoT Consumer Lib will forward the request to

the provided callback function. We will show a simple example of how such a callback func-

tion implementation could look like:

Callback function

AccessRequestHandler accessCallback = new AccessRequestHandler(){

@Override

public BigIotHttpResponse processRequestHandler{

OfferingDescription offeringDescription, Map<String,Object> inputData) {

double longitude=0, latitude=0;

if (inputData.containsKey("longitude")) {

longitude = new Double((String)inputData.get("longitude"));

}

if (inputData.containsKey("latitude")) {

latitude = new Double((String)inputData.get("latitude"));

}

JSONObject results = new JSONObject()

.put("results",ParkingService.getData(longitude,latitude));

return BigIotHttpResponse.okay()

.withBody(results.toString())

.asJsonType();

}

};

Page 33: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 33

The AccessRequestHandler class is an abstract class that requires you to override the pro-

cessRequestHandler method. This method receives the OfferingDescription object that

we created earlier and the inputData Map which contains the input filters that the consumer

has specified during his access request. If any of the possible filters have been used, we pass

them to a service function that simply retrieves the parking data from our platform's data-

base. However, you could of course implement any service logic here. AccessRequest-

Handler is implemented as a functional interface. If you prefer, you can also provide the ap-

plication logic in the Lambda notation.

If you want to remove your offering from the marketplace, just call the deactivate method

on the offering.

Deactivate offering

offering.deregister();

Congratulations! You have created your first offering on the BIG IoT Marketplace.

3.4. BIG IoT from a Consumer's Perspective

Assuming, you want to create a new parking app for the city of Barcelona that is supposed to

display parking data on a web dashboard for different places in the city. Using the BIG IoT

Consumer Lib, it is very easy to make your service use the BIG IoT Marketplace to query rele-

vant data sources and access them.

The Consumer Lib offers the following main functionalities:

Discovering offerings at the Marketplace according to a search specification

Subscribing to offerings

Accessing offerings in per request or in a continuous fashion

3.4.1. Authentication on a BIG IoT Marketplace

To get started with the Consumer Lib, you have to create an instance of the Consumer class.

The constructor requires your specific consumer ID and a marketplace URI.

Page 34: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 34

To authenticate with the marketplace, you have to use the authenticate method provided by

the consumer object. This method requires the marketplace API key and a consumer certifi-

cate, which you both received when you registered on the BIG IoT Marketplace portal.

Consumer instantiation

Consumer consumer = new Consumer("Barcelona_Parking", "https://market.big-iot.org");

// Authenticate on the marketplace

consumer.authenticate("*****");

If you want to connect to a different marketplace, just repeat the previous steps and create

another Consumer object.

3.4.2. Creating a Query for Offering Descriptions

Now, that you are authenticated at the marketplace, you can search for relevant parking sen-

sor data to feed into your service. To do that, you query the marketplace using the Offer-

ingQuery object. The query gets constructed using a builder pattern which first, creates the

empty OfferingQuery object that is completed with additional query filters, such as a spe-

cific search region, a desired accounting type, a maximum price, etc. The marketplace will

later retrieve all matching offerings for this query. In this example, the query is quite simple

however it can be more complex in other situations.

Offering query

OfferingQuery query = Consumer.createOfferingQuery()

.withInformation(

new Information("Parking Information Query", "http://schema.org/parking"))

.inRegion(Region.city("Barcelona"))

.withPricingModel(PricingModel.PER_ACCESS)

.withMaxPrice(Euros.amount(0.001))

.withLicenseType(LicenseType.OPEN_DATA_LICENSE);

Page 35: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 35

First we create a query. The type of offerings returned should be of type

http://schema.org/parking. The types of offerings, which are available can be evaluated

using the online documentation of the BIG IoT Marketplace. The query is using a region filter

that selects only offerings that are provided in the city of Barcelona. Also the pricing mode

should be based on the number of accesses and not, for example, on a monthly fee. The price

should not exceed 0.1 cents per access and the data license should be the Open Data License.

The Consumer Lib offers you Enum classes that you can consult to see, which other licenses or

accounting types are available.

3.4.3. Querying the Marketplace

To execute the query on the marketplace, the Consumer object provides multiple options.

The dedicated method for this is discover, which has different signatures to take different

programming preferences into account.

Overloading of discover()

CompletableFuture<List<SubscribableOfferingDescription>>

discover(IOfferingQuery query);

void discover(

IOfferingQuery query,

DiscoverResponseHandler onSuccess,

DiscoverResponseErrorHandler onFailure);

void discover(IOfferingQuery query, DiscoverResponseHandler onSuccess);

The first variant uses a CompletableFuture as a return type, which is a promise on a list

of OfferingDescriptions, which is part of the functional programming styles introduced in

Java 8. The other two variants are using callback mechanisms.

The following code shows how to discover offerings getting them as a CompletableFuture

on the list of OfferingDescriptions:

Page 36: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 36

Executing discovery returning a CompletableFuture

CompletableFuture<List<SubscribableOfferingDescription>> listFuture =

consumer.discover(query);

List<SubscribableOfferingDescription> offerings = listFuture.get();

Offering offering = offerings.get(0).subscribe().get();

The discover call is actually non-blocking. So, you could do something in between, e.g. hand-

ing over the CompletableFuture object to your management thread. Or alternatively, you

can directly receive the list by calling the get method. This call is blocking and will wait on the

list of OfferingDescriptions. The motivation of using CompletableFuture here is, that

you can come easily from an asynchronous behavior to a blocking behavior and further you

can utilize reactive concepts if you want. For example by calling thenApply as a monad on

the CompletableFuture object allows you to apply functions once the list of offering descrip-

tions is received.

Chaining functions on discover response

listFuture.thenApply(SubscribableOfferingDescription::showOfferingDescriptions);

Before you can utilize an offering, you have to subscribe on the OfferingDescription ob-

ject. Subscription is done through the correspondent subscribe method which returns an

Offering object. The offering object provides different access methods as described later.

You can also use callbacks for discovering offerings. Here is an example how to achieve that:

Executing Discover with callbacks

query.discover((r,l) -> {

SubscribableOfferingDescription.showOfferingDescriptions(l)

});

Page 37: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 37

The callback function in this example again just prints the returned offering descriptions, how-

ever usually you would provide your offering selection logic here, that selects the appropriate

offerings for your use case. The example again utilizes the functional programming features

introduced in Java 8. With lambdas you can express functionality without much boilerplate

code. Alternatively every other instance of DiscoverResponseHandler is accepted by

discover.

As a side note: Of cause you can reuse your query object for subsequent queries. Only if you

want to change something regarding the filtering you have to create a new

OfferingQuery object.

3.4.4. Using SelectionCriteria

By using the SelectionCriteria class, you can specify a rule which is used by the BIG IoT

Lib to filter offerings. You can define the selection criteria based on you service logic needs,

by creating a new SelectionCriteria instance. To create a new selection, you use the

OfferingSelector class, which accepts an arbitrary amount of SelectionCriteria objects.

In the example below, we discover a list of offerings and apply an OfferingSelector, that

selects based on cheapest offerings that have the most permissive license.

Using OfferingSelector

consumer

.discover(query)

.thenApply((list) -> OfferingSelector

.create()

.cheapest()

.mostPermissive()

.select(list));

3.4.5. Accessing Offerings

Before we describe how to access an offering that was retrieved from the marketplace, it

makes sense that you look at the different access concepts provided. The IOffering inter-

face provides the following signatures for access:

Page 38: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 38

Accessing an Offering

void accessOneTime(AccessParameters parameters,

AccessResponseSuccessHandler onSuccess);

void accessOneTime(AccessParameters parameters,

AccessResponseSuccessHandler onSuccess,

AccessResponseFailureHandler onFailure);

CompletableFuture<AccessResponse> accessOneTime(AccessParameters parameters);

IAccessFeed accessContinuously(AccessParameters parameters,

Duration lifetime,

FeedNotificationSuccessHandler onSuccess,

FeedNotificationFailureHandler onFailure);

To access offerings, we distinguish between two types: one-time access and continuous ac-

cess. One-time means that you execute an access request every time you want to get new

data. Continuous refers to the reception of data as a feed.

For one-time access, the Consumer Lib supports again different programming styles. You can

either use callback functions for pure asynchronous access or you can use a

CompletableFuture to do reactive programming or even having a blocking call. In either

case, you have to provide an AccessParameters object for the access call. In includes the

parameters, which are will be passed to the platform that serves the data. Typically they are

needed to filter the output or configure the access.

Here is an example, how to access the parking offering we retrieved earlier:

Setting parameters

/* Create a hashmap to hold parameters for filtering access*/

AccessParameters accessParameters = AccessParameters.create()

.addRdfTypeValue(new RDFType("schema:longitude"), 12.3)

.addRdfTypeValue(new RDFType("schema:latitude"), 42.73);

/* Execute one time access and print the result */

CompletableFuture<AccessResponse> response = offering.accessOneTime(accessParameters);

response.thenAccept((r) -> dashboard.display(r));

Page 39: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 39

As you can see, accessing an offering can be that simple. We use the one-time access method

and pass the parameters object that restricts the access to the specified longitude and lat-

itude coordinates. Since we use accessOneTime returning a CompletableFuture, we can

apply a function on the result. Here we forward the result to the example dashboard’s display

method, which shows the received data on a web dashboard. Note that the response object

is of the type JsonNode, which already includes the parsed response message and provides

functionality for traversing the response.

3.4.6. Continuous Access of Offerings

Since we want to show the returned parking data in real time on our dashboard, it would be

even nicer if we could access the parking data continuously.

Here we describe how this can be done:

Access data continuously

AccessFeed accessFeed = offering

.accessContinuous(

accessParameters,

Duration.standardSeconds(60),

(o,r)->System.out.println("feed result = "+r),

(o,r)->System.out.println("Ups, something failed"));

You notice that the procedure is very similar to the access on a per request base. We use

the accessContinuously method of the OfferingQuery object which requires the

accessParameters object, a duration, a success callback and a failure callback in case some-

thing went wrong. The difference is that when calling accessCalling() we create a feed,

which requires a lifecycle management. The accessFeed object brings functionality for stop-

ping (stop), resuming (resume) and getting the status of a feed subscription (status), which

we don’t want to use now.

If you want to stop accessing an offering, you can unsubscribe accordingly.

Page 40: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 40

Unsubscribing from an offering and terminating consumer

offering.unsubscribe();

consumer.terminate();

Make sure to always call the terminate method of the consumer object before stopping your

application in order to terminate any open network connections.

That's it! You have just learned how to use the BIG IoT Library as a data provider as well as a

data consumer.

3.4.7. More BIG IoT Lib Functionality

Complex types – Provider perspective

In this section, we want to describe an example of complex types. Complex types are used,

so that providers can semantically describe complex datatypes that can contain nested struc-

tures. This was not possible in the earlier version of the BIG IoT SDK.

Creating an offering with complex types

RegistrableOfferingDescription offeringDescription = provider

.createOfferingDescription("parkingSpotFinder")

.withInformation( new Information ("Complex Parking", new RDFType("bigiot:Parking")))

.addInputData("areaSpecification", new RDFType("schema:GeoCircle"),

IOData.createMembers()

.addInputData ("geoCoordinates", new RDFType("schema:geoCoordinates"),

IOData.createMembers()

.addInputData("longitude", new RDFType("schema:longitude"), ValueType.NUMBER)

.addInputData("latitude", new RDFType("schema:latitude"), ValueType.NUMBER))

.addInputData("radius", new RDFType("schema:geoRadius"), ValueType.NUMBER))

.addOutputData("geoCoordinates", new RDFType("schema:geoCoordinates"),

IOData.createMembers()

.addOutputData("longitude", new RDFType("schema:longitude"), ValueType.NUMBER)

.addOutputData("latitude", new RDFType("schema:latitude"), ValueType.NUMBER))

.addOutputData("status", new RDFType("datex:parkingSpaceStatus"), ValueType.TEXT)

.inRegion(Region.city("Barcelona"))

.withPrice(Euros.amount(0.001))

Page 41: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 41

.withPricingModel(PricingModel.PER_ACCESS)

.withLicenseType(LicenseType.OPEN_DATA_LICENSE)

//Below is actually Offering specific

.withAccessRequestHandler(accessCallback);

Let’s expand our previous example with a more complex parking offering. We want to

register a parking information offering on the marketplace with the complex type

areaSpecification, which is described as the semantic RDF type schema:GeoCircle. It

consists of the two nested types: geoCoordinates as well as geoRadius.

We also add the complex type geoCoordinates to the list of output parameters.

Complex types – Consumer perspective

Now that we’ve added complex types to our provider’s offering, we want to add complex type

support to our consumer. In order to do that we make use of complex access parameters. As

you can see in the following example, this is quite similar to the way, we use complex types

in offering descriptions. We use the AccessParameters.create method in order to create

the access parameter for the areaSpecification.

Creating complex access parameters

AccessParameters accessParameters = AccessParameters

.create()

.addNameValue("areaSpecification", AccessParameters

.create()

.addNameValue("geoCoordinates", AccessParameters

.create()

.addNameValue("latitude", 50.22)

.addNameValue("longitude", 8.11))

.addNameValue("radius", 777));

After we retrieved the data, we want to map it automatically to a POJO so that we do not

have to manually parse the response.

Page 42: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 42

Automated mapping to POJO

The following example will show you, how you can access offerings and let the BIG IoT Lib

automatically match the output parameters to your POJO.

Accessing offerings with automatic POJO mapping

CompletableFuture<AccessResponse> response = offering.accessOneTime(accessParameters);

//Mapping the response automatically to your POJO

List<ParkingResultAnnotated> parkingResult = response.get()

.map(ParkingResultAnnotated.class);

For the access request, you use the map method, which accepts an annotated POJO class. The

lib will now map the response data from the parking provider to the POJO

ParkingResultAnnotated.

Accessing offerings with annotated POJO

public class ParkingResultAnnotated {

public static class Coordinate {

public double latitude;

public double longitude;

}

@ResponseMappingType("schema:geoCoordinates")

public MyParkingResultPojoAnnotated.Coordinate coordinate;

@ResponseMappingType("datex:distanceFromParkingSpace")

public double distance;

@ResponseMappingType("datex:parkingSpaceStatus")

public String status;

}

Page 43: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 43

In order to map semantic types to your POJO’s types, you can use the ResponseMappingType

class, which is parameterized with the semantic type you want to map. In this case, we would

map the complex type geoCoordinates from the Complex Parking Offering to the

Coordinate class.

Another option, instead of using an automated mapping approach is, to not use an annotated

POJO but instead do the mapping manually. You can see how this works in the next example

(note that we use the un-annotated version of the ParkingResult).

Manually mapping a POJO to access response

CompletableFuture<AccessResponse> response = offering.accessOneTime(accessParameters);

List parkingResult = response.get()

.map(ParkingResult.class, OutputMapping

.create()

.addTypeMapping("schema:geoCoordinates", "coordinate")

.addTypeMapping("datex:distanceFromParkingSpace", "distance")

.addTypeMapping("datex:parkingSpaceStatus", "status"));

To provide the mapping manually, you use the addTypeMapping method, for each semantic

type from the provider’s output data elements so that the lib can match it to your POJO.

A third option is, to provide your own mapping which means to cherry-pick the required fields

from the access response. In the example, we map latitude from the complex type

geoCoordinates to the field coordinate of the POJO. Also, we map the field distance to

the POJO field meters.

Mapping using cherry-picking

CompletableFuture<AccessResponse> response = offering.accessOneTime(accessParameters);

List parkingResult = response.get()

.map(AlternativeParkingPojo.class, OutputMapping

.create()

.addNameMapping("geoCoordinates.latitude", "coordinates.latitude")

.addNameMapping("geoCoordinates.longitude","coordinates.longitude")

.addNameMapping("distance", "meters"));

Page 44: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 44

Using integration mode 3

Up till now, we have only considered that you run a BIG IoT Gateway Service, where you pro-

vide the callback code to access your IoT platforms. But what if you cannot start additional

services in your environment? In this example, you learn how to register and access offerings

that uses the BIG IoT integration mode 3, which is enables a completely Consumer Lib driven

access to your IoT platform. To learn more about integration mode 3, please refer

to section 4.4.

Suppose, we want to add air quality information to our dashboard application and we want

to integrate the public available Web API OpenAQ (https://openaq.org). In order to integrate

the platform using integration mode 3, first register your offering:

Registering an offering for integration mode 3

RegistrableOfferingDescription airQualityOffering = provider

.createOfferingDescription("Open_AQ_AirQualityOffering")

.withInformation(new Information("OpenAQ_AirQuality", "bigiot:AirQuality"))

.inRegion(Region.city("Berlin"))

.withPrice(Euros.amount(0.01))

.withPricingModel(PricingModel.PER_ACCESS)

.withLicenseType(LicenseType.OPEN_DATA_LICENSE)

// The following properties are different to other integration modes

.addInputDataInQuery("coordinates", new RDFType("schema:location"), ValueType.TEXT)

.addInputDataInQuery("radius", new RDFType("schema:geoRadius"), ValueType.TEXT)

.addInputDataInQuery("from", new RDFType("schema:date"), ValueType.TEXT)

.addInputDataInQuery("limit", new RDFType("schema:value"), ValueType.NUMBER)

.asHttpGet()

.acceptsJson()

.producesJson()

.onExternalEndpoint("https://api.openaq.org/v1/measurements");

The BIG IoT Lib supports different ways, how to transmit input parameters when calling a

service function of a Web API: parameters can be encoded in the query

(...?param1=…&param2=…), in the path (…/paramValue1/paramValue2), in the message body

e.g. as JSON or a combination of all three. In this example, the parameters are added as query

parameters in the URL (addInputDataInQuery). But you can also try: addInputDataInPath,

addInputDataInBody. If your offering requires complex parameter encoding, maybe even

with many static parts, you can check out also addInputDataInTemplate.

Page 45: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 45

The same add methods for input parameters exist, of cause, also for output parameters.

Now, we specify that we access the API through an HTTP GET request, using the asHttpGet

method, followed by a specification of what content types shall be used. The endpoint of the

API is added to the registration in the last step. Note, that the method onExternalEndpoint

is specifically provided by the BIG IoT Lib for integration mode 3.

Now, everyone on the marketplace can use OpenAQ through BIG IoT, including our dashboard

application. Our consumer application can retrieve the data through BIG IoT access (section

3.4.5). Here is an example for the OpenAQ provider:

Setting parameters for integration mode 3

/* Create a hashmap to hold parameters for filtering access*/

AccessParameters accessParameters = AccessParameters.create()

.addNameValue("coordinates", location)

.addNameValue("radius", "2500")

.addNameValue("from", "2017-08-25")

.addNameValue("limit", "10000");

/* Execute one time access and print the result */

CompletableFuture<AccessResponse> response = offering

.accessOneTime(accessParameters);

response.thenAccept((r) -> dashboard.displayAirQuality(r));

Using Proxy support

If you access the Internet through a proxy, for example because you are in a corporate envi-

ronment, you can use the BIG IoT Lib’s proxy support, you can use the setProxy method to

set the host address and the port of your proxy server. If you want to add a host to your proxy

exception list, use addProxyBypass and use removeProxyBypass for removal. If you need to

authenticate the methods.

Page 46: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 46

Using BIG IoT Lib Proxy

ProviderSpark provider =

new ProviderSpark(PROVIDER_ID, MARKETPLACE_URI, "localhost", 9002);

provider.setProxy("127.0.0.1", 3128);

provider.addProxyBypass("172.17.17.100");

Using Swagger support to describe offerings

Another feature of the BIG IoT Lib allows you to automatically evaluate your offering with

Swagger UI. This is useful, for example when you implement a consumer and you want to try

different calls. Just add the following line to your provider setup code:

Evaluate your Offering via Swagger UI

SwaggerGenerator.deploySwaggerFileFrom(offeringDescription, "[email protected]");

Make sure you have added the correct dependencies to your gradle or maven file (group:

'org.bigiot.lib', name: 'bigiot-lib-swagger', version: '0.9.3').

The lib automatically configures a Spark webserver hosting a dynamic web page with Swagger

UI preconfigured with your offering.

Console output when deploying Swagger UI

22:19:18.557 INFO o.e.b.l.s.SwaggerGenerator - Writing swagger file to www/bigiot/providerAPI.json

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

Explore your Offering via Swagger UI on https://localhost:9002/bigiot/swagger-ui/index.html

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

Page 47: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 47

4. BIG IoT API Mechanisms

The BIG IoT API is provided as a software library (BIG IoT Lib), which comes as a Consumer

and as a Provider Lib. It is the main tool for consumers and providers to interact in the BIG IoT

ecosystem. The data flows always directly between them. The marketplace plays only a cen-

tral role in bringing both sides together. The motivation for a software library, in contrast to

a Web API, is that a software library allows additional functionality, which cannot easily be

realized by a pure web API. For example, the Consumer Lib shall also support accounting of

the data access. Further, the Consumer Lib provides data transformation functionality. De-

pending on the integration mode, the degree of transformation capabilities increases.

During chapter 3 covers how the BIG IoT API is used with the programming interface, this

chapter is about the underlying mechanisms, which are used for the communication between

the BIG IoT Lib instances. Therefore a Web API is internally be used, which is completely trans-

parent for developers.

The mechanisms of the BIG IoT API differ depending of the integration mode (Figure 3) of the

offering. The integration modes 1, 2 and 4 foresee a provider side BIG IoT enablement by

providing the A1 interface. Integration mode 3 foresees the direct access of the consumer to

the original IoT platform without modifications.

Section 4.1 explain the different operations (e.g. access), which can be applied through an

offering and which are applicable for all integration modes. Section 4.2 to 4.5 explain the BIG

IoT API aspects with respect to the different integration modes.

The Web API of the marketplace, which is used by BIG IoT Libs are addressed in deliverable

D4.1. Security aspects, such as the authentication at the marketplace, are addressed in deliv-

erable D3.3.

4.1. Operations of BIG IoT Offerings

A BIG IoT Offering can be understood as an element to abstract from the underlying mecha-

nisms of the resources offered by an IoT Platform. We introduce operations on BIG IoT Offer-

ings in order to cover the different operations on an offering. These operations are access,

feed, event and task. An offering can support one or multiple of those operations. The oper-

ation “access” addresses the sporadic retrieval of information, which is typical e.g. for reading

sensor values on a request/response basis. The operation “feed” enables the continuous re-

trieval of information. This is different to the “access” operation as the continuous data access

requires lifecycle management of the feed subscription. The operation “event” is the retrieval

Page 48: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 48

of information according to a ruleset. Data is only received if certain conditions apply. These

could be for example getting a notification if a threshold is exceeded or if spatial data is emit-

ted for a specific area. “Event” can be seen as an extension to the “feed” operation. In con-

trast to these information retrieval centric operations, the operation “task” covers the send-

ing of information towards the platform. This is required if an action or state change shall be

executed. Examples for this are switching-on a light, configuring the sensitivity level of a noise

sensor, moving a camera to a specific direction.

Since the BIG IoT ecosystem is flexible regarding the offering description, it is legal to specify

offerings supporting just one operation or even multiple operations. It is up to the platform

operator how to tailor optimally his platform functionality into BIG IoT Offerings.

The operations “access” and “feed” are described in Sections 4.3.2 and 4.3.4. “Event” and

“task” will be addressed in future deliverables.

4.2. API mechanisms for Integration Mode 1

The integration mode 1 is for provider who are willing to natively support the A1 interface on

their platform. Since the mechanism from the BIG IoT API perspective are similar to integra-

tion mode 2, it is not further discussed here.

4.3. API mechanisms for Integration Mode 2

In integration mode 2 the BIG IoT enablement of an IoT platform foresees the communication

of the BIG IoT Consumer Lib with a Provider Lib, which is used by a gateway service in the

environment of the provider. A data access of the consumer will be accepted by the gateway

service logic, which proxies the call to a call to the IoT platform. The application logic for that

callback is implemented by the provider.

Figure 17 shows the typical workflow for an offering in integration mode 2. In step 1, the

provider registers the Offering at the marketplace by using either a programmatic approach

with the Provider Lib or alternatively by using the web-page-based marketplace. The offering

Description includes all necessary information about an Offering for finding and accessing it.

Step 2 is initiated by the consumer for the discovery of offerings with a search query. A dis-

covery could return multiple offering descriptions.

The access to an offering happens in step 3 via A1 interface. The offering individual callback

implementation in the gateway service accepts this call and executes it in step 4 with the

correct syntax and semantics to the IoT platform.

Page 49: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 49

Figure 17 Typical workflow in integration mode 2

Running an offering in integration mode 2 puts constraints on the deployment of the gate-

way service. Figure 18 gives a typical deployment example.

Page 50: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 50

Figure 18 Deployment example

The platform "My Platform" is integrated into BIG IoT via integration mode 2. It has two of-

ferings (OfferingA and OfferingB). In integration mode 2 offerings are accessed via A1 inter-

face. The platform operator decided to run the BIG IoT Gateway Service as a web service

which has the URL http://bigiot.myplatform.com on port 80 (TCP/IP perspective). The two

offerings are modeled as resources following a REST concept (HTTP perspective). Accordingly,

the URLs are included in the platform's offering description as described in D3.2 (e.g.

endpoints=[{uri=http://bigiot.platform.com/offeringA}]). The sequence of inter-

action is depicted in Figure 19.

Page 51: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 51

Figure 19 Sequence diagram for offering access in integration mode 2

Page 52: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 52

Keep in mind: hosting the gateway service under http://bigiot.myplatform.com is only

an example for a deployment. The gateway service could be also a resource under

http://data.platform.com (e.g. http://data.platform.com/bigiot). The offering on

the IoT platform is accessed via the BIG IoT Gateway Service. The gateway service routes the

call to the respective internal service logic, which forwards the call with the correct syntax

and semantics to the IoT platform. The transformation rules are provided by the IoT platform

operator e.g. via implementing a delegate. Typically, there could be different operations avail-

able for an offering (access, feed, task, event). The operations are represented by different

end points in the offering description (as described in D3.2).

As seen in the example, it is possible to manage multiple offerings with one deployment of

the BIG IoT Gateway Service, but this implies also that the endpoint URI of the managed of-

ferings have to lie in his domain/resource tree. This has direct implications for the definition

of a correct offering description. The endpoint URIs have to fit:

http://bigiot.myplatform.com/offeringA and

http://bigiot.myplatform.com/myFavoriteOffering/somewhere/down/here

are working

http://bigiot.myplatform.com/offeringA and

http://coolOffering.com/hereIsIt is not working, you need two running

instances of the Gateway Service (assuming that both endpoints have different IP

addresses)

Note: The URI is actually an URL, which locates the offering in the Web. In order to

interact with the offering an operation has to be located as well. Such an operation

could be accessing of data in a request/response manner (operation “access”), subscribing

to data as a feed (operation “feed”) or executing a task on the offering (operation “task”).

These operations are modeled as resources below the URI of the offering (e.g.

http://bigiot.myplatform.com/offeringa/access).

The example shows also that the A1 interface is always REST-ified, which means it requires

that it is hosted on a web server, which acts as an application server (e.g. Apache Tomcat or

Jetty). The motivation behind this is, that with integration mode 1, 2, 4 the legacy platform

interface is hidden by a standardized interface.

Page 53: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 53

4.3.1. Blocking and Non-Blocking Operations

The A1 interface includes blocking as well as non-blocking calling patterns. Depending on the

operation the call either is blocking, non-blocking.

Blocking means that the response of the web service to A1 is blocked until the result of the

operation is available. This is a typical pattern for accessing data via A1-ACCESS interface, as

it is assumed that the data can be quickly read out of a database.

Figure 20 Blocking call

However, operations can also be long lasting, as e.g. the calculation of a route. In this case

the consumer doesn't want to hold the connection open until the result is available. This

means that there can be multiple calls on the A1-ACCESS interface to complete an operation.

The first call to the A1-ACCESS interface starts the operation. The response message includes,

instead of the expected result, a reference with which on following calls the status or respec-

tively the result of the completed operation can be retrieved. Other utilization examples for

the non-blocking access pattern are creating and managing data feeds (A1-FEED), or execut-

ing a remote task (A1-TASK).

Page 54: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 54

Figure 21 Non-blocking call

4.3.2. Access Operation

The access of data provided by IoT platforms is an important function block of the BIG IoT API.

Sensor data as well as aggregated data is made available based on offerings. The supported

access modes comprise the data access on a per-request base where the consumer requests

data every time he needs it as well as the continuous access to a data feed. The continuous

access requires a lifecycle management for creation and termination of the data feed, which

is addressed in section 4.3.4. The input parameters for both modes are determined by the

offering description. It is intended that the same offering can allow the access per-request as

well as continuously.

The utilization of the data access from a consumer perspective is performed per programming

interface, which is described in section 3.4. The underlying communication mechanisms be-

tween the endpoints are described in this section.

Page 55: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 55

Except for integration mode 3 the data communication is between deployed BIG IoT Libraries

on the consumer respectively the provider’s side. Therefore, the A1-ACCESS web API is spec-

ified, which is offered by the BIG IoT Provider Lib. The underlying application logic performs

the translation of the semantics of the interface call to the native interface of the provider.

Therefore, the programming interface P2 is used.

4.3.3. Specification

The A1-ACCESS interface is offered by the BIG IoT Provider Lib. It is an internal interface,

which is only used by BIG IoT Libs. Depending on the integration mode, the BIG IoT Lib runs

inside the BIG IoT Gateway Service or is natively integrated in the so called BIG IoT enabled

platform. In integration mode 4 it runs inside the BIG IoT Proxy Service. The web service call

syntax and semantics are the same for all of those modes where the A1-ACCESS

interface is used.

The specification of A1-ACCESS with all necessary parameters is shown in Table 2.

HTTP/HTTPS GET

<offeringDescription.endpoints[ACCESS].uri>

Field Type Location Description

Request

token String header API token authorizes the request

diverse input parameters (e.g. objectId)

diverse query Input parameters as specified in offering descrip-tion as query parameters

Response

JSON body Result of access operation

Table 2 A1-ACCESS specification

The security token authorizes the user. It is located in the header of the HTTP request.

The data access is implemented as a HTTP GET command on a URL with the URL scheme

http[s]://<host address>[:<port>]/<route to gateway service>/access. A typical

URL could be https://myplatform.com/bigiot/parking/access. The exact URL is speci-

fied in the offering description.

Page 56: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 56

If only simple input parameters are specified for the offering, input parameters

are encoded as query parameters. For example, a request call could go on

https://myplatform.com/bigiot/parking?lat= 48.54&lng=11.38&range=500

In case complex parameters are specified for an offering, the parameters are encoded as a

JSON string. For example

{ "coordinate": { "lat":48.54, "lng":11.38 }, "range":500

}

The JSON string is in turn encoded again in order to meet URL conformance. The result is

assigned to the query parameter _jep. The call would be

https://myplatform.com/bigiot/parking?_jep=%7B%22coordinate%22%3A%7B%22lat

%22%3A48.54%2C%20%22lng%22%3A11.38%7D%2C%22range%22%3A500%7D

However, due to the de-facto maximal length of a URL of about 2000 character [14] - [17], it

cannot be guaranteed that a GET call is successful with JSON encodings as query parameters.

In that case the request shall be a HTTP Post with the encoded parameters included in the

message body.

4.3.4. Feed Operation

As mentioned in section 4.3.2, the access on data can be in a continuous fashion. Typically,

such a pattern is referenced as a data stream or data feed. In the following, the term “feed”

is used. The BIG IoT API enables the lifecycle management for data feeds with the A1-FEED

interface. The utilization of feeds by the consumer is performed by the P2 interface. This is

addressed in the tutorials section of the deliverable.

The typical data access pattern is that a consumer sends a retrieval request to the data plat-

form and gets the data immediately in return as response. However, depending on the appli-

cation scenario and the nature of the data source, the consumer wants to retrieve forthcom-

ing data on a regular time basis or on availability.

Page 57: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 57

4.3.5. Synchronous vs. asynchronous feeds

Data feeds can be either synchronous or asynchronous. The difference between both types is

that with synchronous feeds the data is transmitted to the consumer in a regular time interval

independently of the timely behavior of the emitting of new values on the data source. In

contrast, asynchronous feeds foresee transmissions to the consumer whenever new data is

emitted or the data producer decides to update its feed subscribers.

Typically, synchronous feeds are good if the update rate of the data source is high and the

application requires a lower data renewal frequency, e.g. because a data gauge in the UI has

to be updated with a new value. As the timing behavior is deterministic here, the update can

be realized by periodic data polls initiated by the consumer. Synchronous data streams have

their benefits when server initiated data communication towards the consumer is not possi-

ble. If there are security restrictions or the data consumer is behind a NAT then synchronous

feeds are often the only option for continuous data streams. However, in any case there is a

tradeoff between timeliness of the reception and bandwidth utilization. This is cumbersome

if an application requires fast responses without having sufficient bandwidth resources.

Asynchronous data feeds are beneficial if the data emitting at the provider has an irregular

event character or in turn, the notification of the feed subscriber shall be immediate (no wait-

ing until the next synchronized update is due). As it is not predictable when new data is avail-

able, new data is transmitted here to the client when it is emitted. It is optimal in terms of

bandwidth utilization and real time support. However, for asynchronous feeding the producer

must be able to initiate a transmission towards the consumer. This is not always possible e.g.

because the consumer has no open port to send the data to or no persistent connections are

available. Firewall rules might also complicate asynchronous feeds.

Page 58: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 58

Figure 22 shows the different aspects of synchronous and asynchronous feeds.

Figure 22 Synchronous and asynchronous feeds

4.3.6. Feed support in BIG IoT

The BIG IoT API defines different options for asynchronous as well as for synchronous feeds.

Which ones are available for a consumer of an offering depends on restrictions on the pro-

vider as well as on the consumer side. During the timing of data transmissions is always in the

control of the provider side with asynchronous feeds, synchronous feeds can be also realized

by explicit data polls by the consumer. The latter case is the only option if feed mechanisms

are not available for an offering/provider. Synchronous polling is addressed in section 4.3.7.

Page 59: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 59

Arriving feed data at the BIG IoT Consumer Lib is handed over to the consumer code via the

callback method defined by the P2-FEED interface. In integration mode 3, transformation

code has to be available in order to transform the incoming data format in the respective

return format for the programming Interface.

Figure 23 Feeds in integration modes 1 and 3

Data is transmitted to the feed subscriber when it arrives at the platform or when the plat-

form decides to send it. This can be in a synchronous as well as in an asynchronous manner.

Many platforms support natively such a data transmission pattern, for example per MQTT via

WebSockets. In integration mode 3 BIG IoT relies on the platform original feed mechanism (if

available) for data transport (see Figure 23) or introduces (integration mode 2) an own feed

data mechanism between Provider Lib and Consumer Lib, which transport the feed data. The

original mechanism would be then used between BIG IoT Provider Lib in the Gateway Service

and the legacy IoT platform (see Figure 24). The benefit of the first method is that no repack-

ing of feed data is necessary. The second method allows more control of the feed mechanism

by the consumer. For example, in order to circumvent networking restrictions e.g. by using a

mandatory HTTP proxy.

Figure 24 Feeds in integration modes 2

Other options regarding retrofitting an offering or provider not supporting asynchronous or

no feeds at all are described in section 4.3.7.

Page 60: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 60

4.3.7. Concepts for retrofitting Feed support

Not all data offerings come with direct native feed support by the legacy platforms. In order

to enable use cases for these offerings building on top of continuous data access, we intro-

duce a concept to retrofit feed support by moving feed functionality inside the BIG IoT Libs.

One approach is to enable synchronous feeds per repeated polling of the A1-ACCESS interface

by the Consumer Lib. The other concept is to retrofit asynchronous feeds by repeated polling

of the legacy interface by the Provider Lib running in integration mode 2.

Retrofitting synchronous Feeds

Synchronous feeds do not necessarily require native support by the data producer. Since the

data transmission interval is fixed here, the control of the data transmission can be on the

side of the consumer. That's why synchronous feed support can always be achieved by the

BIG IoT Consumer Lib (see Figure 25). The feed functionality is achieved by repeated access

of the platforms A1-ACCESS interface according to a consumer specific time interval. An op-

tion could be to select whether all new values are polled or just the latest.

Figure 25 Retrofitting synchronous feeds

Page 61: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 61

Retrofitting asynchronous Feed support

Actually asynchronous feeds need support from the data provider side. If this is not foreseen,

it can be partly enabled by functionality on the provider side (see Figure 26).

If a platform doesn't provide native feed support out-of-the-box, a kind of asynchronous feed

can be enabled by the BIG IoT Provider Lib. The mechanism is as follows: The callback function

inside the BIG IoT Provider Lib polls for new data regularly in a high interval. If polled values

change they are transmitted asynchronously to the feed subscribers, e.g. by using a Web-

Socket connection. Although this is also a kind of a synchronous feed, it takes place on the

premises of the provider, which means that bandwidth resources are sufficiently high and the

polling interval is optimal for the data source. For consumers this realization pattern is trans-

parent.

Figure 26 Retrofitting asynchronous feeds

4.3.8. Lifecycle Management

The creation and termination of feeds is a side action, which is necessary when enabling con-

tinuous access. A1-FEED introduces a web API for feed lifecycle management in all integration

modes where the Provider Lib is required. In turn the P2 interface provides programming

functions for lifecycle management for the consumer in all integration modes. It provides

mechanisms for lifecycle operations like “subscribe”, “unsubscribe” and feed “status” infor-

mation retrieval. It is used for all kinds of underlying mechanisms realizing the transport of

the feed data. The handling is always the same, independently of the integration mode or

whether the feed is realized synchronously or asynchronously.

The specification for a feed interface tries to be as much transparent to the consumer as pos-

sible in order to hide underlying mechanisms. However due to different constraints of provid-

ing feed functionality the consumer has to be involved in the setup of a feed subscription. E.g.

Page 62: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 62

he has to decide when to start and when to end the transmissions by a subscription or re-

spectively an unsubscription. If it applies it is also important for the feed data provider to

know when to stop sending.

The feed mechanisms of the legacy IoT platforms are masked thru BIG IoT. The Big IoT Lib

terminates existing feed mechanisms. The handover of feed data to the consumer's business

logic happens inside the callback method of the BIG IoT Consumer. The callback method is an

offering dependent implementation similar to the callback methods used for the access in-

terface. The callback method implements the P2 programming interface provided by the BIG

IoT Consumer Lib.

Table 3 includes the required parameters for the A1-FEED interface. It is agnostic to the con-

crete interface protocol binding. Lifecycle management requires different parameter sets for

each phase, A1-FEED has a selector parameter for subscription, unsubscription, status. The

implementation of the interface has to switch between the lifecycle phase accordingly with

e.g. with a parameter selector.

Direction Field Type Required Description

SELECTOR "subscription"

Request offeringId String yes Identifies a specific offering on a provider. This of-feringId could be the reference to a dedicated data feed or to a normal data access offering. In the latter case the feed mechanism is synchronous

token String no Credentials (e.g. an API key token) authorizing the requesting client

lifetime Integer yes Time duration (e.g. seconds) defining the lifetime of the subscription

The following parameters are equivalent to A1-ACCESS. Not every feed offering might allow further par-ametrization.

diverse input param-eters (e.g. objectId)

diverse query Input parameters as specified in offering descrip-tion as query parameters

Response successCode String yes Status of the operation

subscriptionId String yes Reference to subscription

Page 63: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 63

expirationDate Date yes Expiration date in ISO 8601 (e.g. 2016-10-19T11:25:59+02:00)

feedEndpoint URL yes Feed endpoint e.g. the URL for a WebSocket

SELECTOR "unsubscription"

Request subscriptionId String yes Reference to subscription

Response successCode String yes Status of the operation

SELECTOR "list"

Request verbose Bool-ean

yes Enables verbose subscription listing

Response successCode String yes Status of the operation

array of

subscriptionId String yes Reference to subscription

expirationDate Date no Expiration date in ISO 8601 (e.g. 2016-10-19T11:25:59+02:00)

type String no Type of the feed mechanism. Can be

sync for synchronous feeds

async for asynchronous feeds

external for the utilization of an external mes-saging system, as iOS (push) notification

offeringDescription JSON no Offering description serialized in JSON

Table 3 A1-FEED specification

4.4. API mechanisms for Integration Mode 3

Integration mode 3 allows IoT platform operators, for which IM 1 is no option, to provide

access to their offerings via BIG IoT without running a gateway service.

In integration mode 3, the Consumer Lib directly accesses data on the IoT platform. The typi-

cal workflow is depicted in Figure 27, which consists similarly to all other integration modes

of the sequence out of registration, discovery and access.

Page 64: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 64

Figure 27 Typical workflow in integration mode 3

The main challenge of integration mode 3 is to translate a standardized interface (the pro-

gramming interface P2) to an arbitrary interface of the IoT Platform. This means that the un-

derlying mechanisms of call the IoT platform has to be transparent for the consumer. So that

he or she can use its programming interface to the BIG Consumer Lib in the usual manner.

Therefore, integration mode 3 requires more information about the call syntax and semantics

conveyed to the consumer than in the other modes. Especially aspects different to the A1

interface, which is a BIG-IoT wide standardized REST-like web API, has to be included in the

Offering description. All other integration modes leave the adaption to the IoT platform open

to the provider.

The current implementation of the BIG IoT API supports integration mode 3. However, due to

the nearly unlimited variations of web APIs for a IoT platform, only a limited set of classes of

web APIs for IoT platforms are supported.

Table 4 gives an overview about the degree of complexity for integration mode 3 support and

marks with green color the supported and with blue color the conceptually supported char-

acteristics of IoT platform APIs.

Page 65: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 65

Level Supported Characteristic

for IoT Platform APIs

by

Format

by

Code

Level 0

API is equiva-

lent to A1 in-

terface

Has to be HTTP GET with parameters encoded as query

parameters in URL

yes yes

HTTP or HTTPS yes yes

Level 1

API is REST-

like

Arbitrary HTTP commands (PUT, POST or DELETE) yes yes

Arbitrary parameter encodings

in Path: http://myplatform.com/offering/param1/param2

in query: http://myplatform.com/offering?param1=..&param2=..

in body: {"param1":...,"param2":...}

yes yes

Body parameters with a complex structures

Especially APIs using XML-based encodings (e.g. SOAP, OGC) require

complex data structures, often with mandatory elements

(namespaces, API version tags, etc.), which are static for each call. A

precise modelling via offering parameters (i.e. via addInputData()) is

not always not possible. In order to support those APIs, a template

based approach is used.

Consider the following bulky exemplary body

<GetObservation service="SOS" version="2.0.0" xmlns="http://www.[snip]">

<procedure>http://www.52north.org/test/procedure/15</procedure>

<spatialFilter>

<ns:BCIRCLE xmlns:ns="http://www.opengis.net/fes/2.0">

<ns:ValueReference>http://www.opengis.net/[snip]</ns:ValueReference>

<ns1:Envelope srsName="http://www.ope[snip]" xmlns:ns1="http:[snip]">

<ns1:center>48.09423 11.64276</ns1:center>

<ns1:range>1000</ns1:center>

</ns1:Envelope>

</ns:BCIRCLE>

</spatialFilter>

</GetObservation>

yes yes

Arbitrary Content Type in Body and/or Response

For example:

Body of HTTP POST is application/json

Body of response is application/xml

yes yes

Arbitrary web protocols (MQTT, AMPQ, WebSocket etc.) yes yes

Page 66: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 66

Level 2

API requires

conversion of

representa-

tions

Convert data presentations

For example:

Time: 2017-09-15T14:27Z (ISO8601) to “15.9.2017 16:27” or Unix time

Decimal Mark and thousands separator: 1,234.56 to 1.234,56

Numeral System: 4780610 to 0xBABE16 to 10111010101111102

Convert physical unit with simple mapping

For example:

Celsius Fahrenheit, Kelvin

Meters Kilometers, yards, inches

Seconds Milliseconds

yes yes

Convert complex data structures

For example:

The BIG IoT offering is modelled with a search range as input

{

"latitude" : 48.09037,

"longitude" : 11.64685,

"radius" : 500

}

However, IoT platform accepts a square for spatial queries

{

"southEast": {

"coordinate": {

"latitude": 48.08325,

"longitude": 11.63455

},

"northWest": {

"coordinate": {

"latitude": 48.09749,

"longitude": 11.65915

}

}

}

Level 3 Complex offering usage patterns, where one access call is

mapped multiple depending calls on IoT platform API

step 1: HTTP GET platform.com/whichSensorIsOnDuty "sensor42!"

step 2: HTTP GET platform.com/temperature/sensor42 17.5°C

no yes

Page 67: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 67

Complex

transfor-

mations re-

quired

The structure of the request message depends on the in-

put parameters

no yes

Table 4 API characteristics relevant for integration mode 3

The table assigns a numerical level to the API characteristics, which are relevant for integra-

tion mode 3. It is assumed that IoT platforms whose API characteristics are according to level

0 are equivalent to the A1 interface with respect to call syntax and semantics.

For level 2 APIs, it is assumed that they are on a request/response basis and that there exists

a one to one mapping of the data encodings.

Level 2 require a modification in input and response parameters. For example because other

data formats or physical units are used in the API of the IoT platform. The replacement is also

on a one to one basis. This means there is an injective function mapping the input parameters

received from the Consumer to the input parameter of the IoT platform. The same applies to

response parameters.

IoT Platforms with level 3 APIs are the most complex IoT platforms. The transformation from

the Consumer Lib’s programming interface to the API requires a complex description lan-

guage similar to a programming language.

Independently of the feasibility to map the programming intake to IoT Platform API, the au-

thorization of BIG IoT Consumer has to be ensured. This is to a lesser extent a mapping prob-

lem but more a conceptual problem, where different approaches could be driven. For exam-

ple OAuth as an open protocol for the delegation of API authorization could be used.

4.5. API mechanisms for Integration Mode 4

In integration mode 4, the BIG IoT API is implemented by the provider on a constrained IoT

platform, usually a device-level platform. Because of the characteristics of the constrained

devices (limited resources, not always reachable), these device-level IoT platforms are inte-

grated into the BIG IoT ecosystem by means of a BIG IoT Proxy Service.

The BIG IoT Proxy Service acts as an "always-available" proxy on behalf of a constrained BIG

IoT platform. The proxy stores and offers information that are provided by the constrained

Page 68: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 68

platform and is able to queue access requests (e.g. tasks) to functions offered by the con-

strained platform until the platforms wakes up or reconnects. The registration of offerings on

the BIG IoT Marketplace is typically directly initiated by the device-level platform. Figure Fig-

ure 28 shows the proxy service integration in mode 4.

Figure 28 Proxy service integration in integration mode 4

Technically, the BIG IoT Proxy Service implements a BIG IoT Lib provider that handles all A1

access requests from consumers/services and also takes care marketplace interfaces M1 and

M2, mostly for authentication to the marketplace and the registration of new offerings. It

provides a PR1 interface for pulling and pushing information and access requests to and from

the constrained BIG IoT platform. Figure 29 shows some more details for the internal logic of

both proxy service and the constrained platform.

Page 69: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 69

Figure 29 Integration mode 4 interactions

The constrained BIG IoT enabled platform integrates a special BIG IoT Proxy Lib that allows

easy interaction with the consumers and the marketplace over the PR1 interface of BIG IoT

Proxy Service. The BIG IoT Proxy Lib provides the P3 programming interface to the constrained

IoT platform. The P3 interface can be used by a legacy constrained IoT platform and make it

BIG IoT enabled. It enables provider authentication and offering registration to the BIG IoT

Marketplace, even when the platform is not always available due to power-saving or due to

unavailability in general. An example usage of P3 interface on a highly constrained IoT plat-

form in python, is shown below:

Setting parameters for integration mode 3

# 1. Make a new provider object and load the offering.

offering = (OFFERING_NAME, OFFERING_DESC, INPUT_PARAMS,

OUTPUT_PARAMS, ROUTE, REGION)

provider = Provider(DEVICE_PROVIDER_NAME, MARKETPLACE_URI, offering,

outputResourceCallback )

# 2. Create the Provider, register the offering and start talking with the proxy service

provider.initialize(deviceInfo, proxyServer)

# Callback for output resources

def outputResourceCallback(inputData):

return outputData()

Page 70: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 70

5. Conclusion & Outlook

This deliverable describes comprehensively the first release of the BIG IoT API, contributing

to MS1. It already comprises a broad range of functionalities, such as handling data access or

feeds. Based on this first release, we will iteratively add further functionalities to the API in

the coming months. This will result in the release 2 (contributing to MS3) and release 3 (con-

tributing to MS5). In between those official releases, we conduct an agile development, which

provides intermediary versions of the API to dependent tasks, such as the development of

services and applications in WP5.

The BIG IoT API can be seen from 2 perspectives, as (1) a web API and (2) a programming API.

Both perspectives on the BIG IoT API have been described in this document. The detailed

technical specification of the web API in section 3 comprises descriptions of the different in-

teractions realized by the API as well as their implementation in concrete communication

protocols. The description of the programming API (section 3) will be published as online doc-

umentation in a tutorial style in order to attract new developers who contribute services,

platforms or applications. The programming API is provided in this first release in Java, but

further implementations in other languages (e.g. Go, Python and JavaScript) are planned.

The design of the BIG IoT API follows some fundamental principles as guideline for the devel-

opment. A key principle underlying our work is “description before adaptation”. I.e., we do

not define all parameters of the API in advance, as it is often done by standards such as OGC

SOS. Instead, the parameterization of API calls is widely kept generic, by allowing to define

the type and value of input and output data parameters using semantic concepts. The input

and output data parameters accepted by a platform or service are defined by the respective

offering in its offering description (as defined in D3.2). Hence, the description of the resource

becomes a more important role than in other APIs, which are usually implemented through

plain adaptation. The main advantage of this approach is the very high degree of flexibility

gained. An unrestricted number of semantic types for input and output data parameters can

be supported through this approach. Thus, we do not limit the API to a particular domain or

application.

The generic design of the BIG IoT API demands clear semantic (and syntactic) descriptions of

the parameters. Thereby, in order to ignite an IoT ecosystem it is crucial to select or define

an initial set of concepts allowed to be used and which developers can rely on. Here, the work

of Task 4.2 on defining an application domain model is key. The resulting deliverable D4.2

Page 71: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 71

defines a narrow, agreed vocabulary to start the BIG IoT ecosystem. This narrow vocabulary

can then be further extended over time and with the growing of the ecosystem.

In the future, the missing functionalities of the BIG IoT API need to be defined and imple-

mented in the SDK. This includes tasking, i.e., the transmission of commands to actors (e.g.,

sending a message to control a robot arm). Also important is to support eventing, i.e., ena-

bling client to subscribe to and receive events according to a defined set of rules related to

an offering.

More extensive research will be invested into further facilitating the integration of platforms

and services into the ecosystem. We are envisaging a very easy and partially automated

mechanism to adapt and integrate existing platforms by generating gateway services based

on descriptions.

Page 72: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 72

References

[1] https://evrythng.com

[2] https://www.thingworx.com

[3] https://www.xively.com

[4] https://www.yaler.net

[5] https://www.bosch-si.com/de/produkte/bosch-iot-suite/iot-platform/vorteile.html

[6] https://www.smartdatanet.it

[7] Bröring, A., S. Schmid, C.-K.Schindhelm, A. Khelil, S. Kaebisch, D. Kramer, D. Le Phuoc, J. Mitic, D. Anicic, E. Teniente (2017, forthcoming): Enabling IoT Ecosystems through Platform Interoperability. IEEE Software, special issue on: Software Engineering for the Internet of Things.

[8] J. Manyika, M. Chui, P. Bisson, J. Woetzel, R. Dobbs, J. Bughin and D. Aharon, "The Internet of Things: Mapping the Value Beyond the Hype," McKinsey Global Institute, 2015.

[9] https://tools.ietf.org/html/rfc7252

[10] https://www.oasis-open.org/committees/mqtt

[11] http://technical.openmobilealliance.org/Technical/technical-infor-mation/release-program/current-releases/oma-lightweightm2m-v1-0

[12] http://www.opengeospatial.org/ogc/markets-technologies/swe

[13] http://www.onem2m.org

[14] http://tools.ietf.org/html/rfc7230#section-3.1.1

[15] https://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.2.1

[16] https://support.microsoft.com/en-us/kb/208427

[17] https://boutell.com/newfaq/misc/urllength.html

Page 73: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 73

Appendix A UML Class Diagrams

Figure 30 Focus consumer

Page 74: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 74

Figure 31 Focus offering query

Page 75: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 75

Figure 32 Focus offering

Page 76: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 76

Figure 33 Focus provider

Page 77: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Deliverable 3.1.b – BIG IoT API Design D3.1.b

© 2017 77

Appendix B BIG IoT API Documentation

The code documentation follows this page.

Page 78: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

BIG IoT API Reference

Deliverable 3.1.b: BIG IoT API Design - Second ReleaseAnnex B

Page 79: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib

B2

Page 80: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.libClass BigIotAPIjava.lang.Object | +-org.eclipse.bigiot.lib.BigIotAPI

public class BigIotAPIextends Object

This class is the base class of the BIG IoT API, it brings authentication functionality.

Direct Known Subclasses:ConsumerCore, Provider

Constructors

BigIotAPIpublic BigIotAPI(BigIotClientId clientId, String marketplaceUri)

Methods

authenticatepublic void authenticate(String clientSecret) throws IOException

Authenticates instance at the Marketplace.

Parameters:clientSecret - API Key for authentication at the marketplace

Throws:IOException

terminatepublic void terminate()

Terminate the Consumer or Provider instance.

getProviderCertFilepublic String getProviderCertFile()

getMarketplaceClientpublic BigIotMarketplaceClient getMarketplaceClient()

(continued on next page)

B3

org.eclipse.bigiot.lib.BigIotAPI

Page 81: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

setProxypublic void setProxy(String host, int port)

Set a web proxy host and port

Parameters:host

port

addProxyBypasspublic void addProxyBypass(String host)

Add a host on the no-proxy list

Parameters:host

removeProxyBypasspublic void removeProxyBypass(String host)

Remove a host on the no-proxy list

Parameters:host

B4

org.eclipse.bigiot.lib.BigIotAPI

Page 82: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.libClass BigIotClientIdjava.lang.Object | +-org.eclipse.bigiot.lib.BigIotClientId

public class BigIotClientIdextends Objectimplements QueryElement

All Implemented Interfaces:QueryElement

Constructors

BigIotClientIdpublic BigIotClientId(String clientId)

Methods

asStringpublic String asString()

hashCodepublic int hashCode()

equalspublic boolean equals(Object obj)

toStringpublic String toString()

toQueryElementpublic String toQueryElement()

B5

org.eclipse.bigiot.lib.BigIotClientId

Page 83: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.libClass Consumerjava.lang.Object | +- | +- | +-org.eclipse.bigiot.lib.Consumer

public class Consumerextends ConsumerCoreimplements IConsumer, IConsumer

Enables basic lifecycle operations on offerings for consumer. Consumer foresees discovery operations for offering descriptions onthe marketplace. The interface functions are all non-blocking either by returning a completable future or passing delegate objectsfor callback. CompletableFuture allows stream processing and reactive operations on the Type of the nested Object in theCompletableFuture. Calling .get() returns the nested object in a synchronized manner. The call blocks until the operation isfinished. Alternatively method calls foresee callback via delegate objects. The relevant delegate types are defined as functionalinterfaces, which allow lambda expression.

All Implemented Interfaces:IConsumer, IConsumer

Constructors

Consumerpublic Consumer(String consumerId, String marketplaceUri)

Instantiates the Consumer instance

Parameters:consumerId - Identifier of the Consumer instance - as provided by the Marketplace.marketplaceUri - URI to the Marketplace API (e.g. https://marketplace.big-iot.eu:8080/)certificateFile

Methods

discoverpublic CompletableFuture discover(IOfferingQuery offeringQuery)

Performs a marketplace discovery for Offerings matching the implementation as Offering Query. The call is non-blockingas it returns the list of Offering Descriptions as a completable future.

Parameters:offeringQuery - Offering query used for discover

Returns:List of found Offering Descriptions matching Offering Query as CompletableFuture.

B6

org.eclipse.bigiot.lib.Consumer

Page 84: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

discoverpublic void discover(IOfferingQuery offeringQuery, DiscoverResponseHandler onSuccess, DiscoverResponseErrorHandler onFailure)

Performs a marketplace discovery for Offerings according to the offering query. The call is non-blocking. On successfulexecution, onSuccess receives the result via executing its callback method. On failure the respective callback method ofonFailure is called.

Parameters:offeringQuery - Offering query used for discoveronSuccess - Delegate object for processing successful discoveriesonFailure - Delegate object for failing discoveries

discoverpublic void discover(IOfferingQuery offeringQuery, DiscoverResponseHandler onSuccess)

Performs a marketplace discovery for Offerings according to the offering query. The call is non-blocking. On successfulexecution, onSuccess receives the result via executing its callback method. On failure nothing is done.

Parameters:offeringQuery - Offering query used for discoveronSuccess - Delegate object for processing successful discoveries

subscribepublic CompletableFuture subscribe(SubscribableOfferingDescriptionconsumableOfferingDescription) throws InterruptedException, ExecutionException

Subscribes to an offering. The call is non-blocking and returns a CompletableFuture on an Offering.

Parameters:offeringId

Returns:

Throws:InterruptedException

ExecutionException

subscribeBlockingpublic Offering subscribeBlocking(SubscribableOfferingDescriptionconsumableOfferingDescription)

Subscribes to an offering. The call is blocking and returns an Offering.

Parameters:offeringId

Returns:

Throws:

B7

org.eclipse.bigiot.lib.Consumer

Page 85: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

InterruptedException

ExecutionException

B8

org.eclipse.bigiot.lib.Consumer

Page 86: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.libClass ConsumerCorejava.lang.Object | +- | +-org.eclipse.bigiot.lib.ConsumerCore

public class ConsumerCoreextends BigIotAPIimplements IConsumer

Enables basic lifecycle operations on offerings for consumer. Consumer foresees discovery operations for offering descriptions onthe marketplace. The interface functions are all non-blocking either by returning a completable future or passing delegate objectsfor callback. CompletableFuture allows stream processing and reactive operations on the Type of the nested Object in theCompletableFuture. Calling .get() returns the nested object in a synchronized manner. The call blocks until the operation isfinished. Alternatively method calls foresee callback via delegate objects. The relevant delegate types are defined as functionalinterfaces, which allow lambda expression.

All Implemented Interfaces:IConsumer

Direct Known Subclasses:Consumer

Constructors

ConsumerCorepublic ConsumerCore(String consumerId, String marketplaceUri)

Instantiates the Consumer instance

Parameters:consumerId - Identifier of the Consumer instance - as provided by the Marketplace.marketplaceUri - URI to the Marketplace API (e.g. https://marketplace.big-iot.eu:8080/)certificateFile

Methods

createOfferingQuerypublic static OfferingQueryChain createOfferingQuery(String localId) throws IncompleteOfferingQueryException

Creates an empty offering query with a custom query id

Parameters:localId

Returns:

Throws:

B9

org.eclipse.bigiot.lib.ConsumerCore

Page 87: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

IncompleteOfferingQueryException

discoverFuturepublic Future discoverFuture(IOfferingQuery offeringQuery) throws IOException

Performs a marketplace discovery for Offerings according to the offering query. The call is non-blocking as it returns thelist of offering descriptions as a future.

Parameters:offeringQuery - Offering query used for discover

Returns:List of found Offering Descriptions matching Offering Query as CompletableFuture.

discoverBlockingpublic List discoverBlocking(IOfferingQuery offeringQuery) throws IOException, NotRegisteredException

Performs a marketplace discovery for Offerings according to the offering query. The call is blocking.

Parameters:offeringQuery - Offering query used for discover

Returns:List of found Offering Descriptions matching Offering Query as CompletableFuture.

discoverpublic void discover(IOfferingQuery offeringQuery, DiscoverResponseHandler onSuccessDiscover, DiscoverResponseErrorHandler onFailureDiscover) throws IncompleteOfferingQueryException

Performs a marketplace discovery for Offerings according to the offering query. The call is non-blocking. On successfulexecution, onSuccess receives the result via executing its callback method. On failure the respective callback method ofonFailure is called.

Parameters:offeringQuery - Offering query used for discover

Returns:List of found Offering Descriptions matching Offering Query as CompletableFuture.

discoverpublic void discover(IOfferingQuery offeringQuery, DiscoverResponseHandler onSuccessDiscover) throws IncompleteOfferingQueryException

Performs a marketplace discovery for Offerings according to the offering query. The call is non-blocking, on success thecall back is executed.

Parameters:offeringQuery - Offering query used for discover

Returns:List of found Offering Descriptions matching Offering Query as CompletableFuture.

B10

org.eclipse.bigiot.lib.ConsumerCore

Page 88: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Throws:IncompleteOfferingQueryException

terminatepublic void terminate()

Terminates a consumer session.

B11

org.eclipse.bigiot.lib.ConsumerCore

Page 89: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.libInterface IConsumer

public interface IConsumerextends

Enables basic lifecycle operations on offerings for consumer. Consumer foresees discovery operations for offering descriptions onthe marketplace. IConsumer foresees discover operations for Offering Descriptions on the marketplace. The interface functionsare all non-blocking either by returning a completable future or passing delegate objects for callback. CompletableFuture allowsstream processing and reactive operations on the Type of the nested Object in the CompletableFuture. Calling .get() returns thenested object in a synchronized manner. The call blocks until the operation is finished. Alternatively method calls foresee callbackvia delegate objects. The relevant delegate types are defined as functional interfaces, which allow lambda expression.

All Known Implementing Classes:ConsumerCore, Consumer

Methods

discoverFuturepublic abstract Future discoverFuture(IOfferingQuery offeringQuery) throws IOException

Performs a marketplace discovery for Offerings according to the offering query. The call is non-blocking as it returns thelist of offering descriptions as a future.

Parameters:offeringQuery - Offering query used for discover

Returns:List of found Offering Descriptions matching Offering Query as CompletableFuture.

discoverpublic abstract void discover(IOfferingQuery offeringQuery, DiscoverResponseHandler onSuccess, DiscoverResponseErrorHandler onFailure) throws IncompleteOfferingQueryException

Performs a marketplace discovery for Offerings according to the offering query. The call is non-blocking. On successfulexecution, onSuccess receives the result via executing its callback method. On failure the respective callback method ofonFailure is called.

Parameters:offeringQuery - Offering query used for discoveronSuccess - Delegate object for processing successful discoveriesonFailure - Delegate object for failing discoveries

discoverpublic abstract void discover(IOfferingQuery offeringQuery, DiscoverResponseHandler onSuccess) throws IncompleteOfferingQueryException

Performs a marketplace discovery for Offerings matching the implementation as Offering Query. The call is non-blocking.On successful execution, onSuccess receives the result via executing its callback method. On failure nothing is done.

B12

org.eclipse.bigiot.lib.IConsumer

Page 90: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Parameters:offeringQuery - Offering query used for discoveronSuccess - Delegate object for processing successful discoveries

terminatepublic abstract void terminate()

Terminates Consumer session on marketplace

getProviderCertFilepublic abstract String getProviderCertFile()

getMarketplaceClientpublic abstract BigIotMarketplaceClient getMarketplaceClient()

B13

org.eclipse.bigiot.lib.IConsumer

Page 91: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.libInterface IProvider

public interface IProviderextends

Enables basic lifecycle operations on offerings for providers.

All Known Implementing Classes:Provider

Methods

authenticatepublic abstract void authenticate(String clientSecret) throws IOException

Authenticates instance at the Marketplace.

Parameters:clientSecret

Throws:IOException

registerpublic abstract OfferingId register(RegistrableOfferingDescriptionofferingDescription) throws IncompleteOfferingDescriptionException, NotRegisteredException

Registers a new offering description at the Marketplace. Depending on the implementation, it may initiate an A1 interfaceto the offering. accessRequestHandler is called upon receiving an access request. Returns a unique ID referencing theregistered offering for further lifecycle operations.

Parameters:offeringDescription

Returns:

Throws:IncompleteOfferingDescriptionExceptionNotRegisteredException

registerpublic abstract void register(OfferingId offeringId)

Activates an offering, which is already registered at the marketplace. It is assumed here that the OfferingDescription hasalready been created using the web portal of the marketplace. No A1 Interface is deployed.

Parameters:

B14

org.eclipse.bigiot.lib.IProvider

Page 92: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

offeringId

registerpublic abstract void register(OfferingId offeringId, AccessRequestHandler accessRequestHandler, EmbededdedRouteBasedServer server)

Activates an offering, which is already registered at the marketplace. It is assumed here that the OfferingDescription hasalready been created using the web portal of the marketplace. It initiate anA1 interface to the offering via the serverargument. accessRequestHandler is called upon receiving an access request.

Parameters:offeringId

accessRequestHandler

server

deregisterpublic abstract void deregister(RegistrableOfferingDescription offeringDescription)

Deregisters an offering descripton from the Marketplace. If an A1 interface is deployed, it will be also deactivated.

Parameters:offeringDescription

deregisterpublic abstract void deregister(OfferingId offeringId)

Deregisters an offering descripton from the Marketplace based on the OfferingID. If an A1 interface is deployed, it will bealso deactivated.

Parameters:offeringId

terminatepublic abstract void terminate()

Terminates the Provider instance deregisters all offering and stops all deployed A1 Access Interfaces.

createOfferingDescriptionpublic abstract RegistrableOfferingDescriptionChain createOfferingDescription(StringlocalId)

Creates a basic offering description for registration at the marketplace.

Parameters:localId

Returns:

createOfferingDescriptionFromOfferingIdpublic abstract RegistrableOfferingDescriptionChaincreateOfferingDescriptionFromOfferingId(String offeringId)

B15

org.eclipse.bigiot.lib.IProvider

Page 93: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Retrieves the offering description from the marketplace referenced by the offering ID.

Parameters:offeringId

Returns:

B16

org.eclipse.bigiot.lib.IProvider

Page 94: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.libClass Providerjava.lang.Object | +- | +-org.eclipse.bigiot.lib.Provider

public class Providerextends BigIotAPIimplements IProvider

Enables basic lifecycle operations on offerings for providers.

All Implemented Interfaces:IProvider

Direct Known Subclasses:ProviderSpark

Fields

offeringDescriptionpublic static org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionofferingDescription

END_POINT_MANAGEMENT_MAGICpublic static java.lang.String END_POINT_MANAGEMENT_MAGIC

Constructors

Providerpublic Provider(String providerId, String marketplaceUrl)

Instantiates the Provider instance

Methods

createpublic static Provider create(String providerId, String marketplaceUri)

Instantiates the Provider instance

B17

org.eclipse.bigiot.lib.Provider

Page 95: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

terminatepublic void terminate()

Terminates the Provider instance deregisters all offering and stops all deployed A1 Access Interfaces.

registerpublic OfferingId register(RegistrableOfferingDescription offeringDescription) throws IncompleteOfferingDescriptionException, NotRegisteredException

Registers a new offering description at the Marketplace. Depending on the implementation, it may initiate an A1 interfaceto the offering. accessRequestHandler is called upon receiving an access request. Returns a unique ID referencing theregistered offering for further lifecycle operations.

registerpublic void register(OfferingId offeringId)

Activates an offering, which is already registered at the marketplace. It is assumed here that the OfferingDescription hasalready been created using the web portal of the marketplace. No A1 Interface is deployed.

registerpublic void register(OfferingId offeringId, AccessRequestHandler accessRequestHandler, EmbededdedRouteBasedServer server)

Activates an offering, which is already registered at the marketplace. It is assumed here that the OfferingDescription hasalready been created using the web portal of the marketplace. It initiate anA1 interface to the offering via the serverargument. accessRequestHandler is called upon receiving an access request.

activatepublic static RegistrableOfferingDescriptionChain activate(OfferingId offeringId, BigIotMarketplaceClient marketplaceClient)

deregisterpublic void deregister(RegistrableOfferingDescription offeringDescription)

Deregisters an offering. The offering is removed from the marketplace.

deregisterpublic void deregister(OfferingId offeringId)

Deregisters an offering per offering ID. The offering is removed from the marketplace.

createOfferingDescriptionpublic RegistrableOfferingDescriptionChain createOfferingDescription(String localId)

Creates a basic offering description for registration at the marketplace.

B18

org.eclipse.bigiot.lib.Provider

Page 96: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

createOfferingDescriptionFromOfferingIdpublic RegistrableOfferingDescriptionChaincreateOfferingDescriptionFromOfferingId(String offeringId)

Retrieves the offering description from the marketplace referenced by the offering ID.

B19

org.eclipse.bigiot.lib.Provider

Page 97: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.libClass ProviderSparkjava.lang.Object | +- | +- | +-org.eclipse.bigiot.lib.ProviderSpark

public class ProviderSparkextends Provider

All Implemented Interfaces:IProvider

Constructors

ProviderSparkpublic ProviderSpark(String providerId, String marketplaceUri, String localDomain, int localPort)

Methods

createOfferingDescriptionpublic RegistrableOfferingDescriptionChain createOfferingDescription(String localId)

Creates a basic offering description for registration at the marketplace.

Returns:

createOfferingDescriptionFromOfferingIdpublic RegistrableOfferingDescriptionChaincreateOfferingDescriptionFromOfferingId(String offeringId)

Retrieves the offering description from the marketplace referenced by the offering ID.

Parameters:offeringId

Returns:

B20

org.eclipse.bigiot.lib.ProviderSpark

Page 98: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

terminatepublic void terminate()

Terminates the Provider instance deregisters all offering and stops all deployed A1 Access Interfaces.

B21

org.eclipse.bigiot.lib.ProviderSpark

Page 99: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.embeddedspark

B22

Page 100: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.embeddedsparkClass EmbeddedSparkjava.lang.Object | +- | +-org.eclipse.bigiot.lib.embeddedspark.EmbeddedSpark

public class EmbeddedSparkextends EmbededdedRouteBasedServer

All Implemented Interfaces:IRouter, IServerWrapper

Constructors

EmbeddedSparkpublic EmbeddedSpark(String domain, int port)

EmbeddedSparkpublic EmbeddedSpark(String domain, int port, String baseRoute, ServerOptionsSpark serverOptions)

Methods

startpublic void start()

startHttppublic void startHttp()

startpublic void start(String keyStoreFile, String keyStorePassword)

B23

org.eclipse.bigiot.lib.embeddedspark.EmbeddedSpark

Page 101: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

stoppublic void stop()

addRoutepublic void addRoute(String route, AccessRequestHandler accessCallback, RegistrableOfferingDescription offeringDescription)

activateProxypublic void activateProxy(ProxyAccessRequestHandler accessCallback)

removeRoutepublic void removeRoute(String route)

getRoutespublic List getRoutes()

enableCorsAllpublic static void enableCorsAll()

enableCorspublic static void enableCors(String origin, String methods, String headers)

B24

org.eclipse.bigiot.lib.embeddedspark.EmbeddedSpark

Page 102: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.embeddedsparkClass ServerOptionsSparkjava.lang.Object | +- | +-org.eclipse.bigiot.lib.embeddedspark.ServerOptionsSpark

public class ServerOptionsSparkextends ServerOptions

Fields

defaultOptionspublic static org.eclipse.bigiot.lib.embeddedspark.ServerOptionsSpark defaultOptions

Constructors

ServerOptionsSparkpublic ServerOptionsSpark()

B25

org.eclipse.bigiot.lib.embeddedspark.ServerOptionsSpark

Page 103: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.exceptions

B26

Page 104: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.exceptionsClass AccessToNonActivatedOfferingExceptionjava.lang.Object | +- | +- | +- | +-org.eclipse.bigiot.lib.exceptions.AccessToNonActivatedOfferingException

public class AccessToNonActivatedOfferingExceptionextends BIGIoTException

All Implemented Interfaces:Serializable

Constructors

AccessToNonActivatedOfferingExceptionpublic AccessToNonActivatedOfferingException()

B27

org.eclipse.bigiot.lib.exceptions.AccessToNonActivatedOfferingException

Page 105: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.exceptionsClass AccessToNonSubscribedOfferingExceptionjava.lang.Object | +- | +- | +- | +-org.eclipse.bigiot.lib.exceptions.AccessToNonSubscribedOfferingException

public class AccessToNonSubscribedOfferingExceptionextends BIGIoTException

All Implemented Interfaces:Serializable

Constructors

AccessToNonSubscribedOfferingExceptionpublic AccessToNonSubscribedOfferingException()

B28

org.eclipse.bigiot.lib.exceptions.AccessToNonSubscribedOfferingException

Page 106: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.exceptionsClass BIGIoTExceptionjava.lang.Object | +- | +- | +-org.eclipse.bigiot.lib.exceptions.BIGIoTException

public abstract class BIGIoTExceptionextends Exception

All Implemented Interfaces:Serializable

Direct Known Subclasses:AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException, FailedRegistrationException,HttpErrorException, IllegalAccessParameterException, IncompleteOfferingDescriptionException,IncompleteOfferingQueryException, NotRegisteredException, RegisteredTwiceException

Constructors

BIGIoTExceptionpublic BIGIoTException()

B29

org.eclipse.bigiot.lib.exceptions.BIGIoTException

Page 107: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.exceptionsClass FailedRegistrationExceptionjava.lang.Object | +- | +- | +- | +-org.eclipse.bigiot.lib.exceptions.FailedRegistrationException

public class FailedRegistrationExceptionextends BIGIoTException

All Implemented Interfaces:Serializable

Constructors

FailedRegistrationExceptionpublic FailedRegistrationException()

B30

org.eclipse.bigiot.lib.exceptions.FailedRegistrationException

Page 108: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.exceptionsClass HttpErrorExceptionjava.lang.Object | +- | +- | +- | +-org.eclipse.bigiot.lib.exceptions.HttpErrorException

public class HttpErrorExceptionextends BIGIoTException

All Implemented Interfaces:Serializable

Constructors

HttpErrorExceptionpublic HttpErrorException(int status, String response)

B31

org.eclipse.bigiot.lib.exceptions.HttpErrorException

Page 109: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.exceptionsClass IllegalAccessParameterExceptionjava.lang.Object | +- | +- | +- | +-org.eclipse.bigiot.lib.exceptions.IllegalAccessParameterException

public class IllegalAccessParameterExceptionextends BIGIoTException

All Implemented Interfaces:Serializable

Constructors

IllegalAccessParameterExceptionpublic IllegalAccessParameterException()

B32

org.eclipse.bigiot.lib.exceptions.IllegalAccessParameterException

Page 110: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.exceptionsClass IncompleteOfferingDescriptionExceptionjava.lang.Object | +- | +- | +- | +-org.eclipse.bigiot.lib.exceptions.IncompleteOfferingDescriptionException

public class IncompleteOfferingDescriptionExceptionextends BIGIoTException

All Implemented Interfaces:Serializable

Constructors

IncompleteOfferingDescriptionExceptionpublic IncompleteOfferingDescriptionException()

B33

org.eclipse.bigiot.lib.exceptions.IncompleteOfferingDescriptionException

Page 111: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.exceptionsClass IncompleteOfferingQueryExceptionjava.lang.Object | +- | +- | +- | +-org.eclipse.bigiot.lib.exceptions.IncompleteOfferingQueryException

public class IncompleteOfferingQueryExceptionextends BIGIoTException

All Implemented Interfaces:Serializable

Constructors

IncompleteOfferingQueryExceptionpublic IncompleteOfferingQueryException()

B34

org.eclipse.bigiot.lib.exceptions.IncompleteOfferingQueryException

Page 112: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.exceptionsClass NotRegisteredExceptionjava.lang.Object | +- | +- | +- | +-org.eclipse.bigiot.lib.exceptions.NotRegisteredException

public class NotRegisteredExceptionextends BIGIoTException

All Implemented Interfaces:Serializable

Constructors

NotRegisteredExceptionpublic NotRegisteredException()

B35

org.eclipse.bigiot.lib.exceptions.NotRegisteredException

Page 113: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.exceptionsClass RegisteredTwiceExceptionjava.lang.Object | +- | +- | +- | +-org.eclipse.bigiot.lib.exceptions.RegisteredTwiceException

public class RegisteredTwiceExceptionextends BIGIoTException

All Implemented Interfaces:Serializable

Constructors

RegisteredTwiceExceptionpublic RegisteredTwiceException()

B36

org.eclipse.bigiot.lib.exceptions.RegisteredTwiceException

Page 114: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.feed

B37

Page 115: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.feedClass AccessFeedjava.lang.Object | +-org.eclipse.bigiot.lib.feed.AccessFeed

public abstract class AccessFeedextends Objectimplements IAccessFeed

AccessFeed represents data feed and brings functionality for lifecycle management

All Implemented Interfaces:IAccessFeed

Direct Known Subclasses:AccessFeedAsync, AccessFeedSync

Constructors

AccessFeedpublic AccessFeed(Duration lifetime, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure)

AccessFeedpublic AccessFeed(FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure)

Methods

resumepublic abstract void resume()

Resumes a stopped data feed

stoppublic abstract void stop()

Explicitly stop data reception

setLifetimeSecondspublic abstract void setLifetimeSeconds(long lifetimeSeconds)

Set lifetime of data feed with duration. After that the feed is automatically terminated.

B38

org.eclipse.bigiot.lib.feed.AccessFeed

Page 116: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

getStatuspublic abstract FeedStatus getStatus()

Returns status of data feed

getExpirationDatepublic DateTime getExpirationDate()

Expiration data of data feed

B39

org.eclipse.bigiot.lib.feed.AccessFeed

Page 117: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.feedClass AccessFeedAsyncjava.lang.Object | +- | +-org.eclipse.bigiot.lib.feed.AccessFeedAsync

public class AccessFeedAsyncextends AccessFeed

Implementation for asynchronous feed support. AccessFeedAsync represents data feed and brings functionality for lifecyclemanagement

All Implemented Interfaces:IAccessFeed

Constructors

AccessFeedAsyncpublic AccessFeedAsync(Duration lifetime, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure)

Methods

stoppublic void stop()

Explicitly stop data reception

getStatuspublic FeedStatus getStatus()

Returns status of Feed

setLifetimeSecondspublic void setLifetimeSeconds(long lifetimeSeconds)

Set lifetime of feed with duration. After that the feed is automatically terminated.

resumepublic void resume()

Resumes a stopped data feed

B40

org.eclipse.bigiot.lib.feed.AccessFeedAsync

Page 118: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.feedClass AccessFeedSyncjava.lang.Object | +- | +-org.eclipse.bigiot.lib.feed.AccessFeedSync

public class AccessFeedSyncextends AccessFeed

Implementation for synchronous feed support

All Implemented Interfaces:IAccessFeed

Constructors

AccessFeedSyncpublic AccessFeedSync(IOfferingCore offering, AccessParameters accessParameters, Duration lifetime, Duration interval, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure)

Methods

stoppublic void stop()

Explicitly stop data reception

getStatuspublic FeedStatus getStatus()

Returns status of data feed

setLifetimeSecondspublic void setLifetimeSeconds(long lifetimeSeconds)

Set lifetime of feed with duration. After that the feed is automatically terminated.

resumepublic void resume()

Resumes a stopped data feed

B41

org.eclipse.bigiot.lib.feed.AccessFeedSync

Page 119: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.feedClass FeedStatusjava.lang.Object | +-org.eclipse.bigiot.lib.feed.FeedStatus

public class FeedStatusextends Object

FeedStatus represents the status of a data feed

Constructors

FeedStatuspublic FeedStatus(boolean terminated, DateTime expirationDate, BigIotTypes.FeedTypes feedType, Duration interval)

Methods

getFeedTypepublic BigIotTypes.FeedTypes getFeedType()

getExpirationDatepublic DateTime getExpirationDate()

getIntervalpublic Duration getInterval()

isTerminatedpublic boolean isTerminated()

toStringpublic String toString()

B42

org.eclipse.bigiot.lib.feed.FeedStatus

Page 120: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.feedInterface IAccessFeed

public interface IAccessFeedextends

Interface for lifecycle operations on data feeds

All Known Implementing Classes:AccessFeed

Methods

resumepublic abstract void resume()

Resumes a stopped data feed

stoppublic abstract void stop()

Explicitly stop data reception

setLifetimeSecondspublic abstract void setLifetimeSeconds(long lifetimeSeconds)

Set lifetime of data feed with duration. After that the feed is automatically terminated.

getExpirationDatepublic abstract DateTime getExpirationDate()

Expiration data of data feed

getStatuspublic abstract FeedStatus getStatus()

Returns status of data feed

B43

org.eclipse.bigiot.lib.feed.IAccessFeed

Page 121: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.handlers

B44

Page 122: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.handlersInterface AccessRequestHandler

public interface AccessRequestHandlerextends

Handles incoming Offering requests

Methods

processRequestHandlerpublic abstract BigIotHttpResponse processRequestHandler(OfferingDescriptionofferingDescription, Map inputData)

Process incoming Offering requests

Parameters:offeringDescription - Reference to OfferingDescriptioninputData - Input parameter list

Returns:

B45

org.eclipse.bigiot.lib.handlers.AccessRequestHandler

Page 123: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.handlersInterface AccessResponseFailureHandler

public interface AccessResponseFailureHandlerextends

Handles access failure

Methods

processResponseOnFailurepublic abstract void processResponseOnFailure(IOfferingCore reference, AccessResponse response)

Processes failure on Offering access

Parameters:reference - Reference to offeringresponse - Response from Offering

B46

org.eclipse.bigiot.lib.handlers.AccessResponseFailureHandler

Page 124: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.handlersInterface AccessResponseSuccessHandler

public interface AccessResponseSuccessHandlerextends

Handles successful data reception.

Methods

processResponseOnSuccesspublic abstract void processResponseOnSuccess(IOfferingCore reference, AccessResponse response) throws InterruptedException, ExecutionException

Process incoming responses of an Offering access

Parameters:reference - Reference to offeringresponse - Response from Offering access

Throws:ExecutionException

InterruptedException

B47

org.eclipse.bigiot.lib.handlers.AccessResponseSuccessHandler

Page 125: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.handlersClass DiscoverFailureExceptionjava.lang.Object | +- | +- | +-org.eclipse.bigiot.lib.handlers.DiscoverFailureException

public class DiscoverFailureExceptionextends Exception

Exception for DiscoveryFailure

All Implemented Interfaces:Serializable

Constructors

DiscoverFailureExceptionpublic DiscoverFailureException()

B48

org.eclipse.bigiot.lib.handlers.DiscoverFailureException

Page 126: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.handlersInterface DiscoverResponseErrorHandler

public interface DiscoverResponseErrorHandlerextends

Handles discovery error

Methods

processResponsepublic abstract void processResponse(IOfferingQuery reference, DiscoverFailureException failure)

Processes an discovery failure

Parameters:reference - Reference to Offering Queryfailure - Failure object

B49

org.eclipse.bigiot.lib.handlers.DiscoverResponseErrorHandler

Page 127: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.handlersInterface DiscoverResponseHandler

public interface DiscoverResponseHandlerextends

Handles successful discoveries on Marketplace

Methods

processResponsepublic abstract void processResponse(IOfferingQuery reference, List offeringDescriptions)

Processes incoming Offering Descriptions

Parameters:reference - Reference to Offering QueryofferingDescriptions - List of Offering Descriptions

B50

org.eclipse.bigiot.lib.handlers.DiscoverResponseHandler

Page 128: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.handlersClass FeedFailureExceptionjava.lang.Object | +-org.eclipse.bigiot.lib.handlers.FeedFailureException

public class FeedFailureExceptionextends Object

Feed Failure Exception

Constructors

FeedFailureExceptionpublic FeedFailureException()

B51

org.eclipse.bigiot.lib.handlers.FeedFailureException

Page 129: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.handlersInterface FeedNotificationFailureHandler

public interface FeedNotificationFailureHandlerextends

Handles feed failures

Methods

processNotificationOnFailurepublic abstract void processNotificationOnFailure(IAccessFeed reference, FeedFailureException failure)

Process feed failure

Parameters:reference - Reference to AccessFeedfailure - Failure object

B52

org.eclipse.bigiot.lib.handlers.FeedNotificationFailureHandler

Page 130: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.handlersInterface FeedNotificationSuccessHandler

public interface FeedNotificationSuccessHandlerextends

Handles successful feed notifications

Methods

processNotificationOnSuccesspublic abstract void processNotificationOnSuccess(IAccessFeed reference, AccessResponse response) throws InterruptedException, ExecutionException

Process incoming feed data

Parameters:reference - Reference to Feedresponse - Incoming Data

Throws:ExecutionException

InterruptedException

B53

org.eclipse.bigiot.lib.handlers.FeedNotificationSuccessHandler

Page 131: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.handlersInterface ProxyAccessRequestHandler

public interface ProxyAccessRequestHandlerextends

Handles incoming Offering requests

Methods

processRequestHandlerpublic abstract String processRequestHandler(String offeringId, Map inputData)

Process incoming Offering requests

Parameters:offeringDescription - Reference to OfferingDescriptioninputData - Input parameter list

Returns:

B54

org.eclipse.bigiot.lib.handlers.ProxyAccessRequestHandler

Page 132: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.misc

B55

Page 133: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.miscClass BigHttpSupportjava.lang.Object | +-org.eclipse.bigiot.lib.misc.BigHttpSupport

public class BigHttpSupportextends Object

Support for HTTP based access of web resources with static and blocking methods. Utilizes CompletableFuture for return types.

Constructors

BigHttpSupportpublic BigHttpSupport()

Methods

getpublic static CompletableFuture get(String url)

Executes HTTP GET on URL

Parameters:url - URL as String

Returns:HttpResponse as CompletableFuture

getpublic static CompletableFuture get(String url, Map addedHeaders)

Executes HTTP GET on URL with Headers

Parameters:url - URL as String

Returns:HttpResponse as CompletableFuture

postpublic static CompletableFuture post(String url, StringEntity requestEntity)

Executes HTTP POST on URL

Parameters:

B56

org.eclipse.bigiot.lib.misc.BigHttpSupport

Page 134: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

url - URL as StringrequestEntity - Body

Returns:HttpResponse as CompletableFuture

postpublic static CompletableFuture post(String url, StringEntity requestEntity, Map addedHeaders)

Executes HTTP POST on URL with Headers

Parameters:url - URL as StringrequestEntity - BodyaddedHeaders - HTTP headers

Returns:HttpResponse as CompletableFuture

putpublic static CompletableFuture put(String url, StringEntity requestEntity)

Executes HTTP PUT on URL

Parameters:url - URL as StringrequestEntity - Body

Returns:HttpResponse as CompletableFuture

putpublic static CompletableFuture put(String url, StringEntity requestEntity, Map addedHeaders)

Executes HTTP PUT on URL with Headers

Parameters:url - URL as StringrequestEntity - BodyaddedHeaders - HTTP headers

Returns:HttpResponse as CompletableFuture

deletepublic static CompletableFuture delete(String url)

Executes HTTP DELETE on URL

Parameters:

B57

org.eclipse.bigiot.lib.misc.BigHttpSupport

Page 135: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

url - URL as String

Returns:HttpResponse as CompletableFuture

deletepublic static CompletableFuture delete(String url, Map addedHeaders)

Executes HTTP DELETE on URL with Headers

Parameters:url - URL as StringaddedHeaders - HTTP headers

Returns:HttpResponse as CompletableFuture

B58

org.eclipse.bigiot.lib.misc.BigHttpSupport

Page 136: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.miscClass BigIotMarketplaceClientjava.lang.Object | +-org.eclipse.bigiot.lib.misc.BigIotMarketplaceClient

public class BigIotMarketplaceClientextends Object

Methods

createHttpOnlyClientpublic static BigIotMarketplaceClient createHttpOnlyClient(String marketplaceUri, BigIotClientId clientId, String clientSecret)

createpublic static BigIotMarketplaceClient create(String marketplaceUri, BigIotClientId clientId, String clientSecret)

createpublic static BigIotMarketplaceClient create(String marketplaceUri, BigIotClientId clientId, String clientSecret, String marketplaceCertFileName)

authenticatepublic void authenticate() throws IOException

requestpublic void request(String json, Callback callback) throws IOException

B59

org.eclipse.bigiot.lib.misc.BigIotMarketplaceClient

Page 137: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

requestpublic Response request(String json) throws IOException

closepublic void close()

getClientSecretpublic String getClientSecret()

B60

org.eclipse.bigiot.lib.misc.BigIotMarketplaceClient

Page 138: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.miscClass Constantsjava.lang.Object | +-org.eclipse.bigiot.lib.misc.Constants

public class Constantsextends Object

Fields

discoverySubUrlpublic static java.lang.String discoverySubUrl

syncFeedIntervalpublic static Duration syncFeedInterval

COMPLEX_PARAMETER_KEYpublic static java.lang.String COMPLEX_PARAMETER_KEY

ACCESS_PARAMETERS_HAVE_TO_MATCH_INPUT_PARAMETERSpublic static boolean ACCESS_PARAMETERS_HAVE_TO_MATCH_INPUT_PARAMETERS

EXECUTOR_POOL_SIZEpublic static final int EXECUTOR_POOL_SIZE

Constant value: 10

HTTPpublic static final java.lang.String HTTP

nlpublic static final java.lang.String nl

B61

org.eclipse.bigiot.lib.misc.Constants

Page 139: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

wwwFolderpublic static java.lang.String wwwFolder

wwwBigIotpublic static java.lang.String wwwBigIot

swaggerFileNamepublic static final java.lang.String swaggerFileName

Constant value: providerAPI.json

Constructors

Constantspublic Constants()

B62

org.eclipse.bigiot.lib.misc.Constants

Page 140: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.miscClass ExperimentalBypassDecoderjava.lang.Object | +- | +-org.eclipse.bigiot.lib.misc.ExperimentalBypassDecoder

public class ExperimentalBypassDecoderextends ExperimentalBypassEncoder

Constructors

ExperimentalBypassDecoderpublic ExperimentalBypassDecoder()

Methods

extractHiddenOfferingDescriptionpublic static SubscribableOfferingDescriptionextractHiddenOfferingDescription(SubscribableOfferingDescriptioncarrierOfferingDescription)

B63

org.eclipse.bigiot.lib.misc.ExperimentalBypassDecoder

Page 141: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.miscClass ExperimentalBypassEncoderjava.lang.Object | +-org.eclipse.bigiot.lib.misc.ExperimentalBypassEncoder

public class ExperimentalBypassEncoderextends Object

Direct Known Subclasses:ExperimentalBypassDecoder

Fields

CARRIER_URLpublic static final java.lang.String CARRIER_URL

Constant value: http://dirtyhelper.example.org?q=

DOUBLE_QUOTE_ESCAPEpublic static final java.lang.String DOUBLE_QUOTE_ESCAPE

Constant value: $

BACKSLASH_ESCAPEpublic static final java.lang.String BACKSLASH_ESCAPE

Constant value: §

Constructors

ExperimentalBypassEncoderpublic ExperimentalBypassEncoder()

Methods

hideOfferingDescriptionpublic static void hideOfferingDescription(RegistrableOfferingDescriptioncarrierOfferingDescription, RegistrableOfferingDescription hiddenOfferingDescription)

B64

org.eclipse.bigiot.lib.misc.ExperimentalBypassEncoder

Page 142: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.miscClass FilloutTemplatejava.lang.Object | +-org.eclipse.bigiot.lib.misc.FilloutTemplate

public class FilloutTemplateextends Object

Enables template based message generation with keywords

Direct Known Subclasses:OfferingQueryPriceTemplate, OfferingQueryRequestTemplate

Constructors

FilloutTemplatepublic FilloutTemplate(String defaultTemplate, HashMap kvp)

Constructor with a filename for template and hashmap for keyword and value combinations

Parameters:fileName

kvp

FilloutTemplatepublic FilloutTemplate(String defaultTemplate, String fileName, HashMap kvp)

FilloutTemplatepublic FilloutTemplate(HashMap kvp, String resourceName, boolean removeWhitespace)

Methods

filloutpublic String fillout()

Fills out template and returns it as a string

Returns:

B65

org.eclipse.bigiot.lib.misc.FilloutTemplate

Page 143: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.miscClass GraphQLQueriesjava.lang.Object | +-org.eclipse.bigiot.lib.misc.GraphQLQueries

public class GraphQLQueriesextends Object

Constructors

GraphQLQueriespublic GraphQLQueries()

Methods

getRegistrationStringpublic static String getRegistrationString(RegistrableOfferingDescription offering)

Generates a valid registration message accepted by the Marketplace

Parameters:providerId - Identifier of the provider issued by the Marketplace

Returns:Message for Offering registration

getActivationStringpublic static String getActivationString(String offeringId)

Generates activation message

Returns:Activation message

getActivationStringFullResponsepublic static String getActivationStringFullResponse(String offeringId)

getOfferingDescriptionStringpublic static String getOfferingDescriptionString(String offeringId)

B66

org.eclipse.bigiot.lib.misc.GraphQLQueries

Page 144: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

getSubscribtionWithQueryStringpublic static String getSubscribtionWithQueryString(String offeringId, String queryId)

Generates a valid subscription message accepted by the Marketplace

Returns:Message for Offering subscription

getUnsubscribtionStringpublic static String getUnsubscribtionString(String offeringId)

Generates a valid subscription message accepted by the Marketplace

Returns:Message for Offering subscription

getDeactivationStringpublic static String getDeactivationString(String offeringId)

Generates deactivation message

Returns:Deactivation message

getFindMatchingOfferingsStringpublic static String getFindMatchingOfferingsString(String queryId)

getQueryBaseTemplateStringpublic static String getQueryBaseTemplateString()

B67

org.eclipse.bigiot.lib.misc.GraphQLQueries

Page 145: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.miscClass Helperjava.lang.Object | +-org.eclipse.bigiot.lib.misc.Helper

public class Helperextends Object

Fields

df00public static final java.text.DecimalFormat df00

df000public static final java.text.DecimalFormat df000

df0000public static final java.text.DecimalFormat df0000

df0_0000public static final java.text.DecimalFormat df0_0000

Secondpublic static final int Second

Constant value: 1000

Minutepublic static final int Minute

Constant value: 60000

Hourpublic static final int Hour

B68

org.eclipse.bigiot.lib.misc.Helper

Page 146: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Constant value: 3600000

Constructors

Helperpublic Helper()

Methods

formatStringpublic static String formatString(String format, Object[] args)

Convenience function for String.format() using US locale

extractOfferingDescriptionsFromHttpResponsepublic static List extractOfferingDescriptionsFromHttpResponse(HttpResponse response)

Maps Offering Descriptions in JSON format to OfferingDescription

Parameters:response

Returns:List of OfferingDescription

unmarshallingToRootElementpublic static JSONObject unmarshallingToRootElement(String jsonString) throws IOException

Return root element of marketplace response as JSONObject.

Parameters:JSON - String

Returns:JSON Object (Element)

Throws:IOException

unmarshallingToDatapublic static JSONObject unmarshallingToData(String jsonString, String marketplaceCommand, String data) throws IOException

Return marketplace response data as a JSONObject.

Parameters:jsonString

B69

org.eclipse.bigiot.lib.misc.Helper

Page 147: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

marketplaceCommand

req

Returns:

Throws:IOException

unmarshallingToQueryNamepublic static JSONObject unmarshallingToQueryName(String jsonString, String queryName) throws IOException

Return marketplace response data as a JSONObject.

Parameters:jsonString

queryName

Returns:

Throws:IOException

showOfferingDescriptionspublic static void showOfferingDescriptions(List l)

Pretty print of list of Offering Description

Parameters:l

Returns:

roundpublic static double round(double d, int i)

formatDatepublic static String formatDate(String format, DateTime date)

printDeltaTimepublic static void printDeltaTime(DateTime start)

B70

org.eclipse.bigiot.lib.misc.Helper

Page 148: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

printDeltaTimepublic static void printDeltaTime(String prefix, DateTime start)

getResourcepublic static InputStream getResource(String resourceName)

writeFilepublic static void writeFile(File file, String content) throws IOException

mapOfpublic static HashMap mapOf(Object[] arguments)

mapToJsonpublic static String mapToJson(Map map, boolean prettyPrint) throws JsonProcessingException

objectToJsonpublic static String objectToJson(Object object, boolean prettyPrint) throws JsonProcessingException

getPojoAsJsonpublic static String getPojoAsJson(Object pojo)

getPojoAsJsonCompactpublic static String getPojoAsJsonCompact(Object pojo)

jsonPrettyPrintpublic static String jsonPrettyPrint(String body)

B71

org.eclipse.bigiot.lib.misc.Helper

Page 149: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

unixTimeMillisToJodapublic static DateTime unixTimeMillisToJoda(Long expirationTime)

unixTimeToJodapublic static DateTime unixTimeToJoda(Long expirationTime)

constructivePutpublic static void constructivePut(Map map, String dottedFieldName, Object value)

listToJsonpublic static String listToJson(LinkedList list)

B72

org.eclipse.bigiot.lib.misc.Helper

Page 150: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.miscClass HttpClientjava.lang.Object | +-org.eclipse.bigiot.lib.misc.HttpClient

public class HttpClientextends Object

Support for HTTP based access of web resources with and blocking methods. Utilizes CompletableFuture for return types.

Fields

MEDIA_TYPE_JSONpublic static final MediaType MEDIA_TYPE_JSON

isClosedpublic boolean isClosed

Methods

createHttpClientpublic static HttpClient createHttpClient()

createHttpsClientpublic static HttpClient createHttpsClient()

createHttpsClientpublic static HttpClient createHttpsClient(String userName, String password)

createTrustingHttpsClientpublic static HttpClient createTrustingHttpsClient()

B73

org.eclipse.bigiot.lib.misc.HttpClient

Page 151: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

createTrustingHttpsClientpublic static HttpClient createTrustingHttpsClient(String userName, String password)

createHttpsClientpublic static HttpClient createHttpsClient(String pemCertificateFileName)

createHttpsClientpublic static HttpClient createHttpsClient(File pemCertificateFile)

createHttpsClientpublic static HttpClient createHttpsClient(InputStream pemCertificateInputStream)

getpublic Response get(String url) throws IOException

Executes HTTP GET on URL

Parameters:url - URL as String

Returns:HttpResponse as CompletableFuture

getpublic Response get(String url, Map addedHeaders) throws IOException

Executes HTTP GET on URL with Headers

Parameters:url - URL as String

Returns:HttpResponse as CompletableFuture

getpublic void get(String url, Callback callback) throws IOException

B74

org.eclipse.bigiot.lib.misc.HttpClient

Page 152: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

getpublic void get(String url, Map addedHeaders, Callback callback) throws IOException

postpublic Response post(String url, String jsonBody) throws IOException

Executes HTTP POST on URL

Parameters:url - URL as StringrequestEntity - Body

Returns:Response

postpublic Response post(String url, Map addedHeaders, String jsonBody) throws IOException

Executes HTTP POST on URL with Headers

Parameters:url - URL as StringrequestEntity - BodyaddedHeaders - HTTP headers

Returns:Response

postpublic void post(String url, Callback callback, String jsonBody) throws IOException

postpublic void post(String url, Map addedHeaders, Callback callback, String jsonBody) throws IOException

B75

org.eclipse.bigiot.lib.misc.HttpClient

Page 153: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

putpublic Response put(String url, String jsonBody) throws IOException

Executes HTTP PUT on URL

Parameters:url - URL as StringrequestEntity - Body

Returns:Response

putpublic Response put(String url, Map addedHeaders, String jsonBody) throws IOException

Executes HTTP PUT on URL with Headers

Parameters:url - URL as StringrequestEntity - BodyaddedHeaders - HTTP headers

Returns:Response

putpublic void put(String url, Callback callback, String jsonBody) throws IOException

putpublic void put(String url, Map addedHeaders, Callback callback, String jsonBody) throws IOException

deletepublic Response delete(String url) throws IOException

Executes HTTP DELETE on URL

Parameters:url - URL as String

B76

org.eclipse.bigiot.lib.misc.HttpClient

Page 154: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Returns:HttpResponse as CompletableFuture

deletepublic Response delete(String url, Map addedHeaders) throws IOException

Executes HTTP DELETE on URL with Headers

Parameters:url - URL as String

Returns:HttpResponse as CompletableFuture

deletepublic void delete(String url, Callback callback) throws IOException

deletepublic void delete(String url, Map addedHeaders, Callback callback) throws IOException

closepublic void close()

getStatuspublic boolean getStatus()

Check if the HttpClient is closed

Returns:boolean if Client close

inputStreamFromPemCertificateFilepublic static ByteArrayInputStream inputStreamFromPemCertificateFile(InputStreampemFileInputStream) throws IOException

B77

org.eclipse.bigiot.lib.misc.HttpClient

Page 155: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

byteArrayFromPemCertificateFilepublic static byte[] byteArrayFromPemCertificateFile(InputStream pemFileInputStream) throws IOException

setDefaultProxypublic static void setDefaultProxy(String httpProxyHost, int port)

setDefaultProxypublic static void setDefaultProxy(String httpProxyHost, int port, String username, String password)

addDefaultProxyBypasspublic static void addDefaultProxyBypass(String host)

removeDefaultProxyBypasspublic static void removeDefaultProxyBypass(String host)

B78

org.eclipse.bigiot.lib.misc.HttpClient

Page 156: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.miscClass Randomjava.lang.Object | +-org.eclipse.bigiot.lib.misc.Random

public class Randomextends Object

Convenience functions for random number generation based on Apache Commons Math

Fields

testpublic static final java.lang.String test

Constant value: TEST

Constructors

Randompublic Random()

Methods

getNextUniformpublic static double getNextUniform(double lower, double upper)

Generates a double in an interval with uniform distribution

Parameters:lower

upper

Returns:

getNextUniformpublic static long getNextUniform(long lower, long upper)

Generates a long in an interval with uniform distribution

Parameters:lower

upper

B79

org.eclipse.bigiot.lib.misc.Random

Page 157: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Returns:

nextBooleanpublic static boolean nextBoolean()

Generates a random boolean

Returns:

getRandomPositionInsidepublic static Location getRandomPositionInside(Area area)

Generates a random location in an spatial area.

Parameters:area

Returns:

getRandomPositionInsidepublic static Location getRandomPositionInside(Area area, int digits)

Generates a random location in an spatial area with a fixed precision

Parameters:area

digits

Returns:

B80

org.eclipse.bigiot.lib.misc.Random

Page 158: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.model

B81

Page 159: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Activationjava.lang.Object | +-org.eclipse.bigiot.lib.model.Activation

public class Activationextends Object

Offering activation

Constructors

Activationpublic Activation()

Activationpublic Activation(Boolean status)

Activationpublic Activation(Boolean status, Long expirationTime)

Methods

getStatuspublic Boolean getStatus()

setStatuspublic void setStatus(Boolean status)

getExpirationTimepublic Long getExpirationTime()

B82

org.eclipse.bigiot.lib.model.Activation

Page 160: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

setExpirationTimepublic void setExpirationTime(Long expirationTime)

toStringpublic String toString()

B83

org.eclipse.bigiot.lib.model.Activation

Page 161: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Areajava.lang.Object | +-org.eclipse.bigiot.lib.model.Area

public class Areaextends Object

Geographical area based on Location

Constructors

Areapublic Area(Location firstCorner, Location secondCorner)

Methods

getSouthWestCornerpublic Location getSouthWestCorner()

getNorthEastCornerpublic Location getNorthEastCorner()

toStringpublic String toString()

B84

org.eclipse.bigiot.lib.model.Area

Page 162: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass BigIotTypesjava.lang.Object | +-org.eclipse.bigiot.lib.model.BigIotTypes

public class BigIotTypesextends Object

Constructors

BigIotTypespublic BigIotTypes()

B85

org.eclipse.bigiot.lib.model.BigIotTypes

Page 163: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass BigIotTypes.PricingModeljava.lang.Object | +- | +-org.eclipse.bigiot.lib.model.BigIotTypes.PricingModel

public static final class BigIotTypes.PricingModelextends Enum

All Implemented Interfaces:Serializable, Comparable

Fields

FREEpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.PricingModel FREE

PER_ACCESSpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.PricingModel PER_ACCESS

PER_MESSAGEpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.PricingModel PER_MESSAGE

PER_MONTHpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.PricingModel PER_MONTH

PER_BYTEpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.PricingModel PER_BYTE

Methods

valuespublic static BigIotTypes.PricingModel[] values()

B86

org.eclipse.bigiot.lib.model.BigIotTypes.PricingModel

Page 164: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

valueOfpublic static BigIotTypes.PricingModel valueOf(String name)

B87

org.eclipse.bigiot.lib.model.BigIotTypes.PricingModel

Page 165: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass BigIotTypes.LicenseTypejava.lang.Object | +- | +-org.eclipse.bigiot.lib.model.BigIotTypes.LicenseType

public static final class BigIotTypes.LicenseTypeextends Enum

All Implemented Interfaces:Serializable, Comparable

Fields

CREATIVE_COMMONSpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.LicenseTypeCREATIVE_COMMONS

OPEN_DATA_LICENSEpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.LicenseTypeOPEN_DATA_LICENSE

NON_COMMERCIAL_DATA_LICENSEpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.LicenseTypeNON_COMMERCIAL_DATA_LICENSE

Methods

valuespublic static BigIotTypes.LicenseType[] values()

valueOfpublic static BigIotTypes.LicenseType valueOf(String name)

B88

org.eclipse.bigiot.lib.model.BigIotTypes.LicenseType

Page 166: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass BigIotTypes.FormatTypejava.lang.Object | +- | +-org.eclipse.bigiot.lib.model.BigIotTypes.FormatType

public static final class BigIotTypes.FormatTypeextends Enum

All Implemented Interfaces:Serializable, Comparable

Fields

FORMAT_JSONLDpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.FormatType FORMAT_JSONLD

FORMAT_XMLpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.FormatType FORMAT_XML

Methods

valuespublic static BigIotTypes.FormatType[] values()

valueOfpublic static BigIotTypes.FormatType valueOf(String name)

B89

org.eclipse.bigiot.lib.model.BigIotTypes.FormatType

Page 167: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass BigIotTypes.EndpointTypejava.lang.Object | +- | +-org.eclipse.bigiot.lib.model.BigIotTypes.EndpointType

public static final class BigIotTypes.EndpointTypeextends Enum

All Implemented Interfaces:Serializable, Comparable

Fields

HTTP_GETpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.EndpointType HTTP_GET

HTTP_POSTpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.EndpointType HTTP_POST

WEBSOCKETpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.EndpointType WEBSOCKET

Methods

valuespublic static BigIotTypes.EndpointType[] values()

valueOfpublic static BigIotTypes.EndpointType valueOf(String name)

B90

org.eclipse.bigiot.lib.model.BigIotTypes.EndpointType

Page 168: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass BigIotTypes.FunctionTypejava.lang.Object | +- | +-org.eclipse.bigiot.lib.model.BigIotTypes.FunctionType

public static final class BigIotTypes.FunctionTypeextends Enum

All Implemented Interfaces:Serializable, Comparable

Fields

ACCESSpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.FunctionType ACCESS

FEEDpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.FunctionType FEED

TASKpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.FunctionType TASK

EVENTpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.FunctionType EVENT

Methods

valuespublic static BigIotTypes.FunctionType[] values()

valueOfpublic static BigIotTypes.FunctionType valueOf(String name)

B91

org.eclipse.bigiot.lib.model.BigIotTypes.FunctionType

Page 169: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass BigIotTypes.AccessInterfaceTypejava.lang.Object | +- | +-org.eclipse.bigiot.lib.model.BigIotTypes.AccessInterfaceType

public static final class BigIotTypes.AccessInterfaceTypeextends Enum

All Implemented Interfaces:Serializable, Comparable

Fields

UNSPECIFIEDpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.AccessInterfaceTypeUNSPECIFIED

BIGIOT_LIBpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.AccessInterfaceTypeBIGIOT_LIB

BIGIOT_PROXYpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.AccessInterfaceTypeBIGIOT_PROXY

EXTERNALpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.AccessInterfaceTypeEXTERNAL

Methods

valuespublic static BigIotTypes.AccessInterfaceType[] values()

B92

org.eclipse.bigiot.lib.model.BigIotTypes.AccessInterfaceType

Page 170: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

valueOfpublic static BigIotTypes.AccessInterfaceType valueOf(String name)

B93

org.eclipse.bigiot.lib.model.BigIotTypes.AccessInterfaceType

Page 171: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass BigIotTypes.FeedTypesjava.lang.Object | +- | +-org.eclipse.bigiot.lib.model.BigIotTypes.FeedTypes

public static final class BigIotTypes.FeedTypesextends Enum

All Implemented Interfaces:Serializable, Comparable

Fields

ASYNCpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.FeedTypes ASYNC

SYNCpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.FeedTypes SYNC

Methods

valuespublic static BigIotTypes.FeedTypes[] values()

valueOfpublic static BigIotTypes.FeedTypes valueOf(String name)

B94

org.eclipse.bigiot.lib.model.BigIotTypes.FeedTypes

Page 172: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass BigIotTypes.ResponseStatusjava.lang.Object | +- | +-org.eclipse.bigiot.lib.model.BigIotTypes.ResponseStatus

public static final class BigIotTypes.ResponseStatusextends Enum

All Implemented Interfaces:Serializable, Comparable

Fields

okaypublic static final org.eclipse.bigiot.lib.model.BigIotTypes.ResponseStatus okay

failurepublic static final org.eclipse.bigiot.lib.model.BigIotTypes.ResponseStatus failure

Methods

valuespublic static BigIotTypes.ResponseStatus[] values()

valueOfpublic static BigIotTypes.ResponseStatus valueOf(String name)

getCodepublic int getCode()

B95

org.eclipse.bigiot.lib.model.BigIotTypes.ResponseStatus

Page 173: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass BigIotTypes.MimeTypejava.lang.Object | +- | +-org.eclipse.bigiot.lib.model.BigIotTypes.MimeType

public static final class BigIotTypes.MimeTypeextends Enum

All Implemented Interfaces:Serializable, Comparable

Fields

APPLICATION_XMLpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.MimeType APPLICATION_XML

APPLICATION_JSONpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.MimeType APPLICATION_JSON

TEXT_PLAINpublic static final org.eclipse.bigiot.lib.model.BigIotTypes.MimeType TEXT_PLAIN

Methods

valuespublic static BigIotTypes.MimeType[] values()

valueOfpublic static BigIotTypes.MimeType valueOf(String name)

equalsNamepublic boolean equalsName(String other)

B96

org.eclipse.bigiot.lib.model.BigIotTypes.MimeType

Page 174: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

toStringpublic String toString()

B97

org.eclipse.bigiot.lib.model.BigIotTypes.MimeType

Page 175: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass ComplexObjectMembersjava.lang.Object | +-org.eclipse.bigiot.lib.model.ComplexObjectMembers

public class ComplexObjectMembersextends Object

Constructors

ComplexObjectMemberspublic ComplexObjectMembers(String name, RDFType rdfType, String valueType)

ComplexObjectMemberspublic ComplexObjectMembers(String name, RDFType rdfType, ComplexObjectMembers members)

ComplexObjectMemberspublic ComplexObjectMembers()

Methods

addInputDatapublic ComplexObjectMembers addInputData(String name, RDFType rdfType, String valueType)

addInputDatapublic ComplexObjectMembers addInputData(String name, RDFType rdfType, ComplexObjectMembers members)

B98

org.eclipse.bigiot.lib.model.ComplexObjectMembers

Page 176: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

addOutputDatapublic ComplexObjectMembers addOutputData(String name, RDFType rdfType, String valueType)

addOutputDatapublic ComplexObjectMembers addOutputData(String name, RDFType rdfType, ComplexObjectMembers members)

asIoDatapublic IOData asIoData()

toStringpublic String toString()

B99

org.eclipse.bigiot.lib.model.ComplexObjectMembers

Page 177: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Descriptionjava.lang.Object | +-org.eclipse.bigiot.lib.model.Description

public abstract class Descriptionextends Objectimplements Cloneable

Description element in Offering Description

All Implemented Interfaces:Cloneable

Direct Known Subclasses:Information

Constructors

Descriptionpublic Description(String name, String domain, RDFType rdfType)

Methods

getNamepublic String getName()

getDomainpublic String getDomain()

getRdfTypepublic RDFType getRdfType()

toStringpublic String toString()

B100

org.eclipse.bigiot.lib.model.Description

Page 178: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

clonepublic abstract Description clone()

B101

org.eclipse.bigiot.lib.model.Description

Page 179: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass EndPointjava.lang.Object | +-org.eclipse.bigiot.lib.model.EndPoint

public class EndPointextends Object

Endpoint Information of Offering

Constructors

EndPointpublic EndPoint()

EndPointpublic EndPoint(BigIotTypes.EndpointType endpointType, BigIotTypes.AccessInterfaceType accessInterfaceType, String uri)

EndPointpublic EndPoint(String endpointType, String accessInterfaceType, String uri)

EndPointpublic EndPoint(String uri, String endpointType, String accessInterfaceType, String acceptType, String contentType)

EndPointpublic EndPoint(String uri, BigIotTypes.EndpointType endpointType, BigIotTypes.AccessInterfaceType accessInterfaceType, BigIotTypes.MimeType acceptType, BigIotTypes.MimeType contentType)

B102

org.eclipse.bigiot.lib.model.EndPoint

Page 180: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Methods

getUripublic String getUri()

setUripublic void setUri(String uri)

getEndpointTypepublic BigIotTypes.EndpointType getEndpointType()

setEndpointTypepublic void setEndpointType(BigIotTypes.EndpointType endpointType)

getAccessInterfaceTypepublic BigIotTypes.AccessInterfaceType getAccessInterfaceType()

setAccessInterfaceTypepublic void setAccessInterfaceType(BigIotTypes.AccessInterfaceTypeaccessInterfaceType)

toStringpublic String toString()

getAcceptTypepublic BigIotTypes.MimeType getAcceptType()

setAcceptTypepublic void setAcceptType(BigIotTypes.MimeType acceptType)

B103

org.eclipse.bigiot.lib.model.EndPoint

Page 181: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

getContentTypepublic BigIotTypes.MimeType getContentType()

setContentTypepublic void setContentType(BigIotTypes.MimeType contentType)

isSecuredpublic boolean isSecured()

B104

org.eclipse.bigiot.lib.model.EndPoint

Page 182: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Informationjava.lang.Object | +- | +-org.eclipse.bigiot.lib.model.Information

public class Informationextends Description

Information element

All Implemented Interfaces:Cloneable

Constructors

Informationpublic Information(String name, String domain, RDFType rdfType)

Informationpublic Information(String name, RDFType rdfType)

Informationpublic Information(String name, String rdfTypeUri)

Informationpublic Information(String name, String rdfTypeName, String rdfTypeUri)

Methods

clonepublic Description clone()

B105

org.eclipse.bigiot.lib.model.Information

Page 183: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass IODatajava.lang.Object | +-org.eclipse.bigiot.lib.model.IOData

public class IODataextends Object

Input parameter element

Constructors

IODatapublic IOData()

IODatapublic IOData(String name, RDFType rdfType, String valueType, List members)

IODatapublic IOData(String name, RDFType rdfType, String valueType)

IODatapublic IOData(String name, RDFType rdfType)

IODatapublic IOData(String name, RDFType rdfType, String valueType, IOData.ParameterType parameterType)

Methods

B106

org.eclipse.bigiot.lib.model.IOData

Page 184: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

getNamepublic String getName()

setNamepublic void setName(String name)

getRdfTypepublic RDFType getRdfType()

setRdfTypepublic void setRdfType(RDFType rdfType)

getMemberspublic List getMembers()

setMemberspublic void setMembers(List members)

getValueTypepublic String getValueType()

setValueTypepublic void setValueType(String valueType)

getParameterTypepublic IOData.ParameterType getParameterType()

setParameterTypepublic void setParameterType(IOData.ParameterType parameterType)

B107

org.eclipse.bigiot.lib.model.IOData

Page 185: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

toStringpublic String toString()

createMemberspublic static ComplexObjectMembers createMembers()

B108

org.eclipse.bigiot.lib.model.IOData

Page 186: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass IOData.ParameterTypejava.lang.Object | +- | +-org.eclipse.bigiot.lib.model.IOData.ParameterType

public static final class IOData.ParameterTypeextends Enum

All Implemented Interfaces:Serializable, Comparable

Fields

QUERY_PARAMETERpublic static final org.eclipse.bigiot.lib.model.IOData.ParameterType QUERY_PARAMETER

PATH_PARAMETERpublic static final org.eclipse.bigiot.lib.model.IOData.ParameterType PATH_PARAMETER

BODY_PARAMETERpublic static final org.eclipse.bigiot.lib.model.IOData.ParameterType BODY_PARAMETER

TEMPLATEpublic static final org.eclipse.bigiot.lib.model.IOData.ParameterType TEMPLATE

Methods

valuespublic static IOData.ParameterType[] values()

valueOfpublic static IOData.ParameterType valueOf(String name)

B109

org.eclipse.bigiot.lib.model.IOData.ParameterType

Page 187: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Locationjava.lang.Object | +-org.eclipse.bigiot.lib.model.Location

public class Locationextends Object

Location as a 2D Location based on latitude and longitude

Fields

latitudepublic double latitude

longitudepublic double longitude

Constructors

Locationpublic Location()

Locationpublic Location(double latitude, double longitude)

Methods

getLatitudepublic double getLatitude()

getLongitudepublic double getLongitude()

B110

org.eclipse.bigiot.lib.model.Location

Page 188: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

toStringpublic String toString()

B111

org.eclipse.bigiot.lib.model.Location

Page 189: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Moneyjava.lang.Object | +-org.eclipse.bigiot.lib.model.Money

public class Moneyextends Object

Money consisting of value and currency

Fields

EUROpublic static final java.lang.String EURO

Constant value: EUR

USDOLLARpublic static final java.lang.String USDOLLAR

Constant value: USD

Constructors

Moneypublic Money()

Moneypublic Money(double amount, String currency)

Methods

getAmountpublic double getAmount()

setAmountpublic void setAmount(double amount)

B112

org.eclipse.bigiot.lib.model.Money

Page 190: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

getCurrencypublic String getCurrency()

setCurrencypublic void setCurrency(String currency)

toStringpublic String toString()

B113

org.eclipse.bigiot.lib.model.Money

Page 191: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Pricejava.lang.Object | +-org.eclipse.bigiot.lib.model.Price

public class Priceextends Objectimplements Comparable

Price consisting of value and currency

All Implemented Interfaces:Comparable

Constructors

Pricepublic Price()

Pricepublic Price(Money money, BigIotTypes.PricingModel pricingModel)

Pricepublic Price(double amount, String currency, BigIotTypes.PricingModel pricingModel)

Pricepublic Price(double amount, String currency)

Methods

setPricingModelpublic void setPricingModel(BigIotTypes.PricingModel pricingModel)

B114

org.eclipse.bigiot.lib.model.Price

Page 192: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

getPricingModelpublic BigIotTypes.PricingModel getPricingModel()

setMoneypublic void setMoney(Money money)

getMoneypublic Money getMoney()

getAmountpublic double getAmount()

setAmountpublic void setAmount(double amount)

getCurrencypublic String getCurrency()

setCurrencypublic void setCurrency(String currency)

compareTopublic int compareTo(Price o)

toStringpublic String toString()

B115

org.eclipse.bigiot.lib.model.Price

Page 193: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Price.Eurosjava.lang.Object | +-org.eclipse.bigiot.lib.model.Price.Euros

public static class Price.Eurosextends Object

Factory class for prices in EUR

Constructors

Eurospublic Euros()

Methods

amountpublic static Money amount(double euros)

B116

org.eclipse.bigiot.lib.model.Price.Euros

Page 194: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Price.USDollarsjava.lang.Object | +-org.eclipse.bigiot.lib.model.Price.USDollars

public static class Price.USDollarsextends Object

Factory class for prices in USD

Constructors

USDollarspublic USDollars()

Methods

amountpublic static Money amount(double dollars)

B117

org.eclipse.bigiot.lib.model.Price.USDollars

Page 195: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass RDFTypejava.lang.Object | +-org.eclipse.bigiot.lib.model.RDFType

public class RDFTypeextends Objectimplements Cloneable

RDF Type with name and URI

All Implemented Interfaces:Cloneable

Constructors

RDFTypepublic RDFType()

RDFTypepublic RDFType(String name, String uri)

RDFTypepublic RDFType(String uri)

Methods

getNamepublic String getName()

setNamepublic void setName(String name)

getUripublic String getUri()

B118

org.eclipse.bigiot.lib.model.RDFType

Page 196: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

setUripublic void setUri(String uri)

toStringpublic String toString()

hashCodepublic int hashCode()

equalspublic boolean equals(Object obj)

clonepublic RDFType clone()

B119

org.eclipse.bigiot.lib.model.RDFType

Page 197: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Regionjava.lang.Object | +-org.eclipse.bigiot.lib.model.Region

public class Regionextends Object

Class for defining spatial region

Constructors

Regionpublic Region()

Regionpublic Region(String lng, String lat, int r)

Regionpublic Region(String city)

Regionpublic Region(Region.City city)

Methods

getCitypublic Region.City getCity()

setCitypublic void setCity(Region.City city)

B120

org.eclipse.bigiot.lib.model.Region

Page 198: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

setCitypublic void setCity(String city)

toRegistrationStringpublic String toRegistrationString()

toStringpublic String toString()

B121

org.eclipse.bigiot.lib.model.Region

Page 199: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Region.Addressjava.lang.Object | +-org.eclipse.bigiot.lib.model.Region.Address

public class Region.Addressextends Object

Fields

steetpublic java.lang.String steet

numberpublic java.lang.String number

postCodepublic java.lang.String postCode

citypublic java.lang.String city

statepublic java.lang.String state

countrypublic java.lang.String country

Constructors

B122

org.eclipse.bigiot.lib.model.Region.Address

Page 200: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Addresspublic Address()

B123

org.eclipse.bigiot.lib.model.Region.Address

Page 201: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Region.GeoLocjava.lang.Object | +-org.eclipse.bigiot.lib.model.Region.GeoLoc

public class Region.GeoLocextends Object

Fields

lngpublic java.lang.String lng

latpublic java.lang.String lat

radiuspublic int radius

B124

org.eclipse.bigiot.lib.model.Region.GeoLoc

Page 202: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Region.Cityjava.lang.Object | +-org.eclipse.bigiot.lib.model.Region.City

public class Region.Cityextends Object

Fields

namepublic java.lang.String name

Methods

getNamepublic String getName()

setNamepublic void setName(String name)

B125

org.eclipse.bigiot.lib.model.Region.City

Page 203: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass Subscriptionjava.lang.Object | +-org.eclipse.bigiot.lib.model.Subscription

public class Subscriptionextends Object

Subscription

Constructors

Subscriptionpublic Subscription()

Methods

getIdpublic String getId()

setIdpublic void setId(String id)

getAccessTokenpublic String getAccessToken()

setAccessTokenpublic void setAccessToken(String accessToken)

toStringpublic String toString()

B126

org.eclipse.bigiot.lib.model.Subscription

Page 204: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.modelClass ValueTypejava.lang.Object | +-org.eclipse.bigiot.lib.model.ValueType

public class ValueTypeextends Object

Fields

NUMBERpublic static final java.lang.String NUMBER

Constant value: number

BOOLEANpublic static final java.lang.String BOOLEAN

Constant value: boolean

DATEpublic static final java.lang.String DATE

Constant value: date

DATETIMEpublic static final java.lang.String DATETIME

Constant value: datetime

TEXTpublic static final java.lang.String TEXT

Constant value: text

TIMEpublic static final java.lang.String TIME

Constant value: time

B127

org.eclipse.bigiot.lib.model.ValueType

Page 205: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Constructors

ValueTypepublic ValueType()

B128

org.eclipse.bigiot.lib.model.ValueType

Page 206: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.offering

B129

Page 207: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass AccessParametersjava.lang.Object | +-org.eclipse.bigiot.lib.offering.AccessParameters

public class AccessParametersextends Object

Container for parameters for offering data access. AccessParameters supports name/value pair as well as type/value pairs

Constructors

AccessParameterspublic AccessParameters()

Methods

createpublic static AccessParameters create()

Creates an empty parameter container

Returns:

addNameValuepublic AccessParameters addNameValue(String parameterName, Object value)

Adds a name/value pair

Parameters:value

Returns:

addRdfTypeValuepublic AccessParameters addRdfTypeValue(RDFType parameterType, Object value)

Adds a (RDF-)type/value pair

Parameters:parameterType

value

B130

org.eclipse.bigiot.lib.offering.AccessParameters

Page 208: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Returns:

addRdfTypeValuepublic AccessParameters addRdfTypeValue(String rdfUri, Object value)

Adds a (RDF-)type/value pair as URI

Parameters:parameterType

value

Returns:

toNameMappublic Map toNameMap(List inputData, int depth) throws IllegalAccessParameterException

Returns a map with name/value pairs and takes care that it is consistent according to a Offering Description parameterlist

Parameters:inputData - Input parameter list of Offering Description

Returns:

Throws:IllegalAccessParameterException

createArraypublic static AccessParametersArray createArray()

getParametersForEncodingpublic static Map getParametersForEncoding(Map parametersMap, List inputData, IOData.ParameterType parameterType)

Select those Access Parameters in name map which are marked with the specified parameterType (URL, query, body, ortemplate) in ioData. Template marked parameters will be later replace a placeholder in the template (by value). Thereturn map is here the placeholder (from iodata) plus the value object.

Parameters:parametersMap

inputData

parameterType

Returns:

B131

org.eclipse.bigiot.lib.offering.AccessParameters

Page 209: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass AccessParametersArrayjava.lang.Object | +-org.eclipse.bigiot.lib.offering.AccessParametersArray

public class AccessParametersArrayextends Object

Fields

listpublic java.util.LinkedList list

Constructors

AccessParametersArraypublic AccessParametersArray()

Methods

addValuepublic AccessParametersArray addValue(Object value)

Adds a value

Parameters:value

Returns:

getListpublic LinkedList getList()

Returns the parameter array

Returns:

B132

org.eclipse.bigiot.lib.offering.AccessParametersArray

Page 210: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass AccessParametersTuplejava.lang.Object | +-org.eclipse.bigiot.lib.offering.AccessParametersTuple

public abstract class AccessParametersTupleextends Object

Container Element of AccessParameters

Direct Known Subclasses:Type, Name

Constructors

AccessParametersTuplepublic AccessParametersTuple(Object value)

Methods

getValuepublic Object getValue()

B133

org.eclipse.bigiot.lib.offering.AccessParametersTuple

Page 211: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass AccessParametersTuple.Namejava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.AccessParametersTuple.Name

public static class AccessParametersTuple.Nameextends AccessParametersTuple

Name/value based parameter tuple

Constructors

Namepublic Name(String name, Object value)

Methods

getNamepublic String getName()

toStringpublic String toString()

B134

org.eclipse.bigiot.lib.offering.AccessParametersTuple.Name

Page 212: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass AccessParametersTuple.Typejava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.AccessParametersTuple.Type

public static class AccessParametersTuple.Typeextends AccessParametersTuple

Type/value base parameter tuple

Constructors

Typepublic Type(RDFType rdfType, Object value)

Methods

getRdfTypepublic RDFType getRdfType()

toStringpublic String toString()

B135

org.eclipse.bigiot.lib.offering.AccessParametersTuple.Type

Page 213: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass AccessResponsejava.lang.Object | +-org.eclipse.bigiot.lib.offering.AccessResponse

public class AccessResponseextends Object

Response of an BIG IoT Offering

Constructors

AccessResponsepublic AccessResponse(String message, OfferingDescription offeringDescription)

AccessResponsepublic AccessResponse(String message, OfferingDescription offeringDescription, BigIotTypes.MimeType contentType)

Methods

toStringpublic String toString()

asJsonNodepublic JsonNode asJsonNode()

Returns response as a data structure for traversing

Returns:

getBodypublic String getBody()

Returns response as a Json String

B136

org.eclipse.bigiot.lib.offering.AccessResponse

Page 214: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

getStatuspublic BigIotTypes.ResponseStatus getStatus()

Returns response status

Returns:ResponseStatus

mappublic List map(Class pojoClass)

Maps the offering response to pojo class

Parameters:pojoClass

Returns:

mappublic List map(Class pojoClass, OutputMapping outputMapping)

Maps the offering response according to an output mapping

Parameters:pojoClass

outputMapping

Returns:

getPrettyPrintpublic String getPrettyPrint()

remapJsonpublic static String remapJson(String jsonString, OutputMapping outputMapping) throws IOException

Map json paths according to outputMapping

Parameters:jsonString

outputMapping

Returns:

Throws:IOException

B137

org.eclipse.bigiot.lib.offering.AccessResponse

Page 215: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass AccessResponse.MappingIoDataTuplejava.lang.Object | +-org.eclipse.bigiot.lib.offering.AccessResponse.MappingIoDataTuple

public class AccessResponse.MappingIoDataTupleextends Object

Constructors

MappingIoDataTuplepublic MappingIoDataTuple(OutputMappingTuple mapping, IOData ioData)

Methods

getMappingpublic OutputMappingTuple getMapping()

getIoDatapublic IOData getIoData()

B138

org.eclipse.bigiot.lib.offering.AccessResponse.MappingIoDataTuple

Page 216: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass DeployedOfferingjava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.DeployedOffering

public class DeployedOfferingextends RegisteredOffering

Constructors

DeployedOfferingpublic DeployedOffering(RegistrableOfferingDescription offeringDescription, EmbededdedRouteBasedServer server, AccessRequestHandler accessRequestHandler)

Methods

deregisterpublic void deregister()

Deregisters Offering from the marketplace

undeploypublic void undeploy()

deploypublic void deploy()

B139

org.eclipse.bigiot.lib.offering.DeployedOffering

Page 217: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringInterface IOffering

public interface IOfferingextends IOfferingCore

All Superinterfaces:IOfferingCore

All Known Implementing Classes:Offering

Methods

accessOneTimepublic abstract CompletableFuture accessOneTime(AccessParameters accessParameters)

B140

org.eclipse.bigiot.lib.offering.IOffering

Page 218: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringInterface IOfferingCore

public interface IOfferingCoreextends

Interface for an Offering implementation. It provides access to the operations of the Offering

All Subinterfaces:IOffering

All Known Implementing Classes:OfferingCore

Methods

accessOneTimepublic abstract Future accessOneTime(AccessParameters accessParameters) throws AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner asynchronously. Since the return value is a Future, ablocking behavior can be achieved on calling .get() on the return value.

Parameters:accessParameters

Returns:

Throws:AccessToNonActivatedOfferingExceptionAccessToNonSubscribedOfferingException

accessOneTimepublic abstract void accessOneTime(AccessParameters accessParameters, AccessResponseSuccessHandler onSuccess, AccessResponseFailureHandler onFailure) throws IllegalAccessParameterException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner. Method call is nonblocking.

Parameters:accessParameters

onSuccess

onFailure

Throws:IllegalAccessParameterExceptionAccessToNonActivatedOfferingExceptionAccessToNonSubscribedOfferingException

B141

org.eclipse.bigiot.lib.offering.IOfferingCore

Page 219: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

accessOneTimepublic abstract void accessOneTime(AccessParameters accessParameters, AccessResponseSuccessHandler onSuccess) throws IllegalAccessParameterException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner. Method call is nonblocking.

Parameters:accessParameters

onSuccess

Throws:IllegalAccessParameterExceptionAccessToNonActivatedOfferingExceptionAccessToNonSubscribedOfferingException

accessContinuouspublic abstract AccessFeed accessContinuous(AccessParameters accessParameters, long lifetimeMillis, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure) throws IOException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering continuously as a feed. Lifecycle operations are performed on the returned object. It istaken care that the feed setup is correctly according to the feed capabilities of the Offering. Multiple calls e.g. withvarying parameter set is supported in order to create multiple feeds for the same Offering.

Parameters:accessParameters

lifetimeMillis

onSuccess

onFailure

Returns:

Throws:IOException

AccessToNonActivatedOfferingExceptionAccessToNonSubscribedOfferingException

accessContinuouspublic abstract AccessFeed accessContinuous(AccessParameters accessParameters, long lifetimeMillis, long intervalMillis, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure) throws IOException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

B142

org.eclipse.bigiot.lib.offering.IOfferingCore

Page 220: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Retrieves data from an Offering continuously as a feed where an interval has to be specified. Lifecycle operations areperformed on the returned object. It is taken care that the feed setup is correctly according to the feed capabilities of theOffering. Multiple calls e.g. with varying parameter set is supported in order to create multiple feeds for the sameOffering.

Parameters:accessParameters

lifetimeMillis

intervalMillis

onSuccess

onFailure

Returns:

Throws:IOException

AccessToNonActivatedOfferingExceptionAccessToNonSubscribedOfferingException

getMyAccessFeedspublic abstract List getMyAccessFeeds()

Returns a list of all feed subscriptions

Returns:List of feed subscriptions

unsubscribepublic abstract void unsubscribe()

Unsubscribes an offering an deactivates automatic renewal.

unsubscribeBlockingpublic abstract void unsubscribeBlocking()

Unsubscribes an offering an deactivates automatic renewal.

B143

org.eclipse.bigiot.lib.offering.IOfferingCore

Page 221: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass Offeringjava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.Offering

public abstract class Offeringextends OfferingCoreimplements IOfferingCore, IOffering

All Implemented Interfaces:IOffering, IOfferingCore

Direct Known Subclasses:OfferingByExternal, OfferingByLib

Constructors

Offeringpublic Offering(SubscribableOfferingDescription offeringDescription, String offeringToken)

Methods

accessOneTimepublic abstract CompletableFuture accessOneTime(AccessParameters accessParameters)

Retrieves data from an Offering in a request/response manner asynchronously. Since the return value is aCompletableFuture, a blocking behavior can be achieved on calling .get() on the return value.

getOfferingDescriptionpublic SubscribableOfferingDescription getOfferingDescription()

Returns corresponding Offering Description

B144

org.eclipse.bigiot.lib.offering.Offering

Page 222: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass OfferingByExternaljava.lang.Object | +- | +- | +-org.eclipse.bigiot.lib.offering.OfferingByExternal

public class OfferingByExternalextends Offering

All Implemented Interfaces:IOfferingCore, IOffering

Constructors

OfferingByExternalpublic OfferingByExternal(SubscribableOfferingDescription offeringDescription)

Methods

accessOneTimepublic CompletableFuture accessOneTime(AccessParameters accessParameters)

Retrieves data from an Offering in a request/response manner asynchronously. Since the return value is aCompletableFuture, a blocking behavior can be achieved on calling .get() on the return value.

Parameters:accessParameters - Input parameter container

Returns:CompletableFuture of the Offering response

Throws:AccessToNonSubscribedOfferingExceptionSubscriptionToNonActivatedOfferingException

accessOneTimepublic void accessOneTime(AccessParameters accessParameters, AccessResponseSuccessHandler onSuccess, AccessResponseFailureHandler onFailure) throws IllegalAccessParameterException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner. Method call is nonblocking.

B145

org.eclipse.bigiot.lib.offering.OfferingByExternal

Page 223: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

accessOneTimepublic void accessOneTime(AccessParameters accessParameters, AccessResponseSuccessHandler onSuccess) throws IllegalAccessParameterException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner. Method call is nonblocking.

accessContinuouspublic AccessFeed accessContinuous(AccessParameters accessParameters, long lifetimeMillis, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure) throws IOException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering continuously as a feed. Lifecycle operations are performed on the returned object. It istaken care that the feed setup is correctly according to the feed capabilities of the Offering. Multiple calls e.g. withvarying parameter set is supported in order to create multiple feeds for the same Offering.

accessContinuouspublic AccessFeed accessContinuous(AccessParameters accessParameters, long lifetimeMillis, long intervalMillis, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure) throws IOException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException, RuntimeException

Retrieves data from an Offering continuously as a feed. Lifecycle operations are performed on the returned object. It istaken care that the feed setup is correctly according to the feed capabilities of the Offering. Multiple calls e.g. withvarying parameter set is supported in order to create multiple feeds for the same Offering.

getMyAccessFeedspublic List getMyAccessFeeds()

Returns a list of all feed subscriptions

unsubscribepublic void unsubscribe()

Terminates the subscription to the Offering. Don't confuse it with a termination of a subscription to a feed. It isperformed on the specific feed object.

unsubscribeBlockingpublic void unsubscribeBlocking()

B146

org.eclipse.bigiot.lib.offering.OfferingByExternal

Page 224: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass OfferingByLibjava.lang.Object | +- | +- | +-org.eclipse.bigiot.lib.offering.OfferingByLib

public class OfferingByLibextends Offering

Implementation for Offering running in Integration mode 1,2 and 4. The A1 interface is provided by the BIG IoT provider Lib.Accordingly the transformation of the call semantics to the legacy platform semantics is performed by the Provider Lib.

All Implemented Interfaces:IOfferingCore, IOffering

Methods

accessOneTimepublic CompletableFuture accessOneTime(AccessParameters accessParameters)

Retrieves data from an Offering in a request/response manner asynchronously. Since the return value is aCompletableFuture, a blocking behavior can be achieved on calling .get() on the return value.

accessOneTimepublic void accessOneTime(AccessParameters accessParameters, AccessResponseSuccessHandler onSuccess, AccessResponseFailureHandler onFailure) throws IllegalAccessParameterException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner. Method call is nonblocking.

accessOneTimepublic void accessOneTime(AccessParameters accessParameters, AccessResponseSuccessHandler onSuccess) throws IllegalAccessParameterException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner. Method call is nonblocking.

B147

org.eclipse.bigiot.lib.offering.OfferingByLib

Page 225: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

accessContinuouspublic AccessFeed accessContinuous(AccessParameters accessParameters, long lifetimeMillis, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure) throws AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException, IOException

Retrieves data from an Offering continuously as a feed. Lifecycle operations are performed on the returned object. It istaken care that the feed setup is correctly according to the feed capabilities of the Offering. Multiple calls e.g. withvarying parameter set is supported in order to create multiple feeds for the same Offering.

accessContinuouspublic AccessFeed accessContinuous(AccessParameters accessParameters, long lifetimeMillis, long intervalMillis, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure) throws AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException, IOException, RuntimeException

Retrieves data from an Offering continuously as a feed where an interval has to be specified. Lifecycle operations areperformed on the returned object. It is taken care that the feed setup is correctly according to the feed capabilities of theOffering. Multiple calls e.g. with varying parameter set is supported in order to create multiple feeds for the sameOffering.

unsubscribepublic void unsubscribe()

Terminates the subscription to the Offering. Don't confuse it with a termination of a subscription to a feed. It isperformed on the specific feed object.

unsubscribeBlockingpublic void unsubscribeBlocking()

getMyAccessFeedspublic List getMyAccessFeeds()

Returns a list of all feed subscriptions

terminatepublic void terminate()

Unsubscribes an offering an deactivates automatic renewal

B148

org.eclipse.bigiot.lib.offering.OfferingByLib

Page 226: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass OfferingCorejava.lang.Object | +-org.eclipse.bigiot.lib.offering.OfferingCore

public abstract class OfferingCoreextends Objectimplements IOfferingCore

All Implemented Interfaces:IOfferingCore

Direct Known Subclasses:OfferingCoreByLib, Offering

Constructors

OfferingCorepublic OfferingCore(SubscribableOfferingDescriptionCore offeringDescription, String offeringToken)

Methods

accessOneTimepublic abstract Future accessOneTime(AccessParameters accessParameters) throws AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner asynchronously. Since the return value is a Future, ablocking behavior can be achieved on calling .get() on the return value.

accessOneTimepublic abstract void accessOneTime(AccessParameters accessParameters, AccessResponseSuccessHandler onSuccess, AccessResponseFailureHandler onFailure) throws IllegalAccessParameterException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner. Method call is nonblocking.

accessOneTimepublic abstract void accessOneTime(AccessParameters accessParameters, AccessResponseSuccessHandler onSuccess) throws IllegalAccessParameterException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

B149

org.eclipse.bigiot.lib.offering.OfferingCore

Page 227: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Retrieves data from an Offering in a request/response manner. Method call is nonblocking.

accessContinuouspublic abstract AccessFeed accessContinuous(AccessParameters accessParameters, long lifetimeMillis, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure) throws IOException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering continuously as a feed. Lifecycle operations are performed on the returned object. It istaken care that the feed setup is correctly according to the feed capabilities of the Offering. Multiple calls e.g. withvarying parameter set is supported in order to create multiple feeds for the same Offering.

Throws:AccessToNonSubscribedOfferingExceptionAccessToNonActivatedOfferingException

accessContinuouspublic abstract AccessFeed accessContinuous(AccessParameters accessParameters, long lifetimeMillis, long intervalMillis, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure) throws IOException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException, RuntimeException

Retrieves data from an Offering continuously as a feed. Lifecycle operations are performed on the returned object. It istaken care that the feed setup is correctly according to the feed capabilities of the Offering. Multiple calls e.g. withvarying parameter set is supported in order to create multiple feeds for the same Offering.

getMyAccessFeedspublic abstract List getMyAccessFeeds()

Returns a list of all feed subscriptions

unsubscribepublic abstract void unsubscribe()

Terminates the subscription to the Offering. Don't confuse it with a termination of a subscription to a feed. It isperformed on the specific feed object.

unsubscribeBlockingpublic abstract void unsubscribeBlocking()

getOfferingTokenpublic String getOfferingToken()

B150

org.eclipse.bigiot.lib.offering.OfferingCore

Page 228: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

setOfferingTokenpublic void setOfferingToken(String offeringToken)

getOfferingDescriptionpublic SubscribableOfferingDescriptionCore getOfferingDescription()

Returns Offering Description

B151

org.eclipse.bigiot.lib.offering.OfferingCore

Page 229: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass OfferingCoreByLibjava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.OfferingCoreByLib

public class OfferingCoreByLibextends OfferingCore

Implementation for Offering running in Integration mode 1,2 and 4. The A1 interface is provided by the BIG IoT provider Lib.Accordingly the transformation of the call semantics to the legacy platform semantics is performed by the Provider Lib.

All Implemented Interfaces:IOfferingCore

Constructors

OfferingCoreByLibpublic OfferingCoreByLib(SubscribableOfferingDescriptionCore offeringDescription, String offeringToken)

Methods

accessOneTimepublic Future accessOneTime(AccessParameters accessParameters) throws AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner asynchronously. Since the return value is a Future, ablocking behavior can be achieved on calling .get() on the return value.

accessOneTimepublic void accessOneTime(AccessParameters accessParameters, AccessResponseSuccessHandler onAccessSuccess, AccessResponseFailureHandler onAccessFailure) throws IllegalAccessParameterException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner. Method call is nonblocking.

accessOneTimepublic void accessOneTime(AccessParameters accessParameters, AccessResponseSuccessHandler onSuccess) throws IllegalAccessParameterException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering in a request/response manner. Method call is nonblocking.

B152

org.eclipse.bigiot.lib.offering.OfferingCoreByLib

Page 230: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

accessContinuouspublic AccessFeed accessContinuous(AccessParameters accessParameters, long lifetimeMillis, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure) throws AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException, IOException

Retrieves data from an Offering continuously as a feed. Lifecycle operations are performed on the returned object. It istaken care that the feed setup is correctly according to the feed capabilities of the Offering. Multiple calls e.g. withvarying parameter set is supported in order to create multiple feeds for the same Offering.

accessContinuouspublic AccessFeed accessContinuous(AccessParameters accessParameters, long lifetimeMillis, long intervalMillis, FeedNotificationSuccessHandler onSuccess, FeedNotificationFailureHandler onFailure) throws RuntimeException, AccessToNonActivatedOfferingException, AccessToNonSubscribedOfferingException

Retrieves data from an Offering continuously as a feed where an interval has to be specified. Lifecycle operations areperformed on the returned object. It is taken care that the feed setup is correctly according to the feed capabilities of theOffering. Multiple calls e.g. with varying parameter set is supported in order to create multiple feeds for the sameOffering.

getMyAccessFeedspublic List getMyAccessFeeds()

Returns a list of all feed subscriptions

unsubscribepublic void unsubscribe()

Unsubscribes an offering an deactivates automatic renewal.

unsubscribeBlockingpublic void unsubscribeBlocking()

Unsubscribes an offering an deactivates automatic renewal.

B153

org.eclipse.bigiot.lib.offering.OfferingCoreByLib

Page 231: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass OfferingDescriptionjava.lang.Object | +-org.eclipse.bigiot.lib.offering.OfferingDescription

public class OfferingDescriptionextends Object

Pure data object representing offering description

Direct Known Subclasses:RegistrableOfferingDescription, SubscribableOfferingDescriptionCore

Constructors

OfferingDescriptionpublic OfferingDescription()

OfferingDescriptionpublic OfferingDescription(String localId, BigIotClientId providerId)

Creates offering description with local ID and provider ID.

Parameters:localId

providerId

Methods

getIdpublic String getId()

Returns offering ID generated by marketplace

Returns:

setIdpublic void setId(String id)

Overrides offering ID generated by marketplace

getNamepublic String getName()

B154

org.eclipse.bigiot.lib.offering.OfferingDescription

Page 232: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Returns offering name

setNamepublic void setName(String name)

Overrides offering name

getRdfTypepublic RDFType getRdfType()

Returns rdf type category of offering

setRdfTypepublic void setRdfType(RDFType rdfType)

Overrides rdf type category of offering

getProviderIdpublic String getProviderId()

setProviderIdpublic void setProviderId(String providerId)

getLocalIdpublic String getLocalId()

Returns local id used for internal purposes

setLocalIdpublic void setLocalId(String localId)

Overrides local id

getDescriptionpublic Description getDescription()

setDescriptionpublic void setDescription(Description description)

B155

org.eclipse.bigiot.lib.offering.OfferingDescription

Page 233: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

getEndpointspublic List getEndpoints()

setEndpointspublic void setEndpoints(List endpoints)

addEndpointpublic void addEndpoint(EndPoint endpoint)

getRegionpublic RegionFilter getRegion()

setRegionpublic void setRegion(RegionFilter region)

getPricepublic Price getPrice()

setPricepublic void setPrice(Price price)

getLicensepublic BigIotTypes.LicenseType getLicense()

setLicensepublic void setLicense(BigIotTypes.LicenseType license)

getOfferingpublic String getOffering()

B156

org.eclipse.bigiot.lib.offering.OfferingDescription

Page 234: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

setOfferingpublic void setOffering(String offering)

getInputDatapublic List getInputData()

setInputDatapublic void setInputData(List inputData)

addInputDatapublic void addInputData(IOData inputData)

getOutputDatapublic List getOutputData()

setOutputDatapublic void setOutputData(List outputData)

addOutputDatapublic void addOutputData(IOData outputData)

getFormatpublic BigIotTypes.FormatType getFormat()

setFormatpublic void setFormat(BigIotTypes.FormatType format)

B157

org.eclipse.bigiot.lib.offering.OfferingDescription

Page 235: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

getActivationpublic Activation getActivation()

setActivationpublic void setActivation(Activation activation)

getAccessInterfaceTypepublic BigIotTypes.AccessInterfaceType getAccessInterfaceType()

setAccessInterfaceTypepublic void setAccessInterfaceType(BigIotTypes.AccessInterfaceTypeaccessInterfaceType)

getRequestTemplatespublic MessageTemplates getRequestTemplates()

setRequestTemplatespublic void setRequestTemplates(MessageTemplates requestTemplates)

getResponseTemplatespublic MessageTemplates getResponseTemplates()

setResponseTemplatespublic void setResponseTemplates(MessageTemplates responseTemplates)

toStringpublic String toString()

B158

org.eclipse.bigiot.lib.offering.OfferingDescription

Page 236: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass OfferingIdjava.lang.Object | +-org.eclipse.bigiot.lib.offering.OfferingId

public class OfferingIdextends Object

Constructors

OfferingIdpublic OfferingId(String value)

Methods

toStringpublic String toString()

getValuepublic String getValue()

hashCodepublic int hashCode()

equalspublic boolean equals(Object obj)

B159

org.eclipse.bigiot.lib.offering.OfferingId

Page 237: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass OfferingSelectorjava.lang.Object | +-org.eclipse.bigiot.lib.offering.OfferingSelector

public class OfferingSelectorextends Object

Constructors

OfferingSelectorpublic OfferingSelector()

Methods

createpublic static OfferingSelector create()

cheapestpublic OfferingSelector cheapest()

mostPermissivepublic OfferingSelector mostPermissive()

onlyLocalhostpublic OfferingSelector onlyLocalhost()

selectpublic SubscribableOfferingDescription select(List initialSet)

B160

org.eclipse.bigiot.lib.offering.OfferingSelector

Page 238: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass RegisteredOfferingjava.lang.Object | +-org.eclipse.bigiot.lib.offering.RegisteredOffering

public class RegisteredOfferingextends Object

Direct Known Subclasses:DeployedOffering

Constructors

RegisteredOfferingpublic RegisteredOffering(RegistrableOfferingDescription offeringDescription)

Methods

getOfferingIdpublic OfferingId getOfferingId()

Get corresponding offering id to offering

Returns:

getOfferingDescriptionpublic RegistrableOfferingDescription getOfferingDescription()

Get corresponding offering description

deregisterpublic void deregister()

Deregisters Offering from the marketplace

B161

org.eclipse.bigiot.lib.offering.RegisteredOffering

Page 239: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringInterface Registrable

public interface Registrableextends

All Known Implementing Classes:RegistrableOfferingDescription

Methods

registerpublic abstract RegisteredOffering register() throws IncompleteOfferingDescriptionException, NotRegisteredException

activatepublic abstract void activate()

deregisterpublic abstract void deregister()

B162

org.eclipse.bigiot.lib.offering.Registrable

Page 240: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass RegistrableOfferingDescriptionjava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.RegistrableOfferingDescription

public class RegistrableOfferingDescriptionextends OfferingDescriptionimplements Registrable

Offering Description with methods for registration at the marketplace

All Implemented Interfaces:Registrable

Direct Known Subclasses:RegistrableOfferingDescriptionChain

Constructors

RegistrableOfferingDescriptionpublic RegistrableOfferingDescription()

RegistrableOfferingDescriptionpublic RegistrableOfferingDescription(String localId, BigIotClientId clientId, BigIotMarketplaceClient marketplaceClient, Map providerOfferingMap)

Methods

registerpublic RegisteredOffering register() throws IncompleteOfferingDescriptionException, NotRegisteredException

Registers an Offeirng at the marketplace and deploys A1 interface if applicable. Returns a RegisteredOffering object forlifecycle operations.

Parameters:localId

Returns:

Throws:

B163

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescription

Page 241: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

NotRegisteredException

deregisterpublic void deregister()

Deregisters corresponding offering at the marketplace

activatepublic void activate()

Activates the corresponding inactive offering at the marketplace

getOfferingIdpublic OfferingId getOfferingId()

setMarketplaceClientpublic void setMarketplaceClient(BigIotMarketplaceClient marketplaceClient)

internal

getMarketplaceClientpublic BigIotMarketplaceClient getMarketplaceClient()

internal

setOfferingspublic void setOfferings(Map offerings)

internal

getRoutepublic String getRoute()

Return route of A1 interface if applicable

Returns:

getExpirationIntervalpublic long getExpirationInterval()

internal

B164

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescription

Page 242: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass RegistrableOfferingDescriptionChainjava.lang.Object | +- | +- | +-org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionChain

public class RegistrableOfferingDescriptionChainextends RegistrableOfferingDescription

This implementation allows the incremental construction of an Offering via chaining functions. The methods in this class addelements to the offering query, e.g. a price, an accounting type or a region. An example for the usage is

All Implemented Interfaces:Registrable

OfferingDescription offeringDescription = OfferingDescription.create("... LocalID ...")

.withInformation(new Information("Example Offering

Query", "bigiot:Parking"))

.addInputData("longitude", new

RDFType("schema:longitude"))

.addInputData("latitude", new

RDFType("schema:latitude"))

.addInputData("radius", new

RDFType("schema:geoRadius"))

.addOutputData("available", new

RDFType("datex:availableparking"))

.addOutputData("occupied", new

RDFType("datex:occupiedparking"))

.inRegion(RegionFilter.city("Barcelona"))

.withPrice(new

PriceWithAccountingType(Euros.amount(0.002), AccountingType.PER_ACCESS))

.withLicense(LicenseType.OPEN_DATA_LICENSE)

.addEndPoint(EndpointTypes.HTTP_GET,

AccessInterfaceType.BIGIOT_LIB, "/parkinginfo");

Constructors

RegistrableOfferingDescriptionChainpublic RegistrableOfferingDescriptionChain()

B165

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionChain

Page 243: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

RegistrableOfferingDescriptionChainpublic RegistrableOfferingDescriptionChain(String localId, BigIotClientId clientId, BigIotMarketplaceClient marketplaceClient, Map offerings)

Methods

withInformationpublic RegistrableOfferingDescriptionChain withInformation(Description description)

Sets description

Parameters:description

Returns:

withDescriptionpublic RegistrableOfferingDescriptionChain withDescription(Description description)

Sets description

Parameters:description

Returns:

withInformationpublic RegistrableOfferingDescriptionChain withInformation(Information information)

Sets information object describing offering

Parameters:information

Returns:

withInformationpublic RegistrableOfferingDescriptionChain withInformation(String name, String rdfTypeUri)

Convenicence function for setting name and rdftype URI

Parameters:name

rdfTypeUri

B166

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionChain

Page 244: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Returns:

withInformationpublic RegistrableOfferingDescriptionChain withInformation(String name, RDFType rdfType)

Convenicence function for setting name and rdftype

Parameters:name

rdfType

Returns:

inRegionpublic RegistrableOfferingDescriptionChain inRegion(RegionFilter region)

Sets a region filter

Parameters:region

Returns:

inCitypublic RegistrableOfferingDescriptionChain inCity(String cityName)

Sets a region filter by city name

Parameters:cityName

Returns:

withPricepublic RegistrableOfferingDescriptionChain withPrice(Money money)

Sets the price of an offering

Parameters:money

Returns:

withPricingModelpublic RegistrableOfferingDescriptionChain withPricingModel(BigIotTypes.PricingModelpricingModel)

Sets the pricing model of an offering

B167

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionChain

Page 245: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Parameters:pricingModel

Returns:

withLicenseTypepublic RegistrableOfferingDescriptionChain withLicenseType(BigIotTypes.LicenseTypetype)

Sets the license type of an offering

Parameters:type

Returns:

addEndPointpublic RegistrableOfferingDescriptionChain addEndPoint(BigIotTypes.AccessInterfaceTypeaccessInterfaceType, String uri)

Adds an endpoint to an offering. Currently only one endpoint is supported.

Parameters:accessInterfaceType

uri

Returns:

onExternalEndpointpublic RegistrableOfferingDescription onExternalEndpoint(String endpointUrl)

Adds an external endpoint to an offering. Currently only one endpoint is supported. Sets offering implicitly to an int mode3 offering.

Parameters:endpointUrl

Returns:

addInputDatapublic RegistrableOfferingDescriptionChain addInputData(String name, RDFType rdfType, String valueType)

Adds an input parameter to an offering.

Parameters:name

rdfType

valueType

B168

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionChain

Page 246: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Returns:

addInputDatapublic RegistrableOfferingDescriptionChain addInputData(String name, RDFType rdfType, ComplexObjectMembers members)

Adds a complex input parameter to an offering.

Parameters:name

rdfType

members

Returns:

addInputDataInQuerypublic RegistrableOfferingDescriptionChain addInputDataInQuery(String name, RDFType rdfType, String valueType)

Adds a input parameter to an offering, which is encoded as a query parameter (Only applicable for integration mode 3offerings)

Parameters:name

rdfType

valueType

Returns:

addInputDataInBodypublic RegistrableOfferingDescriptionChain addInputDataInBody(String name, RDFType rdfType, String valueType)

Adds a input parameter to an offering, which is encoded as a message body parameter (Only applicable for integrationmode 3 offerings)

Parameters:name

rdfType

valueType

Returns:

addInputDataInUrlpublic RegistrableOfferingDescriptionChain addInputDataInUrl(String name, RDFType rdfType, String valueType)

B169

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionChain

Page 247: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Adds a input parameter to an offering, which is encoded as a route parameter (Only applicable for integration mode 3offerings)

Parameters:name

rdfType

valueType

Returns:

addInputDataInTemplatepublic RegistrableOfferingDescriptionChain addInputDataInTemplate(String name, RDFType rdfType, String valueType)

Adds a input parameter to an offering, which is filled out in a template (Only applicable for integration mode 3 offerings)

Parameters:name

rdfType

valueType

Returns:

addOutputDatapublic RegistrableOfferingDescriptionChain addOutputData(String name, RDFType rdfType, String valueType)

Adds a output parameter to an offering.

Parameters:name

rdfType

valueType

Returns:

addOutputDatapublic RegistrableOfferingDescriptionChain addOutputData(String name, RDFType rdfType, ComplexObjectMembers members)

Adds a complex output parameter to an offering.

Parameters:name

rdfType

members

Returns:

B170

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionChain

Page 248: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

addOutputDataInTemplatepublic RegistrableOfferingDescriptionChain addOutputDataInTemplate(String name, RDFType rdfType, String valueType)

Adds a output parameter to an offering, which is filled out in a template (Only applicable for integration mode 3 offerings)

Parameters:name

rdfType

valueType

Returns:

useOfferingDescriptionpublic RegistrableOfferingDescriptionChain useOfferingDescription(String offeringId)

internal use

Parameters:offeringId

Returns:

withRoutepublic RegistrableOfferingDescriptionChain withRoute(String route)

Overrides the default route for the A1 interface

Parameters:route

Returns:

withAccessInterfaceTypepublic RegistrableOfferingDescriptionChainwithAccessInterfaceType(BigIotTypes.AccessInterfaceType accessInterfaceType)

Overrides the predetermined access interface type

Parameters:accessInterfaceType

Returns:

withProtocolpublic RegistrableOfferingDescriptionChain withProtocol(BigIotTypes.EndpointTypeprotocol)

Sets the protocol type (only relevant in integration mode 3 [at the moment])

B171

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionChain

Page 249: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Parameters:protocol

Returns:

withAccessRequestHandlerpublic RegistrableOfferingDescriptionChainwithAccessRequestHandler(AccessRequestHandler accessCallback)

Sets the callback method for gateway service hosted offerings

Parameters:accessCallback

Returns:

withExpirationIntervalpublic RegistrableOfferingDescriptionChain withExpirationInterval(longintervalInMilli)

Sets the expiration interval at the marketplace in milliseconds

Parameters:intervalInMilli

Returns:

withExpirationIntervalpublic RegistrableOfferingDescriptionChain withExpirationInterval(Duration interval)

Sets the expiration interval at the marketplace

Parameters:interval

Returns:

deployOnpublic RegistrableOfferingDescriptionChain deployOn(EmbededdedRouteBasedServer server)

Sets the server running the gateway service (only relevant in integration mode 2)

Parameters:server

Returns:

B172

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionChain

Page 250: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

asHttpPostpublic RegistrableOfferingDescriptionChain asHttpPost()

Sets the protocol to HTTP POST for an external offering (only relevant in integration mode 3)

Returns:

asHttpGetpublic RegistrableOfferingDescriptionChain asHttpGet()

Sets the protocol to HTTP GET for an external offering (only relevant in integration mode 3)

Returns:

acceptsXmlpublic RegistrableOfferingDescriptionChain acceptsXml()

Sets the accept type to application/xml for an external offering (only relevant in integration mode 3)

Returns:

acceptsJsonpublic RegistrableOfferingDescriptionChain acceptsJson()

Sets the accept type to application/json for an external offering (only relevant in integration mode 3)

Returns:

producesXmlpublic RegistrableOfferingDescriptionChain producesXml()

Sets the content type to application/xml for an external offering (only relevant in integration mode 3)

Returns:

producesJsonpublic RegistrableOfferingDescriptionChain producesJson()

Sets the content type to application/json for an external offering (only relevant in integration mode 3)

Returns:

usingRequestTemplatepublic RegistrableOfferingDescriptionChain usingRequestTemplate(MessageTemplatesrequestTemplates)

B173

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionChain

Page 251: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Sets the input template for a template-based parameter encoding (only relevant in integration mode 3)

Parameters:requestTemplates

Returns:

usingResponseTemplatepublic RegistrableOfferingDescriptionChain usingResponseTemplate(MessageTemplatesresponseTemplates)

Sets the output template for a template-based parameter encoding (only relevant in integration mode 3)

Parameters:responseTemplates

Returns:

B174

org.eclipse.bigiot.lib.offering.RegistrableOfferingDescriptionChain

Page 252: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass SelectionCriteriajava.lang.Object | +-org.eclipse.bigiot.lib.offering.SelectionCriteria

public abstract class SelectionCriteriaextends Object

Direct Known Subclasses:Cheapest, MostPermissive, OnlyLocalhost

Constructors

SelectionCriteriapublic SelectionCriteria()

Methods

filterpublic abstract List filter(List e)

B175

org.eclipse.bigiot.lib.offering.SelectionCriteria

Page 253: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass SelectionCriteria.OnlyLocalhostjava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.SelectionCriteria.OnlyLocalhost

public static class SelectionCriteria.OnlyLocalhostextends SelectionCriteria

Constructors

OnlyLocalhostpublic OnlyLocalhost()

Methods

filterpublic List filter(List offeringDescriptions)

toStringpublic String toString()

B176

org.eclipse.bigiot.lib.offering.SelectionCriteria.OnlyLocalhost

Page 254: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass SelectionCriteria.MostPermissivejava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.SelectionCriteria.MostPermissive

public static class SelectionCriteria.MostPermissiveextends SelectionCriteria

Constructors

MostPermissivepublic MostPermissive()

Methods

filterpublic List filter(List offeringDescriptions)

toStringpublic String toString()

B177

org.eclipse.bigiot.lib.offering.SelectionCriteria.MostPermissive

Page 255: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass SelectionCriteria.Cheapestjava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.SelectionCriteria.Cheapest

public static class SelectionCriteria.Cheapestextends SelectionCriteria

Constructors

Cheapestpublic Cheapest()

Methods

filterpublic List filter(List offeringDescriptions)

toStringpublic String toString()

B178

org.eclipse.bigiot.lib.offering.SelectionCriteria.Cheapest

Page 256: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass SubscribableOfferingDescriptionjava.lang.Object | +- | +- | +-org.eclipse.bigiot.lib.offering.SubscribableOfferingDescription

public class SubscribableOfferingDescriptionextends SubscribableOfferingDescriptionCore

Methods

subscribepublic CompletableFuture subscribe() throws InterruptedException, ExecutionException

subscribeBlockingpublic Offering subscribeBlocking()

Subscribe to Offering and activate automatic renewal.

Returns:

B179

org.eclipse.bigiot.lib.offering.SubscribableOfferingDescription

Page 257: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offeringClass SubscribableOfferingDescriptionCorejava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.SubscribableOfferingDescriptionCore

public class SubscribableOfferingDescriptionCoreextends OfferingDescription

OfferingDescription is a subscribable extension of an OfferingDescriptionData. In order to create the access object (Offering) foran Offering Description this class provides the subscribe() method

Direct Known Subclasses:SubscribableOfferingDescription

Methods

subscribeFuturepublic Future subscribeFuture()

Subscribe to Offering and activate automatic renewal.

Returns:

subscribeBlockingpublic OfferingCore subscribeBlocking()

Subscribe to Offering and activate automatic renewal.

Returns:

showOfferingDescriptionspublic static List showOfferingDescriptions(List l)

Pretty print of list of Offering Description

Parameters:l

Returns:

showOfferingDescriptionsStringpublic static String showOfferingDescriptionsString(List l)

Pretty print of list of Offering Description

B180

org.eclipse.bigiot.lib.offering.SubscribableOfferingDescriptionCore

Page 258: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Parameters:l

Returns:

showOfferingDescriptionsDetailedpublic static List showOfferingDescriptionsDetailed(List l)

Pretty print of list of Offering Description

Parameters:l

Returns:

setConsumerpublic void setConsumer(IConsumer consumer)

getConsumerpublic IConsumer getConsumer()

setQueryIdpublic void setQueryId(String queryId)

getQueryIdpublic String getQueryId()

terminatepublic void terminate()

Terminates automatic renewal and implicitly unsubscribes offering

B181

org.eclipse.bigiot.lib.offering.SubscribableOfferingDescriptionCore

Page 259: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.offering.encoder

B182

Page 260: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass MessageTemplatesjava.lang.Object | +-org.eclipse.bigiot.lib.offering.encoder.MessageTemplates

public class MessageTemplatesextends Object

Constructors

MessageTemplatespublic MessageTemplates()

MessageTemplatespublic MessageTemplates(String template)

Methods

createpublic static MessageTemplates create(String template)

addSubTemplatepublic MessageTemplates addSubTemplate(String subTemplate, String placeholder)

getTemplatepublic String getTemplate()

setTemplatepublic void setTemplate(String template)

B183

org.eclipse.bigiot.lib.offering.encoder.MessageTemplates

Page 261: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

getSubTemplatespublic HashMap getSubTemplates()

setSubTemplatespublic void setSubTemplates(HashMap subTemplates)

B184

org.eclipse.bigiot.lib.offering.encoder.MessageTemplates

Page 262: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderjava.lang.Object | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoder

public abstract class ParameterEncoderextends Object

Encoder for parameterization of Offering access

Direct Known Subclasses:ParameterEncoderJson, ParameterEncoderPath, ParameterEncoderQuery, ParameterEncoderTemplate,ParameterEncoderUrlTrial, ParameterEncoderXml

Fields

ESCAPE_SEQUENCEpublic static final java.lang.String ESCAPE_SEQUENCE

Constant value: @@

Constructors

ParameterEncoderpublic ParameterEncoder()

Methods

encodepublic abstract String encode(Object parameters)

Generates a valid encoding for the access parameters used for an Offering call.

Parameters:parameters

Returns:

Throws:IllegalAccessParameterException

B185

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoder

Page 263: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderJsonjava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderJson

public class ParameterEncoderJsonextends ParameterEncoder

Parameter Encoder for Json

Constructors

ParameterEncoderJsonpublic ParameterEncoderJson()

Methods

encodepublic String encode(Object parameters)

Generates a valid encoding for the access parameters used for an Offering call.

B186

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderJson

Page 264: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderPathjava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderPath

public class ParameterEncoderPathextends ParameterEncoder

Constructors

ParameterEncoderPathpublic ParameterEncoderPath(String urlTemplate)

Methods

encodepublic String encode(Object parameters)

Generates a valid encoding for the access parameters used for an Offering call.

B187

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderPath

Page 265: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderQueryjava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderQuery

public class ParameterEncoderQueryextends ParameterEncoder

Constructors

ParameterEncoderQuerypublic ParameterEncoderQuery()

Methods

encodepublic String encode(Object parameters)

Generates a valid encoding for the access parameters used for an Offering call.

B188

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderQuery

Page 266: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderTemplatejava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTemplate

public class ParameterEncoderTemplateextends ParameterEncoder

Parameter Encoder for Json

Constructors

ParameterEncoderTemplatepublic ParameterEncoderTemplate(MessageTemplates templates)

Methods

encodepublic String encode(Object parameters)

Generates a valid encoding for the access parameters used for an Offering call.

B189

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTemplate

Page 267: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderTestjava.lang.Object | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest

public class ParameterEncoderTestextends Object

Constructors

ParameterEncoderTestpublic ParameterEncoderTest()

Methods

createUserpublic static ParameterEncoderTest.User createUser()

mainpublic static void main(String[] args) throws IllegalAccessParameterException

B190

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest

Page 268: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderTest.Addressjava.lang.Object | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest.Address

public static class ParameterEncoderTest.Addressextends Object

Fields

streetpublic java.lang.String street

citypublic java.lang.String city

Constructors

Addresspublic Address()

Addresspublic Address(String street, String city)

Methods

toStringpublic String toString()

getStreetpublic String getStreet()

B191

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest.Address

Page 269: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

setStreetpublic void setStreet(String street)

getCitypublic String getCity()

setCitypublic void setCity(String city)

B192

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest.Address

Page 270: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderTest.Productjava.lang.Object | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest.Product

public static class ParameterEncoderTest.Productextends Object

Fields

namepublic java.lang.String name

Constructors

Productpublic Product()

Productpublic Product(String name, double version)

Methods

toStringpublic String toString()

getNamepublic String getName()

setNamepublic void setName(String name)

B193

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest.Product

Page 271: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

getVersionpublic double getVersion()

setVersionpublic void setVersion(double version)

B194

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest.Product

Page 272: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderTest.Userjava.lang.Object | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest.User

public static class ParameterEncoderTest.Userextends Object

Fields

namepublic java.lang.String name

birthdaypublic java.util.Date birthday

addresspublic org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest.Address address

productspublic java.util.LinkedList products

nicknamespublic java.lang.String nicknames

Constructors

Userpublic User(String name, Date birthday, ParameterEncoderTest.Address address, LinkedList products, String[] nicknames)

B195

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest.User

Page 273: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Userpublic User()

Methods

toStringpublic String toString()

B196

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderTest.User

Page 274: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderUrlTrialjava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderUrlTrial

public class ParameterEncoderUrlTrialextends ParameterEncoder

Parameter encoder for URL query parameters

Fields

complexObjectUrlSyntaxpublic static finalorg.eclipse.bigiot.lib.offering.encoder.ParameterEncoderUrlTrial.ComplexObjectUrlSyntax complexObjectUrlSyntax

Constructors

ParameterEncoderUrlTrialpublic ParameterEncoderUrlTrial()

Methods

encodepublic String encode(Object parameters)

Generates a valid encoding as a URL parameter string for the parameterization of an Offering call.

Parameters:parameters

Returns:

B197

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderUrlTrial

Page 275: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderUrlTrial.ComplexObjectUrlSyntaxjava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderUrlTrial.ComplexObjectUrlSyntax

public static final class ParameterEncoderUrlTrial.ComplexObjectUrlSyntaxextends Enum

All Implemented Interfaces:Serializable, Comparable

Fields

DOT_SYNTAXpublic static finalorg.eclipse.bigiot.lib.offering.encoder.ParameterEncoderUrlTrial.ComplexObjectUrlSyntax DOT_SYNTAX

BRACE_SYNTAXpublic static finalorg.eclipse.bigiot.lib.offering.encoder.ParameterEncoderUrlTrial.ComplexObjectUrlSyntax BRACE_SYNTAX

Methods

valuespublic static ParameterEncoderUrlTrial.ComplexObjectUrlSyntax[] values()

valueOfpublic static ParameterEncoderUrlTrial.ComplexObjectUrlSyntax valueOf(String name)

B198

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderUrlTrial.ComplexObjectUrlSyntax

Page 276: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.encoderClass ParameterEncoderXmljava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderXml

public class ParameterEncoderXmlextends ParameterEncoder

Parameter Encoder for Json

Constructors

ParameterEncoderXmlpublic ParameterEncoderXml()

Methods

encodepublic String encode(Object parameters)

Generates a valid encoding for the access parameters used for an Offering call.

B199

org.eclipse.bigiot.lib.offering.encoder.ParameterEncoderXml

Page 277: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.offering.mapping

B200

Page 278: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.mappingClass OutputMappingjava.lang.Object | +-org.eclipse.bigiot.lib.offering.mapping.OutputMapping

public class OutputMappingextends Object

Methods

createpublic static OutputMapping create()

addTypeMappingpublic OutputMapping addTypeMapping(String type, String fieldName)

addNameMappingpublic OutputMapping addNameMapping(String sourceNamePath, String destinationNamePath)

toStringpublic String toString()

getListpublic List getList()

B201

org.eclipse.bigiot.lib.offering.mapping.OutputMapping

Page 279: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.mappingClass OutputMappingTuplejava.lang.Object | +-org.eclipse.bigiot.lib.offering.mapping.OutputMappingTuple

public abstract class OutputMappingTupleextends Object

Direct Known Subclasses:Type, Name

Constructors

OutputMappingTuplepublic OutputMappingTuple(String fieldName)

Methods

getMappedFieldNamepublic String getMappedFieldName()

B202

org.eclipse.bigiot.lib.offering.mapping.OutputMappingTuple

Page 280: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.mappingClass OutputMappingTuple.Namejava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.mapping.OutputMappingTuple.Name

public static class OutputMappingTuple.Nameextends OutputMappingTuple

Constructors

Namepublic Name(String sourceNamePath, String destinationNamePath)

Methods

getSourceNamePathpublic String getSourceNamePath()

toStringpublic String toString()

B203

org.eclipse.bigiot.lib.offering.mapping.OutputMappingTuple.Name

Page 281: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.mappingClass OutputMappingTuple.Typejava.lang.Object | +- | +-org.eclipse.bigiot.lib.offering.mapping.OutputMappingTuple.Type

public static class OutputMappingTuple.Typeextends OutputMappingTuple

Constructors

Typepublic Type(String type, String fieldName)

Methods

getTypepublic String getType()

toStringpublic String toString()

B204

org.eclipse.bigiot.lib.offering.mapping.OutputMappingTuple.Type

Page 282: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.offering.mappingInterface ResponseMappingType

public interface ResponseMappingTypeextends Annotation

Methods

valuepublic String value()

B205

org.eclipse.bigiot.lib.offering.mapping.ResponseMappingType

Page 283: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.query

B206

Page 284: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.queryInterface IOfferingQuery

public interface IOfferingQueryextends

Interface for an Offering Query.

All Known Implementing Classes:OfferingQuery

Methods

toOfferingQueryStringpublic abstract String toOfferingQueryString(BigIotClientId consumerId)

Compiles a Offering Query message accepted by the Marketplace

Parameters:consumerId - Consumer identifier issued by Marketplace

Returns:Offering Query string

getLocalIdpublic abstract String getLocalId()

getIdpublic abstract String getId()

setIdpublic abstract void setId(String queryId)

B207

org.eclipse.bigiot.lib.query.IOfferingQuery

Page 285: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.queryClass OfferingQueryjava.lang.Object | +-org.eclipse.bigiot.lib.query.OfferingQuery

public abstract class OfferingQueryextends Objectimplements IOfferingQuery

This abstract class implements IOfferingQuery. It leaves the implementation of query string generation (toOfferingQueryString())open.

All Implemented Interfaces:IOfferingQuery

Direct Known Subclasses:OfferingQueryChain

Constructors

OfferingQuerypublic OfferingQuery()

Methods

toOfferingQueryStringpublic abstract String toOfferingQueryString(BigIotClientId consumerId)

Compiles a Offering Query message accepted by the Marketplace

Parameters:consumerId - Consumer identifier issued by Marketplace

Returns:

createpublic static OfferingQueryChain create() throws IncompleteOfferingQueryException

createpublic static OfferingQueryChain create(String localId) throws IncompleteOfferingQueryException

Factory methods for incremental Offering Query creation

B208

org.eclipse.bigiot.lib.query.OfferingQuery

Page 286: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Parameters:consumerId - Consumer ID

Returns:

Throws:IncompleteOfferingQueryException

getIdpublic String getId()

setIdpublic void setId(String id)

B209

org.eclipse.bigiot.lib.query.OfferingQuery

Page 287: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.queryClass OfferingQueryChainjava.lang.Object | +- | +-org.eclipse.bigiot.lib.query.OfferingQueryChain

public class OfferingQueryChainextends OfferingQuery

This implementation of an Offering Query allows the incremental construction of an Offering Query via chaining functions. Themethods in this class add elements to the offering query, e.g. a max price, an accounting type or a region. As a central element inthe BIG IoT API, the implementation of OfferingQuery shall allow natural, user centric query generation. Motivation is that theuser gets a strongly typed interface for Offering Query Generation without being overstrained by parameters he needn't for hisquery. The stream orientation of the incremental approach and the method names oriented an natural language support this. An example for the usage is

All Implemented Interfaces:IOfferingQuery

IOfferingQuery query = OfferingQuery.create("... Local Query Id ...")

.withInformation(new Information("Example Offering

Query", "bigiot:Parking"))

.inRegion(RegionFilter.city("Barcelona"))

.withAccountingType(EnumTypes.AccountingType.PER_ACCESS)

.withMaxPrice(Euros.amount(0.002))

.withLicenseType(LicenseType.OPEN_DATA_LICENSE);

Constructors

OfferingQueryChainpublic OfferingQueryChain(String localId)

Constructs a minimal Offering Query

Parameters:consumerId - Consumer ID

Throws:IncompleteOfferingQueryException

Methods

B210

org.eclipse.bigiot.lib.query.OfferingQueryChain

Page 288: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

withInformationpublic OfferingQueryChain withInformation(Information information)

All Offerings with specified information element

Parameters:information - Information Element

Returns:Offering Query

withMaxPricepublic OfferingQueryChain withMaxPrice(Price price)

All Offerings with a max price

Parameters:price - Price

Returns:Offering Query

withMaxPricepublic OfferingQueryChain withMaxPrice(Money money)

All Offerings with a max price for selected pricing model

Parameters:price - Price

Returns:Offering Query

inRegionpublic OfferingQueryChain inRegion(RegionFilter region)

All Offerings in a region

Parameters:region - RegionFilter

Returns:Offering Query

inCitypublic OfferingQueryChain inCity(String cityName)

All Offerings in a city

Returns:Offering Query

B211

org.eclipse.bigiot.lib.query.OfferingQueryChain

Page 289: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

withPricingModelpublic OfferingQueryChain withPricingModel(BigIotTypes.PricingModel pricingModel)

All Offerings with specified pricing model

Parameters:pricingModel

Returns:

withLicenseTypepublic OfferingQueryChain withLicenseType(BigIotTypes.LicenseType licenseType)

All Offerings with specified license type

Parameters:licenseType - Licens Type

Returns:

getLocalIdpublic String getLocalId()

toStringpublic String toString()

toOfferingQueryStringpublic String toOfferingQueryString(BigIotClientId consumerId)

Compiles a Offering Query message accepted by the Marketplace

Parameters:consumerId - Consumer identifier issued by Marketplace

Returns:

B212

org.eclipse.bigiot.lib.query.OfferingQueryChain

Page 290: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.query.elements

B213

Page 291: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.query.elementsClass PriceFilterjava.lang.Object | +-org.eclipse.bigiot.lib.query.elements.PriceFilter

public abstract class PriceFilterextends Objectimplements QueryElement

Abstract price filter used for Offering Query

All Implemented Interfaces:QueryElement

Direct Known Subclasses:PriceFilterBetween, PriceFilterMin, PriceFilterMax

Constructors

PriceFilterpublic PriceFilter()

Methods

setPricingModelpublic abstract void setPricingModel(BigIotTypes.PricingModel pricingModel)

Sets accotuning type

Parameters:pricingModel

getPricingModelpublic abstract BigIotTypes.PricingModel getPricingModel()

Returns accounting type

Returns:

setPricepublic abstract void setPrice(Price price)

Sets price

Parameters:

B214

org.eclipse.bigiot.lib.query.elements.PriceFilter

Page 292: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

price

B215

org.eclipse.bigiot.lib.query.elements.PriceFilter

Page 293: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.query.elementsClass PriceFilter.PriceFilterMaxjava.lang.Object | +- | +-org.eclipse.bigiot.lib.query.elements.PriceFilter.PriceFilterMax

public static class PriceFilter.PriceFilterMaxextends PriceFilter

Max pricefilter

All Implemented Interfaces:QueryElement

Constructors

PriceFilterMaxpublic PriceFilterMax(Price max)

Methods

getMaxpublic Price getMax()

toQueryElementpublic String toQueryElement()

setPricingModelpublic void setPricingModel(BigIotTypes.PricingModel pricingModel)

Sets accotuning type

setPricepublic void setPrice(Price price)

Sets price

getPricingModelpublic BigIotTypes.PricingModel getPricingModel()

B216

org.eclipse.bigiot.lib.query.elements.PriceFilter.PriceFilterMax

Page 294: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Returns accounting type

B217

org.eclipse.bigiot.lib.query.elements.PriceFilter.PriceFilterMax

Page 295: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.query.elementsClass PriceFilter.PriceFilterMinjava.lang.Object | +- | +-org.eclipse.bigiot.lib.query.elements.PriceFilter.PriceFilterMin

public static class PriceFilter.PriceFilterMinextends PriceFilter

Min price filter

All Implemented Interfaces:QueryElement

Constructors

PriceFilterMinpublic PriceFilterMin(Price min)

Methods

getMinpublic Price getMin()

toQueryElementpublic String toQueryElement()

setPricingModelpublic void setPricingModel(BigIotTypes.PricingModel pricingModel)

Sets accotuning type

setPricepublic void setPrice(Price price)

Sets price

getPricingModelpublic BigIotTypes.PricingModel getPricingModel()

B218

org.eclipse.bigiot.lib.query.elements.PriceFilter.PriceFilterMin

Page 296: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Returns accounting type

B219

org.eclipse.bigiot.lib.query.elements.PriceFilter.PriceFilterMin

Page 297: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.query.elementsClass PriceFilter.PriceFilterBetweenjava.lang.Object | +- | +-org.eclipse.bigiot.lib.query.elements.PriceFilter.PriceFilterBetween

public static class PriceFilter.PriceFilterBetweenextends PriceFilter

Filter for price in an interval

All Implemented Interfaces:QueryElement

Constructors

PriceFilterBetweenpublic PriceFilterBetween(Price min, Price max)

Methods

getMinpublic Price getMin()

getMaxpublic Price getMax()

toQueryElementpublic String toQueryElement()

setPricingModelpublic void setPricingModel(BigIotTypes.PricingModel accountingType)

Sets accotuning type

B220

org.eclipse.bigiot.lib.query.elements.PriceFilter.PriceFilterBetween

Page 298: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

setPricepublic void setPrice(Price price)

Sets price

getPricingModelpublic BigIotTypes.PricingModel getPricingModel()

Returns accounting type

B221

org.eclipse.bigiot.lib.query.elements.PriceFilter.PriceFilterBetween

Page 299: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.query.elementsInterface QueryElement

public interface QueryElementextends

ABstract Query Element knowing how to represent in an Offering Query

All Known Implementing Classes:PriceFilter, RegionFilter, BigIotClientId

Methods

toQueryElementpublic abstract String toQueryElement()

B222

org.eclipse.bigiot.lib.query.elements.QueryElement

Page 300: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.query.elementsClass RegionFilterjava.lang.Object | +-org.eclipse.bigiot.lib.query.elements.RegionFilter

public abstract class RegionFilterextends Objectimplements QueryElement, Cloneable

RegionFilter as an query element used as spatial filter

All Implemented Interfaces:Cloneable, QueryElement

Direct Known Subclasses:RegionFilterCircle, RegionFilterBox, city, RegionFilterDescriptive

Constructors

RegionFilterpublic RegionFilter()

Methods

citypublic static RegionFilter.city city(String cityName)

Factory for city filter

Parameters:cityName

Returns:

inAreapublic static RegionFilter.RegionFilterBox inArea(Location swCorner, Location neCorner)

Factory for spatial box filter

Parameters:swCorner

neCorner

Returns:

B223

org.eclipse.bigiot.lib.query.elements.RegionFilter

Page 301: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

inRangeAroundpublic static RegionFilter.RegionFilterCircle inRangeAround(Location location, double meters)

Facotry for range filter

Parameters:location

meters

Returns:

B224

org.eclipse.bigiot.lib.query.elements.RegionFilter

Page 302: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.query.elementsClass RegionFilter.RegionFilterDescriptivejava.lang.Object | +- | +-org.eclipse.bigiot.lib.query.elements.RegionFilter.RegionFilterDescriptive

public static class RegionFilter.RegionFilterDescriptiveextends RegionFilter

RegionFilter as a descriptive text

All Implemented Interfaces:Cloneable, QueryElement

Constructors

RegionFilterDescriptivepublic RegionFilterDescriptive()

RegionFilterDescriptivepublic RegionFilterDescriptive(String description)

Methods

getDescriptionpublic String getDescription()

toQueryElementpublic String toQueryElement()

B225

org.eclipse.bigiot.lib.query.elements.RegionFilter.RegionFilterDescriptive

Page 303: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.query.elementsClass RegionFilter.cityjava.lang.Object | +- | +-org.eclipse.bigiot.lib.query.elements.RegionFilter.city

public static class RegionFilter.cityextends RegionFilter

RegionFilter as a city name

All Implemented Interfaces:Cloneable, QueryElement

Constructors

citypublic city()

citypublic city(String cityName)

Methods

toQueryElementpublic String toQueryElement()

toRegistrationStringpublic String toRegistrationString()

clonepublic RegionFilter.city clone()

getCitypublic String getCity()

B226

org.eclipse.bigiot.lib.query.elements.RegionFilter.city

Page 304: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

setCitypublic void setCity(String city)

B227

org.eclipse.bigiot.lib.query.elements.RegionFilter.city

Page 305: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.query.elementsClass RegionFilter.RegionFilterBoxjava.lang.Object | +- | +-org.eclipse.bigiot.lib.query.elements.RegionFilter.RegionFilterBox

public static class RegionFilter.RegionFilterBoxextends RegionFilter

RegionFilter as a spatial box

All Implemented Interfaces:Cloneable, QueryElement

Constructors

RegionFilterBoxpublic RegionFilterBox(Location swCorner, Location neCorner)

Methods

getSwCornerpublic Location getSwCorner()

getNeCornerpublic Location getNeCorner()

toQueryElementpublic String toQueryElement()

B228

org.eclipse.bigiot.lib.query.elements.RegionFilter.RegionFilterBox

Page 306: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.query.elementsClass RegionFilter.RegionFilterCirclejava.lang.Object | +- | +-org.eclipse.bigiot.lib.query.elements.RegionFilter.RegionFilterCircle

public static class RegionFilter.RegionFilterCircleextends RegionFilter

RegionFilter as a spatial circle

All Implemented Interfaces:Cloneable, QueryElement

Constructors

RegionFilterCirclepublic RegionFilterCircle(Location location, double meters)

Methods

getLocationpublic Location getLocation()

getMeterspublic double getMeters()

toQueryElementpublic String toQueryElement()

B229

org.eclipse.bigiot.lib.query.elements.RegionFilter.RegionFilterCircle

Page 307: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.security

B230

Page 308: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.securityClass AccessTokenjava.lang.Object | +-org.eclipse.bigiot.lib.security.AccessToken

public class AccessTokenextends Object

Constructors

AccessTokenpublic AccessToken()

Methods

generatepublic static String generate(String consumerId, String offeringId)

generatepublic static String generate(String consumerId, String offeringId, String secret)

validatepublic static boolean validate(String jwtToken)

validateMarketplaceTokenpublic static boolean validateMarketplaceToken(String jwtToken, String secret, String subjectString)

validateOfferingAccessTokenpublic static boolean validateOfferingAccessToken(String jwtToken, String secret, String offeringId)

B231

org.eclipse.bigiot.lib.security.AccessToken

Page 309: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

getExpirationTimepublic static long getExpirationTime(String jwtToken)

validatepublic static boolean validate(String jwtToken, String secret)

getCurrentDatepublic static Date getCurrentDate()

getExpirationDatepublic static Date getExpirationDate(long ttl)

getCurrentTimepublic static long getCurrentTime()

loadPublicX509public static java.security.cert.X509Certificate loadPublicX509(String fileName) throws java.security.GeneralSecurityException

B232

org.eclipse.bigiot.lib.security.AccessToken

Page 310: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.serverwrapper

B233

Page 311: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.serverwrapperClass BigIotHttpResponsejava.lang.Object | +-org.eclipse.bigiot.lib.serverwrapper.BigIotHttpResponse

public class BigIotHttpResponseextends Object

Constructors

BigIotHttpResponsepublic BigIotHttpResponse(HashMap headers, String status, String body)

Construct a BIG IoT Message for encapsulation offering responses

Parameters:headers

status

body

BigIotHttpResponsepublic BigIotHttpResponse(String status)

Construct an empty BIG IoT Message for encapsulation offering responses

Parameters:status

Methods

okaypublic static BigIotHttpResponse okay()

Construct an empty BIG IoT Message for encapsulation offering responses with HTTP status code 'okay'

Returns:

badRequestpublic static BigIotHttpResponse badRequest()

Construct an empty BIG IoT Message for encapsulation offering responses with HTTP status code 'Bad request'

Returns:

B234

org.eclipse.bigiot.lib.serverwrapper.BigIotHttpResponse

Page 312: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

errorpublic static BigIotHttpResponse error()

Constructing an empty BIG IoT Message for encapsulation offering responses with HTTP status code 'Internal server error'

Returns:

withBodypublic BigIotHttpResponse withBody(String body)

Set the body as a String

Parameters:body

Returns:

asJsonTypepublic BigIotHttpResponse asJsonType()

Set content type to application/json

Returns:

asXmlTypepublic BigIotHttpResponse asXmlType()

Set content type to application/xml

Returns:

asTextPlainpublic BigIotHttpResponse asTextPlain()

Set content type to text/plain

Returns:

asTypepublic BigIotHttpResponse asType(String type)

Set content type

Parameters:type

B235

org.eclipse.bigiot.lib.serverwrapper.BigIotHttpResponse

Page 313: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Returns:

addHeaderpublic BigIotHttpResponse addHeader(String key, String value)

Add a HTTP header to an existing response

Parameters:key

value

Returns:

withStatuspublic BigIotHttpResponse withStatus(String status)

Add a BIG IoT response status to an existing response.

Parameters:status

Returns:

withStatuspublic BigIotHttpResponse withStatus(int status)

Add a BIG IoT response status as an integer to an existing response.

Parameters:status

Returns:

getHeaderspublic HashMap getHeaders()

Get map of response headers.

Returns:

getStatuspublic String getStatus()

Get reponse status

Returns:

B236

org.eclipse.bigiot.lib.serverwrapper.BigIotHttpResponse

Page 314: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

getBodypublic String getBody()

Get response body as string.

Returns:

B237

org.eclipse.bigiot.lib.serverwrapper.BigIotHttpResponse

Page 315: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.serverwrapperClass EmbeddedTopicBasedServerjava.lang.Object | +-org.eclipse.bigiot.lib.serverwrapper.EmbeddedTopicBasedServer

public class EmbeddedTopicBasedServerextends Objectimplements IServerWrapper, ITopic

All Implemented Interfaces:ITopic, IServerWrapper

Constructors

EmbeddedTopicBasedServerpublic EmbeddedTopicBasedServer()

Methods

startpublic void start()

startpublic void start(String keyStoreLocation, String keyStorePassword)

stoppublic void stop()

B238

org.eclipse.bigiot.lib.serverwrapper.EmbeddedTopicBasedServer

Page 316: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.serverwrapperClass EmbededdedRouteBasedServerjava.lang.Object | +-org.eclipse.bigiot.lib.serverwrapper.EmbededdedRouteBasedServer

public abstract class EmbededdedRouteBasedServerextends Objectimplements IServerWrapper, IRouter

All Implemented Interfaces:IRouter, IServerWrapper

Direct Known Subclasses:EmbeddedSpark

Constructors

EmbededdedRouteBasedServerpublic EmbededdedRouteBasedServer(String domain, int port)

EmbededdedRouteBasedServerpublic EmbededdedRouteBasedServer(String domain, String baseRoute, int port)

Methods

getBaseUrlpublic String getBaseUrl()

B239

org.eclipse.bigiot.lib.serverwrapper.EmbededdedRouteBasedServer

Page 317: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.serverwrapperClass ExternalRouteBasedServerjava.lang.Object | +-org.eclipse.bigiot.lib.serverwrapper.ExternalRouteBasedServer

public abstract class ExternalRouteBasedServerextends Objectimplements IRouter

All Implemented Interfaces:IRouter

Constructors

ExternalRouteBasedServerpublic ExternalRouteBasedServer()

B240

org.eclipse.bigiot.lib.serverwrapper.ExternalRouteBasedServer

Page 318: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.serverwrapperInterface IRouter

public interface IRouterextends

All Known Implementing Classes:EmbededdedRouteBasedServer, ExternalRouteBasedServer

Methods

addRoutepublic abstract void addRoute(String route, AccessRequestHandler accessCallback, RegistrableOfferingDescription offeringDescription)

removeRoutepublic abstract void removeRoute(String route)

getRoutespublic abstract List getRoutes()

B241

org.eclipse.bigiot.lib.serverwrapper.IRouter

Page 319: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.serverwrapperInterface IServerWrapper

public interface IServerWrapperextends

All Known Implementing Classes:EmbeddedTopicBasedServer, EmbededdedRouteBasedServer

Methods

startpublic abstract void start()

startpublic abstract void start(String keyStoreLocation, String keyStorePassword)

stoppublic abstract void stop()

B242

org.eclipse.bigiot.lib.serverwrapper.IServerWrapper

Page 320: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.serverwrapperInterface ITopic

public interface ITopicextends

All Known Implementing Classes:EmbeddedTopicBasedServer

B243

org.eclipse.bigiot.lib.serverwrapper.ITopic

Page 321: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.serverwrapperClass ServerOptionsjava.lang.Object | +-org.eclipse.bigiot.lib.serverwrapper.ServerOptions

public class ServerOptionsextends Object

Direct Known Subclasses:ServerOptionsSpark

Constructors

ServerOptionspublic ServerOptions()

B244

org.eclipse.bigiot.lib.serverwrapper.ServerOptions

Page 322: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.swagger

B245

Page 323: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.swaggerClass SwaggerGeneratorjava.lang.Object | +-org.eclipse.bigiot.lib.swagger.SwaggerGenerator

public abstract class SwaggerGeneratorextends Object

Direct Known Subclasses:SwaggerGeneratorJackson

Constructors

SwaggerGeneratorpublic SwaggerGenerator()

Methods

deploySwaggerFileFrompublic static void deploySwaggerFileFrom(RegistrableOfferingDescriptionofferingDescription, String contact)

Generates a swagger description out of an offering description and deploys it on a local Swagger UI

Parameters:offeringDescription

contact

deploySwaggerFileFrompublic static void deploySwaggerFileFrom(RegistrableOfferingDescriptionofferingDescription, String title, String contact)

Generates a swagger description out of an offering description and deploys it on a local Swagger UI

Parameters:offeringDescription

contact

deploySwaggerFileFrompublic static void deploySwaggerFileFrom(List offeringDescriptions, String title, String contact)

B246

org.eclipse.bigiot.lib.swagger.SwaggerGenerator

Page 324: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Generates a swagger description out of multiple offering descriptions and deploys them on a local Swagger UI

Parameters:offeringDescription

contact

B247

org.eclipse.bigiot.lib.swagger.SwaggerGenerator

Page 325: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.swaggerClass SwaggerGeneratorJacksonjava.lang.Object | +- | +-org.eclipse.bigiot.lib.swagger.SwaggerGeneratorJackson

public class SwaggerGeneratorJacksonextends SwaggerGenerator

Constructors

SwaggerGeneratorJacksonpublic SwaggerGeneratorJackson()

B248

org.eclipse.bigiot.lib.swagger.SwaggerGeneratorJackson

Page 326: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.templates

B249

Page 327: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.templatesClass OfferingQueryPriceTemplatejava.lang.Object | +- | +-org.eclipse.bigiot.lib.templates.OfferingQueryPriceTemplate

public class OfferingQueryPriceTemplateextends FilloutTemplate

Template for Price Filter in Offering Query

Constructors

OfferingQueryPriceTemplatepublic OfferingQueryPriceTemplate(String amount, String currencyShort, String accountingModel)

B250

org.eclipse.bigiot.lib.templates.OfferingQueryPriceTemplate

Page 328: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.templatesClass OfferingQueryRequestTemplatejava.lang.Object | +- | +-org.eclipse.bigiot.lib.templates.OfferingQueryRequestTemplate

public class OfferingQueryRequestTemplateextends FilloutTemplate

Template for Offering Query

Constructors

OfferingQueryRequestTemplatepublic OfferingQueryRequestTemplate(LinkedList queryElements)

B251

org.eclipse.bigiot.lib.templates.OfferingQueryRequestTemplate

Page 329: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.test

B252

Page 330: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.testClass Randomjava.lang.Object | +-org.eclipse.bigiot.lib.test.Random

public class Randomextends Object

Convenience functions for random number generation based on Apache Commons Math

Fields

testpublic static final java.lang.String test

Constant value: TEST

Constructors

Randompublic Random()

Methods

getNextUniformpublic static double getNextUniform(double lower, double upper)

Generates a double in an interval with uniform distribution

Parameters:lower

upper

Returns:

getNextUniformpublic static long getNextUniform(long lower, long upper)

Generates a long in an interval with uniform distribution

Parameters:lower

upper

B253

org.eclipse.bigiot.lib.test.Random

Page 331: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

(continued from last page)

Returns:

nextBooleanpublic static boolean nextBoolean()

Generates a random boolean

Returns:

getRandomPositionInsidepublic static Location getRandomPositionInside(Area area)

Generates a random location in an spatial area.

Parameters:area

Returns:

getRandomPositionInsidepublic static Location getRandomPositionInside(Area area, int digits)

Generates a random location in an spatial area with a fixed precision

Parameters:area

digits

Returns:

B254

org.eclipse.bigiot.lib.test.Random

Page 332: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.testClass TestComplexParameterConsumerjava.lang.Object | +-org.eclipse.bigiot.lib.test.TestComplexParameterConsumer

public class TestComplexParameterConsumerextends Object

Constructors

TestComplexParameterConsumerpublic TestComplexParameterConsumer()

Methods

logpublic static void log(Object s)

mainpublic static void main(String[] args) throws InterruptedException, ExecutionException, IncompleteOfferingQueryException, IOException, AccessToNonSubscribedOfferingException, AccessToNonActivatedOfferingException

B255

org.eclipse.bigiot.lib.test.TestComplexParameterConsumer

Page 333: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.testClass TestComplexParameterProviderjava.lang.Object | +-org.eclipse.bigiot.lib.test.TestComplexParameterProvider

public class TestComplexParameterProviderextends Object

Example for using BIG IoT API as a provider. This example corresponds with ExampleConsumerNew.java

Constructors

TestComplexParameterProviderpublic TestComplexParameterProvider()

Methods

mainpublic static void main(String[] args) throws InterruptedException, IncompleteOfferingDescriptionException, IOException, NotRegisteredException

B256

org.eclipse.bigiot.lib.test.TestComplexParameterProvider

Page 334: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

Package

org.eclipse.bigiot.lib.tests

B257

Page 335: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.testsClass TestProviderWithSwaggerUIjava.lang.Object | +-org.eclipse.bigiot.lib.tests.TestProviderWithSwaggerUI

public class TestProviderWithSwaggerUIextends Object

Example for using BIG IoT API as a provider. This example corresponds with ExampleConsumerNew.java

Constructors

TestProviderWithSwaggerUIpublic TestProviderWithSwaggerUI()

Methods

mainpublic static void main(String[] args) throws InterruptedException, IncompleteOfferingDescriptionException, IOException, NotRegisteredException

B258

org.eclipse.bigiot.lib.tests.TestProviderWithSwaggerUI

Page 336: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

org.eclipse.bigiot.lib.testsClass TestSwaggerOnlyjava.lang.Object | +-org.eclipse.bigiot.lib.tests.TestSwaggerOnly

public class TestSwaggerOnlyextends Object

Example for using BIG IoT API as a provider. This example corresponds with ExampleConsumerNew.java

Constructors

TestSwaggerOnlypublic TestSwaggerOnly()

Methods

mainpublic static void main(String[] args) throws InterruptedException, IncompleteOfferingDescriptionException, IOException

B259

Index

Page 337: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

IndexA

acceptsJson 173

acceptsXml 173

ACCESS 91

ACCESS_PARAMETERS_HAVE_TO_MATCH_INPUT_PARAMETE

RS 61

accessContinuous 142, 146, 147, 148, 150, 153

AccessFeed 38

AccessFeedAsync 40

AccessFeedSync 41

accessOneTime 140, 141, 142, 144, 145, 146, 147, 149, 152

AccessParameters 130

AccessParametersArray 132

AccessParametersTuple 133

AccessResponse 136

AccessToken 231

AccessToNonActivatedOfferingException 27

AccessToNonSubscribedOfferingException 28

activate 18, 162, 164

activateProxy 24

Activation 82

addDefaultProxyBypass 78

addEndPoint 168

addEndpoint 156

addHeader 236

addInputData 98, 157, 168, 169

addInputDataInBody 169

addInputDataInQuery 169

addInputDataInTemplate 170

addInputDataInUrl 169

addNameMapping 201

addNameValue 130

addOutputData 98, 99, 157, 170

addOutputDataInTemplate 170

addProxyBypass 4

addRdfTypeValue 130, 131

Address 122, 191

address 195

addRoute 24, 241

addSubTemplate 183

addTypeMapping 201

addValue 132

amount 116, 117

APPLICATION_JSON 96

APPLICATION_XML 96

Area 84

asHttpGet 173

asHttpPost 172

asIoData 99

asJsonNode 136

asJsonType 235

asString 5

asTextPlain 235

asType 235

asXmlType 235

ASYNC 94

authenticate 3, 14, 59

B

BACKSLASH_ESCAPE 64

badRequest 234

BigHttpSupport 56

BIGIOT_LIB 92

BIGIOT_PROXY 92

BigIotAPI 3

BigIotClientId 5

BIGIoTException 29

BigIotHttpResponse 234

BigIotTypes 85

birthday 195

BODY_PARAMETER 109

BOOLEAN 127

BRACE_SYNTAX 198

byteArrayFromPemCertificateFile 77

C

CARRIER_URL 64

Cheapest 178

cheapest 160

city 122, 191, 223, 226

clone 101, 105, 119, 226

close 60, 77

compareTo 115

COMPLEX_PARAMETER_KEY 61

ComplexObjectMembers 98

B260

Index

Page 338: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

complexObjectUrlSyntax 197

Constants 62

constructivePut 72

Consumer 6

ConsumerCore 9

country 122

create 17, 59, 130, 160, 183, 201, 208

createArray 131

createHttpClient 73

createHttpOnlyClient 59

createHttpsClient 73, 74

createMembers 108

createOfferingDescription 15, 18, 20

createOfferingDescriptionFromOfferingId 15, 18, 20

createOfferingQuery 9

createTrustingHttpsClient 73

createUser 190

CREATIVE_COMMONS 88

D

DATE 127

DATETIME 127

defaultOptions 25

delete 57, 58, 76, 77

deploy 139

DeployedOffering 139

deployOn 172

deploySwaggerFileFrom 246

deregister 15, 18, 139, 161, 162, 164

Description 100

df00 68

df000 68

df0000 68

df0_0000 68

discover 6, 7, 10, 12

discoverBlocking 10

DiscoverFailureException 48

discoverFuture 10, 12

discoverySubUrl 61

DOT_SYNTAX 198

DOUBLE_QUOTE_ESCAPE 64

E

EmbeddedSpark 23

EmbeddedTopicBasedServer 238

EmbededdedRouteBasedServer 239

enableCors 24

enableCorsAll 24

encode 185, 186, 187, 188, 189, 197, 199

END_POINT_MANAGEMENT_MAGIC 17

EndPoint 102

equals 5, 119, 159

equalsName 96

error 235

ESCAPE_SEQUENCE 185

EURO 112

Euros 116

EVENT 91

EXECUTOR_POOL_SIZE 61

ExperimentalBypassDecoder 63

ExperimentalBypassEncoder 64

EXTERNAL 92

ExternalRouteBasedServer 240

extractHiddenOfferingDescription 63

extractOfferingDescriptionsFromHttpResponse 69

F

FailedRegistrationException 30

failure 95

FEED 91

FeedFailureException 51

FeedStatus 42

fillout 65

FilloutTemplate 65

filter 175, 176, 177, 178

FORMAT_JSONLD 89

FORMAT_XML 89

formatDate 70

formatString 69

FREE 86

G

generate 231

get 56, 74, 75

getAcceptType 103

getAccessInterfaceType 103, 158

B261

Index

Page 339: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

getAccessToken 126

getActivation 157

getActivationString 66

getActivationStringFullResponse 66

getAmount 112, 115

getBaseUrl 239

getBody 136, 237

getCity 120, 192, 226

getClientSecret 60

getCode 95

getConsumer 181

getContentType 104

getCurrency 113, 115

getCurrentDate 232

getCurrentTime 232

getDeactivationString 67

getDescription 155, 225

getDomain 100

getEndpoints 155

getEndpointType 103

getExpirationDate 39, 42, 43, 232

getExpirationInterval 164

getExpirationTime 82, 232

getFeedType 42

getFindMatchingOfferingsString 67

getFormat 157

getHeaders 236

getId 126, 154, 207, 209

getInputData 157

getInterval 42

getIoData 138

getLatitude 110

getLicense 156

getList 132, 201

getLocalId 155, 207, 212

getLocation 229

getLongitude 110

getMappedFieldName 202

getMapping 138

getMarketplaceClient 3, 13, 164

getMax 216, 220

getMembers 107

getMeters 229

getMin 218, 220

getMoney 115

getMyAccessFeeds 143, 146, 148, 150, 153

getName 100, 106, 118, 125, 134, 154, 193

getNeCorner 228

getNextUniform 79, 253

getNorthEastCorner 84

getOffering 156

getOfferingDescription 144, 151, 161

getOfferingDescriptionString 66

getOfferingId 161, 164

getOfferingToken 150

getOutputData 157

getParametersForEncoding 131

getParameterType 107

getPojoAsJson 71

getPojoAsJsonCompact 71

getPrettyPrint 137

getPrice 156

getPricingModel 114, 214, 216, 218, 221

getProviderCertFile 3, 13

getProviderId 155

getQueryBaseTemplateString 67

getQueryId 181

getRandomPositionInside 80, 254

getRdfType 100, 107, 135, 155

getRegion 156

getRegistrationString 66

getRequestTemplates 158

getResource 71

getResponseTemplates 158

getRoute 164

getRoutes 24, 241

getSourceNamePath 203

getSouthWestCorner 84

getStatus 39, 40, 41, 43, 77, 82, 136, 236

getStreet 191

getSubscribtionWithQueryString 67

getSubTemplates 183

getSwCorner 228

getTemplate 183

getType 204

getUnsubscribtionString 67

getUri 102, 118

getValue 133, 159

getValueType 107

getVersion 194

B262

Index

Page 340: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

GraphQLQueries 66

H

hashCode 5, 119, 159

Helper 69

hideOfferingDescription 64

Hour 68

HTTP 61

HTTP_GET 90

HTTP_POST 90

HttpErrorException 31

I

IllegalAccessParameterException 32

inArea 223

inCity 167, 211

IncompleteOfferingDescriptionException 33

IncompleteOfferingQueryException 34

Information 105

inputStreamFromPemCertificateFile 77

inRangeAround 224

inRegion 167, 211

IOData 106

isClosed 73

isSecured 104

isTerminated 42

J

jsonPrettyPrint 71

L

lat 124

latitude 110

list 132

listToJson 72

lng 124

loadPublicX509 232

Location 110

log 255

longitude 110

M

main 190, 255, 256, 258, 259

map 137

mapOf 71

MappingIoDataTuple 138

mapToJson 71

MEDIA_TYPE_JSON 73

MessageTemplates 183

Minute 68

Money 112

MostPermissive 177

mostPermissive 160

N

Name 134, 203

name 125, 193, 195

nextBoolean 80, 254

nicknames 195

nl 61

NON_COMMERCIAL_DATA_LICENSE 88

NotRegisteredException 35

NUMBER 127

number 122

O

objectToJson 71

Offering 144

OfferingByExternal 145

OfferingCore 149

OfferingCoreByLib 152

OfferingDescription 154

offeringDescription 17

OfferingId 159

OfferingQuery 208

OfferingQueryChain 210

OfferingQueryPriceTemplate 250

OfferingQueryRequestTemplate 251

OfferingSelector 160

okay 95, 234

onExternalEndpoint 168

OnlyLocalhost 176

onlyLocalhost 160

B263

Index

Page 341: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

OPEN_DATA_LICENSE 88

OutputMappingTuple 202

P

ParameterEncoder 185

ParameterEncoderJson 186

ParameterEncoderPath 187

ParameterEncoderQuery 188

ParameterEncoderTemplate 189

ParameterEncoderTest 190

ParameterEncoderUrlTrial 197

ParameterEncoderXml 199

PATH_PARAMETER 109

PER_ACCESS 86

PER_BYTE 86

PER_MESSAGE 86

PER_MONTH 86

post 56, 57, 75

postCode 122

Price 114

PriceFilter 214

PriceFilterBetween 220

PriceFilterMax 216

PriceFilterMin 218

printDeltaTime 70, 71

processNotificationOnFailure 52

processNotificationOnSuccess 53

processRequestHandler 45, 54

processResponse 49, 50

processResponseOnFailure 46

processResponseOnSuccess 47

producesJson 173

producesXml 173

Product 193

products 195

Provider 17

ProviderSpark 20

put 57, 76

Q

QUERY_PARAMETER 109

R

radius 124

Random 79, 253

RDFType 118

Region 120

RegionFilter 223

RegionFilterBox 228

RegionFilterCircle 229

RegionFilterDescriptive 225

register 14, 15, 18, 162, 163

RegisteredOffering 161

RegisteredTwiceException 36

RegistrableOfferingDescription 163

RegistrableOfferingDescriptionChain 165, 166

remapJson 137

removeDefaultProxyBypass 78

removeProxyBypass 4

removeRoute 24, 241

request 59

resume 38, 40, 41, 43

round 70

S

Second 68

select 160

SelectionCriteria 175

ServerOptions 244

ServerOptionsSpark 25

setAcceptType 103

setAccessInterfaceType 103, 158

setAccessToken 126

setActivation 158

setAmount 112, 115

setCity 120, 121, 192, 227

setConsumer 181

setContentType 104

setCurrency 113, 115

setDefaultProxy 78

setDescription 155

setEndpoints 156

setEndpointType 103

setExpirationTime 82

setFormat 157

setId 126, 154, 207, 209

B264

Index

Page 342: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

setInputData 157

setLicense 156

setLifetimeSeconds 38, 40, 41, 43

setLocalId 155

setMarketplaceClient 164

setMembers 107

setMoney 115

setName 107, 118, 125, 155, 193

setOffering 157

setOfferings 164

setOfferingToken 150

setOutputData 157

setParameterType 107

setPrice 156, 214, 216, 218, 220

setPricingModel 114, 214, 216, 218, 220

setProviderId 155

setProxy 4

setQueryId 181

setRdfType 107, 155

setRegion 156

setRequestTemplates 158

setResponseTemplates 158

setStatus 82

setStreet 192

setSubTemplates 184

setTemplate 183

setUri 103, 119

setValueType 107

setVersion 194

showOfferingDescriptions 70, 180

showOfferingDescriptionsDetailed 181

showOfferingDescriptionsString 180

start 23, 238, 242

startHttp 23

state 122

steet 122

stop 24, 38, 40, 41, 43, 238, 242

street 191

subscribe 7, 179

subscribeBlocking 7, 179, 180

subscribeFuture 180

Subscription 126

swaggerFileName 62

SwaggerGenerator 246

SwaggerGeneratorJackson 248

SYNC 94

syncFeedInterval 61

T

TASK 91

TEMPLATE 109

terminate 3, 11, 13, 15, 17, 20, 148, 181

test 79, 253

TestComplexParameterConsumer 255

TestComplexParameterProvider 256

TestProviderWithSwaggerUI 258

TestSwaggerOnly 259

TEXT 127

TEXT_PLAIN 96

TIME 127

toNameMap 131

toOfferingQueryString 207, 208, 212

toQueryElement 5, 216, 218, 220, 222, 225, 226, 228, 229

toRegistrationString 121, 226

toString 5, 42, 83, 84, 97, 99, 100, 103, 108, 111, 113, 115,

119, 121, 126, 134, 135, 136, 158, 159, 176, 177, 178, 191,

193, 196, 201, 203, 204, 212

Type 135, 204

U

undeploy 139

unixTimeMillisToJoda 72

unixTimeToJoda 72

unmarshallingToData 69

unmarshallingToQueryName 70

unmarshallingToRootElement 69

UNSPECIFIED 92

unsubscribe 143, 146, 148, 150, 153

unsubscribeBlocking 143, 146, 148, 150, 153

USDOLLAR 112

USDollars 117

useOfferingDescription 171

User 195, 196

usingRequestTemplate 173

usingResponseTemplate 174

V

B265

Index

Page 343: Deliverable 3.1.b: BIG IoT API Design - Second Releasebig-iot.eu/wp-content/uploads/2016/04/BIG-IoT_D3.1.b-Second-Relea… · BIG IoT API Design - Second Release Version 1.0 Delivery

validate 231, 232

validateMarketplaceToken 231

validateOfferingAccessToken 231

value 205

valueOf 87, 88, 89, 90, 91, 92, 94, 95, 96, 109, 198

values 86, 88, 89, 90, 91, 92, 94, 95, 96, 109, 198

ValueType 127

W

WEBSOCKET 90

withAccessInterfaceType 171

withAccessRequestHandler 172

withBody 235

withDescription 166

withExpirationInterval 172

withInformation 166, 167, 210

withLicenseType 168, 212

withMaxPrice 211

withPrice 167

withPricingModel 167, 211

withProtocol 171

withRoute 171

withStatus 236

writeFile 71

wwwBigIot 62

wwwFolder 62

B266

Index