亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? cmdline.h

?? 一款最完整的工業組態軟源代碼
?? H
字號:
/*------------------------------------------------------
   CCmdLine

   A utility for parsing command lines.

   Copyright (C) 1999 Chris Losinger, Smaller Animals Software.
   http://www.smalleranimals.com

   This software is provided 'as-is', without any express
   or implied warranty.  In no event will the authors be 
   held liable for any damages arising from the use of this software.

   Permission is granted to anyone to use this software 
   for any purpose, including commercial applications, and 
   to alter it and redistribute it freely, subject to the 
   following restrictions:

     1. The origin of this software must not be misrepresented; 
   you must not claim that you wrote the original software. 
   If you use this software in a product, an acknowledgment 
   in the product documentation would be appreciated but is not required.
   
     2. Altered source versions must be plainly marked as such, 
   and must not be misrepresented as being the original software.
   
     3. This notice may not be removed or altered from any source 
   distribution.

  -------------------------

   Example :

   Our example application uses a command line that has two
   required switches and two optional switches. The app should abort
   if the required switches are not present and continue with default
   values if the optional switches are not present.

      Sample command line : 
      MyApp.exe -p1 text1 text2 -p2 "this is a big argument" -opt1 -55 -opt2

      Switches -p1 and -p2 are required. 
      p1 has two arguments and p2 has one.
      
      Switches -opt1 and -opt2 are optional. 
      opt1 requires a numeric argument. 
      opt2 has no arguments.
      
      Also, assume that the app displays a 'help' screen if the '-h' switch
      is present on the command line.

   #include "CmdLine.h"

   void main(int argc, char **argv)
   {
      // our cmd line parser object
      CCmdLine cmdLine;

      // parse argc,argv 
      if (cmdLine.SplitLine(argc, argv) < 1)
      {
         // no switches were given on the command line, abort
         ASSERT(0);
         exit(-1);
      }

      // test for the 'help' case
      if (cmdLine.HasSwitch("-h"))
      {
         show_help();
         exit(0);
      }

      // get the required arguments
      StringType p1_1, p1_2, p2_1;
      try
      {  
         // if any of these fail, we'll end up in the catch() block
         p1_1 = cmdLine.GetArgument("-p1", 0);
         p1_2 = cmdLine.GetArgument("-p1", 1);
         p2_1 = cmdLine.GetArgument("-p2", 0);

      }
      catch (...)
      {
         // one of the required arguments was missing, abort
         ASSERT(0);
         exit(-1);
      }

      // get the optional parameters

      // convert to an int, default to '100'
      int iOpt1Val =    atoi(cmdLine.GetSafeArgument("-opt1", 0, 100));

      // since opt2 has no arguments, just test for the presence of
      // the '-opt2' switch
      bool bOptVal2 =   cmdLine.HasSwitch("-opt2");

      .... and so on....

   }

   If this class is used in an MFC application, StringType is CString, else
   it uses the STL 'string' type.

   If this is an MFC app, you can use the __argc and __argv macros from
   you CYourWinApp::InitInstance() function in place of the standard argc 
   and argv variables. 

------------------------------------------------------*/
#ifndef SACMDSH
#define SACMDSH

#if _MSC_VER > 1000
	#pragma once
	#pragma warning(disable:4786)
	#pragma warning (disable : 4018)
#endif // _MSC_VER > 1000

// #ifdef __AFX_H__
// 	// if we're using MFC, use CStrings 
// #define StringType CString
// #else
// 	// if we're not using MFC, use STL strings
// #define StringType string
// #endif
#ifdef __GNUC__
	#include "ZipString.h"
#else
	#include "../../ZipString.h"
#endif

#define StringType CZipString



//#include <iostream> // you may need this
#include <map>
#include <string>
#include <vector>
using namespace std ;

// handy little container for our argument vector
struct CCmdParam
{
   vector<StringType> m_strings;
};

// this class is actually a map of strings to vectors
typedef map<StringType, CCmdParam> _CCmdLine;

// the command line parser class
class CCmdLine : public _CCmdLine
{

public:
   /*------------------------------------------------------
      int CCmdLine::SplitLine(int argc, char **argv)

      parse the command line into switches and arguments.

      returns number of switches found
   ------------------------------------------------------*/
   int         SplitLine(int argc, char **argv);

