(CDAP-1088) Added support for String type as StreamEventDecoder so that in MR and Spark it can consume stream body as String object.

Also reorganize the code in StreamInputFormat a bit to make code easier to read.
And also remove the need of Flow in the SparkKMeans test to speed up test.
Merge pull request #886 from caskdata/feature/string-stream-decoder

(CDAP-1088) Added support for String type as StreamEventDecoder