153 Service Layer API for oneM2M™

153.1 Introduction of oneM2M

oneM2M™ is a standard for IoT platform, which is standardized by oneM2M partnership project. oneM2M defines set of functionalities that are commonly used in IoT applications, which is called Common Services Function (CSF). The implementation of the CSF is provided by Communication Service Entity (CSE). oneM2M also defines the interface to use the CSF with REST oriented API that consist of limited types of operation (CREATE, RETRIEVE, UPDATE, DELETE, NOTIFY) on many types of resources. Applications of oneM2M use the interface to communicate with CSEs. In a system managed by a single service provider, multiple CSEs can exist and they form tree structure. The root CSE is called Infrastructure Node CSE (IN-CSE). Each application connects to one of CSEs in the system. CSEs have routing capability and application can send request to any CSEs in the system through the directly-connected CSE.

One of characteristic aspects of oneM2M is to allow multiple protocols and serialization formats for messages. Currently specified protocols are HTTP, CoAP, MQTT and WebSocket, and specified serialization are XML, JSON and CBOR (Concise Binary Object Representation). To make specification coherent, oneM2M specifications are separated into abstract level and concrete level. As abstract level, TS-0001 defines the oneM2M architecuture and resource types and TS-0004 defines data procedures and data structures. As concrete level, TS-0008 , TS-0009 , TS-0010 , and TS-0020 define concrete protocol which are mappoed to model of the abstract level. Here, the interface defined in abstract level, which independent on concrete protocols, is regarded as oneM2M Service Layer.

oneM2M Partners Type 1 (ARIB, ATIS, CCSA, ETSI, TIA, TSDSI, TTA, TTC) register oneM2M trademarks and logos in their respective jurisdictions.

153.2 Application Portability Problem of oneM2M

One of potential problems is application portability. oneM2M specifies protocol based interfaces, but doesn’t specify a programming level API. Without a standardized API, application program tends to be built tightly coupled with the libraries handling the communication method (combination of protocol and serialization) that is initially intend to use. In that case it would be hard to operate the application in another environment where different communication method is used; basically it is required to modify the application drastically. oneM2M could introduce segmentation of ecosystem within oneM2M compliant applications due to the lack of application portability.

153.3 Introduction of Service Layer API for oneM2M

This chapter provides interface to oneM2M applications for communicating communicate CSE at Service Layer of oneM2M. The providing API is protocol and serialization agnostic for preventing the problem above. Once application developer write code, it can be run in other environment where different communication method is used.

Another benefit of the service is reduction of computational resources, typically latency of execution in a certain cases, where both application and CSE is implemented on OSGi framework. In that case, it is possible to reduce executiontime for serialization/deserialization of data, context-switch of applications, compared to the case where they communicates with a certain communication protocol.

153.4 Essentials

  • Protocol Agnostic - API is independent on protocol that are used in communications. oneM2M specifies multiple protocols, which are HTTP, CoAP, MQTT and WebSocket. conversion operations.

  • Serialization Agnostic - API is independent on serialization that are actually used in communications. oneM2M specifies multiple serializations, which are XML, JSON and CBOR .

  • Support of synchoronous and asynchronous method call - API allows both of calling manners.

  • Use of Data Transfer Object (DTO) - DTO is used as parameters passing on API. Since oneM2M defines many types, concrete DTOs are specified for the higher level structure, and for lower structures generic DTO is used.

  • Low level and high level operations - API allows for applications to use both low level operation and high level operation, where low level operation allows all possible oneM2M operations and high level operation allows resource level operations, which are create, retrieve, update, and delete.

153.5 Entities

The following entities are used in this specification:

  • Application Bundle - Application, which use oneM2M CSE's capability. This specification assumes that an application bundle consists an oneM2M application.

  • ServiceLayer - This is the API used by oneM2M applications.

  • NotificationListener - Listener Interface, which is necessary to implement by oneM2M applications, when then need to received notifications.

  • ServiceLayer Implementation Bundle - Bundle providing implementation of ServiceLayer and its ServiceFactory.

  • oneM2M CSE - oneM2M's Server. It may exist remotely or locally.

Figure 153.1 Entity overview of Service Layer API for oneM2M

Entity overview of Service Layer API for oneM2M

153.6 oneM2M ServiceLayer

oneM2M ServiceLayer is the interface used by an application for sending request and get response as return method. It contains low level API and high level API.

request() method allows very raw data type access and it enables all possible message exchanges among oneM2M entities. This is called the low level API. The method takes requestPrimitive as an argument and returns responseRequest. It allows all possible operation of oneM2M. For the return type, OSGi Promise ( Promises Specification ) is used for allowing synchronous and asynchronous calling manner.

The low level API may be redundant to application developers, because they need to write composition of requestPrimitive and decomposition of responsePrimitive. Following methods allow application developers to develop application with less lines of code. They provides higher level of abstraction; operation level of resource such as create, retrieve, update, delete, notify and discovery. They cover typical oneM2M operations but do not cover all of possible messages of oneM2M.

Implementation of these high level API automatically inserts ‘requestID’ and ‘from’ parameter to RequestDTO.

Following example shows temperature measurement application using container resource and contentInstance resource.



ServiceReference<ServiceLayer> sr = bc
                                .getServiceReference(ServiceLayer.class);
ServiceLayer sl = bc.getService(sr);

ResourceDTO container = new ResourceDTO();
container.resourceType = Constants.RT_contentInstance;
container.resourceName = "temperatureStore";
sl.create("/CSE1/csebase", container).getValue();

ScheduledExecutorService service = Executors
                .newSingleThreadScheduledExecutor();

AtomicInteger count = new AtomicInteger(0);

service.scheduleAtFixedRate(() -> {
        ResourceDTO instance = new ResourceDTO();
        instance.resourceType = Constants.RT_contentInstance;
        instance.resourceName = "instance" + count.getAndIncrement();
        instance.attribute = new HashMap<String,Object>();
        instance.attribute.put("content", measureTemperature());

        sl.create("/CSE1/csebase/temperatureStore", instance);
}, 0, 60, TimeUnit.SECONDS);
  

Following example shows visualizing application of temperature data.


ServiceReference<ServiceLayer> sr = (ServiceReference<ServiceLayer>) bc
                .getServiceReference("org.osgi.service.onem2m.ServiceLayer");
ServiceLayer sl = bc.getService(sr);

FilterCriteriaDTO fc = new FilterCriteriaDTO();
fc.createdAfter = "20200101T120000";
fc.createdBefore = "20200101T130000";
List<Integer> resourceTypes = new ArrayList<Integer>();
resourceTypes.add(Constants.RT_contentInstance);
fc.resourceType = resourceTypes;
fc.filterOperation = FilterOperation.AND;

List<String> l = sl.discovery("/CSE1/csebase/temperatureStore", fc)
                .getValue();
List<Pair<String,Double>> renderData = new ArrayList<Pair<String,Double>>();
for (String uri : l) {
        ResourceDTO resource = sl.retrieve(uri).getValue();
        renderData.add(new Pair<String,Double>(resource.creationTime,
                        (Double) resource.attribute.get("content")));
}

renderService(renderData);
    

153.7 NotificationListener

NotificationListener is an interface for receiving oneM2M notification. An application that needs to receive oneM2M notifications must implement the interface and register it to the OSGi registry.

A ServiceLayer Implementation Bundle must call the notify() method of the NotificationListener, when it receives notification from CSE. In notification, target address is designated by AE-ID. The ServiceLayer Implementation Bundle finds the coresponding instance of the NotificationListener by checking its registerer bundle and checking internal mapping table of AE-ID and application bundle.


public class MyListener implements NotificationListener {
    public void notified(RequestPrimitiveDTO request){
	      NotificationDTO notification = request.content.notification;
	      NotificationEventDTO event = notification.notificationEvent;
			  Object updatedResource = event.representation;
	      NotificationEventType type = event.notificationEventType;
	      if( type == NotificationEventType.update_of_resource ){
	          // check updated resource, execute some actions.
	      }
	  }
}

@Activate
public void activate(BundleContext bc) {
    NotificationListener l = new MyListener();
		    bc.registerService(NotificationListener.class, l, null);
    }
}
      

153.8 DTO

OSGi DTOs are used for representing data structured passed on the API. Some of the data structures, which are directly referred from API or in small number of hops, are specified with concrete field names. The following figure shows DTOs with concrete field names, and reference relationship of class. Following DTO's rule, instances must not have loop reference relationship.

Figure 153.2 DTOs representing high level structures

DTOs representing high level structures

ResourceDTO represents oneM2M resource. ResourceDTO has both fields with concrete names and a field (named as attribute) for having sub-elements in generic manner. All of fields of the ResourceDTO represent attributes. Most of attributes have a primitive type and part of attributes have structured value. For structured value, if it possible defined concrete DTOs must be used, otherwise GenericDTO must be used.

oneM2M specifies two types of key names for representing name of resources, attributes, and elements of data structure, which are long name and short name. Long name is human readable representation, for example "resourceID", meanwhile short name is compact representation for minimizing network transfer, consist with typically 2-4 alphabetical characters, for example "ri". All field names in concrete DTOs are based on long name. Long name should be used for key names of GenericDTO and attribute names of ResourceDTO.

153.9 Security

Implementation of ServiceLayer may use credentials on behalf of application bundles on the communication with oneM2M CSE. So ServiceLayer Implementation should pass the service reference of ServiceLayer to only the proper application bundle. Use of ServiceFactory is to realize this. Application Bundles should not pass the service reference to other application bundles.

How to configure those credentials is left to developer of ServiceLayer Implementation, and it is out of scope the specification.

153.10 org.osgi.service.onem2m

Version 1.0

Service Layer API for oneM2M Specification Package Version 1.0.

Bundles wishing to use this package must list the package in the Import-Package header of the bundle's manifest. This package has two types of users: the consumers that use the API in this package and the providers that implement the API in this package.

Example import for consumers using the API in this package:

Import-Package: org.osgi.service.onem2m; version="[1.0,2.0)"

Example import for providers implementing the API in this package:

Import-Package: org.osgi.service.onem2m; version="[1.0,1.1)"

153.10.1 Summary

153.10.2 public interface NotificationListener

Interface to receive notification from other oneM2M entities.

Application that receives notification must implement this interface and register to OSGi service registry. No service property is required.

153.10.2.1 public void notified(RequestPrimitiveDTO request)

request primitive

receive notification.

153.10.3 public class OneM2MException
extends IOException

General Exception for oneM2M.

153.10.3.1 public OneM2MException(String message, int errorCode)

The exception message.

The exception error code.

Construct a OneM2MException with a message and an error code.

153.10.3.2 public int getErrorCode()

Return the error code for the exception.

The error code for the exception.

153.10.4 public interface ServiceLayer

Primary Interface for an oneM2M application entity to send request and get response to/from other oneM2M entity.

It contains low level API and high level API. The only low level method is request() and other methods are categorized as high level API.

Consumers of this API must not implement this type

153.10.4.1 public Promise<ResourceDTO> create(String uri, ResourceDTO resource)

URI for parent resource of the resource being created.

resource data

create resource

The create() method is a method to create new resource under specified uri. The second argument resource is expression of resource to be generated. The resourceType field of the resourceDTO must be assigned. For other fields depends on resource type. Section 7.4 of TS-00004 specifies the optionalities of the fields.

Promise of created resource

153.10.4.2 public Promise<Boolean> delete(String uri)

target URI for deleting resource

delete resource

delete resource on the URI specified by uri argument.

promise of execution status

153.10.4.3 public Promise<List<String>> discovery(String uri, FilterCriteriaDTO fc)

URI for resource tree to start the search

filter criteria selecting resources

find resources with filter condition specified in fc argument.

Discovery Result Type is kept as blank and default value of target CSE is used for the parameter.

list of URIs matching the condition specified in fc

153.10.4.4 public Promise<List<String>> discovery(String uri, FilterCriteriaDTO fc, RequestPrimitiveDTO.DesiredIdentifierResultType drt)

URI for resource tree to start the search

filter criteria

Discovery Result Type (structured/unstructured)

find resources with filter condition specified in fc argument.

With this method application can specify desired identifier in result

list of URIs matching the condition specified in fc

153.10.4.5 public Promise<Boolean> notify(String uri, NotificationDTO notification)

uri of destination

content of notification

send notification

Promise of notification execution status

153.10.4.6 public Promise<ResponsePrimitiveDTO> request(RequestPrimitiveDTO request)

request primitive

send a request and receive response.

This method allows very raw data type access and it enables all possible message exchanges among oneM2M entities. This is called the low level API. This method allows all possible operation of oneM2M. For the return type, OSGi Promise is used for allowing synchronous and asynchronous calling manner.

promise of ResponseDTO.

153.10.4.7 public Promise<ResourceDTO> retrieve(String uri)

URI for retrieving resource

retrieve resource

retrieve resource on URI specified by uri argument. This method retrieve all attributes of the resource.

retrieved resource data

153.10.4.8 public Promise<ResourceDTO> retrieve(String uri, List<String> targetAttributes)

URI for retrieving resource

names of the target attribute

retrieve resource with selected attributes.

retrieve resource on URI specified by uri argument. This method retrieve selected attributes by targetAttributes argument. The retrieve() methods are methods to retrieve resource on URI specified by uri argument.

retrieved resource data

153.10.4.9 public Promise<ResourceDTO> update(String uri, ResourceDTO resource)

URI for updating resource

data resource

update resource

The update() method is a method to update resource on the URI specified by uri argument. The resource argument holds attributes to be updated. Attributes not to be updated shall not included in the argument.

updated resource

153.11 org.osgi.service.onem2m.dto

Version 1.0

Service Layer Data Transfer Objects for oneM2M Specification Package Version 1.0.

Bundles wishing to use this package must list the package in the Import-Package header of the bundle's manifest. This package has two types of users: the consumers that use the API in this package and the providers that implement the API in this package.

Example import for consumers using the API in this package:

Import-Package: org.osgi.service.onem2m.dto; version="[1.0,2.0)"

Example import for providers implementing the API in this package:

Import-Package: org.osgi.service.onem2m.dto; version="[1.0,1.1)"

153.11.1 Summary

153.11.2 public class AttributeDTO
extends DTO

DTO expresses Attribute.

This class is typically used in FilterCriteriaDTO for expressing matching condition.

oneM2M TS-0004 6.3.5.9

Not Thread-safe

153.11.2.1 public String name

Attribute name

153.11.2.2 public Object value

Supposed value of the attribute

153.11.2.3 public AttributeDTO()

153.11.3 public class ChildResourceRefDTO
extends DTO

DTO expresses ChildResourceRef.

oneM2M TS-0004 6.3.5.29, oneM2M XSD childResourceRef

Not Thread-safe

153.11.3.1 public String name

name of the child resource pointed to by the URI

153.11.3.2 public String specializationID

resource type specialization of the child resource pointed to by the URI in case type represents a flexContainer. This is an optional field.

153.11.3.3 public Integer type

resourceType of the child resource pointed to by the URI

153.11.3.4 public String uri

URI to the child resource.

153.11.3.5 public ChildResourceRefDTO()

153.11.4 public final class Constants

This class defines constants for resource types.

oneM2M TS-0004 6.3.4.2.1

153.11.4.1 public static final int RT_accessControlPolicy = 1

resource type for accessControlPolicy

153.11.4.2 public static final int RT_accessControlPolicyAnnc = 10001

resource type for accessControlPolicyAnnc

153.11.4.3 public static final int RT_AE = 2

resource type for AE

153.11.4.4 public static final int RT_AEAnnc = 10002

resource type for AEAnnc

153.11.4.5 public static final int RT_AEContactList = 43

resource type for AEContactList

153.11.4.6 public static final int RT_AEContactListPerCSE = 44

resource type for AEContactListPerCSE

153.11.4.7 public static final int RT_authorizationDecision = 35

resource type for authorizationDecision

153.11.4.8 public static final int RT_authorizationInformation = 37

resource type for authorizationInformation

153.11.4.9 public static final int RT_authorizationPolicy = 36

resource type for authorizationPolicy

153.11.4.10 public static final int RT_backgroundDataTransfer = 49

resource type for backgroundDataTransfer

153.11.4.11 public static final int RT_container = 3

resource type for container

153.11.4.12 public static final int RT_containerAnnc = 10003

resource type for containerAnnc

153.11.4.13 public static final int RT_contentInstance = 4

resource type for contentInstance

153.11.4.14 public static final int RT_contentInstanceAnnc = 10004

resource type for contentInstanceAnnc

153.11.4.15 public static final int RT_crossResourceSubscription = 48

resource type for crossResourceSubscription

153.11.4.16 public static final int RT_CSEBase = 5

resource type for CSEBase

153.11.4.17 public static final int RT_delivery = 6

resource type for delivery

153.11.4.18 public static final int RT_dynamicAuthorizationConsultation = 34

resource type for dynamicAuthorizationConsultation

153.11.4.19 public static final int RT_dynamicAuthorizationConsultationAnnc = 10034

resource type for dynamicAuthorizationConsultationAnnc

153.11.4.20 public static final int RT_eventConfig = 7

resource type for eventConfig

153.11.4.21 public static final int RT_execInstance = 8