   /*------------------------------------------------------
      bool CCmdLine::HasSwitch(const char *pSwitch)

      was the switch found on the command line ?

      ex. if the command line is : app.exe -a p1 p2 p3 -b p4 -c -d p5

      call                          return
      ----                          ------
      cmdLine.HasSwitch("-a")       true
      cmdLine.HasSwitch("-z")       false
   ------------------------------------------------------*/   
   bool        HasSwitch(const char *pSwitch);

   /*------------------------------------------------------

      StringType CCmdLine::GetSafeArgument(const char *pSwitch, int iIdx, const char *pDefault)

      fetch an argument associated with a switch . if the parameter at
      index iIdx is not found, this will return the default that you
      provide.

      example :
  
      command line is : app.exe -a p1 p2 p3 -b p4 -c -d p5

      call                                      return
      ----                                      ------
      cmdLine.GetSafeArgument("-a", 0, "zz")    p1
      cmdLine.GetSafeArgument("-a", 1, "zz")    p2
      cmdLine.GetSafeArgument("-b", 0, "zz")    p4
      cmdLine.GetSafeArgument("-b", 1, "zz")    zz

   ------------------------------------------------------*/

   StringType  GetSafeArgument(const char *pSwitch, int iIdx, const char *pDefault);

   /*------------------------------------------------------

      StringType CCmdLine::GetArgument(const char *pSwitch, int iIdx)

      fetch a argument associated with a switch. throws an exception 
      of (int)0, if the parameter at index iIdx is not found.

      example :
  
      command line is : app.exe -a p1 p2 p3 -b p4 -c -d p5

      call                             return
      ----                             ------
      cmdLine.GetArgument("-a", 0)     p1
      cmdLine.GetArgument("-b", 1)     throws (int)0, returns an empty string

   ------------------------------------------------------*/
   StringType  GetArgument(const char *pSwitch, int iIdx); 

   /*------------------------------------------------------
      int CCmdLine::GetArgumentCount(const char *pSwitch)

      returns the number of arguments found for a given switch.

      returns -1 if the switch was not found

   ------------------------------------------------------*/
   int         GetArgumentCount(const char *pSwitch);

protected:
   /*------------------------------------------------------

   protected member function
   test a parameter to see if it's a switch :

   switches are of the form : -x
   where 'x' is one or more characters.
   the first character of a switch must be non-numeric!

   ------------------------------------------------------*/
   bool        IsSwitch(const char *pParam);
};

#endif

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久99精品久久只有精品| 91在线视频免费91| 国产欧美精品国产国产专区| 欧美精品久久一区二区三区| 色国产综合视频| 色婷婷久久久综合中文字幕| 一本大道久久a久久综合婷婷| 色香蕉久久蜜桃| 欧美精品一级二级| 欧美mv日韩mv国产网站app| 久久色视频免费观看| 国产亚洲欧美一区在线观看| 中文成人av在线| 一区二区成人在线| 日韩av一区二区在线影视| 精一区二区三区| 成人av免费在线播放| 91色|porny| 91精品国产入口| 亚洲国产精品t66y| 亚洲综合一二区| 国内成人自拍视频| 91麻豆免费看| 精品日韩99亚洲| 国产精品美女久久久久av爽李琼 | 色婷婷久久久综合中文字幕| 欧美亚洲综合久久| 精品欧美黑人一区二区三区| 日本一区二区在线不卡| 亚洲一区二区三区免费视频| 九九九精品视频| 91麻豆国产在线观看| 日韩美女天天操| 亚洲综合视频在线观看| 国产一区二区在线看| 日本精品一区二区三区四区的功能| 欧美一区二区三区婷婷月色| 国产精品每日更新在线播放网址| 丝袜诱惑制服诱惑色一区在线观看| 国产一区二区三区四区五区入口| 欧洲色大大久久| 国产亚洲视频系列| 日本不卡免费在线视频| 色综合亚洲欧洲| 久久久久久久性| 日韩黄色小视频| 日本韩国精品在线| 国产欧美一区视频| 久久国产婷婷国产香蕉| 欧美日韩一卡二卡三卡| 亚洲人吸女人奶水| 国产成人av电影在线| 欧美三级日韩在线| 亚洲乱码国产乱码精品精98午夜| 国产一区二区三区香蕉| 欧美日韩aaa| 亚洲午夜在线电影| 色综合天天在线| 亚洲欧美一区二区在线观看| 国产91色综合久久免费分享| 这里只有精品视频在线观看| 亚洲欧洲日韩一区二区三区| 国产精品一区在线观看你懂的| 日韩一级大片在线| 日本成人在线一区| 欧美一二区视频| 美腿丝袜亚洲一区| 欧美刺激脚交jootjob| 日日夜夜免费精品视频| 欧美精品日韩综合在线| 天堂成人免费av电影一区| 欧美精品一二三区| 日本美女一区二区| 欧美精品一区二区三区四区| 国产综合色视频| 精品少妇一区二区三区| 国产又粗又猛又爽又黄91精品| 精品动漫一区二区三区在线观看| 视频一区二区不卡| 日韩免费观看高清完整版在线观看| 人妖欧美一区二区| 2020国产精品| www.亚洲精品| 一区二区高清在线| 777a∨成人精品桃花网| 久久se这里有精品| 国产日产亚洲精品系列| 97精品视频在线观看自产线路二| 亚洲色大成网站www久久九九| 91官网在线观看| 日韩高清国产一区在线| 久久婷婷国产综合精品青草| 国产不卡在线视频| 亚洲综合色在线| 日韩视频一区二区三区| 成人妖精视频yjsp地址| 亚洲欧美日韩在线| 日韩欧美黄色影院| 成人久久视频在线观看| 午夜精品免费在线观看| 精品国产一区二区亚洲人成毛片| 懂色av一区二区三区免费观看| 亚洲精品国产精华液| 日韩三级精品电影久久久| 国产成人精品免费在线| 亚洲一区二区三区爽爽爽爽爽| 91麻豆精品国产91久久久久久久久 | 日本不卡123| 国产日产精品1区| 欧美中文字幕一区二区三区亚洲| 蜜臀av一区二区在线观看| 久久久久久久久岛国免费| 色综合久久88色综合天天| 性久久久久久久久| 欧美激情一区在线| 91精选在线观看| 成人app在线观看| 蜜芽一区二区三区| 国产精品毛片无遮挡高清| 91精品国产一区二区三区蜜臀| 成人高清视频在线观看| 精品一区二区三区在线播放| 亚洲综合网站在线观看| 国产精品麻豆欧美日韩ww| 欧美电影免费观看高清完整版| 色综合久久中文综合久久牛| 国产在线不卡一区| 麻豆91免费观看| 天天爽夜夜爽夜夜爽精品视频| 综合分类小说区另类春色亚洲小说欧美| 91精品国产综合久久小美女| 9久草视频在线视频精品| 国产又粗又猛又爽又黄91精品| 午夜电影网一区| 亚洲精品成人精品456| 日韩精品最新网址| 日韩一区二区三区av| 欧美精品tushy高清| 欧美三区在线观看| 欧美色综合天天久久综合精品| kk眼镜猥琐国模调教系列一区二区| 国产成人综合网| 国模少妇一区二区三区| 蜜臀av性久久久久蜜臀av麻豆 | 69久久99精品久久久久婷婷 | 精品国精品国产尤物美女| 欧美人狂配大交3d怪物一区| 色婷婷激情一区二区三区| 色先锋资源久久综合| 欧美在线视频你懂得| 在线观看av一区二区| 色88888久久久久久影院野外| 91一区二区在线观看| 色香色香欲天天天影视综合网| 一本久久精品一区二区| 91成人免费在线| 欧美日韩激情在线| 日韩欧美国产成人一区二区| 精品国产欧美一区二区| 久久婷婷成人综合色| 中文字幕电影一区| 亚洲激情自拍偷拍| 亚洲成人av福利| 精品一区二区日韩| 成人福利视频在线看| 色综合久久综合网欧美综合网| 欧美日韩一区视频| 精品少妇一区二区三区| 国产日韩精品一区| 亚洲伦在线观看| 日韩中文字幕亚洲一区二区va在线 | 欧美三级日韩在线| 日韩午夜中文字幕| 久久精品视频一区二区三区| 亚洲人成在线播放网站岛国| 天天亚洲美女在线视频| 国产精品一二一区| 色呦呦国产精品| 欧美一区二区网站| 国产精品网站导航| 免费精品视频在线| 成人97人人超碰人人99| 在线不卡一区二区| 国产日韩av一区| 日韩精品一二三四| 成人性生交大片免费看视频在线| 欧美伊人久久大香线蕉综合69 | 国产日韩欧美综合在线| 亚洲黄色小说网站| 久久99久久精品| 日本久久一区二区三区| 久久久亚洲午夜电影| 一区二区在线看| 福利电影一区二区三区| 欧美日韩不卡一区二区| 国产精品成人免费在线| 精品一区二区三区免费| 色综合久久综合网97色综合| 国产日韩欧美亚洲| 日产国产欧美视频一区精品 |