You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jmeter-dev@jakarta.apache.org by se...@apache.org on 2008/11/05 17:43:11 UTC
svn commit: r711610 -
/jakarta/jmeter/trunk/src/protocol/tcp/org/apache/jmeter/protocol/tcp/sampler/LengthPrefixedBinaryTCPClientImpl.java
Author: sebb
Date: Wed Nov 5 08:43:11 2008
New Revision: 711610
URL: http://svn.apache.org/viewvc?rev=711610&view=rev
Log:
Delegate eolByte methods to implementation that needs them
Modified:
jakarta/jmeter/trunk/src/protocol/tcp/org/apache/jmeter/protocol/tcp/sampler/LengthPrefixedBinaryTCPClientImpl.java
Modified: jakarta/jmeter/trunk/src/protocol/tcp/org/apache/jmeter/protocol/tcp/sampler/LengthPrefixedBinaryTCPClientImpl.java
URL: http://svn.apache.org/viewvc/jakarta/jmeter/trunk/src/protocol/tcp/org/apache/jmeter/protocol/tcp/sampler/LengthPrefixedBinaryTCPClientImpl.java?rev=711610&r1=711609&r2=711610&view=diff
==============================================================================
--- jakarta/jmeter/trunk/src/protocol/tcp/org/apache/jmeter/protocol/tcp/sampler/LengthPrefixedBinaryTCPClientImpl.java (original)
+++ jakarta/jmeter/trunk/src/protocol/tcp/org/apache/jmeter/protocol/tcp/sampler/LengthPrefixedBinaryTCPClientImpl.java Wed Nov 5 08:43:11 2008
@@ -40,30 +40,16 @@
import org.apache.log.Logger;
/**
- * Sample TCPClient implementation
- *
+ * Implements binary length-prefixed binary data.
+ * This is used in ISO8583 for example.
*/
public class LengthPrefixedBinaryTCPClientImpl extends TCPClientDecorator {
private static final Logger log = LoggingManager.getLoggerForClass();
-
- private int eolInt = JMeterUtils.getPropDefault("tcp.eolByte", 1000); // default
-
- // is
- // not
- // in
- // range
-
- private byte eolByte = (byte) eolInt; // -128 to +127
-
- private boolean eolIgnore = eolInt < -128 || eolInt > 127;
- private int lengthPrefixLen = JMeterUtils.getPropDefault("tcp.length.prefix.length", 2);
+ private final int lengthPrefixLen = JMeterUtils.getPropDefault("tcp.binarylength.prefix.length", 2); // $NON-NLS-1$
public LengthPrefixedBinaryTCPClientImpl() {
super(new BinaryTCPClientImpl());
- if (!eolIgnore) {
- log.info("Using eolByte=" + eolByte);
- }
}
/*
@@ -163,7 +149,7 @@
* @return Returns the eolByte.
*/
public byte getEolByte() {
- return eolByte;
+ return tcpClient.getEolByte();
}
/**
@@ -171,7 +157,6 @@
* The eolByte to set.
*/
public void setEolByte(byte eolByte) {
- this.eolByte = eolByte;
- eolIgnore = false;
+ tcpClient.setEolByte(eolByte);
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org