[F] getVersioningMutators
function getVersioningMutators(program, namespace): | VersionedMutators | TransientVersioningMutator | undefined;Resolve the set of mutators needed to apply versioning to the service.
This constructs mutation recipes without modifying the source namespace.
Apply a recipe with unsafe_mutateSubgraphWithNamespace from
@typespec/compiler/experimental to obtain a snapshot with version-specific
names, types, optionality, and unavailable members removed.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
program | Program |
namespace | Namespace |
Returns
Section titled “Returns”| VersionedMutators
| TransientVersioningMutator
| undefined
either:
- VersionedMutators when the service is versioned.
- TransientVersioningMutator when the service is not versioned but use specific version from another library.
- undefined when neither the service nor its resolved dependencies are versioned.