implicit methods

fetching data from different sources using Spark 2.1

Spark: createDataFrame() vs toDF()

Reading Time: 2 minutes There are two different ways to create a Dataframe in Spark. First, using toDF() and second is using createDataFrame(). In this blog we will see how we can create Dataframe using these two methods and what’s the exact difference between them. toDF() toDF() method provides a very concise way to create a Dataframe. This method can be applied to a sequence of objects. To access Continue Reading

Implicit Conversions In Scala: Let’s extend Functionality

Reading Time: 3 minutes Hello folks, in this blog we will see Implicit Conversions in Scala language. And how it helps to make our code more readable. Before going into much detail about implicit let’s understand why we need implicit in Scala. There is a basic difference between your own code and libraries of other people. You can change your code as your need but when you have to Continue Reading

Back2Basics: The Magic of Implicit – #2

Reading Time: 3 minutes In our previous blog, The Magic of Implicit, we have talked about how implicit values are being used. In this blog, we will explore Type Conversion with implicit and implicit classes. Let’s start with a simple example, scala> val i: Int = 2.3 <console>:11: error: type mismatch; found : Double(2.3) required: Int val i: Int = 2.3 Here we were trying to assign a double type value Continue Reading