BDE 4.14.0 Production release
Loading...
Searching...
No Matches
balber::BerUtil_DateAndTimeHeader Class Reference

#include <balber_berutil.h>

Public Types

typedef BerUtil_DateAndTimeHeaderType Type
 
typedef BerUtil_TimezoneOffsetImpUtil TimezoneUtil
 

Public Member Functions

 BerUtil_DateAndTimeHeader ()
 
 BerUtil_DateAndTimeHeader (const BerUtil_DateAndTimeHeader &original)=default
 
 ~BerUtil_DateAndTimeHeader ()=default
 Destroy this object.
 
BerUtil_DateAndTimeHeaderoperator= (const BerUtil_DateAndTimeHeader &rhs)=default
 
void makeNotExtendedBinary ()
 
void makeExtendedBinaryWithoutTimezone ()
 
void makeExtendedBinaryWithTimezone (int offset)
 
bool isExtendedBinary () const
 
bool isExtendedBinaryWithoutTimezone () const
 
bool isExtendedBinaryWithTimezone () const
 
int timezoneOffsetInMinutes () const
 

Detailed Description

This component-private, in-core, value-semantic attribute class provides a representation of the information available in the first two bytes of any extended-binary-encoding formatted data. All extended-binary encoding schemes for date-and-time types contain a 2-byte header in the same format, which can be unambiguously distinguished from the first 2 bytes of a date-and-time type in its corresponding compact-binary-encoding format or its ISO 8601 format.

See balber_berutil

Member Typedef Documentation

◆ TimezoneUtil

TimezoneUtil is an alias to a namespace for a suite of functions used to implement BER encoding and decoding operations for time-zone offset values.

◆ Type

Type is an alias to a namespace for enumerating the set of "header type" values that may be encoded in the 2-byte header of an extended-binary-encoding formatted date-and-time value.

Constructor & Destructor Documentation

◆ BerUtil_DateAndTimeHeader() [1/2]

balber::BerUtil_DateAndTimeHeader::BerUtil_DateAndTimeHeader ( )
inline

Create a BerUtil_DateAndTimeHeader object having a type attribute with the Type::e_NOT_EXTENDED_BINARY value and a timezoneOffsetInMinutes attribute with the 0 value.

◆ BerUtil_DateAndTimeHeader() [2/2]

balber::BerUtil_DateAndTimeHeader::BerUtil_DateAndTimeHeader ( const BerUtil_DateAndTimeHeader original)
default

Create a 'BerUtil_DateAndTimeHeader' object having the same value as the specified 'original' object.

◆ ~BerUtil_DateAndTimeHeader()

balber::BerUtil_DateAndTimeHeader::~BerUtil_DateAndTimeHeader ( )
default

Member Function Documentation

◆ isExtendedBinary()

bool balber::BerUtil_DateAndTimeHeader::isExtendedBinary ( ) const
inline

Return true if the type attribute of this object is Type::e_EXTENDED_BINARY_WITH_TIMEZONE or Type::e_EXTENDED_BINARY_WITHOUT_TIMEZONE, and false otherwise.

◆ isExtendedBinaryWithoutTimezone()

bool balber::BerUtil_DateAndTimeHeader::isExtendedBinaryWithoutTimezone ( ) const
inline

Return true if the type attribute of this object is Type::e_EXTENDED_BINARY_WITHOUT_TIMEZONE, and false otherwise.

◆ isExtendedBinaryWithTimezone()

bool balber::BerUtil_DateAndTimeHeader::isExtendedBinaryWithTimezone ( ) const
inline

Return true if the type attribute of this object is Type::e_EXTENDED_BINARY_WITH_TIMEZONE, and false otherwise.

◆ makeExtendedBinaryWithoutTimezone()

void balber::BerUtil_DateAndTimeHeader::makeExtendedBinaryWithoutTimezone ( )
inline

Set the type attribute of this object to the Type::e_EXTENDED_BINARY_WITHOUT_TIMEZONE value and the timezoneOffsetInMinutes attribute of this object to the 0 value.

◆ makeExtendedBinaryWithTimezone()

void balber::BerUtil_DateAndTimeHeader::makeExtendedBinaryWithTimezone ( int  offset)
inline

Set the type attribute of this object to the Type::e_EXTENDED_BINARY_WITH_TIMEZONE value and the timezoneOffsetInMinutes attribute of this object to the specified offset. The behavior is undefined unless TimezoneUtil::k_MIN_OFFSET <= offset and TimezoneUtil::k_MAX_OFFSET >= offset.

◆ makeNotExtendedBinary()

void balber::BerUtil_DateAndTimeHeader::makeNotExtendedBinary ( )
inline

Set the type attribute of this object to the Type::e_NOT_EXTENDED_BINARY value and the timezoneOffsetInMinutes attribute of this object to the 0 value.

◆ operator=()

BerUtil_DateAndTimeHeader & balber::BerUtil_DateAndTimeHeader::operator= ( const BerUtil_DateAndTimeHeader rhs)
default

Assign to this object the value of the specified 'rhs' object, and return a non-'const' reference to this object.

◆ timezoneOffsetInMinutes()

int balber::BerUtil_DateAndTimeHeader::timezoneOffsetInMinutes ( ) const
inline

Return the value of the timezoneOffsetInMinutes attribute of this object.


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