Update SerializeAdapter #513

Merged
gaisser merged 3 commits from KSat/fsfw:mueller/serializeif-update into development 2021-11-29 14:37:40 +01:00
Owner
  • Updates SerializerAdapter to also take simple pointer and simply assign the serialized and deSerialized size
  • Added related unittests
- Updates `SerializerAdapter` to also take simple pointer and simply assign the serialized and deSerialized size - Added related unittests
muellerr requested review from mohr 2021-10-22 11:27:44 +02:00
muellerr added the
feature
label 2021-10-22 11:28:13 +02:00
muellerr added this to the v3.0.0 milestone 2021-10-22 11:38:04 +02:00
gaisser reviewed 2021-11-02 14:15:56 +01:00
@ -84,0 +140,4 @@
* - @c RETURN_OK Successful deserialization
*/
template<typename T>
static ReturnValue_t deSerialize(T *object, const uint8_t* const buffer,
Owner

As the Pointer can not be changed here the second const seems useless to me.

This might get rid of the const_cast

As the Pointer can not be changed here the second const seems useless to me. This might get rid of the const_cast
Author
Owner

done

done
gaisser marked this conversation as resolved
gaisser reviewed 2021-11-02 16:45:36 +01:00
@ -84,0 +127,4 @@
*
* @details
* Object Must be trivially copy-able or a child of SerializeIF.
* Buffer will be moved to the current read location. Size will be decreased by the function.
Owner

The comment here is wrong. The size is no longer decreased.

The comment here is wrong. The size is no longer decreased.
Author
Owner

done. buffer is not moved as well here

done. buffer is not moved as well here
gaisser marked this conversation as resolved
gaisser reviewed 2021-11-02 16:52:56 +01:00
@ -84,0 +130,4 @@
* Buffer will be moved to the current read location. Size will be decreased by the function.
*
* @param[in] object: Pointer to object to deserialize
* @param[in/out] buffer: Buffer to deSerialize from
Owner

In this function the buffer is no "out" just in.

In this function the buffer is no "out" just in.
Author
Owner

done

done
gaisser marked this conversation as resolved
gaisser approved these changes 2021-11-08 14:50:09 +01:00
muellerr force-pushed mueller/serializeif-update from 1899d004eb to 30217aa42b 2021-11-10 18:53:00 +01:00 Compare
muellerr added 1 commit 2021-11-24 18:53:31 +01:00
muellerr added 1 commit 2021-11-29 14:36:28 +01:00
gaisser merged commit bf31248a50 into development 2021-11-29 14:37:40 +01:00
gaisser deleted branch mueller/serializeif-update 2021-11-29 14:37:46 +01:00
mohr refused to review 2021-12-06 14:05:40 +01:00
Sign in to join this conversation.
No description provided.