You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I need to write a custom MessageBodyReader (and MessageBodyWriter, this already works) to handle the TBytes type, such that this particular dynamic array type would be treated as a byte stream. This gives the ability to pass/return TBytes to/from a resource declared as consuming/producing a TMediaType.APPLICATION_OCTET_STREAM, without the need to create and having to deal with TMemoryStream (which seems to be the only currently/natively supported type when consuming/producing TMediaType.APPLICATION_OCTET_STREAM).
// TODO: Modify, try first GetObjectFromParam (to rename!) and then GetSimpleParam
The current code actually inhibits the ability to write such a custom MessageBodyReader for the TBytes type, which is a dynamic array and these are treated by special code that doesn't use the MessageBodyReader registry. Solving this TODO would probably solve my issue (well, I tried and it actually solves it, but I can't foresee the drawbacks).
The text was updated successfully, but these errors were encountered:
I need to write a custom MessageBodyReader (and MessageBodyWriter, this already works) to handle the
TBytes
type, such that this particular dynamic array type would be treated as a byte stream. This gives the ability to pass/returnTBytes
to/from a resource declared as consuming/producing aTMediaType.APPLICATION_OCTET_STREAM
, without the need to create and having to deal withTMemoryStream
(which seems to be the only currently/natively supported type when consuming/producingTMediaType.APPLICATION_OCTET_STREAM
).In reference to the following TODO:
WiRL/Source/Core/WiRL.Core.Application.Worker.pas
Line 396 in e72dad1
The current code actually inhibits the ability to write such a custom MessageBodyReader for the
TBytes
type, which is a dynamic array and these are treated by special code that doesn't use the MessageBodyReader registry. Solving this TODO would probably solve my issue (well, I tried and it actually solves it, but I can't foresee the drawbacks).The text was updated successfully, but these errors were encountered: