Batch Port Over to Scala