Last change
on this file since 820 was 818, checked in by イグトランス (egtra), 14 years ago |
Jenga/common/String.hに対するテストを追加
|
File size:
678 bytes
|
Line | |
---|
1 | #include <string>
|
---|
2 |
|
---|
3 | #pragma once
|
---|
4 |
|
---|
5 | namespace Jenga{
|
---|
6 | namespace Common{
|
---|
7 |
|
---|
8 |
|
---|
9 | class CmdLine{
|
---|
10 | std::string command;
|
---|
11 | std::string parameter;
|
---|
12 | public:
|
---|
13 |
|
---|
14 | CmdLine( const std::string &command, const std::string ¶meter )
|
---|
15 | : command( command )
|
---|
16 | , parameter( parameter )
|
---|
17 | {
|
---|
18 | }
|
---|
19 |
|
---|
20 | bool IsNamelessCommand() const
|
---|
21 | {
|
---|
22 | return ( command.size() == 0 );
|
---|
23 | }
|
---|
24 | const std::string& GetCommand() const
|
---|
25 | {
|
---|
26 | return command;
|
---|
27 | }
|
---|
28 | const std::string& GetParameter() const
|
---|
29 | {
|
---|
30 | return parameter;
|
---|
31 | }
|
---|
32 | };
|
---|
33 |
|
---|
34 | class CmdLines : public std::vector<CmdLine>
|
---|
35 | {
|
---|
36 | public:
|
---|
37 | CmdLines( const std::string &strCmdLine );
|
---|
38 | bool IsExist( const std::string &commandString ) const;
|
---|
39 | };
|
---|
40 |
|
---|
41 |
|
---|
42 | }}
|
---|
Note:
See
TracBrowser
for help on using the repository browser.