master
cpp 46 lines 1017 Bytes
Raw
1 /*++
2
3 Copyright (c) Microsoft. All rights reserved.
4
5 Module Name:
6
7 SessionListCommand.cpp
8
9 Abstract:
10
11 Implementation of the session list command.
12
13 --*/
14 #include "CLIExecutionContext.h"
15 #include "SessionCommand.h"
16 #include "SessionTasks.h"
17 #include "Task.h"
18
19 using namespace wsl::windows::wslc::execution;
20 using namespace wsl::windows::wslc::task;
21 using namespace wsl::shared;
22
23 namespace wsl::windows::wslc {
24 // Session List Command
25 std::vector<Argument> SessionListCommand::GetArguments() const
26 {
27 return {
28 Argument::Create(ArgType::Verbose, {.Desc = Localization::WSLCCLI_SessionListVerboseArgDescription()}),
29 };
30 }
31
32 std::wstring SessionListCommand::ShortDescription() const
33 {
34 return Localization::WSLCCLI_SessionListDesc();
35 }
36
37 std::wstring SessionListCommand::LongDescription() const
38 {
39 return Localization::WSLCCLI_SessionListLongDesc();
40 }
41
42 void SessionListCommand::ExecuteInternal(CLIExecutionContext& context) const
43 {
44 context << ListSessions;
45 }
46 } // namespace wsl::windows::wslc