code: def toJSON(self, use_unicode=True):
          
          rdd = self._jdf.toJSON()
          return RDD(rdd.toJavaRDD(), self._sc, UTF8Deserializer(use_unicode))
docs: Converts a :class:`DataFrame` into a :class:`RDD` of string.
  
          Each row is turned into a JSON document as one element in the returned RDD.
  
          >>> df.toJSON().first()
          u'{"age":2,"name":"Alice"}'