Examples of writeValue()


Examples of org.codehaus.jackson.map.ObjectMapper.writeValue()

      {
        ObjectMapper mapper = new ObjectMapper();
        SerializationConfig serializationConfig = mapper.getSerializationConfig();
        serializationConfig.set(SerializationConfig.Feature.INDENT_OUTPUT, true);
        StringWriter sw = new StringWriter();
        mapper.writeValue(sw, _alertHistory);
        return sw.toString();
      }
      catch(Exception e)
      {
        _logger.warn("", e);
View Full Code Here

Examples of org.codehaus.jackson.map.ObjectMapper.writeValue()

     
      ObjectMapper mapper = new ObjectMapper();
      StringWriter sw = new StringWriter();
      try
      {
        mapper.writeValue(sw, _updateMap);
      }
      catch (Exception e)
      {
        LOG.error("",e);
      }
View Full Code Here

Examples of org.codehaus.jackson.map.ObjectMapper.writeValue()

          serializationConfig.set(SerializationConfig.Feature.INDENT_OUTPUT, true);

          StringWriter sw = new StringWriter();
          try
          {
            mapper.writeValue(sw, record);
            logger.info(sw.toString());
          } catch (Exception e)
          {
            logger.warn(
                    "Exception during serialization in ZKPathDataDumpTask.checkAndDump. This can mostly be ignored",
View Full Code Here

Examples of org.codehaus.jackson.map.ObjectMapper.writeValue()

    ObjectMapper mapper = new ObjectMapper();
    SerializationConfig serializationConfig = mapper.getSerializationConfig();
    serializationConfig.set(SerializationConfig.Feature.INDENT_OUTPUT, true);

    StringWriter sw = new StringWriter();
    mapper.writeValue(sw, cr);

    String crString = sw.toString();

    schedulerMessage.getRecord().setSimpleField("Criteria", crString);
    schedulerMessage.getRecord().setMapField("MessageTemplate",
View Full Code Here

Examples of org.codehaus.jackson.map.ObjectMapper.writeValue()

    ObjectMapper mapper = new ObjectMapper();
    SerializationConfig serializationConfig = mapper.getSerializationConfig();
    serializationConfig.set(SerializationConfig.Feature.INDENT_OUTPUT, true);

    StringWriter sw = new StringWriter();
    mapper.writeValue(sw, cr);

    String crString = sw.toString();

    schedulerMessage.getRecord().setSimpleField("Criteria", crString);
    schedulerMessage.getRecord().setMapField("MessageTemplate",
View Full Code Here

Examples of org.codehaus.jackson.map.ObjectMapper.writeValue()

    ObjectMapper mapper = new ObjectMapper();
    SerializationConfig serializationConfig = mapper.getSerializationConfig();
    serializationConfig.set(SerializationConfig.Feature.INDENT_OUTPUT, true);

    StringWriter sw = new StringWriter();
    mapper.writeValue(sw, cr);

    String crString = sw.toString();

    schedulerMessage.getRecord().setSimpleField("Criteria", crString);
    schedulerMessage.getRecord().setMapField("MessageTemplate",
View Full Code Here

Examples of org.codehaus.jackson.map.ObjectMapper.writeValue()

    map.put("stores", stores);
    map.put("storefiles", storefiles);
    map.put("storefileSizeMB", storefileIndexSizeMB);
    map.put("memstoreSizeMB", memstoreSizeMB);
    StringWriter w = new StringWriter();
    mapper.writeValue(w, map);
    w.close();
    return Bytes.toBytes(w.toString());
  }

  /**
 
View Full Code Here

Examples of org.codehaus.jackson.map.ObjectWriter.writeValue()

      Set<PhysicalSource> set = multBuf.getPhysicalSourcesForPartition(key.getPhysicalPartition());
      map.put(key.getPhysicalPartition(), set);
    }
   
    if(keys.isEmpty()) {
      writer.writeValue(out, new HashSet<PhysicalPartition>());
    } else {
      writer.writeValue(out,map);
    }
   
    byte[] resultBytes = out.toString().getBytes(Charset.defaultCharset());
View Full Code Here

Examples of org.codehaus.xfire.aegis.MessageWriter.writeValue()

    }
   
    public void write(MessageWriter writer)
    {
        MessageWriter nons = writer.getElementWriter("nons");
        nons.writeValue("nons");
        nons.close();
       
        MessageWriter intval = writer.getElementWriter("int");
        intval.writeValueAsInt(new Integer(10000));
        intval.close();
View Full Code Here

Examples of org.codehaus.xfire.aegis.MessageWriter.writeValue()

        intval.writeValueAsInt(new Integer(10000));
        intval.close();

        MessageWriter child1 = writer.getElementWriter("child1", "urn:child1");
        MessageWriter att1 = child1.getAttributeWriter("att1");
        att1.writeValue("att1");
        att1.close();
        MessageWriter att2 = child1.getAttributeWriter("att2", "");
        att2.writeValue("att2");
        att2.close();
        MessageWriter att3 = child1.getAttributeWriter("att3", "urn:att3");
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.