?? cvalidate.h
字號:
#ifndef _CVALIDATE_H
#define _CVALIDATE_H
#include "CDate.h"
#include <string>
using namespace std;
/*合法驗證類*/
class CValidate
{
public:
static int LengthIsTure(string &str, int length);//長度是否在給定范圍內
static int IsLetterOrSpace(string &str);//是否為字母或者空格
static int IsTureSex(string& str);//性別是否為'M'或'F'
//static int Datestrcmp(CDate &dateone,CDate &datetwo);//判斷兩個日期大小
static int DateRangle(CDate& currentDate, CDate& beginDate, CDate& endDate);//日期范圍
static int IsDateString(string &datestr,int sign);//是否是日期字符串,sign為0可為空
static int IsMobileTel(string &mobilestr,int sign);//是否符合電話號碼的要求,sign為0可為空
static int IsDataRangle(double data, double begin, double end);//data是否在begin與end之間,為double類型
static int IsDataRangle(int data, int begin, int end);//data是否在begin與end之間,為int類型
static int IsSelectRight(char *str,int select);//菜單選擇是否越界
};
#endif;
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -