Examples of writeStringField()


Examples of com.facebook.swift.codec.internal.TProtocolWriter.writeStringField()

        writer.writeStructBegin("union");

        switch (value._id) {
        case 1:
            writer.writeStringField("stringValue", (short) 1, value.stringValue);
            break;
        case 2:
            writer.writeI64Field("longValue", (short) 2, value.longValue);
            break;
        case 3:
View Full Code Here

Examples of com.fasterxml.jackson.core.JsonGenerator.writeStringField()

            {
                json.writeStringField("type", "timer");
                json.writeFieldName("duration");
                json.writeStartObject();
                {
                    json.writeStringField("unit", timer.durationUnit().toString().toLowerCase());
                    writeSummarizable(timer, json);
                    writeSampling(timer, json);
                    if (context.showFullSamples) {
                        json.writeObjectField("values", timer.getSnapshot().getValues());
                    }
View Full Code Here

Examples of com.fasterxml.jackson.core.JsonGenerator.writeStringField()

        @Override
        public void processGauge(MetricName name, Gauge<?> gauge, Context context) throws Exception {
            final JsonGenerator json = context.json;
            json.writeStartObject();
            {
                json.writeStringField("type", "gauge");
                json.writeObjectField("value", evaluateGauge(gauge));
            }
            json.writeEndObject();
        }
View Full Code Here

Examples of com.fasterxml.jackson.core.JsonGenerator.writeStringField()

        @Override
        public void processMeter(MetricName name, Metered meter, Context context) throws Exception {
            final JsonGenerator json = context.json;
            json.writeStartObject();
            {
                json.writeStringField("type", "meter");
                json.writeStringField("event_type", meter.eventType());
                writeMeteredFields(meter, json);
            }
            json.writeEndObject();
        }
View Full Code Here

Examples of com.fasterxml.jackson.core.JsonGenerator.writeStringField()

        public void processMeter(MetricName name, Metered meter, Context context) throws Exception {
            final JsonGenerator json = context.json;
            json.writeStartObject();
            {
                json.writeStringField("type", "meter");
                json.writeStringField("event_type", meter.eventType());
                writeMeteredFields(meter, json);
            }
            json.writeEndObject();
        }
View Full Code Here

Examples of com.fasterxml.jackson.core.JsonGenerator.writeStringField()

        @Override
        public void processCounter(MetricName name, Counter counter, Context context) throws Exception {
            final JsonGenerator json = context.json;
            json.writeStartObject();
            {
                json.writeStringField("type", "counter");
                json.writeNumberField("count", counter.count());
            }
            json.writeEndObject();
        }
View Full Code Here

Examples of com.fasterxml.jackson.core.JsonGenerator.writeStringField()

        @Override
        public void processHistogram(MetricName name, Histogram histogram, Context context) throws Exception {
            final JsonGenerator json = context.json;
            json.writeStartObject();
            {
                json.writeStringField("type", "histogram");
                json.writeNumberField("count", histogram.count());
                writeSummarizable(histogram, json);
                writeSampling(histogram, json);

                if (context.showFullSamples) {
View Full Code Here

Examples of com.fasterxml.jackson.core.JsonGenerator.writeStringField()

        @Override
        public void processTimer(MetricName name, Timer timer, Context context) throws Exception {
            final JsonGenerator json = context.json;
            json.writeStartObject();
            {
                json.writeStringField("type", "timer");
                json.writeFieldName("duration");
                json.writeStartObject();
                {
                    json.writeStringField("unit", timer.durationUnit().toString().toLowerCase());
                    writeSummarizable(timer, json);
View Full Code Here

Examples of com.fasterxml.jackson.core.JsonGenerator.writeStringField()

                resolvedTypeIds ).sortColumnNames( sortColumnNames ).build();

            StringWriter searchParamStringWriter = new StringWriter();
            JsonGenerator gen = jsonFactory.createGenerator( searchParamStringWriter );
            gen.writeStartObject();
            gen.writeStringField( "jql", jqlQuery );
            gen.writeNumberField( "maxResults", nbEntriesMax );
            gen.writeArrayFieldStart( "fields" );
            // Retrieve all fields. If that seems slow, we can reconsider.
            gen.writeString( "*all" );
            gen.writeEndArray();
View Full Code Here

Examples of com.fasterxml.jackson.core.JsonGenerator.writeStringField()

            client.replacePath( "/rest/auth/1/session" );
            client.type( MediaType.APPLICATION_JSON_TYPE );
            StringWriter jsWriter = new StringWriter( );
            JsonGenerator gen = jsonFactory.createGenerator( jsWriter );
            gen.writeStartObject();
            gen.writeStringField( "username", jiraUser );
            gen.writeStringField( "password", jiraPassword );
            gen.writeEndObject();
            gen.close();
            Response authRes = client.post( jsWriter.toString() );
            if ( authRes.getStatus() != Response.Status.OK.getStatusCode() )
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.