Constructor - an instance of this (private) class is returned from `pa.Table.__dataframe__` or `pa.RecordBatch.__dataframe__`.
(
self, df: pa.Table | pa.RecordBatch,
nan_as_null: bool = False,
allow_copy: bool = True
)
| 44 | """ |
| 45 | |
| 46 | def __init__( |
| 47 | self, df: pa.Table | pa.RecordBatch, |
| 48 | nan_as_null: bool = False, |
| 49 | allow_copy: bool = True |
| 50 | ) -> None: |
| 51 | """ |
| 52 | Constructor - an instance of this (private) class is returned from |
| 53 | `pa.Table.__dataframe__` or `pa.RecordBatch.__dataframe__`. |
| 54 | """ |
| 55 | self._df = df |
| 56 | # ``nan_as_null`` is a keyword intended for the consumer to tell the |
| 57 | # producer to overwrite null values in the data with ``NaN`` (or |
| 58 | # ``NaT``). |
| 59 | if nan_as_null is True: |
| 60 | raise RuntimeError( |
| 61 | "nan_as_null=True currently has no effect, " |
| 62 | "use the default nan_as_null=False" |
| 63 | ) |
| 64 | self._nan_as_null = nan_as_null |
| 65 | self._allow_copy = allow_copy |
| 66 | |
| 67 | def __dataframe__( |
| 68 | self, nan_as_null: bool = False, allow_copy: bool = True |
nothing calls this directly
no outgoing calls
no test coverage detected