unitelabs.cdk.sila.utils

Attributes

  • Name
    __all__
    Type
    Value

    = [ "humanize", "parse_docs", "to_display_name", "set_interval", "clear_interval" ]

    Description

Functions

  • humanize(value, sep) -> str

    Parameters

    • Name
      value
      Type
      Default
      = None
      Description

    • Name
      sep
      Type
      Default
      = '_'
      Description

    Response

    Type
    str
    Description

  • parse_docs(docs : str) -> dict

    Parameters

    • Name
      docs
      Type
      str
      Default
      Description

    Response

    Type
    dict
    Description

  • to_display_name(value : str) -> str

    Parameters

    • Name
      value
      Type
      str
      Default
      Description

    Response

    Type
    str
    Description

  • set_interval(function : typing.Callable, delay : float) -> asyncio.Task

    The set_interval() method repeatedly calls a function or executes a codesnippet, with a fixed time delay between each call.

    Parameters

    • Name
      function
      Type
      typing.Callable
      Default
      Description

    • Name
      delay
      Type
      float
      Default
      = 1
      Description

    Response

    Type
    asyncio.Task
    Description

  • clear_interval(interval : asyncio.Task) -> None

    The clear_interval() method cancels a timed, repeating action which was previously established by a call to set_interval().

    Parameters

    • Name
      interval
      Type
      asyncio.Task
      Default
      Description

Copyright © 2024