def METHOD_NAME(
    self,
    df: pyspark.DataFrame,
    batch_spec: BatchSpec,
) -> pyspark.DataFrame:
    """Match the values in the named column against value_list, and only keep the matches.
    Args:
        df: dataframe to sample
        batch_spec: should contain keys `column_name` and `value_list`
    Returns:
        Sampled dataframe
    Raises:
        SamplerError
    """
    self.verify_batch_spec_sampling_kwargs_exists(batch_spec)
    self.verify_batch_spec_sampling_kwargs_key_exists("column_name", batch_spec)
    self.verify_batch_spec_sampling_kwargs_key_exists("value_list", batch_spec)
    column_name: str = self.get_sampling_kwargs_value_or_default(
        batch_spec, "column_name"
    )
    value_list: list = self.get_sampling_kwargs_value_or_default(
        batch_spec, "value_list"
    )
    return df.where(F.col(column_name).isin(value_list))