This pull request primarily focuses on enhancing the telemetry and output sanitization in the CmdletClass and NewModuleClass within the powershell/cmdlets/class.ts and powershell/module/module-class.ts files respectively. The changes include the addition of a new method NewImplementWriteObject, inclusion of telemetry information, and sanitizing the output object.
Telemetry and Output Sanitization in CmdletClass:
[powershell/cmdlets/class.ts]: Added a new method NewImplementWriteObject that includes two new WriteObject methods to sanitize the output before sending it to the pipeline.
[powershell/cmdlets/class.ts]: Added telemetry information to the CmdletClass that includes sanitized properties and invocation name.
Telemetry and Output Sanitization in NewModuleClass:
[powershell/module/module-class.ts]: Added SanitizerDelegate and GetTelemetryInfoDelegate to the NewModuleClass to sanitize the output object and get telemetry info respectively.
Other Changes:
[powershell/generators/psm1.ts]: Added delegation to sanitize the output object and get the telemetry info in the generatePsm1 function.
This pull request primarily focuses on enhancing the telemetry and output sanitization in the
CmdletClass
andNewModuleClass
within thepowershell/cmdlets/class.ts
andpowershell/module/module-class.ts
files respectively. The changes include the addition of a new methodNewImplementWriteObject
, inclusion of telemetry information, and sanitizing the output object.Telemetry and Output Sanitization in
CmdletClass
:powershell/cmdlets/class.ts
]: Added a new methodNewImplementWriteObject
that includes two newWriteObject
methods to sanitize the output before sending it to the pipeline.powershell/cmdlets/class.ts
]: Added telemetry information to theCmdletClass
that includes sanitized properties and invocation name.Telemetry and Output Sanitization in
NewModuleClass
:powershell/module/module-class.ts
]: AddedSanitizerDelegate
andGetTelemetryInfoDelegate
to theNewModuleClass
to sanitize the output object and get telemetry info respectively.Other Changes:
powershell/generators/psm1.ts
]: Added delegation to sanitize the output object and get the telemetry info in thegeneratePsm1
function.