Phase A of the cleanup deferred from #156's pre-lock work. Deliberately scheduled to CY27 per the project's "improve before audience-reducing changes" guiding principle (method deletion is technically audience-reducing even when the audience is empty, and any post-lock consumer of VisioScripting.Client deserves a deprecation cycle rather than a hard removal).
Background
The hybrid-public-API decision in #156 committed the documented VisioScripting.Client facade as a public-stable contract. The pre-decision usage audit found ~36 public methods on the *Commands classes with zero external callers (no cmdlet, no test, no sample, no doc snippet). They are part of the locked surface as of the #156 cleanup issue, but candidates for removal in CY27 with proper deprecation.
Scope
Dead methods, by class
Confirmed by the #156 usage audit. Counts are conservative — overload-vs-name disambiguation is fuzzy in spots; revisit before deletion to confirm zero-caller.
ApplicationCommands: AssertHasApplication
ArrangeCommands: Send, DistributeVertical
ConnectionCommands: GetTransitiveClosureOnActivePage
CustomPropertyCommands: GetCustomProperties (the bare-list form; GetCustomPropertiesAsShapeDictionary is the one used)
DeveloperCommands: DrawNamespaces(IList<Type>), DrawNamespacesAndClasses(IList<Type>), GetInteropEnums, GetInteropEnum, GetEnum. (GetTypes is intra-class only; can also be made internal.)
DocumentCommands: ActivateDocumentWithName, GetDocumentWithName, NewDocumentFromTemplate(Size, string) overload
DrawCommands: Duplicate
GroupingCommands: Ungroup(TargetSelection) overload
OutputCommands: WriteUser, WriteDebug, WriteWarning, WriteError. (Only WriteVerbose is consumed.)
PageCommands: SetActivePage(TargetDocument, PageRelativePosition) overload, both SetPageSize overloads (one is called intra-namespace from NewPage — keep it but mark internal on examination)
SelectionCommands: SubSelectShapes, SelectShapesByMaster, SelectShapesByLayer, GetSelectedShapes(TargetSelection) overload, GetShapesRecursive, GetShapeCount, GetSubSelectedShapes, CopySelectedShapes, ContainsShapes(TargetSelection, int) overload (most over-built class — 9 of 20 dead)
TextCommands: GetShapeTextFormat
UserDefinedCellCommands: GetUserDefinedCells, ContainsUserDefinedCellsWithName
ViewCommands: GetActiveWindow, GetZoom
Dead classes (delete-the-class candidates)
LayerCommands (FindLayersOnPageByName, GetLayersOnPage). Entire class is reached only from SelectionCommands.SelectShapesByLayer, which is itself dead. Delete both the class and the Client.Layer property if external usage is still nil at deletion time.
File-name cleanup
Process
Out of scope
- The boundary-leak fix and enforcement layer — handled in the pre-lock cleanup issue (CY26Q3) referenced from #156.
- The decision on the #156 open sub-question (mark dead methods as "candidate for CY27 removal" in their gitbook pages, or document them as fully stable). That decision shapes the deprecation messaging at this stage.
References
- #156 closing comment (decision + audit findings)
- The pre-lock cleanup issue (CY26Q3) handles Phases B + C; this issue is Phase A
Phase A of the cleanup deferred from #156's pre-lock work. Deliberately scheduled to CY27 per the project's "improve before audience-reducing changes" guiding principle (method deletion is technically audience-reducing even when the audience is empty, and any post-lock consumer of
VisioScripting.Clientdeserves a deprecation cycle rather than a hard removal).Background
The hybrid-public-API decision in #156 committed the documented
VisioScripting.Clientfacade as a public-stable contract. The pre-decision usage audit found ~36 public methods on the*Commandsclasses with zero external callers (no cmdlet, no test, no sample, no doc snippet). They are part of the locked surface as of the #156 cleanup issue, but candidates for removal in CY27 with proper deprecation.Scope
Dead methods, by class
Confirmed by the #156 usage audit. Counts are conservative — overload-vs-name disambiguation is fuzzy in spots; revisit before deletion to confirm zero-caller.
ApplicationCommands:AssertHasApplicationArrangeCommands:Send,DistributeVerticalConnectionCommands:GetTransitiveClosureOnActivePageCustomPropertyCommands:GetCustomProperties(the bare-list form;GetCustomPropertiesAsShapeDictionaryis the one used)DeveloperCommands:DrawNamespaces(IList<Type>),DrawNamespacesAndClasses(IList<Type>),GetInteropEnums,GetInteropEnum,GetEnum. (GetTypesis intra-class only; can also be madeinternal.)DocumentCommands:ActivateDocumentWithName,GetDocumentWithName,NewDocumentFromTemplate(Size, string)overloadDrawCommands:DuplicateGroupingCommands:Ungroup(TargetSelection)overloadOutputCommands:WriteUser,WriteDebug,WriteWarning,WriteError. (OnlyWriteVerboseis consumed.)PageCommands:SetActivePage(TargetDocument, PageRelativePosition)overload, bothSetPageSizeoverloads (one is called intra-namespace fromNewPage— keep it but markinternalon examination)SelectionCommands:SubSelectShapes,SelectShapesByMaster,SelectShapesByLayer,GetSelectedShapes(TargetSelection)overload,GetShapesRecursive,GetShapeCount,GetSubSelectedShapes,CopySelectedShapes,ContainsShapes(TargetSelection, int)overload (most over-built class — 9 of 20 dead)TextCommands:GetShapeTextFormatUserDefinedCellCommands:GetUserDefinedCells,ContainsUserDefinedCellsWithNameViewCommands:GetActiveWindow,GetZoomDead classes (delete-the-class candidates)
LayerCommands(FindLayersOnPageByName,GetLayersOnPage). Entire class is reached only fromSelectionCommands.SelectShapesByLayer, which is itself dead. Delete both the class and theClient.Layerproperty if external usage is still nil at deletion time.File-name cleanup
Commands/ContainerrCommands.cs→Commands/ContainerCommands.cs(file name has a typo; class name is correct). Trivialgit mv. Could be done before CY27 as a non-audience-affecting change if convenient — file name is not part of the public API.Process
[Obsolete("Will be removed in...")]for one minor cycle) or a cleanMajorbump. Probably the former —VisioAutomation2010is at3.xand a4.0bump for cleanup feels heavy.NuGet/CHANGELOG.mdwith full removal list.Out of scope
References