Skip to content

Commit f1b1123

Browse files
committed
Commands
1 parent 942d6d4 commit f1b1123

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# CodeFactory Commands
2+
When working with CodeFactory you always start with commands.
3+
Commands are the trigger point where all CodeFactory functionality starts from.
4+
As of this release of CodeFactory all commands are triggered from context menus on individual nodes within solution explorer. As per the name a command following a command exection pattern.
5+
This is made up of two methods that are raised from internal events that occur within Visual Studio itself. These events are trigged when a selected solution explorers item content menu is opened.
6+
The following explain the two methods their goal and the different type of commands that are supported in CodeFactory.
7+
8+
## Command Result
9+
Whenever a command is executed a real time data model is generated based on the type of Visual Studio object that has been selected. The data model is regenerated each time the target command is executed.
10+
11+
## Enable Command
12+
When a command is first loaded it sends the command result to the enable method on the command.
13+
This method is called to allow the author of the command to determine if the command should be enabled to be used.
14+
This was added to allow the author to control execution of automation.
15+
You may only want automation to be enabled based on a target condition.
16+
This is controlled by simply returning a true or false value to determine if the command should be accessible.
17+
If enabled is true the command will show up in the context menu.
18+
The developer in Visual Studio will then trigger the command to execute by selecting the context menu item.
19+
20+
## Execute Command
21+
Once the developer selects a command to be executed Visual Studio will trigger the execute method of the command itself.
22+
Like before a real time data model is passed to the execute method.
23+
This is where the automation process starts and whatever functionality has been assigned will executed at this time.
24+
25+
## Solution Explore Commands
26+
CodeFactory current supports the trigger of commands from the solution explorer window in Visual Studio.
27+
The following are the supported Solution Explorer nodes that will CodeFactory Automation.
28+
29+
- Solution Command - Generates a Solutiuon data model
30+
- SolutionFolder Command - Generates a Solution Folder data model
31+
- SolutionDocument Command - Generates a Document data model
32+
- Project Command - Generates a Project data model
33+
- Project Folder - Generates a Project Folder data model
34+
- Document Command - Generates a Document data model
35+
- C# Document Command - Generates a CSharpSource data model

0 commit comments

Comments
 (0)