Callables.with_name_suffix()

with_name_suffix(suffix: str, sensitivity: bool = True) → Callables

Adds a filter to get callables whose names have the given suffix. Returns a filtered Callables child object. This method can be called on all Callables child classes: Functions and Modifiers.

To filter given a list of suffixes, refer to Callables.with_name_suffixes().

Functions Example

from glider import *

def query():
  # Retrieve the functions that have `down` as suffix
  functions = Functions().with_name_suffix("down").exec(100)

  # Return the first five functions
  return functions[:5]

Output:

Modifiers Example

from glider import *

def query():
  # Retrieve the modifiers that have `Initialized` as suffix
  modifiers = Modifiers().with_name_suffix("Initialized").exec(100)

  # Return the first five modifiers
  return modifiers[:5]

Output:

Last updated