Skip to content

Commit 9ff3c90

Browse files
committed
Start VB.NET examples in README
1 parent ecb9e64 commit 9ff3c90

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

‎README.md‎

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,32 @@ let main argv =
120120
| :? Parsed<options> as parsed -> run parsed.Value
121121
| :? NotParsed<options> as notParsed -> fail notParsed.Errors
122122
```
123+
**VB.NET:**
124+
```VB.NET
125+
ClassOptions
126+
<CommandLine.Option('r', "read", Required := true,
127+
HelpText:="Input files to be processed.")>
128+
PublicPropertyInputFilesAsIEnumerable(OfString)
129+
130+
' Omitting long name, default --verbose
131+
<CommandLine.Option(
132+
HelpText:="Prints all messages to standard output.")>
133+
PublicPropertyVerboseAsBoolean
134+
135+
<CommandLine.Option(Default:="中文",
136+
HelpText:="Content language.")>
137+
PublicPropertyLanguageAsString
138+
139+
<CommandLine.Value(0,MetaName:="offset",
140+
HelpText:="File offset.")>
141+
PublicPropertyOffsetAsLong?
142+
EndClass
143+
```
144+
Consume them:
145+
```VB.NET
146+
TODO
147+
```
148+
123149

124150
For verbs:
125151

@@ -176,6 +202,25 @@ let main args =
176202
| :? CloneOptions as opts -> RunCloneAndReturnExitCode opts
177203
| :? CommandLine.NotParsed<obj> -> 1
178204
```
205+
**VB.NET:**
206+
```VB.NET
207+
<CommandLine.Verb("add",HelpText:="Add file contents to the index.")>
208+
PublicClassAddOptions
209+
'Normal options here
210+
EndClass
211+
<CommandLine.Verb("commit",HelpText:="Record changes to the repository.")>
212+
PublicClassAddOptions
213+
'Normal options here
214+
EndClass
215+
<CommandLine.Verb("clone",HelpText:="Clone a repository into a new directory.")>
216+
PublicClassAddOptions
217+
'Normal options here
218+
EndClass
219+
220+
PublicSharedSubMain()
221+
'TODO
222+
EndSub
223+
```
179224

180225
Acknowledgements:
181226
---

0 commit comments

Comments
(0)