SPARK-2895: Add mapPartitionsWithContext related support on Spark Java API.