unity-menustack  0.1.0
A way to track unity menu navigation that doesn't suck too much
Public Member Functions | Public Attributes | Protected Member Functions | List of all members
MenuStack.Navigation.RegexMenuNavigator Class Reference

Represents a menu navigator that navigates to the first Menu in the MenuRoot thats name matches some regex More...

Inheritance diagram for MenuStack.Navigation.RegexMenuNavigator:
MenuStack.Navigation.BaseMenuNavigator MenuStack.Navigation.INavigator

Public Member Functions

Menu FindFirstRecursively (Transform root, Regex match)
 Internal recursive matcher More...
 
- Public Member Functions inherited from MenuStack.Navigation.BaseMenuNavigator
virtual void Navigate ()
 Triggers navigation More...
 

Public Attributes

string Regex
 The regex string with which we try to match menus More...
 

Protected Member Functions

override Menu GetNavigationLocation ()
 Provides a location to navigate to, when navigation occurs More...
 

Detailed Description

Represents a menu navigator that navigates to the first Menu in the MenuRoot thats name matches some regex

Member Function Documentation

◆ FindFirstRecursively()

Menu MenuStack.Navigation.RegexMenuNavigator.FindFirstRecursively ( Transform  root,
Regex  match 
)

Internal recursive matcher

Parameters
rootthe root level transform to start matching
matchthe regex to match against
Returns
a matched Menu, or null

◆ GetNavigationLocation()

override Menu MenuStack.Navigation.RegexMenuNavigator.GetNavigationLocation ( )
protectedvirtual

Provides a location to navigate to, when navigation occurs

Returns
Menu to navigate to

Implements MenuStack.Navigation.BaseMenuNavigator.

Member Data Documentation

◆ Regex

string MenuStack.Navigation.RegexMenuNavigator.Regex

The regex string with which we try to match menus

We'll start at MenuRoot and match the first found


The documentation for this class was generated from the following file: