[MINOR][DOC] Fix doc of ForeachWriter to use writeStream
## What changes were proposed in this pull request? Fix the document of `ForeachWriter` to use `writeStream` instead of `write` for a streaming dataset. ## How was this patch tested? Docs only. Author: Carson Wang <carson.wang@intel.com> Closes #16419 from carsonwang/FixDoc.
This commit is contained in:
parent
76e9bd7488
commit
2a5f52a714
|
@ -28,7 +28,7 @@ import org.apache.spark.annotation.{Experimental, InterfaceStability}
|
|||
*
|
||||
* Scala example:
|
||||
* {{{
|
||||
* datasetOfString.write.foreach(new ForeachWriter[String] {
|
||||
* datasetOfString.writeStream.foreach(new ForeachWriter[String] {
|
||||
*
|
||||
* def open(partitionId: Long, version: Long): Boolean = {
|
||||
* // open connection
|
||||
|
@ -46,7 +46,7 @@ import org.apache.spark.annotation.{Experimental, InterfaceStability}
|
|||
*
|
||||
* Java example:
|
||||
* {{{
|
||||
* datasetOfString.write().foreach(new ForeachWriter<String>() {
|
||||
* datasetOfString.writeStream().foreach(new ForeachWriter<String>() {
|
||||
*
|
||||
* @Override
|
||||
* public boolean open(long partitionId, long version) {
|
||||
|
|
Loading…
Reference in a new issue