class_docstr: Namespace for string related expressions.
class_docstr_tok: ["Namespace","for","string","related","expressions","."]
docstr: Extract all matches for the given regex pattern.
  
  Extract each successive non-overlapping regex match in an individual string
  as a list. If the haystack string is `null`, `null` is returned.
  
  Parameters
  ----------
  pattern
      A valid regular expression pattern, compatible with the `regex crate
      <https://docs.rs/regex/latest/regex/>`_.
  
  Notes
  -----
  To modify regular expression behaviour (such as "verbose" mode and/or
  case-sensitive matching) with flags, use the inline `(?iLmsuxU)` syntax.
  For example:
  
  >>> df = pl.DataFrame(
  ...     data={
  ...         "email": [
  ...             "real.email@spam.com",
  ...             "some_account@somewhere.net",
  ...             "abc.def.ghi.jkl@uvw.xyz.co.uk",
  ...         ]
  ...     }
  ... )
  >>> # extract name/domain parts from the addresses, using verbose regex
  >>> df.with_columns(
  ...     pl.col("email")
  ...     .str.extract_all(
  ...         r"""(?xi)   # activate 'verbose' and 'case-insensitive' flags
  ...         [           # (start character group)
  ...           A-Z       # letters
  ...           0-9       # digits
  ...           ._%+\-    # special chars
  ...         ]           # (end character group)
  ...         +           # 'one or more' quantifier
  ...         """
  ...     )
  ...     .list.to_struct(fields=["name", "domain"])
  ...     .alias("email_parts")
  ... ).unnest("email_parts")
  shape: (3, 3)
  ┌───────────────────────────────┬─────────────────┬───────────────┐
  │ email                         ┆ name            ┆ domain        │
  │ ---                           ┆ ---             ┆ ---           │
  │ str                           ┆ str             ┆ str           │
  ╞═══════════════════════════════╪═════════════════╪═══════════════╡
  │ real.email@spam.com           ┆ real.email      ┆ spam.com      │
  │ some_account@somewhere.net    ┆ some_account    ┆ somewhere.net │
  │ abc.def.ghi.jkl@uvw.xyz.co.uk ┆ abc.def.ghi.jkl ┆ uvw.xyz.co.uk │
  └───────────────────────────────┴─────────────────┴───────────────┘
  
  See the regex crate's section on `grouping and flags
  <https://docs.rs/regex/latest/regex/#grouping-and-flags>`_ for
  additional information about the use of inline expression modifiers.
  
  Returns
  -------
  Expr
      Expression of data type `List(String)`.
  
  Examples
  --------
  >>> df = pl.DataFrame({"foo": ["123 bla 45 asd", "xyz 678 910t", "bar", None]})
  >>> df.select(
  ...     pl.col("foo").str.extract_all(r"\d+").alias("extracted_nrs"),
  ... )
  shape: (4, 1)
  ┌────────────────┐
  │ extracted_nrs  │
  │ ---            │
  │ list[str]      │
  ╞════════════════╡
  │ ["123", "45"]  │
  │ ["678", "910"] │
  │ []             │
  │ null           │
  └────────────────┘
