User story #264
Updated by Ivan Herrero about 9 years ago
*+Current prototype:+*
<pre>
/**
* @brief Moves within the stream to a position that is relative to the
* current location.
[..]
* @warning (1) The deltaPos is a signed integer, so it will always have a
* half addressable space with respect to its unsigned counterpart, i.e.
* the Seek() method.
* @warning (2) Moreover, the deltaPos is a 32 bits integer, less than the
* 64 bits integer used in Seek(), so it will have a shorter addressable
* space, anyway.
*/
virtual bool RelativeSeek(const int32 deltaPos) = 0;
</pre>
*+Desired prototype:+*
<pre>
/**
* @brief Moves within the stream to a position that is relative to the
* current location.
[..]
* @warning The deltaPos is a signed integer, so it will always have a
* half addressable space with respect to its unsigned counterpart, i.e.
* the Seek() method.
*/
virtual bool RelativeSeek(const int64 deltaPos) = 0;
</pre>
*+Update of descendants:+*
All the following classes implement the StreamI interface, so they must be updated accordingly, too.
* MARTe::BasicFile
* MARTe::DoubleBufferedStream
* * DummyDoubleBufferedStream
* MARTe::SingleBufferedStream
* * DummySingleBufferedStream
* MARTe::StreamMemoryReference
* MARTe::StreamString
*Hint:* Use the "Open type hierarchy" feature of Eclipse to show all the descendants of StreamI.
h1. Source code files modified
* Source/Core/BareMetal/L1Portability/BasicConsole.h
* Source/Core/BareMetal/L1Portability/Environment/Linux/BasicConsole.cpp
* Source/Core/BareMetal/L1Portability/Environment/Windows/BasicConsole.cpp
* Source/Core/BareMetal/L1Portability/StreamI.h
* Source/Core/BareMetal/L3Streams/BufferedStreamGenerator.h
* Source/Core/BareMetal/L3Streams/DoubleBufferedStream.cpp
* Source/Core/BareMetal/L3Streams/DoubleBufferedStream.h
* Source/Core/BareMetal/L3Streams/OperatingSystemCallbacksI.h
* Source/Core/BareMetal/L3Streams/SingleBufferedStream.cpp
* Source/Core/BareMetal/L3Streams/SingleBufferedStream.h
* Source/Core/BareMetal/L3Streams/StreamMemoryReference.cpp
* Source/Core/BareMetal/L3Streams/StreamMemoryReference.h
* Source/Core/BareMetal/L3Streams/StreamString.cpp
* Source/Core/BareMetal/L3Streams/StreamString.h
* Source/Core/FileSystem/L1Portability/BasicFile.h
* Source/Core/FileSystem/L1Portability/BasicTCPSocket.h
* Source/Core/FileSystem/L1Portability/BasicUDPSocket.h
* Source/Core/FileSystem/L1Portability/Environment/Linux/BasicFile.cpp
* Source/Core/FileSystem/L1Portability/Environment/Linux/BasicTCPSocket.cpp
* Source/Core/FileSystem/L1Portability/Environment/Linux/BasicUDPSocket.cpp
* Source/Core/FileSystem/L1Portability/Environment/Windows/BasicFile.cpp
* Source/Core/FileSystem/L1Portability/Environment/Windows/BasicTCPSocket.cpp
* Source/Core/FileSystem/L1Portability/Environment/Windows/BasicUDPSocket.cpp
* Test/Core/BareMetal/L3Streams/SingleBufferedStreamTest.cpp
* Test/Core/BareMetal/L3Streams/SingleBufferedStreamTest.h
* Test/Core/BareMetal/L3Streams/StreamMemoryReferenceTest.cpp
* Test/Core/BareMetal/L3Streams/StreamMemoryReferenceTest.h
* Test/Core/BareMetal/L3Streams/StreamStringTest.cpp
* Test/Core/BareMetal/L3Streams/StreamStringTest.h
* Test/Core/BareMetal/L3Streams/StreamTestHelper.h
* Test/GTest/BareMetal/L3Streams/SingleBufferedStreamGTest.cpp
* Test/GTest/BareMetal/L3Streams/StreamMemoryReferenceGTest.cpp
* Test/GTest/BareMetal/L3Streams/StreamStringGTest.cpp
h1. Architecture & design review
*Date of the review:* 03/11/2015
*Person who did the review:* Ivan Herrero
*Version of architecture & design document:* N/A. As per the original MARTe implementation, this is a support function and does not require formal design in UML.
*Result of review:* N/A
*List of non-conformities:* N/A
h1. Code and documentation review
*Date of the review:* 26/01/2016
*Person who did the review:* Ivan Herrero
*Result of review:* PASS
*List of non-conformities:* N/A.
*Note:* The function BasicConsole::Position() was not being tested, because BasicConsoleTest::TestPosition() was testing BasicConsole::Size() instead. It has been fixed.
h1. Unit test review
*Date of the review:* 26/01/2016
*Person who did the review:* Ivan Herrero
*Result of coverage tests review:* PASS
*Result of functional tests review:* PASS
*Result of review:* PASS
*List of non-conformities:* N/A
*Note:* The function BasicConsole::Position() was not being tested, because BasicConsoleTest::TestPosition() was testing BasicConsole::Size() instead. It has been fixed.
<pre>
/**
* @brief Moves within the stream to a position that is relative to the
* current location.
[..]
* @warning (1) The deltaPos is a signed integer, so it will always have a
* half addressable space with respect to its unsigned counterpart, i.e.
* the Seek() method.
* @warning (2) Moreover, the deltaPos is a 32 bits integer, less than the
* 64 bits integer used in Seek(), so it will have a shorter addressable
* space, anyway.
*/
virtual bool RelativeSeek(const int32 deltaPos) = 0;
</pre>
*+Desired prototype:+*
<pre>
/**
* @brief Moves within the stream to a position that is relative to the
* current location.
[..]
* @warning The deltaPos is a signed integer, so it will always have a
* half addressable space with respect to its unsigned counterpart, i.e.
* the Seek() method.
*/
virtual bool RelativeSeek(const int64 deltaPos) = 0;
</pre>
*+Update of descendants:+*
All the following classes implement the StreamI interface, so they must be updated accordingly, too.
* MARTe::BasicFile
* MARTe::DoubleBufferedStream
* * DummyDoubleBufferedStream
* MARTe::SingleBufferedStream
* * DummySingleBufferedStream
* MARTe::StreamMemoryReference
* MARTe::StreamString
*Hint:* Use the "Open type hierarchy" feature of Eclipse to show all the descendants of StreamI.
h1. Source code files modified
* Source/Core/BareMetal/L1Portability/BasicConsole.h
* Source/Core/BareMetal/L1Portability/Environment/Linux/BasicConsole.cpp
* Source/Core/BareMetal/L1Portability/Environment/Windows/BasicConsole.cpp
* Source/Core/BareMetal/L1Portability/StreamI.h
* Source/Core/BareMetal/L3Streams/BufferedStreamGenerator.h
* Source/Core/BareMetal/L3Streams/DoubleBufferedStream.cpp
* Source/Core/BareMetal/L3Streams/DoubleBufferedStream.h
* Source/Core/BareMetal/L3Streams/OperatingSystemCallbacksI.h
* Source/Core/BareMetal/L3Streams/SingleBufferedStream.cpp
* Source/Core/BareMetal/L3Streams/SingleBufferedStream.h
* Source/Core/BareMetal/L3Streams/StreamMemoryReference.cpp
* Source/Core/BareMetal/L3Streams/StreamMemoryReference.h
* Source/Core/BareMetal/L3Streams/StreamString.cpp
* Source/Core/BareMetal/L3Streams/StreamString.h
* Source/Core/FileSystem/L1Portability/BasicFile.h
* Source/Core/FileSystem/L1Portability/BasicTCPSocket.h
* Source/Core/FileSystem/L1Portability/BasicUDPSocket.h
* Source/Core/FileSystem/L1Portability/Environment/Linux/BasicFile.cpp
* Source/Core/FileSystem/L1Portability/Environment/Linux/BasicTCPSocket.cpp
* Source/Core/FileSystem/L1Portability/Environment/Linux/BasicUDPSocket.cpp
* Source/Core/FileSystem/L1Portability/Environment/Windows/BasicFile.cpp
* Source/Core/FileSystem/L1Portability/Environment/Windows/BasicTCPSocket.cpp
* Source/Core/FileSystem/L1Portability/Environment/Windows/BasicUDPSocket.cpp
* Test/Core/BareMetal/L3Streams/SingleBufferedStreamTest.cpp
* Test/Core/BareMetal/L3Streams/SingleBufferedStreamTest.h
* Test/Core/BareMetal/L3Streams/StreamMemoryReferenceTest.cpp
* Test/Core/BareMetal/L3Streams/StreamMemoryReferenceTest.h
* Test/Core/BareMetal/L3Streams/StreamStringTest.cpp
* Test/Core/BareMetal/L3Streams/StreamStringTest.h
* Test/Core/BareMetal/L3Streams/StreamTestHelper.h
* Test/GTest/BareMetal/L3Streams/SingleBufferedStreamGTest.cpp
* Test/GTest/BareMetal/L3Streams/StreamMemoryReferenceGTest.cpp
* Test/GTest/BareMetal/L3Streams/StreamStringGTest.cpp
h1. Architecture & design review
*Date of the review:* 03/11/2015
*Person who did the review:* Ivan Herrero
*Version of architecture & design document:* N/A. As per the original MARTe implementation, this is a support function and does not require formal design in UML.
*Result of review:* N/A
*List of non-conformities:* N/A
h1. Code and documentation review
*Date of the review:* 26/01/2016
*Person who did the review:* Ivan Herrero
*Result of review:* PASS
*List of non-conformities:* N/A.
*Note:* The function BasicConsole::Position() was not being tested, because BasicConsoleTest::TestPosition() was testing BasicConsole::Size() instead. It has been fixed.
h1. Unit test review
*Date of the review:* 26/01/2016
*Person who did the review:* Ivan Herrero
*Result of coverage tests review:* PASS
*Result of functional tests review:* PASS
*Result of review:* PASS
*List of non-conformities:* N/A
*Note:* The function BasicConsole::Position() was not being tested, because BasicConsoleTest::TestPosition() was testing BasicConsole::Size() instead. It has been fixed.