Vault  4.1
Public Member Functions | Static Public Member Functions | Protected Member Functions
VBentoBinary Class Reference

VBentoBinary is a VBentoAttribute that holds untyped data. More...

#include <vbento.h>

Inheritance diagram for VBentoBinary:
VBentoAttribute

List of all members.

Public Member Functions

 VBentoBinary ()
 Constructs with uninitialized name and a zero-length buffer.
 VBentoBinary (VBinaryIOStream &stream)
 Constructs by reading from stream.
 VBentoBinary (const VString &name, const Vu8 *data, Vs64 length)
 Constructs from supplied name and data that is copied.
 VBentoBinary (const VString &name, Vu8 *data, VMemoryStream::BufferAllocationType allocationType, bool adoptBuffer, Vs64 suppliedBufferSize, Vs64 suppliedEOFOffset)
 Constructs from supplied name and information.
virtual ~VBentoBinary ()
 Destructor.
virtual VBentoAttributeclone () const
VBentoBinaryoperator= (const VBentoBinary &rhs)
virtual void getValueAsXMLText (VString &s) const
 Returns a string suitable for an XML attribute value, including escaping via _escapeXMLValue() if needed.
virtual void getValueAsString (VString &s) const
 Returns a printable form of the attribute value.
virtual void getValueAsBentoTextString (VString &s) const
 Returns a Bento Text form of the attribute value.
VReadOnlyMemoryStream getReader () const
 Returns a read-only memory stream that can be used to read the binary data stream without actually modifying this attribute object; the buffer is not copied.
void setValue (Vu8 *buffer, VMemoryStream::BufferAllocationType allocationType, bool adoptBuffer, Vs64 suppliedBufferSize, Vs64 suppliedEOFOffset)
 Sets the attribute's data using VMemoryStream::adoptBuffer(); you can choose to share or copy the data depending on the parameters you specify.

Static Public Member Functions

static VBentoBinarynewFromBentoTextString (const VString &name, const VString &bentoText)
static const VStringDATA_TYPE_ID ()
 The data type name / class ID string.

Protected Member Functions

virtual Vs64 getDataLength () const
 Returns the length of this object's raw data only.
virtual void writeDataToBinaryStream (VBinaryIOStream &stream) const
 Writes the object's raw data only to a binary stream.

Detailed Description

VBentoBinary is a VBentoAttribute that holds untyped data.

Definition at line 1857 of file vbento.h.


Constructor & Destructor Documentation

VBentoBinary::VBentoBinary ( VBinaryIOStream stream) [inline]

Constructs by reading from stream.

Parameters:
streamthe stream to read

Definition at line 1865 of file vbento.h.

References VStream::streamCopy().


Member Function Documentation

VReadOnlyMemoryStream VBentoBinary::getReader ( ) const [inline]

Returns a read-only memory stream that can be used to read the binary data stream without actually modifying this attribute object; the buffer is not copied.

Returns:
readable stream on the buffer

Definition at line 1877 of file vbento.h.

References VMemoryStream::getBuffer(), and VMemoryStream::getEOFOffset().

virtual Vs64 VBentoBinary::getDataLength ( ) const [inline, protected, virtual]

Returns the length of this object's raw data only.

Returns:
the length of the object's raw data

Implements VBentoAttribute.

Definition at line 1882 of file vbento.h.

References VMemoryStream::getEOFOffset().

void VBentoBinary::writeDataToBinaryStream ( VBinaryIOStream stream) const [protected, virtual]

Writes the object's raw data only to a binary stream.

Parameters:
streamthe stream to write to

Implements VBentoAttribute.

Definition at line 1033 of file vbento.cpp.

References VMemoryStream::getBuffer(), VMemoryStream::getEOFOffset(), and VStream::streamCopy().


The documentation for this class was generated from the following files:

Copyright ©1997-2014 Trygve Isaacson. All rights reserved. This documentation was generated with Doxygen.