Cisco Cisco 3365 Mobility Services Engine Developer's Guide

Page of 224
C
ISCO 
MSE
 
API
 
S
PECI FICATI ON 
G
UI DE 
 
C
ONTEXT 
A
W ARE 
S
ERVICE  OF 
MSE,
 
R
ELEASE 
7.4
.
       
P
A G E  
225
  O F  
227  
        static void Main(string[] args) 
       { 
          aaaService LS = new aaaService(); 
          LocationService LS1 = new LocationService(); 
          //Login  
          LoginMethodArgs LM = new LoginMethodArgs(); 
          AesLogin AL = new AesLogin(); 
          AL.userName = "admin" ; 
          AL.password = "admin" ; 
          LM.AesLogin  = AL ; 
         
          Session s = LS.Login(LM); 
          if(s!=null) 
          { 
    
     aaa.AesBusinessSession AB =(aaa.AesBusinessSession)  s.AesBusinessSession; 
             Console.WriteLine("<---------LOGIN-------------------->"); 
             Console.WriteLine("Id =" +AB.id); 
             Console.WriteLine("<---------------------------------->"); 
              //GetServerInfo 
            location.GetTypeArgs GT = new location.GetTypeArgs(); 
            location.AesBusinessSession bSession = new location.AesBusinessSession(); 
 
    bSession.id= AB.id; 
            GT.AesBusinessSession = bSession; 
            location.Response r1= LS1.GetServerInfo(GT); 
            if(r1!=null) 
            {        
              AesServerInfo AS =(AesServerInfo) r1.Items.GetValue(0); 
              Console.WriteLine("<---------SERVERINFO-------------------->"); 
              Console.WriteLine("ProdName="+ AS.productName); 
              Console.WriteLine("Version=" +AS.version); 
              Console.WriteLine("ElemList=" + AS.activeElementsLimit);