⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 hightimer.h

📁 linux程序
💻 H
字号:
#ifndef  _COMPUNICATE_HIGHTIMER_H_
#define  _COMPUNICATE_HIGHTIMER_H_

//#include <limits.h>
#include <stdio.h>
#include "OSHead.h"
#include <time.h>
#include <sys/time.h>


    class HighTimer
    {
    public:
    	HighTimer();
    	HighTimer(struct timeval t1);
		HighTimer(HighTimer &tm);
		HighTimer(UInt16 year,UInt16 month,UInt16 mday,UInt16 hour=0,UInt16 minute=0,UInt16 second=0,UInt32 milliseconds=0);
    	~HighTimer();
		
		void GetTimer(HighTimer *tm);
		
		UInt16 GetYear();
		UInt16 GetMonth();
		UInt16 GetDayOfMonth();
		UInt16 GetDayOfWeek();
		UInt16 GetDayOfYear();
		UInt16 GetHour();
		UInt16 GetMinute();
		UInt16 GetSecond();
		UInt32 GetMicroSeond();
		Bool8  GetIsError() { if(mIsError == 0) return 1;else return 0;}
		Bool8  SetSystemTimer();
		/// only test use
		void   DisplayMe();

    	// gettimeofday 
    private:
        struct timeval cTm;
        struct timezone cTmz;
        SInt32 mIsError;	
    	
    	
    };
#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -