mirror of
https://github.com/pocoproject/poco.git
synced 2025-02-03 23:55:49 +01:00
TextEncodingRegistry documentation
This commit is contained in:
parent
a294e1fd88
commit
7250de8a65
@ -184,11 +184,15 @@ protected:
|
|||||||
|
|
||||||
|
|
||||||
class Foundation_API TextEncodingRegistry
|
class Foundation_API TextEncodingRegistry
|
||||||
|
/// This class serves as the main registry for all
|
||||||
|
/// supported TextEncoding's.
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
TextEncodingRegistry();
|
TextEncodingRegistry();
|
||||||
|
/// Constructs TextEncodingRegistry
|
||||||
|
|
||||||
~TextEncodingRegistry();
|
~TextEncodingRegistry();
|
||||||
|
/// Destroys TextEncodingRegistry
|
||||||
|
|
||||||
bool has(const std::string& name) const;
|
bool has(const std::string& name) const;
|
||||||
// Returns true if requested encoding is found.
|
// Returns true if requested encoding is found.
|
||||||
@ -196,12 +200,19 @@ public:
|
|||||||
// alternative encoding name.
|
// alternative encoding name.
|
||||||
|
|
||||||
void add(TextEncoding::Ptr pEncoding);
|
void add(TextEncoding::Ptr pEncoding);
|
||||||
|
/// Adds encoding to the registry under its canonnical name.
|
||||||
|
|
||||||
void add(TextEncoding::Ptr pEncoding, const std::string& name);
|
void add(TextEncoding::Ptr pEncoding, const std::string& name);
|
||||||
|
/// Adds encoding to the registry under the specified name.
|
||||||
|
|
||||||
void remove(const std::string& name);
|
void remove(const std::string& name);
|
||||||
|
/// Removes the specified encoding from the registry.
|
||||||
|
|
||||||
TextEncoding::Ptr find(const std::string& name) const;
|
TextEncoding::Ptr find(const std::string& name) const;
|
||||||
|
/// Returns Ptr to the enconding registerd under the speciied
|
||||||
|
/// name or having the name as an alias.
|
||||||
|
///
|
||||||
|
/// If encoding is not found, the returned Ptr points to nothing.
|
||||||
|
|
||||||
private:
|
private:
|
||||||
TextEncodingRegistry(const TextEncodingRegistry&);
|
TextEncodingRegistry(const TextEncodingRegistry&);
|
||||||
|
@ -375,7 +375,7 @@ Poco::Timespan WebSocketImpl::getReceiveTimeout()
|
|||||||
|
|
||||||
int WebSocketImpl::available()
|
int WebSocketImpl::available()
|
||||||
{
|
{
|
||||||
int n = _buffer.size() - _bufferOffset;
|
int n = static_cast<int>(_buffer.size()) - _bufferOffset;
|
||||||
if (n > 0)
|
if (n > 0)
|
||||||
return n + _pStreamSocketImpl->available();
|
return n + _pStreamSocketImpl->available();
|
||||||
else
|
else
|
||||||
|
Loading…
x
Reference in New Issue
Block a user