resource type for execInstance

153.11.4.22 public static final int RT_flexContainer = 28

resource type for flexContainer

153.11.4.23 public static final int RT_flexContainerAnnc = 10028

resource type for flexContainerAnnc

153.11.4.24 public static final int RT_group = 9

resource type for group

153.11.4.25 public static final int RT_groupAnnc = 10009

resource type for groupAnnc

153.11.4.26 public static final int RT_localMulticastGroup = 45

resource type for localMulticastGroup

153.11.4.27 public static final int RT_locationPolicy = 10

resource type for locationPolicy

153.11.4.28 public static final int RT_locationPolicyAnnc = 10010

resource type for locationPolicyAnnc

153.11.4.29 public static final int RT_m2mServiceSubscriptionProfile = 11

resource type for m2mServiceSubscriptionProfile

153.11.4.30 public static final int RT_mgmtCmd = 12

resource type for mgmtCmd

153.11.4.31 public static final int RT_mgmtObj = 13

resource type for mgmtObj

153.11.4.32 public static final int RT_mgmtObjAnnc = 10013

resource type for mgmtObjAnnc

153.11.4.33 public static final int RT_multimediaSession = 46

resource type for multimediaSession

153.11.4.34 public static final int RT_multimediaSessionAnnc = 10046

resource type for multimediaSessionAnnc

153.11.4.35 public static final int RT_node = 14

resource type for node

153.11.4.36 public static final int RT_nodeAnnc = 10014

resource type for nodeAnnc

153.11.4.37 public static final int RT_notificationTargetMgmtPolicyRef = 25

resource type for notificationTargetMgmtPolicyRef

153.11.4.38 public static final int RT_notificationTargetPolicy = 26

resource type for notificationTargetPolicy

153.11.4.39 public static final int RT_ontology = 39

resource type for ontology

153.11.4.40 public static final int RT_ontologyAnnc = 10039

resource type for ontologyAnnc

153.11.4.41 public static final int RT_ontologyRepository = 38

resource type for ontologyRepository

153.11.4.42 public static final int RT_ontologyRepositoryAnnc = 10038

resource type for ontologyRepositoryAnnc

153.11.4.43 public static final int RT_policyDeletionRules = 27

resource type for policyDeletionRules

153.11.4.44 public static final int RT_pollingChannel = 15

resource type for pollingChannel

153.11.4.45 public static final int RT_remoteCSE = 16

resource type for remoteCSE

153.11.4.46 public static final int RT_remoteCSEAnnc = 10016

resource type for remoteCSEAnnc

153.11.4.47 public static final int RT_request = 17

resource type for request

153.11.4.48 public static final int RT_role = 31

resource type for role

153.11.4.49 public static final int RT_schedule = 18

resource type for schedule

153.11.4.50 public static final int RT_scheduleAnnc = 10018

resource type for scheduleAnnc

153.11.4.51 public static final int RT_semanticDescriptor = 24

resource type for semanticDescriptor

153.11.4.52 public static final int RT_semanticDescriptorAnnc = 10024

resource type for semanticDescriptorAnnc

153.11.4.53 public static final int RT_semanticMashupInstance = 41

resource type for semanticMashupInstance

153.11.4.54 public static final int RT_semanticMashupInstanceAnnc = 10041

resource type for semanticMashupInstanceAnnc

153.11.4.55 public static final int RT_semanticMashupJobProfile = 40

resource type for semanticMashupJobProfile

153.11.4.56 public static final int RT_semanticMashupJobProfileAnnc = 10040

resource type for semanticMashupJobProfileAnnc

153.11.4.57 public static final int RT_semanticMashupResult = 42

resource type for semanticMashupResult

153.11.4.58 public static final int RT_semanticMashupResultAnnc = 10042

resource type for semanticMashupResultAnnc

153.11.4.59 public static final int RT_serviceSubscribedAppRule = 19

resource type for serviceSubscribedAppRule

153.11.4.60 public static final int RT_serviceSubscribedNode = 20

resource type for serviceSubscribedNode

153.11.4.61 public static final int RT_statsCollect = 21

resource type for statsCollect

153.11.4.62 public static final int RT_statsConfig = 22

resource type for

153.11.4.63 public static final int RT_subscription = 23

resource type for statsConfig

153.11.4.64 public static final int RT_timeSeries = 29

resource type for timeSeries

153.11.4.65 public static final int RT_timeSeriesAnnc = 10029

resource type for timeSeriesAnnc

153.11.4.66 public static final int RT_timeSeriesInstance = 30

resource type for timeSeriesInstance

153.11.4.67 public static final int RT_timeSeriesInstanceAnnc = 10030

resource type for timeSeriesInstanceAnnc

153.11.4.68 public static final int RT_token = 32

resource type for token

153.11.4.69 public static final int RT_transaction = 51

resource type for transaction

153.11.4.70 public static final int RT_transactionMgmt = 50

resource type for transactionMgmt

153.11.4.71 public static final int RT_triggerRequest = 47

resource type for triggerRequest

153.11.5 public class DasInfoDTO
extends DTO

DTO expresses DasInfo. DAS is short for Dynamic Authorization Server.

oneM2M TS-0004 6.3.5.45, oneM2M XSD dynAuthTokenReqInfo and dasInfo

Not Thread-safe

153.11.5.1 public GenericDTO dasRequest

Information to send to the Dynamic Authorization Server

oneM2M XSD dynAuthDasRequest

153.11.5.2 public String securedDasRequest

Secured Information to send to the Dynamic Authorization Server. JWS or JWE is assigned to this field.

153.11.5.3 public String uri

Dynamic Authorization Server URI

153.11.5.4 public DasInfoDTO()

153.11.6 public class FilterCriteriaDTO
extends DTO

DTO expresses FilterCriteria. This data structure is used for searching resources.

