def METHOD_NAME(state: State, title: str | None, suppress_warning: bool) -> str:
    if title is not None:
        return title
    if state.file:
        return state.file.title
    if not suppress_warning:
        warn("save() called but no title was supplied and output_file(...) was never called, using default title 'Bokeh Plot'")
    return DEFAULT_TITLE