Main Page Namespace List Class Hierarchy Compound List File List Namespace Members Compound Members File Members

# mysqlpp::mysql_date Struct Reference

Base class of Date. More...

`#include <datetime.h>`

Inheritance diagram for mysqlpp::mysql_date:

[legend]
Collaboration diagram for mysqlpp::mysql_date:

[legend]
List of all members.

## Public Methods
std::ostream & | out_stream (std::ostream &os) const
| Insert the date into a stream.
cchar * | convert (cchar *)
| Parse a MySQL date string into this object.
## Public Attributes
short int | year
| the year
tiny_int | month
| the month, 1-12
tiny_int | day
| the day, 1-31
## Protected Methods
short int | compare (const mysql_date *other) const
| Compare this date to another.

## Detailed Description

Base class of Date.

## Member Function Documentation

short int mysqlpp::mysql_date::compare | ( | const mysql_date * | other | ) | const`[protected]`

| Compare this date to another. Returns < 0 if this date is before the other, 0 of they are equal, and > 0 if this date is after the other. This method is protected because it is merely the engine used by the various operators in DTbase.

ostream & mysqlpp::mysql_date::out_stream | ( | std::ostream & | os | ) | const

  | Insert the date into a stream. The format is YYYY-MM-DD, zero-padded. Parameters:
  os | stream to insert date into
Reimplemented in mysqlpp::DateTime.

## Member Data Documentation

short int mysqlpp::mysql_date::year

| the year No surprises; the year 2005 is stored as the integer 2005.

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

- datetime.h
- datetime.cpp