obspy.core.util.decorator

Decorator used in ObsPy.

copyright:The ObsPy Development Team (devs@obspy.org)
license:GNU Lesser General Public License, Version 3 (https://www.gnu.org/copyleft/lesser.html)

Public Functions

deprecated This is a decorator which can be used to mark functions as deprecated.
deprecated_keywords Decorator for marking keywords as deprecated.
map_example_filename Decorator that replaces “/path/to/filename” patterns in the arg or kwarg of the specified name with the correct file path.
raise_if_masked Raises if the first argument (self in case of methods) is a Trace with
rlock Place a threading recursive lock (Rlock) on the wrapped function.
skip_if_no_data Does nothing if the first argument (self in case of methods) is a Trace
skip_on_network_error Decorator for unittest to mark test routines that fail with certain network errors (e.g.
uncompress_file Decorator used for temporary uncompressing file if .gz or .bz2 archive.

Private Functions

Warning

Private functions are mainly for internal/developer use and their API might change without notice.

_decorate_polyfill decorate(func, caller) decorates a function using a caller.