Examples of DataHolder


Examples of com.thoughtworks.xstream.converters.DataHolder

     * @param evt sampleResult wrapped in a sampleEvent
     * @param writer output stream which must be created using {@link #getFileEncoding(String)}
     */
    // Used by ResultCollector.sampleOccurred(SampleEvent event)
    public synchronized static void saveSampleResult(SampleEvent evt, Writer writer) throws IOException {
        DataHolder dh = JTLSAVER.newDataHolder();
        dh.put(SAMPLE_EVENT_OBJECT, evt);
        // This is effectively the same as saver.toXML(Object, Writer) except we get to provide the DataHolder
        // Don't know why there is no method for this in the XStream class
        try {
            JTLSAVER.marshal(evt.getResult(), new XppDriver().createWriter(writer), dh);
        } catch(RuntimeException e) {
View Full Code Here

Examples of com.thoughtworks.xstream.converters.DataHolder

     * @throws IOException
     */
    public static void loadTestResults(InputStream reader, ResultCollectorHelper resultCollectorHelper) throws IOException {
        // Get the InputReader to use
        InputStreamReader inputStreamReader = getInputStreamReader(reader);
        DataHolder dh = JTLSAVER.newDataHolder();
        dh.put(RESULTCOLLECTOR_HELPER_OBJECT, resultCollectorHelper); // Allow TestResultWrapper to feed back the samples
        // This is effectively the same as saver.fromXML(InputStream) except we get to provide the DataHolder
        // Don't know why there is no method for this in the XStream class
        JTLSAVER.unmarshal(new XppDriver().createReader(reader), null, dh);
        inputStreamReader.close();
    }
View Full Code Here

Examples of com.vladium.emma.data.ICoverageData.DataHolder

    public IMethodVisitor visit(IType type, String vmname) {
      ClassDescriptor descriptor = (ClassDescriptor) descriptors.remove(vmname);
      if (descriptor == null) {
        return null;
      } else {
        DataHolder data = coveragedata == null ? null : coveragedata.getCoverage(descriptor);
        if (data != null && data.m_stamp != descriptor.getStamp()) {
          TRACER.trace("Invalid meta data signature for {0}.", descriptor.getClassVMName()); //$NON-NLS-1$
          return null;
        } else {
          return new MethodVisitor(type, descriptor, data);
View Full Code Here

Examples of com.vladium.emma.data.ICoverageData.DataHolder

    }

    public void visit(IType type, String vmname) {
      ClassDescriptor descriptor = (ClassDescriptor) descriptors.remove(vmname);
      if (descriptor != null) {
        DataHolder data = coveragedata == null ? null : coveragedata.getCoverage(descriptor);
        if (data != null && data.m_stamp != descriptor.getStamp()) {
          TRACER.trace("Invalid meta data signature for {0}.", descriptor.getClassVMName()); //$NON-NLS-1$
        } else {
          TypeCoverage typecoverage = (TypeCoverage) getCoverage(type, descriptor.hasCompleteLineNumberInfo());
          IResource resource = type.getResource();
View Full Code Here

Examples of com.vladium.emma.data.ICoverageData.DataHolder

    }

    public void visit(IType type, String vmname) {
      ClassDescriptor descriptor = (ClassDescriptor) descriptors.remove(vmname);
      if (descriptor != null) {
        DataHolder data = coveragedata == null ? null : coveragedata.getCoverage(descriptor);
        if (data != null && data.m_stamp != descriptor.getStamp()) {
          TRACER.trace("Invalid meta data signature for {0}.", descriptor.getClassVMName()); //$NON-NLS-1$
        } else {
          TypeCoverage typecoverage = (TypeCoverage) getCoverage(type, descriptor.hasCompleteLineNumberInfo());
          IResource resource = type.getResource();
View Full Code Here

Examples of com.vladium.emma.data.ICoverageData.DataHolder

    public IMethodVisitor visit(IType type, String vmname) {
      ClassDescriptor descriptor = (ClassDescriptor) descriptors.remove(vmname);
      if (descriptor == null) {
        return null;
      } else {
        DataHolder data = coveragedata == null ? null : coveragedata
            .getCoverage(descriptor);
        if (data != null && data.m_stamp != descriptor.getStamp()) {
          TRACER.trace("Invalid meta data signature for {0}.", descriptor.getClassVMName()); //$NON-NLS-1$
          return null;
        } else {
View Full Code Here

Examples of com.vladium.emma.data.ICoverageData.DataHolder

    public IMethodVisitor visit(IType type, String vmname) {
      ClassDescriptor descriptor = (ClassDescriptor) descriptors.remove(vmname);
      if (descriptor == null) {
        return null;
      } else {
        DataHolder data = coveragedata == null ? null : coveragedata
            .getCoverage(descriptor);
        if (data != null && data.m_stamp != descriptor.getStamp()) {
          TRACER.trace("Invalid meta data signature for {0}.", descriptor.getClassVMName()); //$NON-NLS-1$
          return null;
        } else {
View Full Code Here

Examples of com.vladium.emma.data.ICoverageData.DataHolder

    public IMethodVisitor visit(IType type, String vmname) {
      ClassDescriptor descriptor = (ClassDescriptor) descriptors.remove(vmname);
      if (descriptor == null) {
        return null;
      } else {
        DataHolder data = coveragedata == null ? null : coveragedata
            .getCoverage(descriptor);
        if (data != null && data.m_stamp != descriptor.getStamp()) {
          TRACER.trace("Invalid meta data signature for {0}.", descriptor.getClassVMName()); //$NON-NLS-1$
          return null;
        } else {
View Full Code Here

Examples of com.vladium.emma.data.ICoverageData.DataHolder

    }

    public void visit(IType type, String vmname) {
      ClassDescriptor descriptor = (ClassDescriptor) descriptors.remove(vmname);
      if (descriptor != null) {
        DataHolder data = coveragedata == null ? null : coveragedata.getCoverage(descriptor);
        if (data != null && data.m_stamp != descriptor.getStamp()) {
          TRACER.trace("Invalid meta data signature for {0}.", descriptor.getClassVMName()); //$NON-NLS-1$
        } else {
          TypeCoverage typecoverage = (TypeCoverage) getCoverage(type, true);
          IResource resource = type.getResource();
View Full Code Here

Examples of net.sf.apptools.data.DataHolder

        final String title = CoreMessages.getString("ProbeMakerPlugIn.TITLE_REMOVING_PROBES"); //$NON-NLS-1$
        final String message = CoreMessages.getString("ProbeMakerPlugIn.QUERY_REMOVE_TARGETS"); //$NON-NLS-1$

        final DataDescriptor option = new OptionDescriptor(message,null,"OPTION",options,true); //$NON-NLS-1$
        final DataHolder dh = new DefaultDataHolder(new DataDescriptor[] { option });

        if (!platform.getUI().inputData(dh,title)) {
          return;
        }

        final Integer result = (Integer) dh.getData("OPTION"); //$NON-NLS-1$
        if (result == null) {
          return;
        }

        switch(result.intValue()) {
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.