Skip to content

Commit

Permalink
Return the old RowEncoder API
Browse files Browse the repository at this point in the history
  • Loading branch information
kotlovs committed Nov 29, 2023
1 parent 853c926 commit a862a46
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,14 @@ import org.apache.spark.sql.types._
* }}}
*/
object RowEncoder {
def apply(schema: StructType, lenient: Boolean): ExpressionEncoder[Row] = {
ExpressionEncoder(schema, lenient)
}

def apply(schema: StructType): ExpressionEncoder[Row] = {
ExpressionEncoder(schema)
}

def encoderFor(schema: StructType): AgnosticEncoder[Row] = {
encoderFor(schema, lenient = false)
}
Expand Down

0 comments on commit a862a46

Please sign in to comment.