You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jmeter.apache.org by Vladimir Sitnikov <si...@gmail.com> on 2015/05/22 15:07:03 UTC
JMeter compoents API: setProperty vs setXXX
Hi,
I'm trying to understand what is the recommended way to create
components via java API.
Initially I thought properties should be set via setProperty while
names are provided via constants like
org.apache.jmeter.testelement.TestPlan#FUNCTIONAL_MODE.
However CounterConfig breaks this nice picture:
org.apache.jmeter.modifiers.CounterConfig#START and other properties
are private.
BeanShellPreProcessor goes even further and it completely ignores
"setProperties".
Can you please advise me what is the suggested way to create test
elements via API?
--
Regards,
Vladimir Sitnikov
Re: JMeter compoents API: setProperty vs setXXX
Posted by Andrey Pokhilko <ap...@ya.ru>.
Hi,
>From my experience there is no common rules among components, part of
them provide public constants, part of them provide setter methods. You
have to have API docs at your hand and use each component according to
its interface.
Andrey Pokhilko
On 05/22/2015 04:07 PM, Vladimir Sitnikov wrote:
> Hi,
>
> I'm trying to understand what is the recommended way to create
> components via java API.
>
> Initially I thought properties should be set via setProperty while
> names are provided via constants like
> org.apache.jmeter.testelement.TestPlan#FUNCTIONAL_MODE.
>
> However CounterConfig breaks this nice picture:
> org.apache.jmeter.modifiers.CounterConfig#START and other properties
> are private.
>
> BeanShellPreProcessor goes even further and it completely ignores
> "setProperties".
>
>
> Can you please advise me what is the suggested way to create test
> elements via API?
>