datetime 类

警告

本主题包含有关 C++ REST SDK 1.0 (codename "Casablanca") 的信息。如果你正在从 Codeplex Casablanca 网页 使用更高版本,则使用 http://casablanca.codeplex.com/documentation 上的本地文档。

class datetime;

Members

公共 Typedef

名称

描述

interval_type

公共枚举

名称

描述

datetime::date_format 枚举

定义支持的日期和时间字符串格式。

公共构造函数

名称

描述

datetime::datetime 构造函数

公共方法

名称

描述

datetime::from_days 方法

datetime::from_hours 方法

datetime::from_minutes 方法

datetime::from_seconds 方法

datetime::from_string 方法

基于表示 UTC 时间的字符串创建 RFC 1123 格式的 datetime

datetime::is_initialized 方法

datetime::to_interval 方法

返回整数时间值。

datetime::to_string 方法

返回 datetime 的字符串表示形式。

datetime::utc_now 方法

返回当前 UTC 时间。

公共运算符

名称

描述

datetime::operator- 运算符

datetime::operator!= 运算符

datetime::operator+ 运算符

datetime::operator== 运算符

要求

**标头:**asyncrt_utils.h

**命名空间:**utility

请参见

参考

utility 命名空间