Class ToString

    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static PTransform<PCollection<?>,​PCollection<java.lang.String>> elements()
      Transforms each element of the input PCollection to a String using the Object.toString() method.
      static PTransform<PCollection<? extends java.lang.Iterable<?>>,​PCollection<java.lang.String>> iterables()
      Transforms each item in the iterable of the input PCollection to a String using the Object.toString() method followed by a "," until the last element in the iterable.
      static PTransform<PCollection<? extends java.lang.Iterable<?>>,​PCollection<java.lang.String>> iterables​(java.lang.String delimiter)
      Transforms each item in the iterable of the input PCollection to a String using the Object.toString() method followed by the specified delimiter until the last element in the iterable.
      static PTransform<PCollection<? extends KV<?,​?>>,​PCollection<java.lang.String>> kvs()
      Transforms each element of the input PCollection to a String by using the Object.toString() on the key followed by a "," followed by the Object.toString() of the value.
      static PTransform<PCollection<? extends KV<?,​?>>,​PCollection<java.lang.String>> kvs​(java.lang.String delimiter)
      Transforms each element of the input PCollection to a String by using the Object.toString() on the key followed by the specified delimiter followed by the Object.toString() of the value.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • kvs

        public static PTransform<PCollection<? extends KV<?,​?>>,​PCollection<java.lang.String>> kvs()
        Transforms each element of the input PCollection to a String by using the Object.toString() on the key followed by a "," followed by the Object.toString() of the value.
      • kvs

        public static PTransform<PCollection<? extends KV<?,​?>>,​PCollection<java.lang.String>> kvs​(java.lang.String delimiter)
        Transforms each element of the input PCollection to a String by using the Object.toString() on the key followed by the specified delimiter followed by the Object.toString() of the value.
        Parameters:
        delimiter - The delimiter to put between the key and value
      • iterables

        public static PTransform<PCollection<? extends java.lang.Iterable<?>>,​PCollection<java.lang.String>> iterables()
        Transforms each item in the iterable of the input PCollection to a String using the Object.toString() method followed by a "," until the last element in the iterable. There is no trailing delimiter.
      • iterables

        public static PTransform<PCollection<? extends java.lang.Iterable<?>>,​PCollection<java.lang.String>> iterables​(java.lang.String delimiter)
        Transforms each item in the iterable of the input PCollection to a String using the Object.toString() method followed by the specified delimiter until the last element in the iterable. There is no trailing delimiter.
        Parameters:
        delimiter - The delimiter to put between the items in the iterable.