Package com.thoughtworks.xstream

Examples of com.thoughtworks.xstream.XStream


          }
        }   
      }
     
      roomRecording.setInitwhiteboardvars(initwhiteboardvars);
      XStream xStream_temp = new XStream(new XppDriver());
      xStream_temp.setMode(XStream.NO_REFERENCES);
      roomRecording.setInitwhiteboardvarsInXml(xStream_temp.toXML(initwhiteboardvars));
     
      roomRecording.setRecordingName(recordingName);
      roomRecording.setStarttime(new java.util.Date());
     
      roomRecording.setStartedby(currentClient);
View Full Code Here


      RoomRecording roomRecording = roomRecordingList.get(roomrecordingName);
     
      Date recordingsStartTime = roomRecording.getStarttime();
      Date currentDate = new Date();
     
      XStream xStream = new XStream(new XppDriver());
      xStream.setMode(XStream.NO_REFERENCES);
      String action = xStream.toXML(vars);
     
      WhiteBoardEvent whiteBoardEvent = new WhiteBoardEvent();
      whiteBoardEvent.setStarttime(currentDate.getTime()-recordingsStartTime.getTime());
      whiteBoardEvent.setAction(action);
     
View Full Code Here

      RoomRecording roomRecording = roomRecordingList.get(roomrecordingName);
     
      Date recordingsStartTime = roomRecording.getStarttime();
      Date currentDate = new Date();
     
      XStream xStream = new XStream(new XppDriver());
      xStream.setMode(XStream.NO_REFERENCES);
      String action = xStream.toXML(vars);
     
      ChatvaluesEvent chatvaluesEvent = new ChatvaluesEvent();
      chatvaluesEvent.setStarttime(currentDate.getTime()-recordingsStartTime.getTime());
      chatvaluesEvent.setAction(action);
     
View Full Code Here

   
    byte[] serialized = SerializationUtils.serialize(child);
    log.debug("Session size: " + serialized.length);
   
    if (testXmlSessionPath != null) {
      XStream xstream = new XStream(new DomDriver());
      PrintWriter writer = new PrintWriter(new FileWriter(testXmlSessionPath + "/" + sess.getId() + ".xml"));
      xstream.toXML(child, writer);
      writer.close();
    }
  }
View Full Code Here

        return ids;
    }

    private String serialize(Object task) {
        XStream xStream = new XStream();
        return xStream.toXML(task);
    }
View Full Code Here

        XStream xStream = new XStream();
        return xStream.toXML(task);
    }

    private Object deserialize(String serializedRunnable) {
        XStream xStream = new XStream();
        return xStream.fromXML(serializedRunnable);
    }
View Full Code Here

    private static final Logger LOG = LoggerFactory.getLogger(XMLSerializer.class);

    public static String serialize(final Object object) {
        String result = null;

        XStream xstream = new XStream();
        xstream.registerConverter(new GuardedStringConverter());
        try {
            result = URLEncoder.encode(xstream.toXML(object), SyncopeConstants.DEFAULT_ENCODING);
        } catch (UnsupportedEncodingException e) {
            LOG.error("During serialization", e);
        }

        return result;
View Full Code Here

    @SuppressWarnings("unchecked")
    public static <T extends Object> T deserialize(final String serialized) {
        T result = null;

        XStream xstream = new XStream();
        xstream.registerConverter(new GuardedStringConverter());
        try {
            result = (T) xstream.fromXML(URLDecoder.decode(serialized, SyncopeConstants.DEFAULT_ENCODING));
        } catch (UnsupportedEncodingException e) {
            LOG.error("During deserialization", e);
        }

        return result;
View Full Code Here

   */
  private void checkXStream()
  {
    if (xstream == null)
    {
      xstream = new XStream();

      xstream.setClassLoader(getClass().getClassLoader());

      xstream.alias("review", Review.class);

View Full Code Here

        this.client = client;
    }

    public Page loadRootPage(String baseUrl, String spaceKey, String pageName) {
        String searchResult = client.get(format(SEARCH_PAGE, baseUrl, spaceKey, pageName));
        XStream parse = configureXStream();
        Results results = (Results) parse.fromXML(searchResult);
        return results.getGroup().getResult();
    }
View Full Code Here

TOP

Related Classes of com.thoughtworks.xstream.XStream

Copyright © 2018 www.massapicom. 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.