oneM2M TS-0004 6.3.5.8, oenM2M TS-0004 7.3.3.17.17

Not Thread-safe

153.11.6.1 public String applyRelativePath

Apply Relative Path

153.11.6.2 public List<AttributeDTO> attribute

Attribute

153.11.6.3 public List<AttributeDTO> childAttribute

Child Attribute

153.11.6.4 public List<String> childLabels

Child Labels

153.11.6.5 public List<Integer> childResourceType

Child Resource Type

153.11.6.6 public String contentFilterQuery

Content Filter Query

153.11.6.7 public Integer contentFilterSyntax

Content Filter Syntax

153.11.6.8 public List<String> contentType

Content Type

153.11.6.9 public String createdAfter

Created After

153.11.6.10 public String createdBefore

Created Before

153.11.6.11 public String expireAfter

Expire After

153.11.6.12 public String expireBefore

Expire Before

153.11.6.13 public FilterCriteriaDTO.FilterOperation filterOperation

Filter Operation

153.11.6.14 public FilterCriteriaDTO.FilterUsage filterUsage

Filter Usage

153.11.6.15 public List<String> labels

Labels

153.11.6.16 public String labelsQuery

Label Query

153.11.6.17 public Integer level

Level

153.11.6.18 public Integer limit

Limit number of Answers

153.11.6.19 public String modifiedSince

Modified Since

153.11.6.20 public Integer offset

Offset

153.11.6.21 public List<AttributeDTO> parentAttribute

Parent Attribute

153.11.6.22 public List<String> parentLabels

Parent Labels

153.11.6.23 public List<Integer> parentResourceType

Parent Resource Type

153.11.6.24 public List<Integer> resourceType

Resource Type

153.11.6.25 public List<String> semanticsFilter

Semantic Filter

153.11.6.26 public Integer sizeAbove

Size Above

153.11.6.27 public Integer sizeBelow

Size Below

153.11.6.28 public Integer stateTagBigger

State Tag Bigger

153.11.6.29 public Integer stateTagSmaller

State Tag Smaller

153.11.6.30 public String unmodifiedSince

Unmodified Since

153.11.6.31 public FilterCriteriaDTO()

153.11.7 enum FilterCriteriaDTO.FilterOperation

Enum FilterOperation

oneM2M TS-0004 6.3.4.2.34

153.11.7.1 AND

Logical AND

153.11.7.2 OR

Logical OR

153.11.7.3 public int getValue()

get assigned value

assigned integer value

153.11.7.4 public static FilterCriteriaDTO.FilterOperation valueOf(String name)

153.11.7.5 public static FilterCriteriaDTO.FilterOperation[] values()

153.11.8 enum FilterCriteriaDTO.FilterUsage

Enum FilterUsage

oneM2M TS-0004 6.3.4.2.31

153.11.8.1 DiscoveryCriteria

Discovery Criteria

153.11.8.2 ConditionalRetrival

Conditional Retrieve

153.11.8.3 IPEOndemandDiscovery

IPE on Demand Discovery

153.11.8.4 public int getValue()

get assigned integer value

assigned integer value

153.11.8.5 public static FilterCriteriaDTO.FilterUsage valueOf(String name)

153.11.8.6 public static FilterCriteriaDTO.FilterUsage[] values()

153.11.9 public class GenericDTO
extends DTO

GenericDTO expresses miscellaneous data structures of oneM2M.

Not Thread-safe

153.11.9.1 public Map<String, Object> element

Substructure of DTO. Type of the value part should be one of types allowed as OSGi DTO.

153.11.9.2 public GenericDTO()

153.11.10 public class IPEDiscoveryRequestDTO
extends DTO

IPEDiscoveryRequestDTO is an element of NotificationEventDTO

oneM2M TS-0004 6.3.5.13

Not Thread-safe

153.11.10.1 public FilterCriteriaDTO filterCriteria

FilterCriteria

oneM2M TS-0004 6.3.5.8

153.11.10.2 public String originator

originator

153.11.10.3 public IPEDiscoveryRequestDTO()

153.11.11 public class LocalTokenIdAssignmentDTO
extends DTO

DTO expresses LocalTokenIdAssignment.

oneM2M XSD dynAuthLocalTokenIdAssignments and localTokenIdAssignment

Not Thread-safe

153.11.11.1 public String localTokenID

local token ID

153.11.11.2 public String tokenID

token ID

153.11.11.3 public LocalTokenIdAssignmentDTO()

153.11.12 public class NotificationDTO
extends DTO

DTO expresses Notification.

oneM2M TS-0004 6.3.5.13

Not Thread-safe

153.11.12.1 public Boolean aeReferenceIDChange

aeReferenceIDChange element

oneM2M TS-0004 7.5.1.2.17

153.11.12.2 public Boolean aeRegistrationPointChange

AE Registration Point Change

oneM2M TS-0004 7.5.1.2.16

153.11.12.3 public String creator

creator

153.11.12.4 public IPEDiscoveryRequestDTO ipeDiscoveryRequest

IPE Discovery Request.

153.11.12.5 public NotificationEventDTO notificationEvent

Notification Event

153.11.12.6 public String notificationForwardingURI

notification forwarding URI

153.11.12.7 public String notificationTarget

ID for notification target

153.11.12.8 public Boolean subscriptionDeletion

Flag showing subscription deletion This field is optional.

153.11.12.9 public String subscriptionReference

URI referring subscription resource.

153.11.12.10 public String trackingID1

tracking ID 1

oneM2M TS-0004 7.5.1.2.16, oneM2M TS-0004 7.5.1.2.17

153.11.12.11 public String trackingID2

tracking ID 1

oneM2M TS-0004 7.5.1.2.16, oneM2M TS-0004 7.5.1.2.17

153.11.12.12 public Boolean verificationRequest

Flag showing verification request. This field is optional.

153.11.12.13 public NotificationDTO()

