Skip to content

Commit 33e1da7

Browse files
Merge pull request #101 from cisco-system-traffic-generator/ASTFProgram
Astf program int to Long
2 parents 084e4d6 + 3683bef commit 33e1da7

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

src/main/java/com/cisco/trex/stateful/api/lowlevel/ASTFCmdSetVal.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ public class ASTFCmdSetVal extends ASTFCmd {
1010
* @param idVal
1111
* @param val
1212
*/
13-
public ASTFCmdSetVal(String idVal, int val) {
13+
public ASTFCmdSetVal(String idVal, Long val) {
1414
super();
1515
this.fields.addProperty("name", NAME);
1616
this.fields.addProperty("id", idVal);

src/main/java/com/cisco/trex/stateful/api/lowlevel/ASTFProgram.java

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -407,6 +407,17 @@ public void setKeepAliveMsg(int msec) {
407407
* @param value
408408
*/
409409
public void setVar(String varId, int value) {
410+
addVar(varId);
411+
fields.get(COMMANDS).add(new ASTFCmdSetVal(varId, (long) value));
412+
}
413+
414+
/**
415+
* set var command
416+
*
417+
* @param varId
418+
* @param value
419+
*/
420+
public void setVar(String varId, Long value) {
410421
addVar(varId);
411422
fields.get(COMMANDS).add(new ASTFCmdSetVal(varId, value));
412423
}

0 commit comments

Comments
 (0)