Java Text File Write writeStringField(String name, String value, JsonGenerator jgen)

Here you can find the source of writeStringField(String name, String value, JsonGenerator jgen)

Description

write String Field

License

Apache License

Declaration

static public void writeStringField(String name, String value, JsonGenerator jgen)
            throws JsonProcessingException, IOException 

Method Source Code


//package com.java2s;
//License from project: Apache License 

import java.io.IOException;
import com.fasterxml.jackson.core.JsonGenerator;
import com.fasterxml.jackson.core.JsonProcessingException;

public class Main {
    static public void writeStringField(String name, String value, JsonGenerator jgen)
            throws JsonProcessingException, IOException {
        if (value != null) {
            jgen.writeStringField(name, value);
        }/*from w  w w .  j  a  va 2  s. c  o  m*/
    }
}

Related

  1. writeString(String path, String str, boolean append)
  2. writeString(String s, File output, String encoding)
  3. writeString(String string, ObjectOutput out)
  4. writeString(String value)
  5. writeString(StringBuilder out, CharSequence value, boolean escapeXML)
  6. writeStringFile(String FileName, String text)
  7. writeStringInto(String s, File outputFile)
  8. writeStringInto(String s, File outputFile)
  9. writeStringListToFile(File file, ArrayList lines)