@simplysf/simply-aep 0.15.8 → 0.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +358 -17
- package/lib/commands/simply/aep/generate/domain.d.ts +21 -0
- package/lib/commands/simply/aep/generate/domain.js +41 -0
- package/lib/commands/simply/aep/generate/domain.js.map +1 -0
- package/lib/commands/simply/aep/generate/selector.d.ts +21 -0
- package/lib/commands/simply/aep/generate/selector.js +41 -0
- package/lib/commands/simply/aep/generate/selector.js.map +1 -0
- package/lib/commands/simply/aep/generate/service.d.ts +21 -0
- package/lib/commands/simply/aep/generate/service.js +45 -0
- package/lib/commands/simply/aep/generate/service.js.map +1 -0
- package/lib/commands/simply/aep/generate/unit-of-work.d.ts +22 -0
- package/lib/commands/simply/aep/generate/unit-of-work.js +42 -0
- package/lib/commands/simply/aep/generate/unit-of-work.js.map +1 -0
- package/lib/commands/simply/aep/generate.d.ts +25 -0
- package/lib/commands/simply/aep/generate.js +45 -0
- package/lib/commands/simply/aep/generate.js.map +1 -0
- package/lib/common/generate/flags.d.ts +27 -0
- package/lib/common/generate/flags.js +63 -0
- package/lib/common/generate/flags.js.map +1 -0
- package/lib/common/generate/runGeneration.d.ts +52 -0
- package/lib/common/generate/runGeneration.js +196 -0
- package/lib/common/generate/runGeneration.js.map +1 -0
- package/messages/simply.aep.generate.common.md +78 -0
- package/messages/simply.aep.generate.domain.md +19 -0
- package/messages/simply.aep.generate.md +37 -0
- package/messages/simply.aep.generate.selector.md +19 -0
- package/messages/simply.aep.generate.service.md +23 -0
- package/messages/simply.aep.generate.unit-of-work.md +23 -0
- package/oclif.manifest.json +1510 -764
- package/package.json +7 -5
package/README.md
CHANGED
|
@@ -39,6 +39,11 @@ This package is part of the [`@simplysf/simply`](https://github.com/SimplySF/sim
|
|
|
39
39
|
- [`sf simply aep at4dx platform-event-subscription simulate`](#sf-simply-aep-at4dx-platform-event-subscription-simulate)
|
|
40
40
|
- [`sf simply aep at4dx platform-event-subscription update`](#sf-simply-aep-at4dx-platform-event-subscription-update)
|
|
41
41
|
- [`sf simply aep at4dx platform-event-subscription validate`](#sf-simply-aep-at4dx-platform-event-subscription-validate)
|
|
42
|
+
- [`sf simply aep generate`](#sf-simply-aep-generate)
|
|
43
|
+
- [`sf simply aep generate domain`](#sf-simply-aep-generate-domain)
|
|
44
|
+
- [`sf simply aep generate selector`](#sf-simply-aep-generate-selector)
|
|
45
|
+
- [`sf simply aep generate service`](#sf-simply-aep-generate-service)
|
|
46
|
+
- [`sf simply aep generate unit-of-work`](#sf-simply-aep-generate-unit-of-work)
|
|
42
47
|
|
|
43
48
|
## `sf simply aep at4dx binding create`
|
|
44
49
|
|
|
@@ -117,7 +122,7 @@ EXAMPLES
|
|
|
117
122
|
$ sf simply aep at4dx binding create --source-dir sfdx-source/core --type unit-of-work --developer-name Account_UOW --sobject Account --sequence 10
|
|
118
123
|
```
|
|
119
124
|
|
|
120
|
-
_See code: [lib/commands/simply/aep/at4dx/binding/create.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
125
|
+
_See code: [lib/commands/simply/aep/at4dx/binding/create.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/binding/create.js)_
|
|
121
126
|
|
|
122
127
|
## `sf simply aep at4dx binding list`
|
|
123
128
|
|
|
@@ -173,7 +178,7 @@ FLAG DESCRIPTIONS
|
|
|
173
178
|
Comma-separated list of binding types to include. If not specified, all four are included.
|
|
174
179
|
```
|
|
175
180
|
|
|
176
|
-
_See code: [lib/commands/simply/aep/at4dx/binding/list.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
181
|
+
_See code: [lib/commands/simply/aep/at4dx/binding/list.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/binding/list.js)_
|
|
177
182
|
|
|
178
183
|
## `sf simply aep at4dx binding update`
|
|
179
184
|
|
|
@@ -246,7 +251,7 @@ EXAMPLES
|
|
|
246
251
|
$ sf simply aep at4dx binding update --target-org myOrg --type unit-of-work --developer-name Account_UOW --sequence 20
|
|
247
252
|
```
|
|
248
253
|
|
|
249
|
-
_See code: [lib/commands/simply/aep/at4dx/binding/update.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
254
|
+
_See code: [lib/commands/simply/aep/at4dx/binding/update.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/binding/update.js)_
|
|
250
255
|
|
|
251
256
|
## `sf simply aep at4dx binding validate`
|
|
252
257
|
|
|
@@ -304,7 +309,7 @@ FLAG DESCRIPTIONS
|
|
|
304
309
|
Comma-separated list of binding types to include. If not specified, all four are included.
|
|
305
310
|
```
|
|
306
311
|
|
|
307
|
-
_See code: [lib/commands/simply/aep/at4dx/binding/validate.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
312
|
+
_See code: [lib/commands/simply/aep/at4dx/binding/validate.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/binding/validate.js)_
|
|
308
313
|
|
|
309
314
|
## `sf simply aep at4dx domain-process-binding create`
|
|
310
315
|
|
|
@@ -385,7 +390,7 @@ EXAMPLES
|
|
|
385
390
|
$ sf simply aep at4dx domain-process-binding create --source-dir sfdx-source/core --developer-name ServiceResource_Before_Update_Sync --sobject ServiceResource --sobject-alternate --process-context TriggerExecution --trigger-operation Before_Update --type Action --class-to-inject ServiceResourceSyncAction --order 10
|
|
386
391
|
```
|
|
387
392
|
|
|
388
|
-
_See code: [lib/commands/simply/aep/at4dx/domain-process-binding/create.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
393
|
+
_See code: [lib/commands/simply/aep/at4dx/domain-process-binding/create.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/domain-process-binding/create.js)_
|
|
389
394
|
|
|
390
395
|
## `sf simply aep at4dx domain-process-binding list`
|
|
391
396
|
|
|
@@ -431,7 +436,7 @@ EXAMPLES
|
|
|
431
436
|
$ sf simply aep at4dx domain-process-binding list --target-org myOrg --active-only --json
|
|
432
437
|
```
|
|
433
438
|
|
|
434
|
-
_See code: [lib/commands/simply/aep/at4dx/domain-process-binding/list.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
439
|
+
_See code: [lib/commands/simply/aep/at4dx/domain-process-binding/list.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/domain-process-binding/list.js)_
|
|
435
440
|
|
|
436
441
|
## `sf simply aep at4dx domain-process-binding update`
|
|
437
442
|
|
|
@@ -510,7 +515,7 @@ EXAMPLES
|
|
|
510
515
|
$ sf simply aep at4dx domain-process-binding update --target-org myOrg --developer-name Account_Before_Insert_Assign_Owner --class-to-inject AccountAssignOwnerActionV2
|
|
511
516
|
```
|
|
512
517
|
|
|
513
|
-
_See code: [lib/commands/simply/aep/at4dx/domain-process-binding/update.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
518
|
+
_See code: [lib/commands/simply/aep/at4dx/domain-process-binding/update.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/domain-process-binding/update.js)_
|
|
514
519
|
|
|
515
520
|
## `sf simply aep at4dx domain-process-binding validate`
|
|
516
521
|
|
|
@@ -563,7 +568,7 @@ EXAMPLES
|
|
|
563
568
|
$ sf simply aep at4dx domain-process-binding validate --target-org myOrg --json
|
|
564
569
|
```
|
|
565
570
|
|
|
566
|
-
_See code: [lib/commands/simply/aep/at4dx/domain-process-binding/validate.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
571
|
+
_See code: [lib/commands/simply/aep/at4dx/domain-process-binding/validate.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/domain-process-binding/validate.js)_
|
|
567
572
|
|
|
568
573
|
## `sf simply aep at4dx field-set-inclusion create`
|
|
569
574
|
|
|
@@ -621,7 +626,7 @@ EXAMPLES
|
|
|
621
626
|
$ sf simply aep at4dx field-set-inclusion create --target-org myOrg --developer-name ServiceResource_Skills --sobject ServiceResource --sobject-alternate --fieldset-name SkillFields
|
|
622
627
|
```
|
|
623
628
|
|
|
624
|
-
_See code: [lib/commands/simply/aep/at4dx/field-set-inclusion/create.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
629
|
+
_See code: [lib/commands/simply/aep/at4dx/field-set-inclusion/create.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/field-set-inclusion/create.js)_
|
|
625
630
|
|
|
626
631
|
## `sf simply aep at4dx field-set-inclusion list`
|
|
627
632
|
|
|
@@ -659,7 +664,7 @@ EXAMPLES
|
|
|
659
664
|
$ sf simply aep at4dx field-set-inclusion list --target-org myOrg --json
|
|
660
665
|
```
|
|
661
666
|
|
|
662
|
-
_See code: [lib/commands/simply/aep/at4dx/field-set-inclusion/list.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
667
|
+
_See code: [lib/commands/simply/aep/at4dx/field-set-inclusion/list.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/field-set-inclusion/list.js)_
|
|
663
668
|
|
|
664
669
|
## `sf simply aep at4dx field-set-inclusion update`
|
|
665
670
|
|
|
@@ -716,7 +721,7 @@ EXAMPLES
|
|
|
716
721
|
$ sf simply aep at4dx field-set-inclusion update --target-org myOrg --developer-name Account_Contact_Fields --fieldset-name ContactRelatedFieldsV2
|
|
717
722
|
```
|
|
718
723
|
|
|
719
|
-
_See code: [lib/commands/simply/aep/at4dx/field-set-inclusion/update.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
724
|
+
_See code: [lib/commands/simply/aep/at4dx/field-set-inclusion/update.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/field-set-inclusion/update.js)_
|
|
720
725
|
|
|
721
726
|
## `sf simply aep at4dx field-set-inclusion validate`
|
|
722
727
|
|
|
@@ -760,7 +765,7 @@ EXAMPLES
|
|
|
760
765
|
$ sf simply aep at4dx field-set-inclusion validate --target-org myOrg --json
|
|
761
766
|
```
|
|
762
767
|
|
|
763
|
-
_See code: [lib/commands/simply/aep/at4dx/field-set-inclusion/validate.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
768
|
+
_See code: [lib/commands/simply/aep/at4dx/field-set-inclusion/validate.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/field-set-inclusion/validate.js)_
|
|
764
769
|
|
|
765
770
|
## `sf simply aep at4dx platform-event-subscription create`
|
|
766
771
|
|
|
@@ -856,7 +861,7 @@ EXAMPLES
|
|
|
856
861
|
$ sf simply aep at4dx platform-event-subscription create --target-org myOrg --developer-name Account_Change_Subscriber --event-bus Account_Change__e --consumer AccountChangeConsumer --matcher-rule MatchEventBusAndCategoryAndEventName --event-category Finance --event-name AccountUpdated
|
|
857
862
|
```
|
|
858
863
|
|
|
859
|
-
_See code: [lib/commands/simply/aep/at4dx/platform-event-subscription/create.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
864
|
+
_See code: [lib/commands/simply/aep/at4dx/platform-event-subscription/create.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/platform-event-subscription/create.js)_
|
|
860
865
|
|
|
861
866
|
## `sf simply aep at4dx platform-event-subscription list`
|
|
862
867
|
|
|
@@ -894,7 +899,7 @@ EXAMPLES
|
|
|
894
899
|
$ sf simply aep at4dx platform-event-subscription list --target-org myOrg --json
|
|
895
900
|
```
|
|
896
901
|
|
|
897
|
-
_See code: [lib/commands/simply/aep/at4dx/platform-event-subscription/list.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
902
|
+
_See code: [lib/commands/simply/aep/at4dx/platform-event-subscription/list.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/platform-event-subscription/list.js)_
|
|
898
903
|
|
|
899
904
|
## `sf simply aep at4dx platform-event-subscription simulate`
|
|
900
905
|
|
|
@@ -950,7 +955,7 @@ EXAMPLES
|
|
|
950
955
|
$ sf simply aep at4dx platform-event-subscription simulate --target-org myOrg --event-bus Account_Change__e --json
|
|
951
956
|
```
|
|
952
957
|
|
|
953
|
-
_See code: [lib/commands/simply/aep/at4dx/platform-event-subscription/simulate.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
958
|
+
_See code: [lib/commands/simply/aep/at4dx/platform-event-subscription/simulate.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/platform-event-subscription/simulate.js)_
|
|
954
959
|
|
|
955
960
|
## `sf simply aep at4dx platform-event-subscription update`
|
|
956
961
|
|
|
@@ -1019,7 +1024,7 @@ EXAMPLES
|
|
|
1019
1024
|
$ sf simply aep at4dx platform-event-subscription update --target-org myOrg --developer-name Account_Change_Subscriber --consumer AccountChangeConsumerV2
|
|
1020
1025
|
```
|
|
1021
1026
|
|
|
1022
|
-
_See code: [lib/commands/simply/aep/at4dx/platform-event-subscription/update.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
1027
|
+
_See code: [lib/commands/simply/aep/at4dx/platform-event-subscription/update.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/platform-event-subscription/update.js)_
|
|
1023
1028
|
|
|
1024
1029
|
## `sf simply aep at4dx platform-event-subscription validate`
|
|
1025
1030
|
|
|
@@ -1068,5 +1073,341 @@ EXAMPLES
|
|
|
1068
1073
|
$ sf simply aep at4dx platform-event-subscription validate --target-org myOrg --json
|
|
1069
1074
|
```
|
|
1070
1075
|
|
|
1071
|
-
_See code: [lib/commands/simply/aep/at4dx/platform-event-subscription/validate.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.
|
|
1076
|
+
_See code: [lib/commands/simply/aep/at4dx/platform-event-subscription/validate.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/at4dx/platform-event-subscription/validate.js)_
|
|
1077
|
+
|
|
1078
|
+
## `sf simply aep generate`
|
|
1079
|
+
|
|
1080
|
+
Generate selector, domain, and unit-of-work layers for an SObject in one run.
|
|
1081
|
+
|
|
1082
|
+
```
|
|
1083
|
+
USAGE
|
|
1084
|
+
$ sf simply aep generate -o <value> -s <value> -f at4dx|fflib [--json] [--flags-dir <value>] [-a <value>] [--prefix
|
|
1085
|
+
<value>] [--selector] [--domain] [--unit-of-work] [--sequence <value>] [-d <value>] [--dry-run] [--overwrite]
|
|
1086
|
+
[--force]
|
|
1087
|
+
|
|
1088
|
+
FLAGS
|
|
1089
|
+
-a, --api-version=<value> Override the api version used for api requests made by this command
|
|
1090
|
+
-d, --output-dir=<value> [default: generated-files] Directory to write into, relative to the project root unless
|
|
1091
|
+
absolute.
|
|
1092
|
+
-f, --flavor=<option> (required) Framework to generate for: at4dx or fflib.
|
|
1093
|
+
<options: at4dx|fflib>
|
|
1094
|
+
-o, --target-org=<value> (required) Username or alias of the target org. Not required if the `target-org`
|
|
1095
|
+
configuration variable is already set.
|
|
1096
|
+
-s, --sobject=<value> (required) API name of the SObject to generate for. The generators describe it in
|
|
1097
|
+
--target-org.
|
|
1098
|
+
--domain Generate the domain layer and its trigger.
|
|
1099
|
+
--dry-run Show the files that would be written, and any validation issues, without writing anything.
|
|
1100
|
+
--force Write even if validation finds an error-severity issue the generated binding records would
|
|
1101
|
+
introduce. The issues are still printed and returned.
|
|
1102
|
+
--overwrite Replace files that already exist at a planned path. Without it, the command refuses before
|
|
1103
|
+
writing anything.
|
|
1104
|
+
--prefix=<value> Class-name prefix, upper-cased and joined with an underscore (--prefix acme gives
|
|
1105
|
+
ACME_Accounts).
|
|
1106
|
+
--selector Generate the selector layer.
|
|
1107
|
+
--sequence=<value> BindingSequence__c for the unit-of-work binding (at4dx only): where the SObject falls in
|
|
1108
|
+
the commit order, lower first.
|
|
1109
|
+
--unit-of-work Generate the unit-of-work binding (at4dx) or print the Application entry to add (fflib).
|
|
1110
|
+
|
|
1111
|
+
GLOBAL FLAGS
|
|
1112
|
+
--flags-dir=<value> Import flag values from a directory.
|
|
1113
|
+
--json Format output as json.
|
|
1114
|
+
|
|
1115
|
+
DESCRIPTION
|
|
1116
|
+
Generate selector, domain, and unit-of-work layers for an SObject in one run.
|
|
1117
|
+
|
|
1118
|
+
Describes --sobject in --target-org once and scaffolds every layer you select (at least one of --selector, --domain,
|
|
1119
|
+
or --unit-of-work) into --output-dir, sharing --flavor and --prefix. With --flavor at4dx each layer also gets its
|
|
1120
|
+
Application Factory binding record.
|
|
1121
|
+
|
|
1122
|
+
Before writing, the binding records are checked against the project's package directories and --output-dir with the
|
|
1123
|
+
rules `simply aep at4dx binding validate` uses. An error-severity issue they would introduce — a second Domain binding
|
|
1124
|
+
for the same SObject, say — stops the run unless you pass --force; problems that were already there don't. Existing
|
|
1125
|
+
files stop it too unless you pass --overwrite. Nothing is written in either case.
|
|
1126
|
+
|
|
1127
|
+
With --flavor fflib, --unit-of-work writes no file: fflib has no unit-of-work binding, so the command prints the
|
|
1128
|
+
Application factory entry to add by hand, and returns it as manualSteps.
|
|
1129
|
+
|
|
1130
|
+
EXAMPLES
|
|
1131
|
+
Generate all three AT4DX layers for Account:
|
|
1132
|
+
|
|
1133
|
+
$ sf simply aep generate --target-org myOrg --sobject Account --flavor at4dx --selector --domain --unit-of-work
|
|
1134
|
+
|
|
1135
|
+
Preview an fflib selector and domain with a class prefix, writing nothing:
|
|
1136
|
+
|
|
1137
|
+
$ sf simply aep generate --target-org myOrg --sobject Property__c --flavor fflib --prefix acme --selector \
|
|
1138
|
+
--domain --dry-run
|
|
1139
|
+
|
|
1140
|
+
FLAG DESCRIPTIONS
|
|
1141
|
+
-d, --output-dir=<value> Directory to write into, relative to the project root unless absolute.
|
|
1142
|
+
|
|
1143
|
+
Files go under main/classes, main/schema, and test/classes inside it. Defaults to generated-files, as apx's
|
|
1144
|
+
--output-path did, so generated paths don't move.
|
|
1145
|
+
|
|
1146
|
+
-f, --flavor=at4dx|fflib Framework to generate for: at4dx or fflib.
|
|
1147
|
+
|
|
1148
|
+
Sets the templates for every file: the interface and implementation shape, base classes, and whether Application
|
|
1149
|
+
Factory binding records are written. fflib writes none; at4dx writes one per layer.
|
|
1150
|
+
```
|
|
1151
|
+
|
|
1152
|
+
_See code: [lib/commands/simply/aep/generate.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/generate.js)_
|
|
1153
|
+
|
|
1154
|
+
## `sf simply aep generate domain`
|
|
1155
|
+
|
|
1156
|
+
Generate a domain class, its interface, test, and trigger, and its AT4DX binding for an SObject.
|
|
1157
|
+
|
|
1158
|
+
```
|
|
1159
|
+
USAGE
|
|
1160
|
+
$ sf simply aep generate domain -o <value> -s <value> -f at4dx|fflib [--json] [--flags-dir <value>] [-a <value>] [--prefix
|
|
1161
|
+
<value>] [-d <value>] [--dry-run] [--overwrite] [--force]
|
|
1162
|
+
|
|
1163
|
+
FLAGS
|
|
1164
|
+
-a, --api-version=<value> Override the api version used for api requests made by this command
|
|
1165
|
+
-d, --output-dir=<value> [default: generated-files] Directory to write into, relative to the project root unless
|
|
1166
|
+
absolute.
|
|
1167
|
+
-f, --flavor=<option> (required) Framework to generate for: at4dx or fflib.
|
|
1168
|
+
<options: at4dx|fflib>
|
|
1169
|
+
-o, --target-org=<value> (required) Username or alias of the target org. Not required if the `target-org`
|
|
1170
|
+
configuration variable is already set.
|
|
1171
|
+
-s, --sobject=<value> (required) API name of the SObject to generate for. The generators describe it in
|
|
1172
|
+
--target-org.
|
|
1173
|
+
--dry-run Show the files that would be written, and any validation issues, without writing anything.
|
|
1174
|
+
--force Write even if validation finds an error-severity issue the generated binding records would
|
|
1175
|
+
introduce. The issues are still printed and returned.
|
|
1176
|
+
--overwrite Replace files that already exist at a planned path. Without it, the command refuses before
|
|
1177
|
+
writing anything.
|
|
1178
|
+
--prefix=<value> Class-name prefix, upper-cased and joined with an underscore (--prefix acme gives
|
|
1179
|
+
ACME_Accounts).
|
|
1180
|
+
|
|
1181
|
+
GLOBAL FLAGS
|
|
1182
|
+
--flags-dir=<value> Import flag values from a directory.
|
|
1183
|
+
--json Format output as json.
|
|
1184
|
+
|
|
1185
|
+
DESCRIPTION
|
|
1186
|
+
Generate a domain class, its interface, test, and trigger, and its AT4DX binding for an SObject.
|
|
1187
|
+
|
|
1188
|
+
Describes --sobject in --target-org and scaffolds the domain into --output-dir: the implementation, its interface, a
|
|
1189
|
+
unit test, the trigger that hands every event to fflib_SObjectDomain.triggerHandler, and their -meta.xml files. With
|
|
1190
|
+
--flavor at4dx it also writes the ApplicationFactory_DomainBinding record.
|
|
1191
|
+
|
|
1192
|
+
An SObject can have only one Domain binding, so generating one where the project already has one fails validation;
|
|
1193
|
+
pass --force to write it anyway. See `simply aep generate --help` for the full --force and --overwrite rules.
|
|
1194
|
+
|
|
1195
|
+
EXAMPLES
|
|
1196
|
+
Generate an AT4DX domain for Account:
|
|
1197
|
+
|
|
1198
|
+
$ sf simply aep generate domain --target-org myOrg --sobject Account --flavor at4dx
|
|
1199
|
+
|
|
1200
|
+
Preview the files without writing them:
|
|
1201
|
+
|
|
1202
|
+
$ sf simply aep generate domain --target-org myOrg --sobject Account --flavor at4dx --dry-run
|
|
1203
|
+
|
|
1204
|
+
FLAG DESCRIPTIONS
|
|
1205
|
+
-d, --output-dir=<value> Directory to write into, relative to the project root unless absolute.
|
|
1206
|
+
|
|
1207
|
+
Files go under main/classes, main/schema, and test/classes inside it. Defaults to generated-files, as apx's
|
|
1208
|
+
--output-path did, so generated paths don't move.
|
|
1209
|
+
|
|
1210
|
+
-f, --flavor=at4dx|fflib Framework to generate for: at4dx or fflib.
|
|
1211
|
+
|
|
1212
|
+
Sets the templates for every file: the interface and implementation shape, base classes, and whether Application
|
|
1213
|
+
Factory binding records are written. fflib writes none; at4dx writes one per layer.
|
|
1214
|
+
```
|
|
1215
|
+
|
|
1216
|
+
_See code: [lib/commands/simply/aep/generate/domain.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/generate/domain.js)_
|
|
1217
|
+
|
|
1218
|
+
## `sf simply aep generate selector`
|
|
1219
|
+
|
|
1220
|
+
Generate a selector class, its interface and test, and its AT4DX binding for an SObject.
|
|
1221
|
+
|
|
1222
|
+
```
|
|
1223
|
+
USAGE
|
|
1224
|
+
$ sf simply aep generate selector -o <value> -s <value> -f at4dx|fflib [--json] [--flags-dir <value>] [-a <value>] [--prefix
|
|
1225
|
+
<value>] [-d <value>] [--dry-run] [--overwrite] [--force]
|
|
1226
|
+
|
|
1227
|
+
FLAGS
|
|
1228
|
+
-a, --api-version=<value> Override the api version used for api requests made by this command
|
|
1229
|
+
-d, --output-dir=<value> [default: generated-files] Directory to write into, relative to the project root unless
|
|
1230
|
+
absolute.
|
|
1231
|
+
-f, --flavor=<option> (required) Framework to generate for: at4dx or fflib.
|
|
1232
|
+
<options: at4dx|fflib>
|
|
1233
|
+
-o, --target-org=<value> (required) Username or alias of the target org. Not required if the `target-org`
|
|
1234
|
+
configuration variable is already set.
|
|
1235
|
+
-s, --sobject=<value> (required) API name of the SObject to generate for. The generators describe it in
|
|
1236
|
+
--target-org.
|
|
1237
|
+
--dry-run Show the files that would be written, and any validation issues, without writing anything.
|
|
1238
|
+
--force Write even if validation finds an error-severity issue the generated binding records would
|
|
1239
|
+
introduce. The issues are still printed and returned.
|
|
1240
|
+
--overwrite Replace files that already exist at a planned path. Without it, the command refuses before
|
|
1241
|
+
writing anything.
|
|
1242
|
+
--prefix=<value> Class-name prefix, upper-cased and joined with an underscore (--prefix acme gives
|
|
1243
|
+
ACME_Accounts).
|
|
1244
|
+
|
|
1245
|
+
GLOBAL FLAGS
|
|
1246
|
+
--flags-dir=<value> Import flag values from a directory.
|
|
1247
|
+
--json Format output as json.
|
|
1248
|
+
|
|
1249
|
+
DESCRIPTION
|
|
1250
|
+
Generate a selector class, its interface and test, and its AT4DX binding for an SObject.
|
|
1251
|
+
|
|
1252
|
+
Describes --sobject in --target-org and scaffolds the selector into --output-dir: the implementation (selecting every
|
|
1253
|
+
filterable, non-textarea field), its interface, a unit test, and their -meta.xml files. With --flavor at4dx it also
|
|
1254
|
+
writes the ApplicationFactory_SelectorBinding record, using BindingSObject__c when EntityDefinition can reference the
|
|
1255
|
+
object and BindingSObjectAlternate__c when it can't.
|
|
1256
|
+
|
|
1257
|
+
The binding is checked against the project's package directories and --output-dir before anything is written; see
|
|
1258
|
+
`simply aep generate --help` for the --force and --overwrite rules.
|
|
1259
|
+
|
|
1260
|
+
EXAMPLES
|
|
1261
|
+
Generate an AT4DX selector for Account:
|
|
1262
|
+
|
|
1263
|
+
$ sf simply aep generate selector --target-org myOrg --sobject Account --flavor at4dx
|
|
1264
|
+
|
|
1265
|
+
Generate an fflib selector with a class prefix:
|
|
1266
|
+
|
|
1267
|
+
$ sf simply aep generate selector --target-org myOrg --sobject Property__c --flavor fflib --prefix acme
|
|
1268
|
+
|
|
1269
|
+
FLAG DESCRIPTIONS
|
|
1270
|
+
-d, --output-dir=<value> Directory to write into, relative to the project root unless absolute.
|
|
1271
|
+
|
|
1272
|
+
Files go under main/classes, main/schema, and test/classes inside it. Defaults to generated-files, as apx's
|
|
1273
|
+
--output-path did, so generated paths don't move.
|
|
1274
|
+
|
|
1275
|
+
-f, --flavor=at4dx|fflib Framework to generate for: at4dx or fflib.
|
|
1276
|
+
|
|
1277
|
+
Sets the templates for every file: the interface and implementation shape, base classes, and whether Application
|
|
1278
|
+
Factory binding records are written. fflib writes none; at4dx writes one per layer.
|
|
1279
|
+
```
|
|
1280
|
+
|
|
1281
|
+
_See code: [lib/commands/simply/aep/generate/selector.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/generate/selector.js)_
|
|
1282
|
+
|
|
1283
|
+
## `sf simply aep generate service`
|
|
1284
|
+
|
|
1285
|
+
Generate a service facade, interface, implementation, exception, and test, and its AT4DX binding.
|
|
1286
|
+
|
|
1287
|
+
```
|
|
1288
|
+
USAGE
|
|
1289
|
+
$ sf simply aep generate service --service-basename <value> -f at4dx|fflib [--json] [--flags-dir <value>] [-o <value>] [-a
|
|
1290
|
+
<value>] [--prefix <value>] [-d <value>] [--dry-run] [--overwrite] [--force]
|
|
1291
|
+
|
|
1292
|
+
FLAGS
|
|
1293
|
+
-a, --api-version=<value> Override the api version used for api requests made by this command
|
|
1294
|
+
-d, --output-dir=<value> [default: generated-files] Directory to write into, relative to the project root
|
|
1295
|
+
unless absolute.
|
|
1296
|
+
-f, --flavor=<option> (required) Framework to generate for: at4dx or fflib.
|
|
1297
|
+
<options: at4dx|fflib>
|
|
1298
|
+
-o, --target-org=<value> Org whose API version the generated metadata declares, when --api-version isn't given.
|
|
1299
|
+
Nothing is read from it.
|
|
1300
|
+
--dry-run Show the files that would be written, and any validation issues, without writing
|
|
1301
|
+
anything.
|
|
1302
|
+
--force Write even if validation finds an error-severity issue the generated binding records
|
|
1303
|
+
would introduce. The issues are still printed and returned.
|
|
1304
|
+
--overwrite Replace files that already exist at a planned path. Without it, the command refuses
|
|
1305
|
+
before writing anything.
|
|
1306
|
+
--prefix=<value> Class-name prefix, upper-cased and joined with an underscore (--prefix acme gives
|
|
1307
|
+
ACME_Accounts).
|
|
1308
|
+
--service-basename=<value> (required) Base name for the generated classes, used as given (not pluralized).
|
|
1309
|
+
|
|
1310
|
+
GLOBAL FLAGS
|
|
1311
|
+
--flags-dir=<value> Import flag values from a directory.
|
|
1312
|
+
--json Format output as json.
|
|
1313
|
+
|
|
1314
|
+
DESCRIPTION
|
|
1315
|
+
Generate a service facade, interface, implementation, exception, and test, and its AT4DX binding.
|
|
1316
|
+
|
|
1317
|
+
Scaffolds a service named from --service-basename into --output-dir — `--service-basename Billing` gives
|
|
1318
|
+
BillingService, IBillingService, BillingServiceImpl, BillingServiceException, and BillingServiceTest — with their
|
|
1319
|
+
-meta.xml files. With --flavor at4dx it also writes the ApplicationFactory_ServiceBinding record mapping the interface
|
|
1320
|
+
to the implementation.
|
|
1321
|
+
|
|
1322
|
+
A service isn't tied to an SObject, so nothing is described and no org is needed. The generated -meta.xml files
|
|
1323
|
+
declare --api-version, else the version of --target-org if one is given, else 60.0.
|
|
1324
|
+
|
|
1325
|
+
EXAMPLES
|
|
1326
|
+
Generate an AT4DX service without an org:
|
|
1327
|
+
|
|
1328
|
+
$ sf simply aep generate service --service-basename LimitMonitors --flavor at4dx --api-version 62.0
|
|
1329
|
+
|
|
1330
|
+
Generate an fflib service at a connected org's API version:
|
|
1331
|
+
|
|
1332
|
+
$ sf simply aep generate service --target-org myOrg --service-basename Billing --flavor fflib
|
|
1333
|
+
|
|
1334
|
+
FLAG DESCRIPTIONS
|
|
1335
|
+
-d, --output-dir=<value> Directory to write into, relative to the project root unless absolute.
|
|
1336
|
+
|
|
1337
|
+
Files go under main/classes, main/schema, and test/classes inside it. Defaults to generated-files, as apx's
|
|
1338
|
+
--output-path did, so generated paths don't move.
|
|
1339
|
+
|
|
1340
|
+
-f, --flavor=at4dx|fflib Framework to generate for: at4dx or fflib.
|
|
1341
|
+
|
|
1342
|
+
Sets the templates for every file: the interface and implementation shape, base classes, and whether Application
|
|
1343
|
+
Factory binding records are written. fflib writes none; at4dx writes one per layer.
|
|
1344
|
+
```
|
|
1345
|
+
|
|
1346
|
+
_See code: [lib/commands/simply/aep/generate/service.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/generate/service.js)_
|
|
1347
|
+
|
|
1348
|
+
## `sf simply aep generate unit-of-work`
|
|
1349
|
+
|
|
1350
|
+
Generate an AT4DX unit-of-work binding for an SObject, or print the fflib Application entry to add.
|
|
1351
|
+
|
|
1352
|
+
```
|
|
1353
|
+
USAGE
|
|
1354
|
+
$ sf simply aep generate unit-of-work -o <value> -s <value> -f at4dx|fflib [--json] [--flags-dir <value>] [-a <value>] [--prefix
|
|
1355
|
+
<value>] [--sequence <value>] [-d <value>] [--dry-run] [--overwrite] [--force]
|
|
1356
|
+
|
|
1357
|
+
FLAGS
|
|
1358
|
+
-a, --api-version=<value> Override the api version used for api requests made by this command
|
|
1359
|
+
-d, --output-dir=<value> [default: generated-files] Directory to write into, relative to the project root unless
|
|
1360
|
+
absolute.
|
|
1361
|
+
-f, --flavor=<option> (required) Framework to generate for: at4dx or fflib.
|
|
1362
|
+
<options: at4dx|fflib>
|
|
1363
|
+
-o, --target-org=<value> (required) Username or alias of the target org. Not required if the `target-org`
|
|
1364
|
+
configuration variable is already set.
|
|
1365
|
+
-s, --sobject=<value> (required) API name of the SObject to generate for. The generators describe it in
|
|
1366
|
+
--target-org.
|
|
1367
|
+
--dry-run Show the files that would be written, and any validation issues, without writing anything.
|
|
1368
|
+
--force Write even if validation finds an error-severity issue the generated binding records would
|
|
1369
|
+
introduce. The issues are still printed and returned.
|
|
1370
|
+
--overwrite Replace files that already exist at a planned path. Without it, the command refuses before
|
|
1371
|
+
writing anything.
|
|
1372
|
+
--prefix=<value> Class-name prefix, upper-cased and joined with an underscore (--prefix acme gives
|
|
1373
|
+
ACME_Accounts).
|
|
1374
|
+
--sequence=<value> BindingSequence__c: where the SObject falls in the commit order, lower first. Defaults to
|
|
1375
|
+
1000.
|
|
1376
|
+
|
|
1377
|
+
GLOBAL FLAGS
|
|
1378
|
+
--flags-dir=<value> Import flag values from a directory.
|
|
1379
|
+
--json Format output as json.
|
|
1380
|
+
|
|
1381
|
+
DESCRIPTION
|
|
1382
|
+
Generate an AT4DX unit-of-work binding for an SObject, or print the fflib Application entry to add.
|
|
1383
|
+
|
|
1384
|
+
With --flavor at4dx, writes the ApplicationFactory_UnitOfWorkBinding record registering --sobject with the Unit of
|
|
1385
|
+
Work at --sequence. With --flavor fflib nothing is written, since fflib has no unit-of-work binding: the command
|
|
1386
|
+
prints the Application.UnitOfWorkFactory entry to add by hand, and returns it as manualSteps.
|
|
1387
|
+
|
|
1388
|
+
Two unit-of-work bindings can't share a sequence or an SObject, so a run that would introduce either fails validation
|
|
1389
|
+
unless you pass --force.
|
|
1390
|
+
|
|
1391
|
+
EXAMPLES
|
|
1392
|
+
Register Account with the AT4DX Unit of Work:
|
|
1393
|
+
|
|
1394
|
+
$ sf simply aep generate unit-of-work --target-org myOrg --sobject Account --flavor at4dx --sequence 1000
|
|
1395
|
+
|
|
1396
|
+
Print the fflib Application entry for Account:
|
|
1397
|
+
|
|
1398
|
+
$ sf simply aep generate unit-of-work --target-org myOrg --sobject Account --flavor fflib
|
|
1399
|
+
|
|
1400
|
+
FLAG DESCRIPTIONS
|
|
1401
|
+
-d, --output-dir=<value> Directory to write into, relative to the project root unless absolute.
|
|
1402
|
+
|
|
1403
|
+
Files go under main/classes, main/schema, and test/classes inside it. Defaults to generated-files, as apx's
|
|
1404
|
+
--output-path did, so generated paths don't move.
|
|
1405
|
+
|
|
1406
|
+
-f, --flavor=at4dx|fflib Framework to generate for: at4dx or fflib.
|
|
1407
|
+
|
|
1408
|
+
Sets the templates for every file: the interface and implementation shape, base classes, and whether Application
|
|
1409
|
+
Factory binding records are written. fflib writes none; at4dx writes one per layer.
|
|
1410
|
+
```
|
|
1411
|
+
|
|
1412
|
+
_See code: [lib/commands/simply/aep/generate/unit-of-work.js](https://github.com/SimplySF/simply-plugins/blob/@simplysf/simply-aep@0.16.0/packages/simply-aep/lib/commands/simply/aep/generate/unit-of-work.js)_
|
|
1072
1413
|
<!-- commandsstop -->
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { SfCommand } from '@salesforce/sf-plugins-core';
|
|
2
|
+
import { type GenerateCommandResult } from '../../../../common/generate/runGeneration.js';
|
|
3
|
+
/** Generates a domain class, its interface, test, and trigger, and (at4dx) its Application Factory binding. */
|
|
4
|
+
export default class AepGenerateDomain extends SfCommand<GenerateCommandResult> {
|
|
5
|
+
static readonly summary: string;
|
|
6
|
+
static readonly description: string;
|
|
7
|
+
static readonly examples: string[];
|
|
8
|
+
static readonly flags: {
|
|
9
|
+
'output-dir': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
10
|
+
'dry-run': import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
11
|
+
overwrite: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
12
|
+
force: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
13
|
+
flavor: import("@oclif/core/interfaces").OptionFlag<import("@simplysf/simply-aep-core").Flavor, import("@oclif/core/interfaces").CustomOptions>;
|
|
14
|
+
prefix: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
15
|
+
sobject: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
16
|
+
'api-version': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
17
|
+
'target-org': import("@oclif/core/interfaces").OptionFlag<import("@salesforce/core").Org>;
|
|
18
|
+
'flags-dir': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
19
|
+
};
|
|
20
|
+
run(): Promise<GenerateCommandResult>;
|
|
21
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2026, SimplySF.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { Messages } from '@salesforce/core';
|
|
17
|
+
import { SfCommand } from '@salesforce/sf-plugins-core';
|
|
18
|
+
import { generateDomain } from '@simplysf/simply-aep-core';
|
|
19
|
+
import { requireConnection } from '@simplysf/simply-plugin-kit';
|
|
20
|
+
import { runGeneration } from '../../../../common/generate/runGeneration.js';
|
|
21
|
+
import { flavorFlags, generateWriteFlags, orgFlags, sobjectFlag } from '../../../../common/generate/flags.js';
|
|
22
|
+
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
|
|
23
|
+
const messages = Messages.loadMessages('@simplysf/simply-aep', 'simply.aep.generate.domain');
|
|
24
|
+
/** Generates a domain class, its interface, test, and trigger, and (at4dx) its Application Factory binding. */
|
|
25
|
+
export default class AepGenerateDomain extends SfCommand {
|
|
26
|
+
static summary = messages.getMessage('summary');
|
|
27
|
+
static description = messages.getMessage('description');
|
|
28
|
+
static examples = messages.getMessages('examples');
|
|
29
|
+
static flags = {
|
|
30
|
+
...SfCommand.baseFlags,
|
|
31
|
+
...orgFlags,
|
|
32
|
+
sobject: sobjectFlag,
|
|
33
|
+
...flavorFlags,
|
|
34
|
+
...generateWriteFlags,
|
|
35
|
+
};
|
|
36
|
+
async run() {
|
|
37
|
+
const { flags } = await this.parse(AepGenerateDomain);
|
|
38
|
+
return runGeneration(generateDomain, requireConnection(flags), flags, this);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
//# sourceMappingURL=domain.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"domain.js","sourceRoot":"","sources":["../../../../../src/commands/simply/aep/generate/domain.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAC;AACxD,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,EAAE,aAAa,EAA8B,MAAM,8CAA8C,CAAC;AACzG,OAAO,EAAE,WAAW,EAAE,kBAAkB,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AAE9G,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ,GAAG,QAAQ,CAAC,YAAY,CAAC,sBAAsB,EAAE,4BAA4B,CAAC,CAAC;AAE7F,+GAA+G;AAC/G,MAAM,CAAC,OAAO,OAAO,iBAAkB,SAAQ,SAAgC;IACtE,MAAM,CAAU,OAAO,GAAG,QAAQ,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC;IACzD,MAAM,CAAU,WAAW,GAAG,QAAQ,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC;IACjE,MAAM,CAAU,QAAQ,GAAG,QAAQ,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;IAE5D,MAAM,CAAU,KAAK,GAAG;QAC7B,GAAG,SAAS,CAAC,SAAS;QACtB,GAAG,QAAQ;QACX,OAAO,EAAE,WAAW;QACpB,GAAG,WAAW;QACd,GAAG,kBAAkB;KACtB,CAAC;IAEK,KAAK,CAAC,GAAG;QACd,MAAM,EAAE,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,iBAAiB,CAAC,CAAC;QACtD,OAAO,aAAa,CAAC,cAAc,EAAE,iBAAiB,CAAC,KAAK,CAAC,EAAE,KAAK,EAAE,IAAI,CAAC,CAAC;IAC9E,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { SfCommand } from '@salesforce/sf-plugins-core';
|
|
2
|
+
import { type GenerateCommandResult } from '../../../../common/generate/runGeneration.js';
|
|
3
|
+
/** Generates a selector class, its interface and test, and (at4dx) its Application Factory binding. */
|
|
4
|
+
export default class AepGenerateSelector extends SfCommand<GenerateCommandResult> {
|
|
5
|
+
static readonly summary: string;
|
|
6
|
+
static readonly description: string;
|
|
7
|
+
static readonly examples: string[];
|
|
8
|
+
static readonly flags: {
|
|
9
|
+
'output-dir': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
10
|
+
'dry-run': import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
11
|
+
overwrite: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
12
|
+
force: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
13
|
+
flavor: import("@oclif/core/interfaces").OptionFlag<import("@simplysf/simply-aep-core").Flavor, import("@oclif/core/interfaces").CustomOptions>;
|
|
14
|
+
prefix: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
15
|
+
sobject: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
16
|
+
'api-version': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
17
|
+
'target-org': import("@oclif/core/interfaces").OptionFlag<import("@salesforce/core").Org>;
|
|
18
|
+
'flags-dir': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
19
|
+
};
|
|
20
|
+
run(): Promise<GenerateCommandResult>;
|
|
21
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2026, SimplySF.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { Messages } from '@salesforce/core';
|
|
17
|
+
import { SfCommand } from '@salesforce/sf-plugins-core';
|
|
18
|
+
import { generateSelector } from '@simplysf/simply-aep-core';
|
|
19
|
+
import { requireConnection } from '@simplysf/simply-plugin-kit';
|
|
20
|
+
import { runGeneration } from '../../../../common/generate/runGeneration.js';
|
|
21
|
+
import { flavorFlags, generateWriteFlags, orgFlags, sobjectFlag } from '../../../../common/generate/flags.js';
|
|
22
|
+
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
|
|
23
|
+
const messages = Messages.loadMessages('@simplysf/simply-aep', 'simply.aep.generate.selector');
|
|
24
|
+
/** Generates a selector class, its interface and test, and (at4dx) its Application Factory binding. */
|
|
25
|
+
export default class AepGenerateSelector extends SfCommand {
|
|
26
|
+
static summary = messages.getMessage('summary');
|
|
27
|
+
static description = messages.getMessage('description');
|
|
28
|
+
static examples = messages.getMessages('examples');
|
|
29
|
+
static flags = {
|
|
30
|
+
...SfCommand.baseFlags,
|
|
31
|
+
...orgFlags,
|
|
32
|
+
sobject: sobjectFlag,
|
|
33
|
+
...flavorFlags,
|
|
34
|
+
...generateWriteFlags,
|
|
35
|
+
};
|
|
36
|
+
async run() {
|
|
37
|
+
const { flags } = await this.parse(AepGenerateSelector);
|
|
38
|
+
return runGeneration(generateSelector, requireConnection(flags), flags, this);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
//# sourceMappingURL=selector.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"selector.js","sourceRoot":"","sources":["../../../../../src/commands/simply/aep/generate/selector.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAC;AACxD,OAAO,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAC7D,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,EAAE,aAAa,EAA8B,MAAM,8CAA8C,CAAC;AACzG,OAAO,EAAE,WAAW,EAAE,kBAAkB,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AAE9G,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ,GAAG,QAAQ,CAAC,YAAY,CAAC,sBAAsB,EAAE,8BAA8B,CAAC,CAAC;AAE/F,uGAAuG;AACvG,MAAM,CAAC,OAAO,OAAO,mBAAoB,SAAQ,SAAgC;IACxE,MAAM,CAAU,OAAO,GAAG,QAAQ,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC;IACzD,MAAM,CAAU,WAAW,GAAG,QAAQ,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC;IACjE,MAAM,CAAU,QAAQ,GAAG,QAAQ,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;IAE5D,MAAM,CAAU,KAAK,GAAG;QAC7B,GAAG,SAAS,CAAC,SAAS;QACtB,GAAG,QAAQ;QACX,OAAO,EAAE,WAAW;QACpB,GAAG,WAAW;QACd,GAAG,kBAAkB;KACtB,CAAC;IAEK,KAAK,CAAC,GAAG;QACd,MAAM,EAAE,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,mBAAmB,CAAC,CAAC;QACxD,OAAO,aAAa,CAAC,gBAAgB,EAAE,iBAAiB,CAAC,KAAK,CAAC,EAAE,KAAK,EAAE,IAAI,CAAC,CAAC;IAChF,CAAC"}
|