File tree Expand file tree Collapse file tree 2 files changed +24
-1
lines changed Expand file tree Collapse file tree 2 files changed +24
-1
lines changed Original file line number Diff line number Diff line change @@ -221,7 +221,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
221221 -i " pandas.core.resample.Resampler.transform PR01,RT03,SA01" \
222222 -i " pandas.core.resample.Resampler.var SA01" \
223223 -i " pandas.date_range RT03" \
224- -i " pandas.errors.AbstractMethodError PR01,SA01" \
225224 -i " pandas.errors.AttributeConflictWarning SA01" \
226225 -i " pandas.errors.CSSWarning SA01" \
227226 -i " pandas.errors.CategoricalConversionWarning SA01" \
Original file line number Diff line number Diff line change @@ -285,6 +285,30 @@ class AbstractMethodError(NotImplementedError):
285285 """
286286 Raise this error instead of NotImplementedError for abstract methods.
287287
288+ The `AbstractMethodError` is designed for use in classes that follow an abstract
289+ base class pattern. By raising this error in the method, it ensures that a subclass
290+ must implement the method to provide specific functionality. This is useful in a
291+ framework or library where certain methods must be implemented by the user to
292+ ensure correct behavior.
293+
294+ Parameters
295+ ----------
296+ class_instance : object
297+ The instance of the class where the abstract method is being called.
298+ methodtype : str, default "method"
299+ A string indicating the type of method that is abstract.
300+ Must be one of {"method", "classmethod", "staticmethod", "property"}.
301+
302+ See Also
303+ --------
304+ api.extensions.ExtensionArray
305+ An example of a pandas extension mechanism that requires implementing
306+ specific abstract methods.
307+ NotImplementedError
308+ A built-in exception that can also be used for abstract methods but lacks
309+ the specificity of `AbstractMethodError` in indicating the need for subclass
310+ implementation.
311+
288312 Examples
289313 --------
290314 >>> class Foo:
You can’t perform that action at this time.
0 commit comments