param.parameterized.Parameters#

class param.parameterized.Parameters(cls: type[Parameterized], self: Parameterized | None = None)[source]#

Object that holds the .param namespace and implementation of Parameterized methods as well as any state that is not in __slots__ or the Parameters themselves.

Exists at both the metaclass level (instantiated by the metaclass) and at the instance level. Can contain state specific to either the class or the instance as necessary.

References

https://param.holoviz.org/user_guide/Parameters.html#parameterized-namespace

__init__(cls: type[Parameterized], self: Parameterized | None = None)[source]#

cls is the Parameterized class which is always set. self is the instance if set.

Methods

__init__(cls[, self])

cls is the Parameterized class which is always set.

add_parameter(param_name, param_obj)

Add a new Parameter object to this class.

deserialize_parameters(serialization[, ...])

Deserialize the given serialized data.

deserialize_value(pname, value[, mode])

Deserialize the value of a specific parameter.

force_new_dynamic_value(name)

Force a new value to be generated for the dynamic attribute name, and return it.

get_value_generator(name)

Retrieve the value or value-generating object of a named parameter.

inspect_value(name)

Inspect the current value of a parameter without modifying it.

log(level, msg, *args, **kw)

Log a message at the specified logging level.

method_dependencies(name[, intermediate])

Retrieve the parameter dependencies of a specified method.

objects([instance])

Return the Parameters of this instance or class.

outputs()

Retrieve a mapping of declared outputs for the Parameterized object.

pprint([imports, prefix, unknown_value, ...])

Generate a pretty-printed representation of the object.

schema([safe, subset, mode])

Generate a schema for the parameters on this Parameterized object.

serialize_parameters([subset, mode])

Return the serialized parameters of the Parameterized object.

serialize_value(pname[, mode])

Serialize the value of a specific parameter.

set_dynamic_time_fn(time_fn[, sublistattr])

Set time_fn for all param.Dynamic Parameters of this class or instance object that are currently being dynamically generated.

trigger(*param_names)

Trigger watchers for the given set of parameter names.

unwatch(watcher)

Remove a watcher from this object's list of registered watchers.

update([arg])

Update multiple parameters of this object or class before triggering events.

values([onlychanged])

Retrieve a dictionary of parameter names and their current values.

warning(msg, *args, **kw)

Print msg merged with args as a warning, unless module variable warnings_as_exceptions is True, then raise an Exception containing the arguments.

watch(fn, parameter_names[, what, ...])

Register a callback function to be invoked for parameter events.

watch_values(fn, parameter_names[, what, ...])

Register a callback function for changes in parameter values.

Attributes

self_or_cls

watchers

Dictionary of instance watchers.