Printer FriendlyEmail Article Link

Spirent TestCenter: Spirent TestCenter Java API env setup in windows.

Objective/Summary

  Spirent TestCenter Java API env setup in windows.

Environment/Versions

 Spirent TestCenter 

Java API

Procedure

 1. Once user install the SPIRENT TESTCENTER application user will find java folder present under below location. 

Set this java folder to CLASSPATH in system environment variables:
Set CLASSPATH = C:\Program Files (x86)\Spirent Communications\Spirent TestCenter 4.40\Spirent TestCenter Application\API\Java;
 
2. Post installation user can find a sample SPIRENT TESTCENTER java script ”Anatomy.java” under below location:
C:\Program Files (x86)\Spirent Communications\Spirent TestCenter 4.40\Spirent TestCenter Application\SampleScripts.
 
3. Copy this script to your execution path and set the system properties as below. 
import java.util.Properties;
try {
Properties props = System.getProperties();
props.setProperty("stc.dir", "C:/Program Files (x86)/Spirent Communications/Spirent TestCenter 4.40/Spirent TestCenter Application/");
stc.Init();
 
4. Compile and execute the script.
javac Anatomy.java
java Anatomy

Product : Spirent TestCenter,Product,API