Class AbstractProperty

  • All Implemented Interfaces:
    java.io.Serializable , java.lang.Cloneable , java.lang.Comparable , org.apache.jmeter.testelement.property.JMeterProperty

    
    public abstract class AbstractProperty
     implements JMeterProperty
                        
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
      public String name
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      String getName() The name of the property.
      void setName(String name) Set the property name.
      boolean isRunningVersion() Returns whether the property is a running version.
      AbstractProperty clone()
      int getIntValue() Returns 0 if string is invalid or null.
      long getLongValue() Returns 0 if string is invalid or null.
      double getDoubleValue() Returns 0 if string is invalid or null.
      float getFloatValue() Returns 0 if string is invalid or null.
      boolean getBooleanValue() Returns false if string is invalid or null.
      boolean equals(Object o) Determines if the two objects are equal by comparing names and values
      int hashCode()
      int compareTo(JMeterProperty arg0) Compares two JMeterProperty object values.
      static JMeterProperty createProperty(Object item)
      String toString() Provides the string representation of the property.
      void mergeIn(JMeterProperty prop) Take the given property object and merge it's value with the current property object.
      void setRunningVersion(boolean runningVersion) Make the property a running version or turn it off as the running version.
      • Methods inherited from class org.apache.jmeter.testelement.property.JMeterProperty

        getObjectValue, getStringValue, recoverRunningVersion, setObjectValue
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • getName

         String getName()

        The name of the property. Typically this should match the name that keys the property's location in the test elements Map.

      • isRunningVersion

         boolean isRunningVersion()

        Returns whether the property is a running version.

      • getIntValue

         int getIntValue()

        Returns 0 if string is invalid or null.

      • getLongValue

         long getLongValue()

        Returns 0 if string is invalid or null.

      • getDoubleValue

         double getDoubleValue()

        Returns 0 if string is invalid or null.

      • getFloatValue

         float getFloatValue()

        Returns 0 if string is invalid or null.

      • getBooleanValue

         boolean getBooleanValue()

        Returns false if string is invalid or null.

      • equals

         boolean equals(Object o)

        Determines if the two objects are equal by comparing names and values

        Returns:

        true if names are equal and values are equal (or both null)

      • compareTo

         int compareTo(JMeterProperty arg0)

        Compares two JMeterProperty object values. N.B. Does not compare names

        Parameters:
        arg0 - JMeterProperty to compare against
        Returns:

        0 if equal values or both values null; -1 otherwise

      • toString

         String toString()

        Provides the string representation of the property.

        Returns:

        the string value

      • mergeIn

         void mergeIn(JMeterProperty prop)

        Take the given property object and merge it's value with the current property object. For most property types, this will simply be ignored. But for collection properties and test element properties, more complex behavior is required.

      • setRunningVersion

         void setRunningVersion(boolean runningVersion)

        Make the property a running version or turn it off as the running version. A property that is made a running version will preserve the current state in such a way that it is retrievable by a future call to 'recoverRunningVersion()'. Additionally, a property that is a running version will resolve all functions prior to returning it's property value. A non-running version property will return functions as their uncompiled string representation.