docstr_tok: ["Extract","all","matches","for","the","given","regex","pattern",".","Extract","each","successive","non-overlapping","regex","match","in","an","individual","string","as","a","list",".","If","the","haystack","string","is","`","null","`",",","`","null","`","is","returned",".","Parameters","--","--","--","--","--","pattern","A","valid","regular","expression","pattern",",","compatible","with","the","`","regex","crate","<","https",":","\/\/docs.rs\/regex\/latest\/regex\/",">","`","_",".","Notes","--","--","-","To","modify","regular","expression","behaviour","(","such","as","``","verbose","''","mode","and\/or","case-sensitive","matching",")","with","flags",",","use","the","inline","`","(","?","iLmsuxU",")","`","syntax",".","For","example",":",">",">",">","df","=","pl.DataFrame","(","...","data=","{","...","``","email","''",":","[","...","``","real.email","@","spam.com","''",",","...","``","some_account","@","somewhere.net","''",",","...","``","abc.def.ghi.jkl","@","uvw.xyz.co.uk","''",",","...","]","...","}","...",")",">",">",">","#","extract","name\/domain","parts","from","the","addresses",",","using","verbose","regex",">",">",">","df.with_columns","(","...","pl.col","(","``","email","''",")","...",".str.extract_all","(","...","r","''","''","''","(","?","xi",")","#","activate","'verbose","'","and","'case-insensitive","'","flags","...","[","#","(","start","character","group",")","...","A-Z","#","letters","...","0-9","#","digits","...","._","%","+\\-","#","special","chars","...","]","#","(","end","character","group",")","...","+","#","'one","or","more","'","quantifier","...","``","''","''","...",")","...",".list.to_struct","(","fields=","[","``","name","''",",","``","domain","''","]",")","...",".alias","(","``","email_parts","''",")","...",")",".unnest","(","``","email_parts","''",")","shape",":","(","3",",","3",")","\u250c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u252c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u252c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510","\u2502","email","\u2506","name","\u2506","domain","\u2502","\u2502","--","-","\u2506","--","-","\u2506","--","-","\u2502","\u2502","str","\u2506","str","\u2506","str","\u2502","\u255e\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u256a\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u256a\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2561","\u2502","real.email","@","spam.com","\u2506","real.email","\u2506","spam.com","\u2502","\u2502","some_account","@","somewhere.net","\u2506","some_account","\u2506","somewhere.net","\u2502","\u2502","abc.def.ghi.jkl","@","uvw.xyz.co.uk","\u2506","abc.def.ghi.jkl","\u2506","uvw.xyz.co.uk","\u2502","\u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2534\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2534\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518","See","the","regex","crate","'s","section","on","`","grouping","and","flags","<","https",":","\/\/docs.rs\/regex\/latest\/regex\/","#","grouping-and-flags",">","`","_","for","additional","information","about","the","use","of","inline","expression","modifiers",".","Returns","--","--","--","-","Expr","Expression","of","data","type","`","List","(","String",")","`",".","Examples","--","--","--","--",">",">",">","df","=","pl.DataFrame","(","{","``","foo","''",":","[","``","123","bla","45","asd","''",",","``","xyz","678","910t","''",",","``","bar","''",",","None","]","}",")",">",">",">","df.select","(","...","pl.col","(","``","foo","''",")",".str.extract_all","(","r","''","\\d+","''",")",".alias","(","``","extracted_nrs","''",")",",","...",")","shape",":","(","4",",","1",")","\u250c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510","\u2502","extracted_nrs","\u2502","\u2502","--","-","\u2502","\u2502","list","[","str","]","\u2502","\u255e\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2561","\u2502","[","``","123","''",",","``","45","''","]","\u2502","\u2502","[","``","678","''",",","``","910","''","]","\u2502","\u2502","[","]","\u2502","\u2502","null","\u2502","\u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518"]
code: def extract_all(self, pattern: str | Expr) -> Expr:
      r'''
      Extract all matches for the given regex pattern.
  
      Extract each successive non-overlapping regex match in an individual string
      as a list. If the haystack string is `null`, `null` is returned.
  
      Parameters
      ----------
      pattern
          A valid regular expression pattern, compatible with the `regex crate
          <https://docs.rs/regex/latest/regex/>`_.
  
      Notes
      -----
      To modify regular expression behaviour (such as "verbose" mode and/or
      case-sensitive matching) with flags, use the inline `(?iLmsuxU)` syntax.
      For example:
  
      >>> df = pl.DataFrame(
      ...     data={
      ...         "email": [
      ...             "real.email@spam.com",
      ...             "some_account@somewhere.net",
      ...             "abc.def.ghi.jkl@uvw.xyz.co.uk",
      ...         ]
      ...     }
      ... )
      >>> # extract name/domain parts from the addresses, using verbose regex
      >>> df.with_columns(
      ...     pl.col("email")
      ...     .str.extract_all(
      ...         r"""(?xi)   # activate 'verbose' and 'case-insensitive' flags
      ...         [           # (start character group)
      ...           A-Z       # letters
      ...           0-9       # digits
      ...           ._%+\-    # special chars
      ...         ]           # (end character group)
      ...         +           # 'one or more' quantifier
      ...         """
      ...     )
      ...     .list.to_struct(fields=["name", "domain"])
      ...     .alias("email_parts")
      ... ).unnest("email_parts")
      shape: (3, 3)
      ┌───────────────────────────────┬─────────────────┬───────────────┐
      │ email                         ┆ name            ┆ domain        │
      │ ---                           ┆ ---             ┆ ---           │
      │ str                           ┆ str             ┆ str           │
      ╞═══════════════════════════════╪═════════════════╪═══════════════╡
      │ real.email@spam.com           ┆ real.email      ┆ spam.com      │
      │ some_account@somewhere.net    ┆ some_account    ┆ somewhere.net │
      │ abc.def.ghi.jkl@uvw.xyz.co.uk ┆ abc.def.ghi.jkl ┆ uvw.xyz.co.uk │
      └───────────────────────────────┴─────────────────┴───────────────┘
  
      See the regex crate's section on `grouping and flags
      <https://docs.rs/regex/latest/regex/#grouping-and-flags>`_ for
      additional information about the use of inline expression modifiers.
  
      Returns
      -------
      Expr
          Expression of data type `List(String)`.
  
      Examples
      --------
      >>> df = pl.DataFrame({"foo": ["123 bla 45 asd", "xyz 678 910t", "bar", None]})
      >>> df.select(
      ...     pl.col("foo").str.extract_all(r"\d+").alias("extracted_nrs"),
      ... )
      shape: (4, 1)
      ┌────────────────┐
      │ extracted_nrs  │
      │ ---            │
      │ list[str]      │
      ╞════════════════╡
      │ ["123", "45"]  │
      │ ["678", "910"] │
      │ []             │
      │ null           │
      └────────────────┘
  
      '''
      pattern = parse_as_expression(pattern, str_as_lit=True)
      return wrap_expr(self._pyexpr.str_extract_all(pattern))
  
imports: from __future__ import annotations
  import warnings
  from typing import TYPE_CHECKING
  import polars._reexport
  from polars import functions
  from polars.datatypes import Date, Datetime, Int32, Time, py_type_to_dtype
  from polars.exceptions import ChronoFormatWarning
  from polars.utils._parse_expr_input import parse_as_expression
  from polars.utils._wrap import wrap_expr
  from polars.utils.deprecation import deprecate_renamed_function, deprecate_renamed_parameter, rename_use_earliest_to_ambiguous
  from polars.utils.various import find_stacklevel
label_desc: Use image node_id 29 for calling the ExprStringNameSpace obj's underlying member method code with example usage: obj.extract_all(pattern) and returns: wrap_expr