5#include <system/array.h>
6#include <system/exceptions.h>
7#include <system/idisposable.h>
8#include <system/io/memory_stream.h>
9#include <system/io/stream.h>
10#include <system/nullable.h>
11#include <system/object.h>
12#include <system/shared_ptr.h>
13#include <system/string.h>
14#include <system/text/encoding.h>
16#include <net/http/headers/http_content_headers.h>
18namespace System {
namespace Net {
namespace Http {
32 typedef ::System::BaseTypesInfo<BaseType> ThisTypeBaseTypesInfo;
34 ASPOSECPP_SHARED_RTTI_INFO_DECL();
46 typedef ::System::BaseTypesInfo<BaseType> ThisTypeBaseTypesInfo;
48 ASPOSECPP_SHARED_RTTI_INFO_DECL();
54 LimitMemoryStream(int32_t maxSize, int32_t capacity);
57 void Write(
const ArrayPtr<uint8_t>& buffer, int32_t offset, int32_t count)
override;
59 void Write(
const System::Details::ArrayView<uint8_t>& buffer, int32_t offset, int32_t count)
override;
61 void WriteByte(uint8_t value)
override;
68 void CheckSize(int32_t countToAdd);
124 bool _canCalculateLength;
126 static const int32_t UTF8CodePage;
128 static const int32_t UTF8PreambleLength;
130 static const uint8_t UTF8PreambleByte0;
132 static const uint8_t UTF8PreambleByte1;
134 static const uint8_t UTF8PreambleByte2;
136 static const int32_t UTF8PreambleFirst2Bytes;
138 static const int32_t UTF32CodePage;
140 static const int32_t UTF32PreambleLength;
142 static const uint8_t UTF32PreambleByte0;
144 static const uint8_t UTF32PreambleByte1;
146 static const uint8_t UTF32PreambleByte2;
148 static const uint8_t UTF32PreambleByte3;
150 static const int32_t UTF32OrUnicodePreambleFirst2Bytes;
152 static const int32_t UnicodeCodePage;
154 static const int32_t UnicodePreambleLength;
156 static const uint8_t UnicodePreambleByte0;
158 static const uint8_t UnicodePreambleByte1;
160 static const int32_t BigEndianUnicodeCodePage;
162 static const int32_t BigEndianUnicodePreambleLength;
164 static const uint8_t BigEndianUnicodePreambleByte0;
166 static const uint8_t BigEndianUnicodePreambleByte1;
168 static const int32_t BigEndianUnicodePreambleFirst2Bytes;
171 bool get_IsBuffered();
187 void CheckDisposed();
Template that represents wrapper of exceptions that are derived from Exception class.
Definition: exception.h:113
Defines method that releases resources owned by the current object. Objects of this class should only...
Definition: idisposable.h:30
Represents a stream that reads from and writes to memory. Objects of this class should only be alloca...
Definition: memory_stream.h:19
Represents content of an HTTP entity. Object of this class should only be allocated using System::Mak...
Definition: http_content.h:25
void LoadIntoBuffer()
Serializes content to a memory buffer.
System::SharedPtr< Headers::HttpContentHeaders > get_Headers()
Returns the HTTP content headers.
virtual void Dispose(bool disposing)
Disposes the current instance. This method also disposes the stream that is returned by 'ReadAsStream...
static System::SharedPtr< Text::Encoding > DefaultStringEncoding
The default encoding.
Definition: http_content.h:75
virtual void SerializeToStream(System::SharedPtr< IO::Stream > stream)=0
Serializes content to a stream.
void Dispose() override
Disposes the current instance. This method also disposes the stream that is returned by 'ReadAsStream...
virtual bool TryComputeLength(int64_t &length)=0
Tries to calculate the content size.
void LoadIntoBuffer(int64_t maxBufferSize)
Serializes content to a memory buffer.
String ReadAsString()
Serializes content and returns a string.
System::SharedPtr< IO::Stream > ReadAsStream()
Serializes content and returns a stream.
System::ArrayPtr< uint8_t > ReadAsByteArray()
Serializes content and returns a byte array.
static const int64_t MaxBufferSize
The maximum number of bytes.
Definition: http_content.h:73
HttpContent()
Constructs a new instance.
Pointer class to wrap types being allocated on heap. Use it to manage memory for classes inheriting O...
Definition: smart_ptr.h:180
String class used across the library. Is a substitute for C# System.String when translating code....
Definition: string.h:122
Definition: db_command.h:9