BadScript 2
Loading...
Searching...
No Matches
Verb_Fakes.cs
Go to the documentation of this file.
1
// Copyright 2005-2015 Giacomo Stelluti Scala & Contributors. All rights reserved. See License.md in the project root for license information.
2
3
using
System.Collections.Generic;
4
5
namespace
CommandLine.Tests.Fakes
6
{
7
[Verb(
"add"
, HelpText =
"Add file contents to the index."
)]
8
public
class
Add_Verb
9
{
10
[Option(
'p'
,
"patch"
, SetName =
"mode-p"
,
11
HelpText =
"Interactively choose hunks of patch between the index and the work tree and add them to the index."
)]
12
public
bool
Patch
{
get
;
set
; }
13
14
[Option(
'f'
,
"force"
, SetName =
"mode-f"
,
15
HelpText =
"Allow adding otherwise ignored files."
)]
16
public
bool
Force
{
get
;
set
; }
17
18
[Value(0)]
19
public
string
FileName
{
get
;
set
; }
20
}
21
[Verb(
"add"
, isDefault:true,HelpText =
"Add file contents to the index."
)]
22
public class
Add_Verb_As_Default
23
{
24
[Option(
'p'
,
"patch"
, SetName =
"mode-p"
,
25
HelpText =
"Interactively choose hunks of patch between the index and the work tree and add them to the index."
)]
26
public
bool
Patch {
get
;
set
; }
27
28
[Option(
'f'
,
"force"
, SetName =
"mode-f"
,
29
HelpText =
"Allow adding otherwise ignored files."
)]
30
public
bool
Force {
get
;
set
; }
31
32
[Value(0)]
33
public
string
FileName {
get
;
set
; }
34
}
35
[Verb(
"commit"
, HelpText =
"Record changes to the repository."
)]
36
public
class
Commit_Verb
37
{
38
[Option(
'p'
,
"patch"
,
39
HelpText =
"Use the interactive patch selection interface to chose which changes to commit."
)]
40
public
bool
Patch
{
get
;
set
; }
41
42
[Option(
"amend"
, HelpText =
"Used to amend the tip of the current branch."
)]
43
public
bool
Amend
{
get
;
set
; }
44
45
[Option(
'm'
,
"message"
, HelpText =
"Use the given message as the commit message."
)]
46
public
string
Message
{
get
;
set
; }
47
}
48
49
[Verb(
"clone"
, HelpText =
"Clone a repository into a new directory."
)]
50
public
class
Clone_Verb
51
{
52
[Option(
"no-hardlinks"
,
53
HelpText =
"Optimize the cloning process from a repository on a local filesystem by copying files."
)]
54
public
bool
NoHardLinks
{
get
;
set
; }
55
56
[Option(
'q'
,
"quiet"
,
57
HelpText =
"Suppress summary message."
)]
58
public
bool
Quiet
{
get
;
set
; }
59
60
[Value(0)]
61
public
IEnumerable<string>
Urls
{
get
;
set
; }
62
}
63
64
[Verb(
"sequence"
, HelpText =
"Sequence options test."
)]
65
public
class
SequenceOptions
66
{
67
[Option(
"long-seq"
, Separator =
';'
)]
68
public
IEnumerable<long>
LongSequence
{
get
;
set
; }
69
70
[Option(
's'
, Min = 1, Max = 100, Separator =
','
)]
71
public
IEnumerable<string>
StringSequence
{
get
;
set
; }
72
}
73
74
abstract
class
Base_Class_For_Verb
75
{
76
[Option(
'p'
,
"patch"
, SetName =
"mode"
,
77
HelpText =
"Interactively choose hunks of patch between the index and the work tree and add them to the index."
)]
78
public
bool
Patch
{
get
;
set
; }
79
80
[Value(0)]
81
public
string
FileName
{
get
;
set
; }
82
}
83
84
[Verb(
"derivedadd"
, HelpText =
"Add file contents to the index."
)]
85
class
Derived_Verb
:
Base_Class_For_Verb
86
{
87
[Option(
'f'
,
"force"
, SetName =
"mode"
,
88
HelpText =
"Allow adding otherwise ignored files."
)]
89
public
bool
Force
{
get
;
set
; }
90
}
91
92
[Verb(
"test"
)]
93
class
Verb_With_Option_And_Value_Of_String_Type
94
{
95
[Option(
'o'
,
"opt"
)]
96
public
string
OptValue
{
get
;
set
; }
97
98
[Value(0)]
99
public
string
PosValue
{
get
;
set
; }
100
}
101
102
[Verb(
"default1"
,
true
)]
103
class
Default_Verb_One
104
{
105
[Option(
't'
,
"test-one"
)]
106
public
bool
TestValueOne
{
get
;
set
; }
107
}
108
109
[Verb(
"default2"
,
true
)]
110
class
Default_Verb_Two
111
{
112
[Option(
't'
,
"test-two"
)]
113
public
bool
TestValueTwo
{
get
;
set
; }
114
}
115
116
[Verb(
null
,
true
)]
117
class
Default_Verb_With_Empty_Name
118
{
119
[Option(
't'
,
"test"
)]
120
public
bool
TestValue
{
get
;
set
; }
121
}
122
}
CommandLine.Tests.Fakes.Add_Verb_As_Default
Definition
Verb_Fakes.cs:23
CommandLine.Tests.Fakes.Add_Verb
Definition
Verb_Fakes.cs:9
CommandLine.Tests.Fakes.Add_Verb.Patch
bool Patch
Definition
Verb_Fakes.cs:12
CommandLine.Tests.Fakes.Add_Verb.Force
bool Force
Definition
Verb_Fakes.cs:16
CommandLine.Tests.Fakes.Add_Verb.FileName
string FileName
Definition
Verb_Fakes.cs:19
CommandLine.Tests.Fakes.Base_Class_For_Verb
Definition
Verb_Fakes.cs:75
CommandLine.Tests.Fakes.Base_Class_For_Verb.Patch
bool Patch
Definition
Verb_Fakes.cs:78
CommandLine.Tests.Fakes.Base_Class_For_Verb.FileName
string FileName
Definition
Verb_Fakes.cs:81
CommandLine.Tests.Fakes.Clone_Verb
Definition
Verb_Fakes.cs:51
CommandLine.Tests.Fakes.Clone_Verb.NoHardLinks
bool NoHardLinks
Definition
Verb_Fakes.cs:54
CommandLine.Tests.Fakes.Clone_Verb.Quiet
bool Quiet
Definition
Verb_Fakes.cs:58
CommandLine.Tests.Fakes.Clone_Verb.Urls
IEnumerable< string > Urls
Definition
Verb_Fakes.cs:61
CommandLine.Tests.Fakes.Commit_Verb
Definition
Verb_Fakes.cs:37
CommandLine.Tests.Fakes.Commit_Verb.Amend
bool Amend
Definition
Verb_Fakes.cs:43
CommandLine.Tests.Fakes.Commit_Verb.Message
string Message
Definition
Verb_Fakes.cs:46
CommandLine.Tests.Fakes.Commit_Verb.Patch
bool Patch
Definition
Verb_Fakes.cs:40
CommandLine.Tests.Fakes.Default_Verb_One
Definition
Verb_Fakes.cs:104
CommandLine.Tests.Fakes.Default_Verb_One.TestValueOne
bool TestValueOne
Definition
Verb_Fakes.cs:106
CommandLine.Tests.Fakes.Default_Verb_Two
Definition
Verb_Fakes.cs:111
CommandLine.Tests.Fakes.Default_Verb_Two.TestValueTwo
bool TestValueTwo
Definition
Verb_Fakes.cs:113
CommandLine.Tests.Fakes.Default_Verb_With_Empty_Name
Definition
Verb_Fakes.cs:118
CommandLine.Tests.Fakes.Default_Verb_With_Empty_Name.TestValue
bool TestValue
Definition
Verb_Fakes.cs:120
CommandLine.Tests.Fakes.Derived_Verb
Definition
Verb_Fakes.cs:86
CommandLine.Tests.Fakes.Derived_Verb.Force
bool Force
Definition
Verb_Fakes.cs:89
CommandLine.Tests.Fakes.SequenceOptions
Definition
Verb_Fakes.cs:66
CommandLine.Tests.Fakes.SequenceOptions.LongSequence
IEnumerable< long > LongSequence
Definition
Verb_Fakes.cs:68
CommandLine.Tests.Fakes.SequenceOptions.StringSequence
IEnumerable< string > StringSequence
Definition
Verb_Fakes.cs:71
CommandLine.Tests.Fakes.Verb_With_Option_And_Value_Of_String_Type
Definition
Verb_Fakes.cs:94
CommandLine.Tests.Fakes.Verb_With_Option_And_Value_Of_String_Type.OptValue
string OptValue
Definition
Verb_Fakes.cs:96
CommandLine.Tests.Fakes.Verb_With_Option_And_Value_Of_String_Type.PosValue
string PosValue
Definition
Verb_Fakes.cs:99
CommandLine.Tests.Fakes
Definition
Custom_Struct.cs:6
deps
commandlineparser
tests
CommandLine.Tests
Fakes
Verb_Fakes.cs
Generated by
1.9.8