Package org.apache.jmeter.testelement.property

Examples of org.apache.jmeter.testelement.property.MultiProperty


                    if (log.isDebugEnabled()) {
                        log.debug("Replacement result: " + val);
                    }
                }
            } else if (val instanceof MultiProperty) {
                MultiProperty multiVal = (MultiProperty) val;
                Collection<JMeterProperty> newValues = replaceValues(multiVal.iterator(), transform);
                multiVal.clear();
                Iterator<JMeterProperty> propIter = newValues.iterator();
                while (propIter.hasNext()) {
                    multiVal.addProperty(propIter.next());
                }
                if (log.isDebugEnabled()) {
                    log.debug("Replacement result: " + multiVal);
                }
            } else {
View Full Code Here


                    log.debug("Replacement result: " +val);
                }
            }
            else if (val instanceof MultiProperty)
            {
                MultiProperty multiVal = (MultiProperty)val;
                Collection newValues =
                    replaceValues(multiVal.iterator(), transform);
                multiVal.clear();
                Iterator propIter = newValues.iterator();
                while(propIter.hasNext())
                {
                    multiVal.addProperty((JMeterProperty) propIter.next());
                }
                if (log.isDebugEnabled())
                {
                    log.debug("Replacement result: " +multiVal);
                }
View Full Code Here

    }

    /** {@inheritDoc} */
    @Override
    public void marshal(Object arg0, HierarchicalStreamWriter writer, MarshallingContext context) {
        MultiProperty prop = (MultiProperty) arg0;
        writer.addAttribute(ConversionHelp.ATT_NAME, ConversionHelp.encode(prop.getName()));
        PropertyIterator iter = prop.iterator();
        while (iter.hasNext()) {
            writeItem(iter.next(), context, writer);
        }

    }
View Full Code Here

    }

    /** {@inheritDoc} */
    @Override
    public Object unmarshal(HierarchicalStreamReader reader, UnmarshallingContext context) {
        MultiProperty prop = (MultiProperty) createCollection(context.getRequiredType());
        prop.setName(ConversionHelp.decode(reader.getAttribute(ConversionHelp.ATT_NAME)));
        while (reader.hasMoreChildren()) {
            reader.moveDown();
            JMeterProperty subProp = (JMeterProperty) readItem(reader, context, prop);
            if (subProp != null) { // could be null if it has been deleted via NameUpdater
                prop.addProperty(subProp);
            }
            reader.moveUp();
        }
        return prop;
    }
View Full Code Here

                    if (log.isDebugEnabled()) {
                        log.debug("Replacement result: " + val);
                    }
                }
            } else if (val instanceof MultiProperty) {
                MultiProperty multiVal = (MultiProperty) val;
                Collection<JMeterProperty> newValues = replaceValues(multiVal.iterator(), transform);
                multiVal.clear();
                for (JMeterProperty jmp : newValues) {
                    multiVal.addProperty(jmp);
                }
                if (log.isDebugEnabled()) {
                    log.debug("Replacement result: " + multiVal);
                }
            } else {
View Full Code Here

          if (log.isDebugEnabled()) {
            log.debug("Replacement result: " + val);
          }
        }
      } else if (val instanceof MultiProperty) {
        MultiProperty multiVal = (MultiProperty) val;
        Collection newValues = replaceValues(multiVal.iterator(), transform);
        multiVal.clear();
        Iterator propIter = newValues.iterator();
        while (propIter.hasNext()) {
          multiVal.addProperty((JMeterProperty) propIter.next());
        }
        if (log.isDebugEnabled()) {
          log.debug("Replacement result: " + multiVal);
        }
      } else {
View Full Code Here

     * @see com.thoughtworks.xstream.converters.Converter#marshal(java.lang.Object,
     *      com.thoughtworks.xstream.io.HierarchicalStreamWriter,
     *      com.thoughtworks.xstream.converters.MarshallingContext)
     */
    public void marshal(Object arg0, HierarchicalStreamWriter writer, MarshallingContext context) {
        MultiProperty prop = (MultiProperty) arg0;
        writer.addAttribute(ATT_NAME, ConversionHelp.encode(prop.getName()));
        PropertyIterator iter = prop.iterator();
        while (iter.hasNext()) {
            writeItem(iter.next(), context, writer);
        }

    }
View Full Code Here

     *
     * @see com.thoughtworks.xstream.converters.Converter#unmarshal(com.thoughtworks.xstream.io.HierarchicalStreamReader,
     *      com.thoughtworks.xstream.converters.UnmarshallingContext)
     */
    public Object unmarshal(HierarchicalStreamReader reader, UnmarshallingContext context) {
        MultiProperty prop = (MultiProperty) createCollection(context.getRequiredType());
        prop.setName(ConversionHelp.decode(reader.getAttribute(ATT_NAME)));
        while (reader.hasMoreChildren()) {
            reader.moveDown();
            JMeterProperty subProp = (JMeterProperty) readItem(reader, context, prop);
            prop.addProperty(subProp);
            reader.moveUp();
        }
        return prop;
    }
View Full Code Here

                    if (log.isDebugEnabled()) {
                        log.debug("Replacement result: " + val);
                    }
                }
            } else if (val instanceof MultiProperty) {
                MultiProperty multiVal = (MultiProperty) val;
                Collection newValues = replaceValues(multiVal.iterator(), transform);
                multiVal.clear();
                Iterator propIter = newValues.iterator();
                while (propIter.hasNext()) {
                    multiVal.addProperty((JMeterProperty) propIter.next());
                }
                if (log.isDebugEnabled()) {
                    log.debug("Replacement result: " + multiVal);
                }
            } else {
View Full Code Here

            {
                val = transform.transformValue((StringProperty) val);
            }
            else if (val instanceof MultiProperty)
            {
                MultiProperty multiVal = (MultiProperty)val;
                Collection newValues =
                    replaceValues(multiVal.iterator(), transform);
                multiVal.clear();
                Iterator propIter = newValues.iterator();
                while(propIter.hasNext())
                {
                    multiVal.addProperty((JMeterProperty) propIter.next());
                }
            }
            props.add(val);
        }
        return props;
View Full Code Here

TOP

Related Classes of org.apache.jmeter.testelement.property.MultiProperty

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.