template < typename T >

class LOB

Library: Data
Package: DataCore
Header: Poco/Data/LOB.h


Representation of a Large OBject.

A LOB can hold arbitrary data. The maximum size depends on the underlying database.

The LOBInputStream and LOBOutputStream classes provide a convenient way to access the data in a LOB.

Member Summary

Member Functions: appendRaw, assignRaw, assignVal, begin, clear, compact, content, end, operator !=, operator =, operator ==, rawContent, size, swap



typedef typename std::vector < T > Container;


typedef Poco::SharedPtr < Container > ContentPtr;


typedef typename std::vector < T >::const_iterator Iterator;


typedef T ValueType;


LOB inline


Creates an empty LOB.

LOB inline

    const std::vector < T > & content

Creates the LOB, content is deep-copied.

LOB inline

    const std::basic_string < T > & content

Creates a LOB from a string.

LOB inline

    const LOB & other

Creates a LOB by copying another one.

LOB inline

    const T * const pContent,
    std::size_t size

Creates the LOB by deep-copying pContent.


~LOB inline


Destroys the LOB.

Member Functions

appendRaw inline

void appendRaw(
    const T * pChar,
    std::size_t count

Assigns raw content to internal storage.

assignRaw inline

void assignRaw(
    const T * ptr,
    std::size_t count

Assigns raw content to internal storage.

assignVal inline

void assignVal(
    std::size_t count,
    const T & val

Assigns raw content to internal storage.

begin inline

Iterator begin() const;

clear inline

void clear(
    bool doCompact = false

Clears the content of the blob. If doCompact is true, trims the excess capacity.

compact inline

void compact();

Trims the internal storage excess capacity.

content inline

const std::vector < T > & content() const;

Returns the content.

end inline

Iterator end() const;

operator != inline

bool operator != (
    const LOB & other
) const;

Compares for inequality LOB by value.

operator = inline

LOB & operator = (
    const LOB & other

Assignment operator.

operator == inline

bool operator == (
    const LOB & other
) const;

Compares for equality LOB by value.

rawContent inline

const T * rawContent() const;

Returns the raw content.

If the LOB is empty, returns NULL.

size inline

std::size_t size() const;

Returns the size of the LOB in bytes.

swap inline

void swap(
    LOB & other

Swaps the LOB with another one.

Securely control IoT edge devices from anywhere   Connect a Device