153.11.13 public class NotificationEventDTO

DTO expresses NotificationEventDTO

This data structure is held in NotificationDTO.

oneM2M TS-0004 6.3.5.13

Not Thread-safe

153.11.13.1 public NotificationEventDTO.NotificationEventType notificationEventType

notificationEventType

oneM2M TS-0004 6.3.4.2.19

153.11.13.2 public Map<String, Object> operationMonitor

operationMonitor

oneM2M TS-0004 6.3.5.57

153.11.13.3 public Object representation

m2m:representation

oneM2M TS-0004 6.3.5.62

153.11.13.4 public NotificationEventDTO()

153.11.14 enum NotificationEventDTO.NotificationEventType

NotificationEventType

oneM2M TS-0004 6.3.4.2.19

153.11.14.1 update_of_resource

update_of_resouce. This is the default value.

153.11.14.2 delete_of_resource

delete_of_resource

153.11.14.3 create_of_direct_child_resource

create_of_direct_child_resource

153.11.14.4 delete_of_direct_child_resouce

create_of_direct_child_resouce

153.11.14.5 retrieve_of_container_resource_with_no_child_resource

retrieve_of_container_resource_with_no_child_resource

153.11.14.6 public int getValue()

Return notification type value.

The notification type value.

153.11.14.7 public static NotificationEventDTO.NotificationEventType valueOf(String name)

153.11.14.8 public static NotificationEventDTO.NotificationEventType[] values()

153.11.15 public class PrimitiveContentDTO
extends DTO

DTO expresses Primitive Content.

This Data structure is used as union. Only one field MUST have a value, the others MUST be null.

oneM2M TS-0004 6.3.5.5, oneM2M TS-0004 7.2.1, oneM2M XSD primitiveContent

Not Thread-safe

153.11.15.1 public List<NotificationDTO> aggregatedNotification

Aggregated Notification

153.11.15.2 public List<ResponsePrimitiveDTO> aggregatedResponse

Aggregated Response

153.11.15.3 public List<String> attributeList

Attribute List

153.11.15.4 public List<ChildResourceRefDTO> childResourceRefList

Child Resource RefList

153.11.15.5 public String debugInfo

Debug Info

153.11.15.6 public List<String> listOfURIs

List Of URIs

153.11.15.7 public NotificationDTO notification

Notification

153.11.15.8 public String queryResult

Query Result

153.11.15.9 public RequestPrimitiveDTO requestPrimitive

Request Primitive

153.11.15.10 public ResourceDTO resource

Resource

153.11.15.11 public ResourceWrapperDTO resourceWrapper

Resource Wrapper

153.11.15.12 public ResponsePrimitiveDTO responsePrimitive

Response Primitive

153.11.15.13 public SecurityInfoDTO securityInfo

Security Info

153.11.15.14 public String uri

URI

153.11.15.15 public PrimitiveContentDTO()

153.11.16 enum ReleaseVersion

enum expresses oneM2M specification version.

This information is introduced after Release 2.0 and oneM2M uses only R2A, R3_0 (as 2a and 3).

oneM2M XSD releaseVersion

153.11.16.1 R1_0

Release 1

153.11.16.2 R1_1

Release 1.1

153.11.16.3 R2_0

Release 2

153.11.16.4 R2A

Release 2A

153.11.16.5 R3_0

Release 3

153.11.16.6 R4_0

Release 4 (reserved for future)

153.11.16.7 R5_0

Release 5 (reserved for future)

153.11.16.8 public static ReleaseVersion valueOf(String name)

153.11.16.9 public static ReleaseVersion[] values()

153.11.17 public class RequestPrimitiveDTO
extends DTO

DTO expresses Request Primitive.

oneM2M TS-0004 6.4.1, oneM2M XSD requestPrimitive

Not Thread-safe

153.11.17.1 public Boolean authorizationRelationshipIndicator

Authorization Relationship Indicator

153.11.17.2 public Boolean authorizationSignatureIndicator

Authorization Signature Indicator

153.11.17.3 public List<String> authorizationSignatures

Authorization Signatures

In oneM2M this parameter is expressed in m2m:signatureList.

oneM2M TS-0004 6.3.4.2.8, oneM2M XSD signatureList

153.11.17.4 public PrimitiveContentDTO content

Primitive Content

oneM2M TS-0004 6.3.5.5, oneM2M TS-0004 7.2.1.1

153.11.17.5 public Boolean deliveryAggregation

Delivery Aggregation

This parameter is related to CMDH(Communication Management and Delivery Handling) policy.

oneM2M TS-0004 D.12

153.11.17.6 public RequestPrimitiveDTO.DesiredIdentifierResultType desiredIdentifierResultType

Desired Identifier Result Type

This parameter specifies identifier type in response, such as structured or unstructured. This parameter used to be Discovery Result Type in previous oneM2M release.

oneM2M TS-0004 6.3.4.2.8

153.11.17.7 public Integer eventCategory

Event Category

allowed values are 2(Immediate), 3(BestEffort), 4(Latest), and 100-999 as user defined range.

oneM2M TS-0004 6.3.3, oneM2M XSD eventCat, oneM2M XSD stdEventCats

153.11.17.8 public FilterCriteriaDTO filterCriteria

Filter Criteria

oneM2M TS-0004 6.3.5.8

153.11.17.9 public String from

From Parameter.

Originator of the request is stored.

oneM2M TS-0004 6.3.4.2.5

153.11.17.10 public String groupRequestIdentifier

Group Request Identifier TODO: search doc.

153.11.17.11 public List<String> groupRequestTargetMembers

Group Request Target Members

153.11.17.12 public List<String> localTokenIDs

Local Token Identifiers

In oneM2M this parameter is expressed as list of xs:NCName.

153.11.17.13 public RequestPrimitiveDTO.Operation operation

Operation This field is mandatory.

oneM2M TS-0004 6.3.4.2.5

153.11.17.14 public String operationExecutionTime

Operation Execution Time

153.11.17.15 public String originatingTimestamp

Originating Timestamp

153.11.17.16 public ReleaseVersion releaseVersionIndicator

Release Version

153.11.17.17 public String requestExpirationTimestamp

Request Expiration Timestamp

* This parameter is related to CMDH(Communication Management and Delivery Handling) policy.

oneM2M TS-0004 D.12

153.11.17.18 public String requestIdentifier

Request Identifier

oneM2M TS-0004 6.3.3

153.11.17.19 public Integer resourceType

Resource Type

oneM2M TS-0004 6.3.4.2.1

153.11.17.20 public ResponseTypeInfoDTO responseType

Response Type Info

oneM2M TS-0004 6.3.5.30

153.11.17.21 public RequestPrimitiveDTO.ResultContent resultContent

Result Content

oneM2M TS-0004 6.3.4.2.7

153.11.17.22 public String resultExpirationTimestamp

Result Expiration Timestamp

This parameter is related to CMDH(Communication Management and Delivery Handling) policy.

oneM2M TS-0004 D.12

153.11.17.23 public String resultPersistence

Result Persistence

This parameter is related to CMDH(Communication Management and Delivery Handling) policy.

oneM2M TS-0004 D.12

153.11.17.24 public List<String> roleIDs

Role IDs

153.11.17.25 public Boolean semanticQueryIndicator

Semantic Query Indicator

oneM2M TS-0004 7.3.3.19

153.11.17.26 public String to

To Parameter

153.11.17.27 public List<String> tokenIDs

Token Identifiers

In oneM2M this parameter is expressed as list of m2m:tokenID.

oneM2M XSD signatureList

153.11.17.28 public Boolean tokenRequestIndicator

Token Request Indicator

153.11.17.29 public List<String> tokens

Tokens

Each token is in m2m:dynAuthJWT

oneM2M XSD signatureList

153.11.17.30 public String vendorInformation

Vendor Information

Used for vendor specific information. No procedure is defined for the parameter.

153.11.17.31 public RequestPrimitiveDTO()

153.11.18 enum RequestPrimitiveDTO.DesiredIdentifierResultType

Enum for DesiredIdentifierResultType

oneM2M TS-0004 6.3.4.2.8

153.11.18.1 structured

structured

153.11.18.2 unstructured

unstructured

153.11.18.3 public int getValue()

Return result type value.

The result type value.

153.11.18.4 public static RequestPrimitiveDTO.DesiredIdentifierResultType valueOf(String name)

153.11.18.5 public static RequestPrimitiveDTO.DesiredIdentifierResultType[] values()

153.11.19 enum RequestPrimitiveDTO.Operation

enum type for Operation

oneM2M XSD resultContent

153.11.19.1 Create

Create

153.11.19.2 Retrieve

Retrieve

153.11.19.3 Update

Update

153.11.19.4 Delete

Delete

153.11.19.5 Notify

Notify

153.11.19.6 public int getValue()

get assigned integer value

assigned integer value

153.11.19.7 public static RequestPrimitiveDTO.Operation valueOf(String name)

153.11.19.8 public static RequestPrimitiveDTO.Operation[] values()

153.11.20 enum RequestPrimitiveDTO.ResultContent

enum type for Result Content

oneM2M XSD resultContent

153.11.20.1 nothing

nothing

153.11.20.2 attributes

attributes

153.11.20.3 hierarchicalAddress

hierarchicalAddress

153.11.20.4 hierarchicalAddressAndAttributes

hierarchicalAddressAndAttributes

153.11.20.5 attributesAndChildResources

attributesAndChildResources

153.11.20.6 attributesAndChildResourceReferences

attributesAndChildResourceReferences

153.11.20.7 childResourceReferences

childResourceReferences

153.11.20.8 originalResource

originalResource

153.11.20.9 childResources

childResources

153.11.20.10 public int getValue()

get assigned integer value

assigned integer value

153.11.20.11 public static RequestPrimitiveDTO.ResultContent valueOf(String name)

153.11.20.12 public static RequestPrimitiveDTO.ResultContent[] values()

153.11.21 public class ResourceDTO
extends DTO

DTO expresses Resource.

Universal attributes are expressed in field of the class. Common attributes and other attributes are stored in attribute field.

oneM2M TS-0001 9.6.1.3.1

Not Thread-safe

153.11.21.1 public Map<String, Object> attribute

Non Universal Attribute. Value Part must be the types that are allowed for OSGi DTO. In case of value part can be expressed DTO in this package, the DTO must be used. In case of value part have sub-elements, GenericDTO must be used.

153.11.21.2 public String creationTime

Creation time

oneM2M TS-0001 9.6.1.3.1

153.11.21.3 public String lastModifiedTime

last modified time

oneM2M TS-0001 9.6.1.3.1

153.11.21.4 public String parentID

Parent ID Resource ID of parent resource.

oneM2M TS-0001 9.6.1.3.1

153.11.21.5 public String resourceID

Resource ID

oneM2M TS-0001 9.6.1.3.1

153.11.21.6 public String resourceName

Resource name

oneM2M TS-0001 9.6.1.3.1

153.11.21.7 public Integer resourceType

Resource Type

oneM2M TS-0001 9.6.1.3.1, oenM2M TS-0004 6.3.4.2.1

153.11.21.8 public ResourceDTO()

153.11.22 public class ResourceWrapperDTO
extends DTO

DTO expresses ResourceWrapper.

oneM2M TS-0004 6.3.5.25

Not Thread-safe

153.11.22.1 public ResourceDTO resource

Resource

153.11.22.2 public String uri

Hierarchical URI of the resource

153.11.22.3 public ResourceWrapperDTO()

153.11.23 public class ResponsePrimitiveDTO
extends DTO

DTO expresses Response Primitive.

oneM2M TS-0004 6.4.2, oneM2M XSD responsePrimitive

Not Thread-safe

153.11.23.1 public List<LocalTokenIdAssignmentDTO> assignedTokenIdentifiers

Assigned Token Identifiers

oneM2M TS-0004 6.3.5.43

153.11.23.2 public Boolean AuthSignatureReqInfo

AuthSignatureReqInfo

153.11.23.3 public PrimitiveContentDTO content

Primitive Content

oneM2M TS-0004 6.3.5.5, oneM2M TS-0004 7.2.1.2

153.11.23.4 public Integer contentOffset

Content Offset

153.11.23.5 public ResponsePrimitiveDTO.ContentStatus contentStatus

Content Status

oneM2M TS-0004 6.3.4.2.44

153.11.23.6 public Integer eventCategory

Event Category

allowed values are 2(Immediate), 3(BestEffort), 4(Latest), and 100-999 as user defined range.

oneM2M TS-0004 6.3.3, oneM2M XSD eventCat, oneM2M XSD stdEventCats

153.11.23.7 public String from

From Parameter

153.11.23.8 public String originatingTimestamp

Originating Timestamp To Parameter

oneM2M TS-0004 Table 6.3.3-1

153.11.23.9 public ReleaseVersion releaseVersionIndicator

Release Version Indicator

153.11.23.10 public String requestIdentifier

Request Identifier

oneM2M TS-0004 6.3.3

153.11.23.11 public Integer responseStatusCode

Response Status Code

oneM2M TS-0004 6.3.4.2.9

153.11.23.12 public String resultExpirationTimestamp

ResultExpiration Timestamp

oneM2M TS-0004 Table 6.3.3-1

153.11.23.13 public String to

To Parameter

oneM2M TS-0004 6.3.3

153.11.23.14 public List<DasInfoDTO> tokenReqInfo

Token Request Info

oneM2M TS-0004 6.3.5.45

153.11.23.15 public String vendorInformation

Vendor Information

Used for vendor specific information. No procedure is defined for the parameter.

153.11.23.16 public ResponsePrimitiveDTO()

153.11.24 enum ResponsePrimitiveDTO.ContentStatus

Enum ContentStatus

oneM2M TS-0004 6.3.4.2.44

153.11.24.1 PARTIAL_CONTENT

PARTIAL_CONTENT

153.11.24.2 FULL_CONTENT

FULL_CONTENT

153.11.24.3 public static ResponsePrimitiveDTO.ContentStatus valueOf(String name)

153.11.24.4 public static ResponsePrimitiveDTO.ContentStatus[] values()

153.11.25 public class ResponseTypeInfoDTO
extends DTO

DTO expresses ResponseTypeInfo

oneM2M TS-0004 6.3.5.30

Not Thread-safe

153.11.25.1 public List<String> notificationURI

Notification URI

oneM2M TS-0004 6.3.5.30, oneM2M TS-0004 7.5.1.2.5

153.11.25.2 public ResponseTypeInfoDTO.ResponseType responseTypeValue

Response Type Value

oneM2M TS-0004 6.3.4.2.6

153.11.25.3 public ResponseTypeInfoDTO()

153.11.26 enum ResponseTypeInfoDTO.ResponseType

enum ResponseType

oneM2M TS-0004 6.3.4.2.6

153.11.26.1 nonBlockingRequestSynch

nonBlockingRequestSynch

153.11.26.2 nonBlockingRequestAsynch

nonBlockingRequestAsynch

153.11.26.3 blockingRequest

blockingRequest

153.11.26.4 flexBlocking

flexBlocking

153.11.26.5 public int getValue()

get assigned value

assigned integer value.

153.11.26.6 public static ResponseTypeInfoDTO.ResponseType valueOf(String name)

153.11.26.7 public static ResponseTypeInfoDTO.ResponseType[] values()

153.11.27 public class SecurityInfoDTO
extends DTO

DTO expresses Security Info.

This class is used as union. SecurityInfoType field indicates which type of content is stored.

oenM2M TS-0004 6.3.5.4.8

Not Thread-safe

153.11.27.1 public GenericDTO dasRequest

Das Request

153.11.27.2 public GenericDTO dasResponse

Das Response

153.11.27.3 public byte[] escertkeMessage

Escertke Message

153.11.27.4 public String esprimObject

Esprim Object

153.11.27.5 public GenericDTO esprimRandObject

Esprim Rand Object

153.11.27.6 public SecurityInfoDTO.SecurityInfoType securityInfoType

Security Info Type

oenM2M TS-0004 6.3.4.2.35

153.11.27.7 public SecurityInfoDTO()

153.11.28 enum SecurityInfoDTO.SecurityInfoType

Enum SecurityInfoType

oenM2M TS-0004 6.3.4.2.35

153.11.28.1 DynamicAuthorizationRequest

DynamicAuthorizationRequest

153.11.28.2 DynamicAuthorizationResponse

DynamicAuthorizationResponse

153.11.28.3 ReceiverESPrimRandObjectRequest

ReceiverESPrimRandObjectRequest

153.11.28.4 ReceiverESPrimRandObjectResponse

ReceiverESPrimRandObjectResponse

153.11.28.5 ESPrimObject

ESPrimObject

153.11.28.6 ESCertKEMessage

ESCertKEMessage

153.11.28.7 DynamicAuthorizationRelationshipMappingRequest

DynamicAuthorizationRelationshipMappingRequest

153.11.28.8 DynamicAuthorizationRelationshipMappingResponse

DynamicAuthorizationRelationshipMappingResponse

153.11.28.9 public int getValue()

Get assigned value.

assigned value

153.11.28.10 public static SecurityInfoDTO.SecurityInfoType valueOf(String name)

153.11.28.11 public static SecurityInfoDTO.SecurityInfoType[] values()