Skip to content

Add search, goto, and view_vba methods to Browser #17

@WolfpackWilson

Description

@WolfpackWilson

The following methods could be useful in the future and may be worth implementing.

def search(self, name: str, exact: bool = False):
    """Return a dictionary in format {item: [paths]} matching the name.

    Search for all instances of a method or object containing a name.

    Parameters
    ----------
    exact: bool
        A flag that searches for exact matches.
    name: str
        The name of the attribute to search for.

    Returns
    -------
    dict
        The results of the search in format {item: [paths]}.
    """
    ...

def goto(self, path: list):
    """Retrieve an object at a given location.

    Parameters
    ----------
    path: list
        The steps to take to arrive to an object.

    Examples
    --------
    `goto(['Bodies','Item','HybridShapes','GetItem'])` yields the 'GetItem' function.

    """
    ...

def view_vba(self) -> str:
    """Returns a string that replicates the VBA tree."""
    ...

Metadata

Metadata

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions