:py:mod:`spark_auto_mapper.data_types.if_column_exists` ======================================================= .. py:module:: spark_auto_mapper.data_types.if_column_exists Module Contents --------------- Classes ~~~~~~~ .. autoapisummary:: spark_auto_mapper.data_types.if_column_exists.AutoMapperIfColumnExistsType .. py:class:: AutoMapperIfColumnExistsType(column, if_exists, if_not_exists) Bases: :py:obj:`spark_auto_mapper.data_types.data_type_base.AutoMapperDataTypeBase`, :py:obj:`Generic`\ [\ :py:obj:`_TAutoMapperDataType`\ ] Allows for columns to be defined based in which a source column may not exist. If the optional source column does not exist, the "default" column definition is used instead. .. py:method:: get_column_spec(self, source_df, current_column) Gets the column spec for this automapper data type :param source_df: source data frame in case the automapper type needs that data to decide what to do :param current_column: (Optional) this is set when we are inside an array