#include <stdlib.h>
#include <unistd.h>
#include "rpcclt_openapi.h"
#include "proc_util.h"
void printDot1sAppMenu()
{
printf("Usage: dot1s_example <test#> <arg1> <arg2> ... \n");
printf("Test 1: Set Spanning Tree Operational Mode: dot1s_example 1 <mode> \n");
printf("Test 2: Get Spanning Tree Operational Mode: dot1s_example 2 \n");
printf("Test 3: Set Spanning Tree Interface BPDU Filter Mode: dot1s_example 3 <interface> <mode> \n");
printf("Test 4: Get Spanning Tree Interface BPDU Filter Mode: dot1s_example 4 <interface> \n");
printf("Test 5: Set Spanning Tree Interface BPDU Flood Mode: dot1s_example 5 <interface> <mode> \n");
printf("Test 6: Get Spanning Tree Interface BPDU Flood Mode: dot1s_example 6 <interface> \n");
printf("Test 7: Set Spanning Tree BPDU Guard Mode: dot1s_example 7 <mode> \n");
printf("Test 8: Get Spanning Tree BPDU Guard Mode: dot1s_example 8 \n");
printf("Test 9: Set Spanning Tree Configuration Name: dot1s_example 9 <name> \n");
printf("Test 10: Get Spanning Tree Configuration Name: dot1s_example 10 \n");
printf("Test 11: Set Spanning Tree Configuration Revision: dot1s_example 11 <revision> \n");
printf("Test 12: Get Spanning Tree Configuration Revision: dot1s_example 12 \n");
printf("Test 13: Set Spanning Tree Configuration Force Version: dot1s_example 13 <version> \n");
printf("Test 14: Get Spanning Tree Configuration Force Version: dot1s_example 14 \n");
printf("Test 15: Set Spanning Tree Interface Guard Mode: dot1s_example 15 <interface> <mode> \n");
printf("Test 16: Get Spanning Tree Interface Guard Mode: dot1s_example 16 <interface> \n");
printf("Test 17: Create Spanning Tree Instance: dot1s_example 17 <instance id> \n");
printf("Test 18: Delete Spanning Tree Instance: dot1s_example 18 <instance id> \n");
printf("Test 19: Get All Spanning Tree Instances: dot1s_example 19 \n");
printf("Test 20: Set Spanning Tree MST Instance Priority: dot1s_example 20 <instance id> <priority> \n");
printf("Test 21: Get Spanning Tree MST Instance Priority: dot1s_example 21 <instance id> \n");
printf("Test 22: Add Spanning Tree MST Instance - VLAN Association: dot1s_example 22 <instance id> <vlanid> \n");
printf("Test 23: Delete Spanning Tree MST Instance - VLAN Association: dot1s_example 23 <instance id> <vlanid> \n");
printf("Test 24: Get All VLANs associated with the Spanning Tree Instance: dot1s_example 24 <instance id> \n");
printf("Test 25: Get All Forwarding Database Ids associated with the Spanning Tree Instance: dot1s_example 25 <instance id> \n");
printf("Test 26: Set Spanning Tree Interface Mode: dot1s_example 26 <interface> <mode> \n");
printf("Test 27: Get Spanning Tree Interface Mode: dot1s_example 27 <interface> \n");
printf("Test 28: Get Spanning Tree Interface Forwarding State: dot1s_example 28 <interface> <instance id> \n");
printf("Test 29: Get Spanning Tree Interface Mode: dot1s_example 29 <interface> <instance id> \n");
printf("Test 30: Set Spanning Tree Interface Edge Port Mode: dot1s_example 30 <interface> <mode> \n");
printf("Test 31: Get Spanning Tree Interface Edge Port Mode: dot1s_example 31 <interface> \n");
printf("Test 32: Get Spanning Tree Interface Port Loop Inconsistent State: dot1s_example 32 <interface> <instance id> \n");
printf("Test 33: Get the Spanning Tree MST Bridge Identifier for a specific instance: dot1s_example 33 <instance id>\n");
printf("Test 34: Get the Spanning Tree MST Time since the last Topology Change for a specific instance: dot1s_example 34 <instance id>\n");
printf("Test 35: Get the Spanning Tree MST count of Topology Changes in a specific instance: dot1s_example 35 <instance id>\n");
printf("Test 36: Get if a topology change is in progress for any port assigned to a specific Spanning Tree MST instance: dot1s_example 36 <instance id>\n");
printf("Test 37: Get the Spanning Tree MST Designated Root Identifier in a specific instance: dot1s_example 37 <instance id>\n");
printf("Test 38: Get the Spanning Tree MST Designated Root Path Cost parameter in a specific instance: dot1s_example 38 <instance id>\n");
printf("Test 39: Get the Spanning Tree Port Root Port ID in a specific instance: dot1s_example 39 <instance id>\n");
printf("Test 40: Get the max age for the CIST: dot1s_example 40\n");
printf("Test 41: Get Max Hop count for the device: dot1s_example 41\n");
printf("Test 42: Get the Tx Hold count value for the device: dot1s_example 42\n");
printf("Test 43: Get the CIST Bridge Forward Delay: dot1s_example 43\n");
printf("Test 44: Get the CIST Hello Time for a specific port: dot1s_example 44 <interface>\n");
printf("Test 45: Get the CIST Bridge Hold Time: dot1s_example 45\n");
printf("Test 46: Get the CIST Regional Root Identifier: dot1s_example 46\n");
printf("Test 47: Get the CIST Regional Root Path Cost: dot1s_example 47\n");
printf("Test 48: Get Spanning Tree MST Interface port details: dot1s_example 48 <instance id> <interface> \n");
printf("Test 49: Set Spanning Tree MST Interface priority: dot1s_example 49 <instance id> <interface> <priority> \n");
printf("Test 50: Get Spanning Tree MST Interface priority: dot1s_example 50 <instance id> <interface> \n");
printf("Test 51: Get Spanning Tree MST Interface Path Cost Mode: dot1s_example 51 <instance id> <interface> \n");
printf("Test 52: Set Spanning Tree MST Interface Cost: dot1s_example 52 <instance id> <interface> <priority> \n");
printf("Test 53: Get Spanning Tree MST Interface Operational Cost: dot1s_example 53 <instance id> <interface> \n");
printf("Test 54: Get Spanning Tree MST Interface Designated Root ID: dot1s_example 54 <instance id> <interface> \n");
printf("Test 55: Get Spanning Tree MST Interface Designated Cost: dot1s_example 55 <instance id> <interface> \n");
printf("Test 56: Get Spanning Tree MST Interface Designated Bridge ID: dot1s_example 56 <instance id> <interface> \n");
printf("Test 57: Get Spanning Tree MST Interface Designated Port ID: dot1s_example 57 <instance id> <interface> \n");
printf("Test 58: Get Spanning Tree External Port Path Cost Mode: dot1s_example 58 <interface> \n");
printf("Test 59: Get Spanning Tree External Port Path Cost: dot1s_example 59 <interface> \n");
printf("Test 60: Set Spanning Tree External Port Path Cost: dot1s_example 60 <interface> <cost> \n");
printf("Test 61: Get Spanning Tree Topology Change ACK: dot1s_example 61 <interface> \n");
printf("Test 62: Get Spanning Tree Hello Time: dot1s_example 62 \n");
printf("Test 63: Get Spanning Tree Operational Edge Status: dot1s_example 63 <interface> \n");
printf("Test 64: Get Spanning Tree Point-To-Point MAC Status: dot1s_example 64 <interface> \n");
printf("Test 65: Get Spanning Tree Interface Regional Root ID: dot1s_example 65 <interface> \n");
printf("Test 66: Get Spanning Tree Interface Port Path Cost: dot1s_example 66 <interface> \n");
printf("Test 67: Get Spanning Tree MST Port Loop Inconsistant State: dot1s_example 67 <instance id> <interface> \n");
printf("Test 68: Get Spanning Tree MST Transitions Into Loop Inconsistant: dot1s_example 68 <instance id> <interface> \n");
printf("Test 69: Get Spanning Tree MST Transitions Out of Loop Inconsistant: dot1s_example 69 <instance id> <interface> \n");
printf("Test 70: Clear Spanning Tree Interface Statistics: dot1s_example 70 <interface> \n");
printf("Test 71: Get Spanning Tree Interface Hello Time: dot1s_example 71 <interface> \n");
printf("Test 72: Get Spanning Tree Interface BPDU Guard Effect: dot1s_example 72 <interface> \n");
printf("Test 73: Set Spanning Tree Interface Restricted TCN Parameter: dot1s_example 73 <interface> <mode> \n");
printf("Test 74: Get Spanning Tree Interface Restricted TCN Parameter: dot1s_example 74 <interface> \n");
printf("Test 75: Get Spanning Tree Interface Auto Edge Status: dot1s_example 75 <interface> \n");
printf("Test 76: Set Spanning Tree Interface Auto Edge Status: dot1s_example 76 <interface> <mode> \n");
printf("Test 77: Get Spanning Tree Interface Up Time: dot1s_example 77 <interface> \n");
printf("Test 78: Get Spanning Tree Interface STP BPDUs Sent: dot1s_example 78 <interface> \n");
printf("Test 79: Get Spanning Tree Interface STP BPDUs Received: dot1s_example 79 <interface> \n");
printf("Test 80: Get Spanning Tree Interface RSTP BPDUs Sent: dot1s_example 80 <interface> \n");
printf("Test 81: Get Spanning Tree Interface RSTP BPDUs Received: dot1s_example 81 <interface> \n");
printf("Test 82: Get Spanning Tree Interface MSTP BPDUs Sent: dot1s_example 82 <interface> \n");
printf("Test 83: Get Spanning Tree Interface MSTP BPDUs Received: dot1s_example 83 <interface> \n");
printf("Test 84: Test Spanning Tree OpEN APIs sanity: dot1s_example 84 <interface> \n");
return;
}
{
{
printf("Bad return code trying to set Spanning Tree Operational Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Operational Mode set successfully \n");
}
return;
}
{
{
printf("Bad return code trying to get Spanning Tree Operational Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Operational Mode: %u \n", mode);
}
return;
}
{
{
printf("Bad return code trying to set Spanning Tree Interface BPDU Filter Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface BPDU Filter Mode set successfully \n");
}
return;
}
{
{
printf("Bad return code trying to get Spanning Tree Interface BPDU Filter Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface BPDU Filter Mode for interface %u: %u \n", ifNum, mode);
}
return;
}
{
{
printf("Bad return code trying to set Spanning Tree Interface BPDU Flood Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface BPDU Flood Mode set successfully \n");
}
return;
}
{
{
printf("Bad return code trying to get Spanning Tree Interface BPDU Flood Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface BPDU Flood Mode for interface %u: %u \n", ifNum, mode);
}
return;
}
{
{
printf("Bad return code trying to set Spanning Tree BPDU Guard Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree BPDU Guard Mode set successfully \n");
}
return;
}
{
{
printf("Bad return code trying to get Spanning Tree BPDU Guard Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree BPDU Guard Mode: %u \n", mode);
}
return;
}
{
char str[100];
memset(str, 0, sizeof(str));
strncpy(str, name, (sizeof(str) - 1));
buffDesc.
size = strlen(str) + 1;
{
printf("Bad return code trying to set Spanning Tree Configuration Name. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Configuration Name set successfully \n");
}
return;
}
{
char *str;
uint32_t dot1SMgmtStrLen;
{
printf("Bad return code. (result = %d)\n", result);
return;
}
if ((str = (char*)malloc(dot1SMgmtStrLen)) == NULL)
{
printf("Could not allocate memory.\n");
return;
}
memset(str, 0, dot1SMgmtStrLen);
buffDesc.pstart = str;
buffDesc.size = dot1SMgmtStrLen;
{
printf("Bad return code trying to get Spanning Tree Configuration Name. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Configuration Name: %s \n", str);
}
free(str);
return;
}
{
{
printf("Bad return code trying to set Spanning Tree Configuration Revision. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Configuration Revision set successfully \n");
}
return;
}
{
uint32_t revision;
{
printf("Bad return code trying to get Spanning Tree Configuration Revision. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Configuration Revision: %u \n", revision);
}
return;
}
{
{
printf("Bad return code trying to set Spanning Tree Force Version. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Force Version set successfully \n");
}
return;
}
{
uint32_t forceVersion;
{
printf("Bad return code trying to get Spanning Tree Force Version. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Force Version: %u \n", forceVersion);
}
return;
}
{
{
printf("Bad return code trying to set Spanning Tree Interface Guard Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface Guard Mode set successfully \n");
}
return;
}
{
{
printf("Bad return code trying to get Spanning Tree Interface Guard Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface Guard Mode for interface %u: %u \n", ifNum, mode);
}
return;
}
{
{
printf("Bad return code trying to configure Spanning Tree MST Instance. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Instance set successfully \n");
}
return;
}
{
uint32_t currInstanceId, nextInstanceId;
{
printf("Bad return code trying to get the first Spanning Tree MST Instance. (result = %d)\n", result);
return;
}
else
{
printf("Spanning Tree MST Instances:\n");
printf("%u", currInstanceId);
}
{
printf(", %u", nextInstanceId);
currInstanceId = nextInstanceId;
}
printf("\n");
return;
}
void dot1SMSTInstancePrioritySet(
openapiClientHandle_t *clientHandle, uint32_t dot1sMSTInstance, uint32_t priority)
{
{
printf("Bad return code trying to set Spanning Tree Instance Priority. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Instance Priority set successfully \n");
}
return;
}
{
uint16_t priority;
{
printf("Bad return code trying to get Spanning Tree Instance Priority. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Instance Priority for instance %u: %u \n", dot1sMSTInstance, priority);
}
return;
}
{
uint32_t vlanMax;
{
if ((vlanId > vlanMax))
{
printf("Invalid VLAN id. The maximum id is %d.\n", vlanMax);
}
}
{
{
printf("Bad return code trying to configure Spanning Tree MST Instance - VLAN association. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Instance - VLAN association set successfully \n");
}
}
return;
}
{
uint32_t currVLANId, nextVLANId;
{
printf("Bad return code trying to get the first Spanning Tree MST VLAN. (result = %d)\n", result);
return;
}
else
{
printf("Spanning Tree MST VLANs:\n");
printf("%u", currVLANId);
}
{
printf(", %u", nextVLANId);
currVLANId = nextVLANId;
}
printf("\n");
return;
}
{
uint32_t currFId, nextFId;
{
printf("Bad return code trying to get the first Spanning Tree MST Forwarding Database Id. (result = %d)\n", result);
return;
}
else
{
printf("Spanning Tree MST FIds:\n");
printf("%u", currFId);
}
{
printf(", %u", nextFId);
currFId = nextFId;
}
printf("\n");
return;
}
{
{
printf("Bad return code trying to set Spanning Tree Interface Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface Mode set successfully \n");
}
return;
}
{
{
printf("Bad return code trying to get Spanning Tree Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface Mode for interface %u: %u \n", ifNum, mode);
}
return;
}
void dot1SIntfPortFwdStateGet(
openapiClientHandle_t *clientHandle, uint32_t ifNum, uint32_t dot1sInstance)
{
{
printf("Bad return code trying to get Spanning Tree Port Forwarding State. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface Port Forwarding State for interface %u: %u \n", ifNum, dot1sPortFwdState);
}
return;
}
{
{
printf("Bad return code trying to get Spanning Tree Port Role. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Port Role for interface %u: %u \n", ifNum, dot1sPortRole);
}
return;
}
{
{
printf("Bad return code trying to set Spanning Tree Interface Edge Port Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface Edge Port Mode set successfully \n");
}
return;
}
{
{
printf("Bad return code trying to get Spanning Tree Interface Edge Port Mode. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface Edge Port Mode for interface %u: %u \n", ifNum, mode);
}
return;
}
void dot1SIntfPortLoopInconsistentStateGet(
openapiClientHandle_t *clientHandle, uint32_t ifNum, uint32_t dot1sInstance)
{
{
printf("Bad return code trying to get Spanning Tree Port Loop Inconsistent State. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface Port Loop Inconsistent State for interface %u: %u \n", ifNum, loopInconsistentState);
}
return;
}
{
unsigned char *p = (unsigned char *) id;
snprintf(idStr, size, "%02X:%02X:%02X:%02X:%02X:%02X:%02X:%02X",
p[0], p[1], p[2], p[3], p[4], p[5], p[6], p[7]);
return idStr;
}
{
char idStr[25];
{
printf("Bad return code trying to get the Spanning Tree MST Bridge Identifier for a specific instance. (result = %d)\n", result);
}
else
{
printf("MST Instance Bridge Identifier for mstId %d: %s\n", mstId, idToStr(&id, idStr, sizeof(idStr)));
}
return;
}
{
uint32_t tVal;
{
printf("Bad return code trying to get the Spanning Tree MST Time since the last Topology Change for a specific instance. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Time since the last Topology Change for mstId %d: %u seconds\n", mstId, tVal);
}
return;
}
{
uint32_t count;
{
printf("Bad return code trying to get the Spanning Tree MST count of Topology Changes in a specific instance. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST count of Topology Changes for mstId %d: %u\n", mstId, count);
}
return;
}
{
{
printf("Bad return code trying to get the Spanning Tree MST Topology Change state in a specific instance. (result = %d)\n", result);
}
else
{
printf(
"A topology change is %s for some port in the MST instance %d.\n", (state ==
OPEN_TRUE ?
"in progress":
"not in progress"), mstId);
}
return;
}
{
char idStr[25];
{
printf("Bad return code trying to get the Spanning Tree MST Designated Root Identifier in a specific instance. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Designated Root Identifier for mstId %d: %s\n", mstId, idToStr(&id, idStr, sizeof(idStr)));
}
return;
}
{
uint32_t cost;
{
printf("Bad return code trying to get the Spanning Tree MST Designated Root Path Cost parameter in a specific instance. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Designated Root path cost for mstId %d: %u\n", mstId, cost);
}
return;
}
{
uint32_t port;
{
printf("Bad return code trying to get the Spanning Tree MST Root Port ID in a specific instance. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST root port ID for mstId %d: %u\n", mstId, port);
}
return;
}
{
uint32_t age;
{
printf("Bad return code trying to get the max age for the CIST. (result = %d)\n", result);
}
else
{
printf("Max age for the CIST: %u\n", age);
}
return;
}
{
uint32_t count;
{
printf("Bad return code trying to get the Max Hop count for the bridge. (result = %d)\n", result);
}
else
{
printf("Max hop count for the bridge: %u\n", count);
}
return;
}
{
uint32_t count;
{
printf("Bad return code trying to get the Spanning Tree MST Tx Hold count for the bridge. (result = %d)\n", result);
}
else
{
printf("Tx hold count for the bridge: %u\n", count);
}
return;
}
{
uint32_t delay;
{
printf("Bad return code trying to get the Spanning Tree MST Bridge Forward Delay for the CIST. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Bridge Forward Delay for the CIST: %u\n", delay);
}
return;
}
{
uint32_t helloTime;
{
printf("Bad return code trying to get the Spanning Tree MST Hello Time of a specific port for the CIST. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Hello Time of port %u for the CIST: %u\n", ifNum, helloTime);
}
return;
}
{
uint32_t holdTime;
{
printf("Bad return code trying to get the Spanning Tree MST Bridge Hold Time for the CIST. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Bridge Hold Time for the CIST: %u\n", holdTime);
}
return;
}
{
char idStr[25];
{
printf("Bad return code trying to get the Spanning Tree MST CIST Regional Root Identifier. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST CIST Regional Root Identifier: %s\n", idToStr(&rootId, idStr, sizeof(idStr)));
}
return;
}
{
uint32_t cost;
{
printf("Bad return code trying to get the Spanning Tree MST CIST Regional Root Path Cost. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST CIST Regional Root Path Cost: %u\n", cost);
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum)
{
char str[256];
buffdesc.pstart = str;
buffdesc.size = sizeof(str);
dot1sMSTInstance,
{
printf("Bad return code trying to get Spanning Tree MST Instance Port identifier fo interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Instance Port ID for interface %u %u: %s \n", dot1sMSTInstance, ifNum, str);
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum, uint32_t priority)
{
{
printf("Bad return code trying to set Spanning Tree MST priority for an Interface . (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface MST Port Priority set successfully \n");
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum)
{
uint32_t priority = 0;
dot1sMSTInstance,
{
printf("Bad return code trying to get Spanning Tree MST Instance Priority for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Instance Priority for interface %u %u: %u \n", dot1sMSTInstance, ifNum, priority);
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum)
{
dot1sMSTInstance,
{
printf("Bad return code trying to get Spanning Tree MST Instance path cost mode for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Instance Path Cost Mode for interface %u %u: %u \n", dot1sMSTInstance, ifNum, mode);
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum, uint32_t cost)
{
{
printf("Bad return code trying to set Spanning Tree MST Path Cost for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Interface MST Port Path Cost set successfully \n");
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum)
{
uint32_t cost = 0;
dot1sMSTInstance,
{
printf("Bad return code trying to get Spanning Tree MST Instance Operatinal Path Cost for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Instance Operational Path Cost for interface %u %u: %u \n", dot1sMSTInstance, ifNum, cost);
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum)
{
char str[256];
buffdesc.pstart = str;
buffdesc.size = sizeof(str);
dot1sMSTInstance,
{
printf("Bad return code trying to get Spanning Tree MST Instance Designationed Root ID for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Instance Designated Root ID for interface %u %u: %s \n", dot1sMSTInstance, ifNum, str);
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum)
{
uint32_t cost = 0;
dot1sMSTInstance,
{
printf("Bad return code trying to get Spanning Tree MST Instance Designated Port Path Cost for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Instance Designated Port Path Cost for interface %u %u: %u \n", dot1sMSTInstance, ifNum, cost);
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum)
{
char str[256];
buffdesc.pstart = str;
buffdesc.size = sizeof(str);
dot1sMSTInstance,
{
printf("Bad return code trying to get Spanning Tree MST Instance Designationed Bridge ID for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Instance Designated Bridge ID for interface %u %u: %s \n", dot1sMSTInstance, ifNum, str);
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum)
{
char str[256];
buffdesc.pstart = str;
buffdesc.size = sizeof(str);
dot1sMSTInstance,
{
printf("Bad return code trying to get Spanning Tree MST Instance Designationed Port ID for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Instance Designated Port ID for interface %u %u: %s \n", dot1sMSTInstance, ifNum, str);
}
return;
}
uint32_t ifNum)
{
{
printf("Bad return code trying to get Spanning Tree CIST External Path Cost Mode for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree CIST External Path Cost Mode for interface %u: %u \n", ifNum, mode);
}
return;
}
uint32_t ifNum)
{
uint32_t cost = 0;
{
printf("Bad return code trying to get Spanning Tree CIST External Path Cost for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree CIST External Path Cost for interface %u: %u \n", ifNum, cost);
}
return;
}
uint32_t ifNum, uint32_t cost)
{
{
printf("Bad return code trying to set Spanning Tree CIST External Path Cost for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree CIST External Port Path Cost set successfully \n");
}
return;
}
uint32_t ifNum)
{
{
printf("Bad return code trying to get Spanning Tree CIST Topology Change ACK for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree CIST Topology Change ACK for interface %u : %u \n", ifNum, val);
}
return;
}
{
uint32_t val = 0;
{
printf("Bad return code trying to get Spanning Tree CIST Hello time. (result = %d)\n", result);
}
else
{
printf("Spanning Tree CIST Hello time %u \n", val);
}
return;
}
uint32_t ifNum)
{
{
printf("Bad return code trying to get Spanning Tree CIST Operational Edge Port Status for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree CIST Operational Edge Port Status for interface %u : %u \n", ifNum, val);
}
return;
}
uint32_t ifNum)
{
{
printf("Bad return code trying to get Spanning Tree CIST Point-to-Point MAC status for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree CIST Point-to-Point MAC status for interface %u : %u \n", ifNum, val);
}
return;
}
uint32_t ifNum)
{
char str[256];
buffdesc.pstart = str;
buffdesc.size = sizeof(str);
{
printf("Bad return code trying to get Spanning Tree CIST Regional Root ID for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree CIST Regional Root ID for interface %u: %s \n", ifNum, str);
}
return;
}
uint32_t ifNum)
{
uint32_t cost = 0;
{
printf("Bad return code trying to get Spanning Tree CIST Internal Root path cost for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree CIST Internal Root path cost for interface %u: %u \n", ifNum, cost);
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum)
{
dot1sMSTInstance,
{
printf("Bad return code trying to get Spanning Tree MST Loop Inconsistent State for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST Loop Inconsistent State for interface %u %u: %u \n", dot1sMSTInstance, ifNum, val);
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum)
{
uint32_t count = 0;
dot1sMSTInstance,
{
printf("Bad return code trying to get Spanning Tree MST transitions into loop inconsistent state for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST transitions into loop inconsistent state for interface %u %u: %u \n",
dot1sMSTInstance, ifNum, count);
}
return;
}
uint32_t dot1sMSTInstance,
uint32_t ifNum)
{
uint32_t count = 0;
dot1sMSTInstance,
{
printf("Bad return code trying to get Spanning Tree MST transitions out of loop inconsistent state for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MST transitions out of loop inconsistent state for interface %u %u: %u \n",
dot1sMSTInstance, ifNum, count);
}
return;
}
uint32_t ifNum)
{
{
printf("Bad return code trying to clear Spanning CIST statistics for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree CIST statistics cleared for interface %u\n", ifNum);
}
return;
}
uint32_t ifNum)
{
uint32_t val = 0;
{
printf("Bad return code trying to get Spanning Tree Hello Time for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Hello Time for interface %u : %u \n", ifNum, val);
}
return;
}
uint32_t ifNum)
{
{
printf("Bad return code trying to get Spanning Tree BPDU Guard effect for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Administrative BPDU Guard effect for interface %u: %u \n", ifNum, val);
}
return;
}
uint32_t ifNum)
{
{
printf("Bad return code trying to get Spanning Tree Restricted TCN parameterfor an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Restricted TCN parameter for interface %u: %u \n", ifNum, val);
}
return;
}
{
{
printf("Bad return code trying to set Spanning Tree Restricted TCN parameter for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Restricted TCN parameter set successfully \n");
}
return;
}
uint32_t ifNum)
{
{
printf("Bad return code trying to get Spanning Tree Auto Edge Value for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Auto Edge Value for interface %u: %u \n", ifNum, val);
}
return;
}
{
{
printf("Bad return code trying to set Spanning Tree Auto Edge Value for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Auto Edge Value set successfully \n");
}
return;
}
uint32_t ifNum)
{
char str[256];
buffdesc.pstart = str;
buffdesc.size = sizeof(str);
{
printf("Bad return code trying to get Spanning Tree Up Time for an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree Up Time for interface %u: %s \n", ifNum, str);
}
return;
}
uint32_t ifNum)
{
uint32_t val = 0;
ifNum,
{
printf("Bad return code trying to get STP BPDUs sent on an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree STP BPDUs sent on interface %u: %u \n", ifNum, val);
}
return;
}
uint32_t ifNum)
{
uint32_t val = 0;
ifNum,
{
printf("Bad return code trying to get STP BPDUs received on an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree STP BPDUs received on interface %u: %u \n", ifNum, val);
}
return;
}
uint32_t ifNum)
{
uint32_t val = 0;
ifNum,
{
printf("Bad return code trying to get RSTP BPDUs sent on an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree RSTP BPDUs sent on interface %u: %u \n", ifNum, val);
}
return;
}
uint32_t ifNum)
{
uint32_t val = 0;
ifNum,
{
printf("Bad return code trying to get RSTP BPDUs received on an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree RSTP BPDUs received on interface %u: %u \n", ifNum, val);
}
return;
}
uint32_t ifNum)
{
uint32_t val = 0;
ifNum,
{
printf("Bad return code trying to get MSTP BPDUs sent on an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MSTP BPDUs sent on interface %u: %u \n", ifNum, val);
}
return;
}
uint32_t ifNum)
{
uint32_t val = 0;
ifNum,
{
printf("Bad return code trying to get MSTP BPDUs received on an interface. (result = %d)\n", result);
}
else
{
printf("Spanning Tree MSTP BPDUs received on interface %u: %u \n", ifNum, val);
}
return;
}
{
uint32_t invalidControlMode = 10;
uint32_t dot1SMgmtStrLen, strLen, dot1sConfigRev, instanceId, nextInstanceId;
uint32_t vlan, nextVlan, FId, nextFId;
uint16_t priority;
char *str, buf[256];
uint32_t var1;
uint32_t port_priority = 0, val = 0;
uint32_t mstid = 0;
uint32_t badMstid = 9999;
printf("Testing Spanning Tree OpEN APIs sanity:\n\n");
{
printf("Bad return code. (result = %d)\n", result);
return;
}
if ((str = (char*)malloc(dot1SMgmtStrLen)) == NULL)
{
printf("Could not allocate memory.\n");
return;
}
memset(str, 0, dot1SMgmtStrLen);
printf("Testing openapiDot1sMgmtStrLenGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid string type:(result = %d)\n", result);
printf("NULL String Length:(result = %d)\n", result);
printf("openapiDot1sMgmtStrLenGet() sanity successful\n\n");
printf("Testing openapiDot1SModeSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid Control Mode:(result = %d)\n", result);
printf("openapiDot1SModeSet() sanity successful\n\n");
printf("Testing openapiDot1SModeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Control Mode:(result = %d)\n", result);
printf("openapiDot1SModeGet() sanity successful\n\n");
printf("Testing openapiDot1SIntfBPDUFilterModeSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid Control Mode:(result = %d)\n", result);
printf("openapiDot1SIntfBPDUFilterModeSet() sanity successful\n\n");
printf("Testing openapiDot1SIntfBPDUFilterModeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Control Mode:(result = %d)\n", result);
printf("openapiDot1SIntfBPDUFloodModeSet() sanity successful\n\n");
printf("Testing openapiDot1SIntfBPDUFloodModeSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid Control Mode:(result = %d)\n", result);
printf("openapiDot1SIntfBPDUFloodModeSet() sanity successful\n\n");
printf("Testing openapiDot1SIntfBPDUFloodModeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Control Mode:(result = %d)\n", result);
printf("openapiDot1SIntfBPDUFloodModeGet() sanity successful\n\n");
printf("Testing openapiDot1SBPDUGuardModeSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid Control Mode:(result = %d)\n", result);
printf("openapiDot1SBPDUGuardModeSet() sanity successful\n\n");
printf("Testing openapiDot1SBPDUGuardModeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Control Mode:(result = %d)\n", result);
printf("openapiDot1SBPDUGuardModeGet() sanity successful\n\n");
printf("Testing openapiDot1SConfigNameSet():\n");
buffDesc.pstart = str;
buffDesc.size = dot1SMgmtStrLen;
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Config Name:(result = %d)\n", result);
buffDesc.pstart = NULL;
printf("NULL Config Name buffer:(result = %d)\n", result);
buffDesc.pstart = str;
buffDesc.size = dot1SMgmtStrLen + 10;
printf("NULL Config Name buffer length:(result = %d)\n", result);
printf("openapiDot1SConfigNameSet() sanity successful\n\n");
printf("Testing openapiDot1SConfigNameGet():\n");
buffDesc.pstart = str;
buffDesc.size = dot1SMgmtStrLen;
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Config Name:(result = %d)\n", result);
buffDesc.pstart = NULL;
printf("NULL Config Name buffer:(result = %d)\n", result);
buffDesc.pstart = str;
buffDesc.size = 0;
printf("NULL Config Name buffer length:(result = %d)\n", result);
printf("openapiDot1SConfigNameGet() sanity successful\n\n");
printf("Testing openapiDot1SConfigRevisionSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("openapiDot1SConfigRevisionSet() sanity successful\n\n");
printf("Testing openapiDot1SConfigRevisionGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Config Revision:(result = %d)\n", result);
printf("openapiDot1SConfigRevisionGet() sanity successful\n\n");
printf("Testing openapiDot1SForceVersionSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid Force Version:(result = %d)\n", result);
printf("openapiDot1SForceVersionSet() sanity successful\n\n");
printf("Testing openapiDot1SForceVersionGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Force Version:(result = %d)\n", result);
printf("openapiDot1SForceVersionGet() sanity successful\n\n");
printf("Testing openapiDot1SIntfGuardModeSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid Guard Mode:(result = %d)\n", result);
printf("openapiDot1SIntfGuardModeSet() sanity successful\n\n");
printf("Testing openapiDot1SIntfGuardModeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Guard Mode:(result = %d)\n", result);
printf("openapiDot1SIntfGuardModeGet() sanity successful\n\n");
printf("Testing openapiDot1SMSTInstanceSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid Action:(result = %d)\n", result);
printf("openapiDot1SMSTInstanceSet() sanity successful\n\n");
printf("Testing openapiDot1SMSTInstanceFirstGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Instance:(result = %d)\n", result);
printf("openapiDot1SMSTInstanceFirstGet() sanity successful\n\n");
printf("Testing openapiDot1SMSTInstanceNextGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Next Instance:(result = %d)\n", result);
printf("openapiDot1SMSTInstanceNextGet() sanity successful\n\n");
printf("Testing openapiDot1SMSTInstancePrioritySet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("openapiDot1SMSTInstancePrioritySet() sanity successful\n\n");
printf("Testing openapiDot1SMSTInstancePriorityGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Priority:(result = %d)\n", result);
printf("openapiDot1SMSTInstancePriorityGet() sanity successful\n\n");
printf("Testing openapiDot1SMSTInstanceVLANSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Action:(result = %d)\n", result);
printf("openapiDot1SMSTInstanceVLANSet() sanity successful\n\n");
printf("Testing openapiDot1SMSTInstanceFirstVLANGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL VLAN:(result = %d)\n", result);
printf("openapiDot1SMSTInstanceFirstVLANGet() sanity successful\n\n");
printf("Testing openapiDot1SMSTInstanceNextVLANGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Next Vlan:(result = %d)\n", result);
printf("openapiDot1SMSTInstanceNextVLANGet() sanity successful\n\n");
printf("Testing openapiDot1SMSTInstanceFirstFIdGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL FId:(result = %d)\n", result);
printf("openapiDot1SMSTInstanceFirstFIdGet() sanity successful\n\n");
printf("Testing openapiDot1SMSTInstanceNextFIdGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Next FId:(result = %d)\n", result);
printf("openapiDot1SMSTInstanceNextFIdGet() sanity successful\n\n");
printf("Testing openapiDot1SIntfModeSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Control Mode:(result = %d)\n", result);
printf("openapiDot1SIntfModeSet() sanity successful\n\n");
printf("Testing openapiDot1SIntfModeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Control Mode:(result = %d)\n", result);
printf("openapiDot1SIntfModeGet() sanity successful\n\n");
printf("Testing openapiDot1SIntfModeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Control Mode:(result = %d)\n", result);
printf("openapiDot1SIntfModeGet() sanity successful\n\n");
printf("Testing openapiDot1SIntfPortFwdStateGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL FwdState:(result = %d)\n", result);
printf("openapiDot1SIntfPortFwdStateGet() sanity successful\n\n");
printf("Testing openapiDot1SIntfPortRoleGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL PortRole:(result = %d)\n", result);
printf("openapiDot1SIntfPortRoleGet() sanity successful\n\n");
printf("Testing openapiDot1SIntfEdgePortModeSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid Control Mode:(result = %d)\n", result);
printf("openapiDot1SIntfEdgePortModeSet() sanity successful\n\n");
printf("Testing openapiDot1SIntfEdgePortModeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Control Mode:(result = %d)\n", result);
printf("openapiDot1SIntfEdgePortModeGet() sanity successful\n\n");
printf("Testing openapiDot1SIntfPortLoopInconsistentStateGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL Loop Inconsistent State:(result = %d)\n", result);
printf("openapiDot1SIntfPortLoopInconsistentStateGet() sanity successful\n\n");
buffDesc.pstart = buf;
buffDesc.size = sizeof(buf);
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid MST instance:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL pointer to string:(result = %d)\n", result);
printf("openapiDot1SMSTIntfPortIDGet() sanity successful\n\n");
printf("Testing openapiDot1SMstiPortPrioritySet():\n");
port_priority = 64;
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid MST instance:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("Invalid priority:(result = %d)\n", result);
printf("openapiDot1SMstiPortPrioritySet() sanity successful\n\n");
printf("Testing openapiDot1SMstiPortPathCostModeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid MST instance:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL control mode:(result = %d)\n", result);
printf("openapiDot1SMstiPortPathCostModeGet() sanity successful\n\n");
printf("Testing openapiDot1SMstiPortPathCostSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid MST instance:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("Invalid cost:(result = %d)\n", result);
printf("openapiDot1SMstiPortPathCostSet() sanity successful\n\n");
printf("Testing openapiDot1SMstiOperPortPathCostGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid MST instance:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL cost:(result = %d)\n", result);
printf("openapiDot1SMstiOperPortPathCostGet() sanity successful\n\n");
printf("Testing openapiDot1SMstiPortDesignatedRootIDGet():\n");
buffDesc.pstart = buf;
buffDesc.size = sizeof(buf);
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid MST instance:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL string:(result = %d)\n", result);
printf("openapiDot1SMstiPortDesignatedRootIDGet() sanity successful\n\n");
printf("Testing openapiDot1SMstiDesignatedCostGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid MST instance:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL cost:(result = %d)\n", result);
printf("openapiDot1SMstiDesignatedCostGet() sanity successful\n\n");
printf("Testing openapiDot1SMstiDesignatedPortIDGet():\n");
buffDesc.pstart = buf;
buffDesc.size = sizeof(buf);
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid MST instance:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL string:(result = %d)\n", result);
printf("openapiDot1SMstiDesignatedPortIDGet() sanity successful\n\n");
printf("Testing openapiDot1SMstiPortLoopInconsistentStateGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid MST instance:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL boolean value:(result = %d)\n", result);
printf("openapiDot1SMstiPortLoopInconsistentStateGet() sanity successful\n\n");
printf("Testing openapiDot1SPortStatsTransitionsIntoLoopInconsistentStateGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid MST instance:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL boolean value:(result = %d)\n", result);
printf("openapiDot1SPortStatsTransitionsIntoLoopInconsistentStateGet() sanity successful\n\n");
printf("Testing openapiDot1SPortStatsTransitionsOutOfLoopInconsistentStateGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("Invalid MST instance:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL boolean value:(result = %d)\n", result);
printf("openapiDot1SPortStatsTransitionsOutOfLoopInconsistentStateGet() sanity successful\n\n");
printf("Testing openapiDot1SCistExtPortPathCostModeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL controlMode:(result = %d)\n", result);
printf("openapiDot1SCistExtPortPathCostModeGet() sanity successful\n\n");
printf("Testing openapiDot1SCistExtPortPathCostGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL cost:(result = %d)\n", result);
printf("openapiDot1SCistExtPortPathCostGet() sanity successful\n\n");
printf("Testing openapiDot1SCistExtPortPathCostSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("Invalid cost:(result = %d)\n", result);
printf("openapiDot1SCistExtPortPathCostSet() sanity successful\n\n");
printf("Testing openapiDot1SCistPortTopologyChangeAckGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL boolean mode:(result = %d)\n", result);
printf("openapiDot1SCistPortTopologyChangeAckGet() sanity successful\n\n");
printf("Testing openapiDot1SCistHelloTimeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL value:(result = %d)\n", result);
printf("openapiDot1SCistHelloTimeGet() sanity successful\n\n");
printf("Testing openapiDot1SCistPortOperEdgeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL boolean mode:(result = %d)\n", result);
printf("openapiDot1SCistPortOperEdgeGet() sanity successful\n\n");
printf("Testing openapiDot1SCistPortOperPointToPointGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL boolean mode:(result = %d)\n", result);
printf("openapiDot1SCistPortOperPointToPointGet() sanity successful\n\n");
printf("Testing openapiDot1SCistPortRegionalRootIDGet():\n");
buffDesc.pstart = buf;
buffDesc.size = sizeof(buf);
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL string:(result = %d)\n", result);
printf("openapiDot1SCistPortRegionalRootIDGet() sanity successful\n\n");
printf("Testing openapiDot1SCistPortPathCostGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL cost:(result = %d)\n", result);
printf("openapiDot1SCistPortPathCostGet() sanity successful\n\n");
printf("Testing openapiDot1SPortStatsClear():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("openapiDot1SPortStatsClear() sanity successful\n\n");
printf("Testing openapiDot1SIntfHelloTimeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL val:(result = %d)\n", result);
printf("openapiDot1SIntfHelloTimeGet() sanity successful\n\n");
printf("Testing openapiDot1SIntfBPDUGuardEffectGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL val:(result = %d)\n", result);
printf("openapiDot1SIntfBPDUGuardEffectGet() sanity successful\n\n");
printf("Testing openapiDot1SPortRestrictedTcnSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("Invalid boolean val:(result = %d)\n", result);
printf("openapiDot1SPortRestrictedTcnSet() sanity successful\n\n");
printf("Testing openapiDot1SPortRestrictedTcnGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL val:(result = %d)\n", result);
printf("openapiDot1SPortRestrictedTcnGet() sanity successful\n\n");
printf("Testing openapiDot1SPortAutoEdgeGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL val:(result = %d)\n", result);
printf("openapiDot1SPortAutoEdgeGet() sanity successful\n\n");
printf("Testing openapiDot1SPortAutoEdgeSet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("Invalid boolean val:(result = %d)\n", result);
printf("openapiDot1SPortAutoEdgeSet() sanity successful\n\n");
printf("Testing openapiDot1SPortUpTimeGet():\n");
memset(buf, 0, sizeof(buf));
buffDesc.pstart = buf;
buffDesc.size = sizeof(buf);
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL val:(result = %d)\n", result);
printf("openapiDot1SPortUpTimeGet() sanity successful\n\n");
printf("Testing openapiDot1SPortStatsSTPBPDUsSentGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL val:(result = %d)\n", result);
printf("openapiDot1SPortStatsSTPBPDUsSentGet() sanity successful\n\n");
printf("Testing openapiDot1SPortStatsSTPBPDUsReceivedGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL val:(result = %d)\n", result);
printf("openapiDot1SPortStatsSTPBPDUsReceivedGet() sanity successful\n\n");
printf("Testing openapiDot1SPortStatsRSTPBPDUsSentGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL val:(result = %d)\n", result);
printf("openapiDot1SPortStatsRSTPBPDUsSentGet() sanity successful\n\n");
printf("Testing openapiDot1SPortStatsRSTPBPDUsReceivedGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL val:(result = %d)\n", result);
printf("openapiDot1SPortStatsRSTPBPDUsReceivedGet() sanity successful\n\n");
printf("Testing openapiDot1SPortStatsMSTPBPDUsSentGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL val:(result = %d)\n", result);
printf("openapiDot1SPortStatsMSTPBPDUsSentGet() sanity successful\n\n");
printf("Testing openapiDot1SPortStatsMSTPBPDUsReceivedGet():\n");
printf("NULL Client Handle:(result = %d)\n", result);
printf("NULL interface:(result = %d)\n", result);
printf("NULL val:(result = %d)\n", result);
printf("openapiDot1SPortStatsMSTPBPDUsReceivedGet() sanity successful\n\n");
free(str);
mstid = 0;
printf("Testing openapiDot1sMSTInstanceBridgeIdentifierGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceBridgeIdentifierGet():\n");
printf("Invalid MST ID:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceBridgeIdentifierGet():\n");
printf("NULL argument 3:(result = %d)\n", result);
printf("openapiDot1sMSTInstanceBridgeIdentifierGet() sanity successful\n\n");
printf("Testing openapiDot1sMSTInstanceTimeSinceTopologyChangeGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceTimeSinceTopologyChangeGet():\n");
printf("Invalid MST ID:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceTimeSinceTopologyChangeGet():\n");
printf("NULL argument 3:(result = %d)\n", result);
printf("openapiDot1sMSTInstanceTimeSinceTopologyChangeGet() sanity successful\n\n");
printf("Testing openapiDot1sMSTInstanceTopologyChangeCountGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceTopologyChangeCountGet():\n");
printf("Invalid MST ID:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceTopologyChangeCountGet():\n");
printf("NULL argument 3:(result = %d)\n", result);
printf("openapiDot1sMSTInstanceTopologyChangeCountGet() sanity successful\n\n");
printf("Testing openapiDot1sMSTInstanceTopologyChangeStateGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceTopologyChangeStateGet():\n");
printf("Invalid MST ID:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceTopologyChangeStateGet():\n");
printf("NULL argument 3:(result = %d)\n", result);
printf("openapiDot1sMSTInstanceTopologyChangeStateGet() sanity successful\n\n");
printf("Testing openapiDot1sMSTInstanceDesignatedRootIDGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceDesignatedRootIDGet():\n");
printf("Invalid MST ID:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceDesignatedRootIDGet():\n");
printf("NULL argument 3:(result = %d)\n", result);
printf("openapiDot1sMSTInstanceDesignatedRootIDGet() sanity successful\n\n");
printf("Testing openapiDot1sMSTInstanceRootPathCostGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceRootPathCostGet():\n");
printf("Invalid MST ID:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceRootPathCostGet():\n");
printf("NULL argument 3:(result = %d)\n", result);
printf("openapiDot1sMSTInstanceRootPathCostGet() sanity successful\n\n");
printf("Testing openapiDot1sMSTInstanceRootPortIDGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceRootPortIDGet():\n");
printf("Invalid MST ID:(result = %d)\n", result);
printf("Testing openapiDot1sMSTInstanceRootPortIDGet():\n");
printf("NULL argument 3:(result = %d)\n", result);
printf("openapiDot1sMSTInstanceRootPortIDGet() sanity successful\n\n");
printf("Testing openapiDot1sCISTMaxAgeGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sCISTMaxAgeGet():\n");
printf("NULL argument 2:(result = %d)\n", result);
printf("openapiDot1sCISTMaxAgeGet() sanity successful\n\n");
printf("Testing openapiDot1sBridgeMaxHopGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sBridgeMaxHopGet():\n");
printf("NULL argument 2:(result = %d)\n", result);
printf("openapiDot1sBridgeMaxHopGet() sanity successful\n\n");
printf("Testing openapiDot1sBridgeTxHoldCountGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sBridgeTxHoldCountGet():\n");
printf("NULL argument 2:(result = %d)\n", result);
printf("openapiDot1sBridgeTxHoldCountGet() sanity successful\n\n");
printf("Testing openapiDot1sCISTRootFwdDelayGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sCISTRootFwdDelayGet():\n");
printf("NULL argument 2:(result = %d)\n", result);
printf("openapiDot1sCISTRootFwdDelayGet() sanity successful\n\n");
printf("Testing openapiDot1sCISTHelloTimeGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sCISTHelloTimeGet():\n");
printf("Likely invalid interface number:(result = %d)\n", result);
printf("Testing openapiDot1sCISTHelloTimeGet():\n");
printf("NULL argument 3:(result = %d)\n", result);
printf("openapiDot1sCISTHelloTimeGet() sanity successful\n\n");
printf("Testing openapiDot1sCISTBridgeHoldTimeGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sCISTBridgeHoldTimeGet():\n");
printf("NULL argument 2:(result = %d)\n", result);
printf("openapiDot1sCISTBridgeHoldTimeGet() sanity successful\n\n");
printf("Testing openapiDot1sCISTRegionalRootIDGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sCISTRegionalRootIDGet():\n");
printf("NULL argument 2:(result = %d)\n", result);
printf("openapiDot1sCISTRegionalRootIDGet() sanity successful\n\n");
printf("Testing openapiDot1sCISTRegionalRootPathCostGet():\n");
printf("NULL client handle:(result = %d)\n", result);
printf("Testing openapiDot1sCISTRegionalRootPathCostGet():\n");
printf("NULL argument 2:(result = %d)\n", result);
printf("openapiDot1sCISTRegionalRootPathCostGet() sanity successful\n\n");
return;
}
int main(int argc, char **argv)
{
uint32_t testNum, arg1, arg2, arg3;
char switch_os_revision_string[100];
if (argc < 2)
{
printDot1sAppMenu();
exit(1);
}
testNum = atoi(argv[1]);
l7proc_crashlog_register();
{
printf("\nFailed to initialize RPC to OpEN. Exiting (result = %d)\n", result);
exit(2);
}
{
sleep(1);
}
L7PROC_LOGF(L7PROC_LOG_SEVERITY_INFO, 0, "Starting Spanning Tree API example application");
printf("\n");
switch_os_revision.pstart = switch_os_revision_string;
switch_os_revision.size = sizeof(switch_os_revision_string);
printf("Network OS version = %s\n", switch_os_revision_string);
else
printf("Network OS version retrieve error\n");
printf("\n");
switch (testNum)
{
case 1:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SModeSet(&clientHandle, arg1);
break;
case 2:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1SModeGet(&clientHandle);
break;
case 3:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SIntfBPDUFilterModeSet(&clientHandle, arg1, arg2);
break;
case 4:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SIntfBPDUFilterModeGet(&clientHandle, arg1);
break;
case 5:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SIntfBPDUFloodModeSet(&clientHandle, arg1, arg2);
break;
case 6:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SIntfBPDUFloodModeGet(&clientHandle, arg1);
break;
case 7:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SBPDUGuardModeSet(&clientHandle, arg1);
break;
case 8:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1SBPDUGuardModeGet(&clientHandle);
break;
case 9:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
dot1SConfigNameSet(&clientHandle, argv[2]);
break;
case 10:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1SConfigNameGet(&clientHandle);
break;
case 11:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SConfigRevisionSet(&clientHandle, arg1);
break;
case 12:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1SConfigRevisionGet(&clientHandle);
break;
case 13:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SForceVersionSet(&clientHandle, arg1);
break;
case 14:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1SForceVersionGet(&clientHandle);
break;
case 15:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SIntfGuardModeSet(&clientHandle, arg1, arg2);
break;
case 16:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SIntfGuardModeGet(&clientHandle, arg1);
break;
case 17:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SMSTInstanceSet(&clientHandle, arg1, OPEN_ACTION_ADD);
break;
case 18:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SMSTInstanceSet(&clientHandle, arg1, OPEN_ACTION_DELETE);
break;
case 19:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1SMSTInstancesGet(&clientHandle);
break;
case 20:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMSTInstancePrioritySet(&clientHandle, arg1, arg2);
break;
case 21:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SMSTInstancePriorityGet(&clientHandle, arg1);
break;
case 22:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMSTInstanceVLANSet(&clientHandle, arg1, arg2, OPEN_ACTION_ADD);
break;
case 23:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMSTInstanceVLANSet(&clientHandle, arg1, arg2, OPEN_ACTION_DELETE);
break;
case 24:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SMSTInstanceVLANsGet(&clientHandle, arg1);
break;
case 25:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SMSTInstanceFIdsGet(&clientHandle, arg1);
break;
case 26:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SIntfModeSet(&clientHandle, arg1, arg2);
break;
case 27:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SIntfModeGet(&clientHandle, arg1);
break;
case 28:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SIntfPortFwdStateGet(&clientHandle, arg1, arg2);
break;
case 29:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SIntfPortRoleGet(&clientHandle, arg1, arg2);
break;
case 30:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SIntfEdgePortModeSet(&clientHandle, arg1, arg2);
break;
case 31:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SIntfEdgePortModeGet(&clientHandle, arg1);
break;
case 32:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SIntfPortLoopInconsistentStateGet(&clientHandle, arg1, arg2);
break;
case 33:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1sMSTInstanceBridgeIdentifierGet(&clientHandle, arg1);
break;
case 34:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1sMSTInstanceTimeSinceTopologyChangeGet(&clientHandle, arg1);
break;
case 35:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1sMSTInstanceTopologyChangeCountGet(&clientHandle, arg1);
break;
case 36:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1sMSTInstanceTopologyChangeStateGet(&clientHandle, arg1);
break;
case 37:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1sMSTInstanceDesignatedRootIDGet(&clientHandle, arg1);
break;
case 38:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1sMSTInstanceRootPathCostGet(&clientHandle, arg1);
break;
case 39:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1sMSTInstanceRootPortIDGet(&clientHandle, arg1);
break;
case 40:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1sCISTMaxAgeGet(&clientHandle);
break;
case 41:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1sBridgeMaxHopGet(&clientHandle);
break;
case 42:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1sBridgeTxHoldCountGet(&clientHandle);
break;
case 43:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1sCISTRootFwdDelayGet(&clientHandle);
break;
case 44:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1sCISTHelloTimeGet(&clientHandle, arg1);
break;
case 45:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1sCISTBridgeHoldTimeGet(&clientHandle);
break;
case 46:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1sCISTRegionalRootIDGet(&clientHandle);
break;
case 47:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1sCISTRegionalRootPathCostGet(&clientHandle);
break;
case 48:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMSTInstanceIntfPortIDGet(&clientHandle, arg1, arg2);
break;
case 49:
if (argc != 5)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
arg3 = atoi(argv[4]);
dot1SMSTInstanceIntfPrioritySet(&clientHandle, arg1, arg2, arg3);
break;
case 50:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMSTInstanceIntfPriorityGet(&clientHandle, arg1, arg2);
break;
case 51:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMSTInstancePortPathCostModeGet(&clientHandle, arg1, arg2);
break;
case 52:
if (argc != 5)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
arg3 = atoi(argv[4]);
dot1SMSTInstancePortPathCostSet(&clientHandle, arg1, arg2, arg3);
break;
case 53:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMSTInstanceOperPortPathCostGet(&clientHandle, arg1, arg2);
break;
case 54:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMstiPortDesignatedRootIDGet(&clientHandle, arg1, arg2);
break;
case 55:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMstiPortDesignatedCostGet(&clientHandle, arg1, arg2);
break;
case 56:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMstiPortDesignatedBridgeIDGet(&clientHandle, arg1, arg2);
break;
case 57:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMstiPortDesignatedPortIDGet(&clientHandle, arg1, arg2);
break;
case 58:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SCistExtPortPathCostModeGet(&clientHandle, arg1);
break;
case 59:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SCistExtPortPathCostGet(&clientHandle, arg1);
break;
case 60:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SCistExtPortPathCostSet(&clientHandle, arg1, arg2);
break;
case 61:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SCistPortTopologyChangeAckGet(&clientHandle, arg1);
break;
case 62:
if (argc != 2)
{
printDot1sAppMenu();
exit(1);
}
dot1SCistHelloTimeGet(&clientHandle);
break;
case 63:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SCistPortOperEdgeGet(&clientHandle, arg1);
break;
case 64:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SCistPortOperPointToPointGet(&clientHandle, arg1);
break;
case 65:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SCistPortRegionalRootIDGet(&clientHandle, arg1);
break;
case 66:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SCistPortPathCostGet(&clientHandle, arg1);
break;
case 67:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SMstiPortLoopInconsistentStateGet(&clientHandle, arg1, arg2);
break;
case 68:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SPortStatsTransitionsIntoLoopInconsistentStateGet(&clientHandle, arg1, arg2);
break;
case 69:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SPortStatsTransitionsOutOfLoopInconsistentStateGet(&clientHandle, arg1, arg2);
break;
case 70:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SPortStatsClear(&clientHandle, arg1);
break;
case 71:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SIntfHelloTimeGet(&clientHandle, arg1);
break;
case 72:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SIntfBPDUGuardEffectGet(&clientHandle, arg1);
break;
case 73:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SPortRestrictedTcnSet(&clientHandle, arg1, arg2);
break;
case 74:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SPortRestrictedTcnGet(&clientHandle, arg1);
break;
case 75:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SPortAutoEdgeGet(&clientHandle, arg1);
break;
case 76:
if (argc != 4)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
arg2 = atoi(argv[3]);
dot1SPortAutoEdgeSet(&clientHandle, arg1, arg2);
break;
case 77:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SPortUpTimeGet(&clientHandle, arg1);
break;
case 78:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SPortStatsSTPBPDUsSentGet(&clientHandle, arg1);
break;
case 79:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SPortStatsSTPBPDUsReceivedGet(&clientHandle, arg1);
break;
case 80:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SPortStatsRSTPBPDUsSentGet(&clientHandle, arg1);
break;
case 81:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SPortStatsRSTPBPDUsReceivedGet(&clientHandle, arg1);
break;
case 82:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SPortStatsMSTPBPDUsSentGet(&clientHandle, arg1);
break;
case 83:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SPortStatsMSTPBPDUsReceivedGet(&clientHandle, arg1);
break;
case 84:
if (argc != 3)
{
printDot1sAppMenu();
exit(1);
}
arg1 = atoi(argv[2]);
dot1SOpENAPIsTestSanity(&clientHandle, arg1);
break;
default:
printDot1sAppMenu();
break;
}
L7PROC_LOGF(L7PROC_LOG_SEVERITY_INFO, 0, "Stopping Spanning Tree API example application");
return 0;
}