uproot.class_named — Uproot documentation

# uproot.class_named

Defined in uproot.model on line 254.

uproot.model.class_named(classname, version=None, custom_classes=None)

  Returns a class with a given C++ (decoded) classname.

  If `version` is None, no attempt is made to find a specific version.

  - If the class is a uproot.model.DispatchByVersion, then this is object returned.

  - If the class is a versionless model, then this is the object returned.

  If `version` is an integer, an attempt is made to find the specific version.

  - If the class is a uproot.model.DispatchByVersion, then it is queried for a versioned model.

  - If the class is a versionless model, then this is the object returned.

  If `custom_classes` are provided, then these are searched (exclusively) for the class. If `custom_classes` is None, then `uproot.classes` is used.

  No classes are created if a class is not found (an error is raised).