分享

C++中CTime的头文件

 xubin2016 2015-01-13
#include <afx.h> CTime CTime does not have a base class. A CTime object represents an absolute time and date. The CTime class incorporates the ANSI time_t data type and its associated run-time functions, including the ability to convert to and from a Gregorian date and 24-hour time. CTime values are based on coordinated universal time (UTC), which is equivalent to Greenwich mean time (GMT). The local time zone is controlled by the TZ environment variable. When creating a CTime, set the nDST parameter to 0 to indicate that standard time is in effect, or to a value greater than 0 to indicate that daylight savings time is in effect, or to a value less than zero to have the C run-time library code compute whether standard time or daylight savings time is in effect. tm_isdst is a required field. If not set, its value is undefined and the return value frommktime is unpredictable. If timeptr points to a tm structure returned by a previous call to asctime, gmtime, or localtime, the tm_isdst field contains the correct value. See the Run-Time Library Reference for more information on the time_t data type and the run-time functions that are used by CTime. A companion class, CTimeSpan, represents a time interval — the difference between two CTime objects. The CTime and CTimeSpan classes are not designed for derivation. Because there are no virtual functions, the size of CTime and CTimeSpan objects is exactly 4 bytes. Most member functions are inline. For more information on using CTime, see the articleDate and Time in Visual C++ Programmer’s Guide andTime Management in the Run-Time Library Reference. #include <afx.h> Class Members | Hierarchy Chart See Also Run-time functions:asctime,_ftime,gmtime,localtime,strftime,time -------------------------------------------------------------------------------- Send feedback to MSDN.Look here for MSDN Online resources.

    本站是提供个人知识管理的网络存储空间,所有内容均由用户发布,不代表本站观点。请注意甄别内容中的联系方式、诱导购买等信息,谨防诈骗。如发现有害或侵权内容,请点击一键举报。
    转藏 分享 献花(0

    0条评论

    发表

    请遵守用户 评论公约

    类似文章 更多