-
Notifications
You must be signed in to change notification settings - Fork 408
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#1228: Add timestampedNodes support to SenML encoder.
- Loading branch information
1 parent
389e60b
commit a759c24
Showing
5 changed files
with
128 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
39 changes: 39 additions & 0 deletions
39
...an-core/src/main/java/org/eclipse/leshan/core/node/codec/TimestampedMultiNodeEncoder.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/******************************************************************************* | ||
* Copyright (c) 2022 Orange. | ||
* | ||
* All rights reserved. This program and the accompanying materials | ||
* are made available under the terms of the Eclipse Public License v2.0 | ||
* and Eclipse Distribution License v1.0 which accompany this distribution. | ||
* | ||
* The Eclipse Public License is available at | ||
* http://www.eclipse.org/legal/epl-v20.html | ||
* and the Eclipse Distribution License is available at | ||
* http://www.eclipse.org/org/documents/edl-v10.html. | ||
* | ||
* Contributors: | ||
* Orange | ||
*******************************************************************************/ | ||
package org.eclipse.leshan.core.node.codec; | ||
|
||
import org.eclipse.leshan.core.model.LwM2mModel; | ||
import org.eclipse.leshan.core.node.TimestampedLwM2mNodes; | ||
|
||
/** | ||
* An encoder for {@link TimestampedLwM2mNodes}. | ||
* | ||
* @see DefaultLwM2mEncoder | ||
*/ | ||
public interface TimestampedMultiNodeEncoder { | ||
/** | ||
* Serializes a {@link TimestampedLwM2mNodes} object into a byte array. | ||
* <p> | ||
* | ||
* @param timestampedNodes timestamped nodes to be serialized | ||
* @param model the collection of supported object models | ||
* @param converter value converter for resources | ||
* @return the serialized byte array | ||
* @throws CodecException if encoding fails | ||
*/ | ||
byte[] encodeTimestampedNodes(TimestampedLwM2mNodes timestampedNodes, LwM2mModel model, | ||
LwM2mValueConverter converter) throws CodecException; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters