شركة التطبيقات المتكاملة لتصميم النظم البرمجية الخاصة

Integrated Applications Programming Company

Skip Navigation LinksHome » Code Library » Ims

Public general use code classes and xml files that we've compiled and used over the years:

Optical Fiber Network Management Intranet Portal (OFN) support class for Next Generation Network (NGN) business model

   1:  using System;
   2:  using System.Collections.Generic;
   3:  using System.Linq;
   4:   
   5:  namespace Ia.Ngn.Cl.Model.Business
   6:  {
   7:      ////////////////////////////////////////////////////////////////////////////
   8:   
   9:      /// <summary publish="true">
  10:      /// Optical Fiber Network Management Intranet Portal (OFN) support class for Next Generation Network (NGN) business model
  11:      /// </summary>
  12:      /// 
  13:      /// <value>
  14:      ///   <appSettings>
  15:      ///     <add key="imsHuaweiServerHost" value="https://*" />
  16:      ///     <add key="imsHuaweiServerPort" value="*" />
  17:      ///     <add key="imsHuaweiServerServiceUrl" value="*" />
  18:      ///     <add key="imsHuaweiServerUser" value="*" />
  19:      ///     <add key="imsHuaweiServerUserPassword" value="*" />
  20:      ///   </appSettings>
  21:      /// </value>
  22:      /// 
  23:      /// <remarks> 
  24:      /// Copyright © 2014-2017 Jasem Y. Al-Shamlan (info@ia.com.kw), Internet Applications - Kuwait. All Rights Reserved.
  25:      ///
  26:      /// This library is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by
  27:      /// the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
  28:      ///
  29:      /// This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
  30:      /// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
  31:      /// 
  32:      /// You should have received a copy of the GNU General Public License along with this library. If not, see http://www.gnu.org/licenses.
  33:      /// 
  34:      /// Copyright notice: This notice may not be removed or altered from any source distribution.
  35:      /// </remarks> 
  36:      public class Ims
  37:      {
  38:          public class ImsBasicService
  39:          {
  40:              public string MgcIp;
  41:              public string MgcSecondaryIp;
  42:              public string MgcSubnetMask;
  43:              public int Service;
  44:              public string Fsdb;
  45:              public string PrimarySwitch;
  46:          }
  47:   
  48:          ////////////////////////////////////////////////////////////////////////////
  49:   
  50:          /// <summary>
  51:          ///
  52:          /// </summary>
  53:          public Ims()
  54:          {
  55:          }
  56:   
  57:          ////////////////////////////////////////////////////////////////////////////
  58:   
  59:          /// <summary>
  60:          ///
  61:          /// </summary>
  62:          public static int NextVacantFlatTermIdFromAgcfEndpointUsingGwIdForOnt(Ia.Ngn.Cl.Model.Business.Huawei.Ont.EquipmentType familyType, int gwId)
  63:          {
  64:              int ft;
  65:              List<int> list;
  66:   
  67:              list = Ia.Ngn.Cl.Model.Data.Nokia.AgcfEndpoint.UsedFlatTermIdListForGatewayId(gwId);
  68:   
  69:              if (list.Count == 0) ft = 1; // this means agcfEndpoint does not exist for any number and the box is empty, and we should create agcfEndpoint at 1
  70:              else
  71:              {
  72:                  // change this later to accommodate the Huawei ONT type
  73:                  list = Ia.Cl.Model.Default.ExcludedNumberListFromNumberListWithinRange(list, Ia.Ngn.Cl.Model.Business.Huawei.Ems.PossibleNumberOfTdForOntEquipmentType(familyType));
  74:   
  75:                  if (list.Count > 0) ft = list[0];
  76:                  else ft = 0; // something went wrong
  77:              }
  78:   
  79:              return ft;
  80:          }
  81:   
  82:          /*
  83:          ////////////////////////////////////////////////////////////////////////////
  84:  
  85:          /// <summary>
  86:          ///
  87:          /// </summary>
  88:          public static Ia.Ngn.Cl.Model.Business.Ims.ImsBasicService OldNokiaImsBasicServiceItem(Ia.Ngn.Cl.Model.Data.OldNetworkDesignDocument.Ont ont)
  89:          {
  90:              string mgcIp, fsdb;
  91:              Ia.Ngn.Cl.Model.Business.Ims.ImsBasicService imsBasicService;
  92:              Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicService nokiaImsBasicService;
  93:  
  94:              mgcIp = ont.Pon.Olt.MgcIp;
  95:  
  96:              nokiaImsBasicService = (from ibs in Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceList where ibs.MgcIp == mgcIp select ibs).Single();
  97:  
  98:              // Fsdb will always be "fsdb0" for *any* ONT (event if it was an MDU) that has a PBX SERVICEBUNDLE2 category. I will check to see if this ONT has any PBX before I assign the fsdb value to it.
  99:              fsdb = (OntHasAPbxDesignatedSubParty(ont.Ip)) ? "fsdb0" : nokiaImsBasicService.Fsdb;
 100:  
 101:              imsBasicService = new ImsBasicService()
 102:              {
 103:                  PrimarySwitch = nokiaImsBasicService.PrimarySwitch,
 104:                  Fsdb = fsdb,
 105:                  MgcIp = nokiaImsBasicService.MgcIp,
 106:                  MgcSecondaryIp = nokiaImsBasicService.MgcSecondaryIp,
 107:                  MgcSubnetMask = nokiaImsBasicService.MgcSubnetMask,
 108:                  Service = nokiaImsBasicService.Service
 109:              };
 110:  
 111:              return imsBasicService;
 112:          }
 113:          */
 114:   
 115:          ////////////////////////////////////////////////////////////////////////////
 116:   
 117:          /// <summary>
 118:          ///
 119:          /// </summary>
 120:          public static Ia.Ngn.Cl.Model.Business.Ims.ImsBasicService NokiaImsBasicServiceItem(Ia.Ngn.Cl.Model.Business.NetworkDesignDocument.Ont ont)
 121:          {
 122:              string mgcIp, fsdb;
 123:              Ia.Ngn.Cl.Model.Business.Ims.ImsBasicService imsBasicService;
 124:              Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicService nokiaImsBasicService;
 125:   
 126:              mgcIp = ont.Pon.PonGroup.MgcIp;
 127:   
 128:              nokiaImsBasicService = (from ibs in Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceList where ibs.MgcIp == mgcIp select ibs).Single();
 129:   
 130:              // Fsdb will always be "fsdb0" for *any* ONT (event if it was an MDU) that has a PBX SERVICEBUNDLE2 category. I will check to see if this ONT has any PBX before I assign the fsdb value to it.
 131:              fsdb = (OntHasAPbxDesignatedSubParty(ont.Ip)) ? "fsdb0" : nokiaImsBasicService.Fsdb;
 132:   
 133:              imsBasicService = new ImsBasicService()
 134:              {
 135:                  PrimarySwitch = nokiaImsBasicService.PrimarySwitch,
 136:                  Fsdb = fsdb,
 137:                  MgcIp = nokiaImsBasicService.MgcIp,
 138:                  MgcSecondaryIp = nokiaImsBasicService.MgcSecondaryIp,
 139:                  MgcSubnetMask = nokiaImsBasicService.MgcSubnetMask,
 140:                  Service = nokiaImsBasicService.Service
 141:              };
 142:   
 143:              return imsBasicService;
 144:          }
 145:   
 146:          ////////////////////////////////////////////////////////////////////////////
 147:   
 148:          /// <summary>
 149:          ///
 150:          /// </summary>
 151:          public static bool OntHasAPbxDesignatedSubParty(string ip)
 152:          {
 153:              bool hasPbx;
 154:              List<string> list;
 155:   
 156:              list = new List<string>();
 157:   
 158:              list = Ia.Ngn.Cl.Model.Data.Nokia.Ims.AgcfGatewayRecordsWithinWhichSubPartiesHaveServiceBundle2CategoryList;
 159:   
 160:              if (list.Count > 0) hasPbx = list.Contains(ip);
 161:              else hasPbx = false;
 162:   
 163:              return hasPbx;
 164:          }
 165:   
 166:          ////////////////////////////////////////////////////////////////////////////
 167:   
 168:          /// <summary>
 169:          ///
 170:          /// </summary>
 171:          public static Ia.Ngn.Cl.Model.Business.Ims.ImsBasicService HuaweiImsBasicServiceItem(string mgcIp)
 172:          {
 173:              Ia.Ngn.Cl.Model.Business.Ims.ImsBasicService imsBasicService;
 174:              Ia.Ngn.Cl.Model.Business.Huawei.Ims.ImsBasicService huaweiImsBasicService;
 175:   
 176:              huaweiImsBasicService = (from ibs in Ia.Ngn.Cl.Model.Business.Huawei.Ims.ImsBasicServiceList where ibs.MgcIp == mgcIp select ibs).Single();
 177:   
 178:              imsBasicService = new ImsBasicService()
 179:              {
 180:                  PrimarySwitch = huaweiImsBasicService.PrimarySwitch,
 181:                  Fsdb = huaweiImsBasicService.Fsdb,
 182:                  MgcIp = huaweiImsBasicService.MgcIp,
 183:                  MgcSecondaryIp = huaweiImsBasicService.MgcSecondaryIp,
 184:                  MgcSubnetMask = huaweiImsBasicService.MgcSubnetMask,
 185:                  Service = huaweiImsBasicService.Service
 186:              };
 187:   
 188:              return imsBasicService;
 189:          }
 190:   
 191:          /*
 192:          ////////////////////////////////////////////////////////////////////////////
 193:  
 194:          /// <summary>
 195:          ///
 196:          /// </summary>
 197:          public static Ia.Ngn.Cl.Model.Business.Ims.ImsBasicService OldSpecialHuaweiIpHandlingForNokiaImsBasicServiceItem(Ia.Ngn.Cl.Model.Data.OldNetworkDesignDocument.Ont nddOnt)
 198:          {
 199:              Ia.Ngn.Cl.Model.Business.Ims.ImsBasicService imsBasicService;
 200:              Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicService nokiaImsBasicService;
 201:  
 202:              if (nddOnt.Pon.Olt.Odf.Name == "SAA")
 203:              {
 204:                  /*
 205:                   * SAA:
 206:                   * Cable        MGC Primary IP  MGC Secondary
 207:                   * Cable 5        10.16.1.38        10.16.5.38
 208:                   * Cable 6        10.16.1.34        10.16.5.34
 209:                   * Cable 7        10.16.1.31        10.16.5.31
 210:                   * Cable 8        10.16.1.33        10.16.5.33
 211:                   * /
 212:  
 213:                  if (Ia.Ngn.Cl.Model.Data.Huawei.Default.ListOfHuaweiOntThatWereIntiallyInstalledAndProvisionedWithNokiaMgcIp10_16_5_37BeforeNewMgcIpToCableDistributionAgreement.Contains(nddOnt.Access.Name))
 214:                  {
 215:                      nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.5.37");
 216:                  }
 217:                  else if (nddOnt.Pon.Number >= 500 && nddOnt.Pon.Number < 600) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.1.38");
 218:                  else if (nddOnt.Pon.Number >= 600 && nddOnt.Pon.Number < 700) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.1.34");
 219:                  else if (nddOnt.Pon.Number >= 700 && nddOnt.Pon.Number < 800) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.1.31");
 220:                  else if (nddOnt.Pon.Number >= 800 && nddOnt.Pon.Number < 900) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.1.33");
 221:                  // below: fake
 222:                  else if (nddOnt.Pon.Number >= 900 && nddOnt.Pon.Number < 1000) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.1.33");
 223:                  else
 224:                  {
 225:                      throw new Exception("Huawei imsBasicService undefined for access: " + nddOnt.Access.Name + ". ");
 226:                  }
 227:              }
 228:              else if (nddOnt.Pon.Olt.Odf.Name == "SDQ")
 229:              {
 230:                  /*
 231:                   * SDQ:
 232:                   * Cable        MGC Primary IP  MGC Secondary
 233:                   * Cable 7      10.16.5.32    10.16.1.32
 234:                   * Cable 8        10.16.5.35    10.16.1.35
 235:                   * Cable 9        10.16.5.36    10.16.1.36
 236:                   * /
 237:  
 238:                  if (nddOnt.Pon.Number >= 700 && nddOnt.Pon.Number < 800) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.5.32");
 239:                  else if (nddOnt.Pon.Number >= 800 && nddOnt.Pon.Number < 900) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.5.35");
 240:                  else if (nddOnt.Pon.Number >= 900 && nddOnt.Pon.Number < 1000) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.5.36");
 241:                  else
 242:                  {
 243:                      throw new Exception("Huawei imsBasicService undefined for access: " + nddOnt.Access.Name + ". ");
 244:                  }
 245:              }
 246:              else if (nddOnt.Pon.Olt.Odf.Name == "MSF")
 247:              {
 248:                  /*
 249:                   * MSF:
 250:                   * Cable        MGC Primary IP  MGC Secondary
 251:                   * Cable 1      10.16.5.31    10.16.1.31
 252:                   * /
 253:  
 254:                  if (nddOnt.Pon.Number >= 1 && nddOnt.Pon.Number <= 256) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.5.31");
 255:                  else
 256:                  {
 257:                      throw new Exception("Huawei imsBasicService undefined for access: " + nddOnt.Access.Name + ". ");
 258:                  }
 259:              }
 260:              // else if (nddOnt.Pon.PonGroup.Olt.Odf.Name == "BYN") { }
 261:              else
 262:              {
 263:                  nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem(nddOnt.Pon.Olt.MgcIp);
 264:              }
 265:  
 266:              imsBasicService = new ImsBasicService()
 267:              {
 268:                  PrimarySwitch = nokiaImsBasicService.PrimarySwitch,
 269:                  Fsdb = nokiaImsBasicService.Fsdb,
 270:                  MgcIp = nokiaImsBasicService.MgcIp,
 271:                  MgcSecondaryIp = nokiaImsBasicService.MgcSecondaryIp,
 272:                  MgcSubnetMask = nokiaImsBasicService.MgcSubnetMask,
 273:                  Service = nokiaImsBasicService.Service
 274:              };
 275:  
 276:              return imsBasicService;
 277:          }
 278:      */
 279:   
 280:          ////////////////////////////////////////////////////////////////////////////
 281:   
 282:          /// <summary>
 283:          ///
 284:          /// </summary>
 285:          public static Ia.Ngn.Cl.Model.Business.Ims.ImsBasicService SpecialHuaweiIpHandlingForNokiaImsBasicServiceItem(Ia.Ngn.Cl.Model.Business.NetworkDesignDocument.Ont nddOnt)
 286:          {
 287:              Ia.Ngn.Cl.Model.Business.Ims.ImsBasicService imsBasicService;
 288:              Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicService nokiaImsBasicService;
 289:   
 290:              /*
 291:              if (nddOnt.Pon.PonGroup.Olt.Odf.Name == "LAB")
 292:              {
 293:                  nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.5.32");
 294:              }
 295:              else
 296:              */
 297:              if (nddOnt.Pon.PonGroup.Olt.Odf.Name == "SAA")
 298:              {
 299:                  /*
 300:                   * SAA:
 301:                   * Cable        MGC Primary IP  MGC Secondary
 302:                   * Cable 5        10.16.1.38        10.16.5.38
 303:                   * Cable 6        10.16.1.34        10.16.5.34
 304:                   * Cable 7        10.16.1.31        10.16.5.31
 305:                   * Cable 8        10.16.1.33        10.16.5.33
 306:                   */
 307:   
 308:                  if (Ia.Ngn.Cl.Model.Data.Huawei.Default.ListOfHuaweiOntThatWereIntiallyInstalledAndProvisionedWithNokiaMgcIp10_16_5_37BeforeNewMgcIpToCableDistributionAgreement.Contains(nddOnt.Access.Name))
 309:                  {
 310:                      nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.5.37");
 311:                  }
 312:                  else if (nddOnt.Pon.Number >= 500 && nddOnt.Pon.Number < 600) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.1.38");
 313:                  else if (nddOnt.Pon.Number >= 600 && nddOnt.Pon.Number < 700) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.1.34");
 314:                  else if (nddOnt.Pon.Number >= 700 && nddOnt.Pon.Number < 800) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.1.31");
 315:                  else if (nddOnt.Pon.Number >= 800 && nddOnt.Pon.Number < 900) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.1.33");
 316:                  // below: fake
 317:                  else if (nddOnt.Pon.Number >= 900 && nddOnt.Pon.Number < 1000) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.1.33");
 318:                  else
 319:                  {
 320:                      throw new Exception("Huawei imsBasicService undefined for access: " + nddOnt.Access.Name + ". ");
 321:                  }
 322:              }
 323:              else if (nddOnt.Pon.PonGroup.Olt.Odf.Name == "SDQ")
 324:              {
 325:                  /*
 326:                   * SDQ:
 327:                   * Cable        MGC Primary IP  MGC Secondary
 328:                   * Cable 7      10.16.5.32    10.16.1.32
 329:                   * Cable 8        10.16.5.35    10.16.1.35
 330:                   * Cable 9        10.16.5.36    10.16.1.36
 331:                   */
 332:   
 333:                  if (nddOnt.Pon.Number >= 700 && nddOnt.Pon.Number < 800) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.5.32");
 334:                  else if (nddOnt.Pon.Number >= 800 && nddOnt.Pon.Number < 900) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.5.35");
 335:                  else if (nddOnt.Pon.Number >= 900 && nddOnt.Pon.Number < 1000) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.5.36");
 336:                  else
 337:                  {
 338:                      throw new Exception("Huawei imsBasicService undefined for access: " + nddOnt.Access.Name + ". ");
 339:                  }
 340:              }
 341:              /*
 342:              else if (nddOnt.Pon.PonGroup.Olt.Odf.Name == "MSF")
 343:              {
 344:                  // MSF:
 345:                  // Cable        MGC Primary IP  MGC Secondary
 346:                  // Cable 1      10.16.5.31    10.16.1.31
 347:  
 348:                  if (nddOnt.Pon.Number >= 1 && nddOnt.Pon.Number <= 256) nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem("10.16.5.31");
 349:                  else
 350:                  {
 351:                      throw new Exception("Huawei imsBasicService undefined for access: " + nddOnt.Access.Name + ". ");
 352:                  }
 353:              }
 354:              else if (nddOnt.Pon.PonGroup.Olt.Odf.Name == "BYN") 
 355:              { 
 356:              }
 357:              */
 358:              else
 359:              {
 360:                  nokiaImsBasicService = Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicServiceItem(nddOnt.Pon.PonGroup.MgcIp);
 361:   
 362:                  if (nokiaImsBasicService == null)
 363:                  {
 364:                      /*
 365:                  // below: I think service and fsdb here are meaningless but service must remain unique
 366:                  new ImsBasicService { MgcIp="10.16.1.142", MgcSecondaryIp="10.16.5.142", MgcSubnetMask="255.255.224.0",Service=0,Fsdb=string.Empty,PrimarySwitch=TEC },
 367:  
 368:                  // below: maybe should not be here. service must remain unique
 369:                  new ImsBasicService { MgcIp="10.10.9.254", MgcSecondaryIp="10.10.1.254", MgcSubnetMask="255.255.224.0",Service=0,Fsdb=string.Empty,PrimarySwitch=TEC }, 
 370:  
 371:  
 372:                  // below: I think service and fsdb here are meaningless but service must remain unique
 373:                  new ImsBasicService { MgcIp="10.16.5.142", MgcSecondaryIp="10.16.1.142", MgcSubnetMask="255.255.224.0",Service=0,Fsdb=string.Empty,PrimarySwitch=SKB },
 374:  
 375:                  // below: maybe should not be here. service must remain unique
 376:                  new ImsBasicService { MgcIp="10.10.1.254", MgcSecondaryIp="10.10.9.254", MgcSubnetMask="255.255.224.0",Service=0,Fsdb=string.Empty,PrimarySwitch=SKB },
 377:                       */
 378:   
 379:                      if (nddOnt.Pon.PonGroup.MgcIp == "10.16.1.142")
 380:                      {
 381:                          nokiaImsBasicService = new Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicService { MgcIp = "10.16.1.142", MgcSecondaryIp = "10.16.5.142", MgcSubnetMask = "255.255.224.0", Service = 0, Fsdb = string.Empty, PrimarySwitch = Ia.Ngn.Cl.Model.Business.Nokia.Ims.TEC };
 382:                      }
 383:                      else if (nddOnt.Pon.PonGroup.MgcIp == "10.16.5.142")
 384:                      {
 385:                          nokiaImsBasicService = new Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicService { MgcIp = "10.16.5.142", MgcSecondaryIp = "10.16.1.142", MgcSubnetMask = "255.255.224.0", Service = 0, Fsdb = string.Empty, PrimarySwitch = Ia.Ngn.Cl.Model.Business.Nokia.Ims.SKB };
 386:                      }
 387:                      else if (nddOnt.Pon.PonGroup.MgcIp == "10.10.9.254")
 388:                      {
 389:                          nokiaImsBasicService = new Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicService { MgcIp = "10.10.9.254", MgcSecondaryIp = "10.10.1.254", MgcSubnetMask = "255.255.224.0", Service = 0, Fsdb = string.Empty, PrimarySwitch = Ia.Ngn.Cl.Model.Business.Nokia.Ims.TEC };
 390:                      }
 391:                      else if (nddOnt.Pon.PonGroup.MgcIp == "10.10.1.254")
 392:                      {
 393:                          nokiaImsBasicService = new Ia.Ngn.Cl.Model.Business.Nokia.Ims.ImsBasicService { MgcIp = "10.10.1.254", MgcSecondaryIp = "10.10.9.254", MgcSubnetMask = "255.255.224.0", Service = 0, Fsdb = string.Empty, PrimarySwitch = Ia.Ngn.Cl.Model.Business.Nokia.Ims.SKB };
 394:                      }
 395:   
 396:   
 397:                      // Use fixed random to assign fsdb values from fsdb0-fsdb3 randomly to passed area with nddOnt
 398:   
 399:                      switch (Ia.Cl.Model.Default.AlphanumericStringToInt(nddOnt.Pon.PonGroup.Symbol) % 4)
 400:                      {
 401:                          case 0: nokiaImsBasicService.Fsdb = "fsdb0"; break;
 402:                          case 1: nokiaImsBasicService.Fsdb = "fsdb1"; break;
 403:                          case 2: nokiaImsBasicService.Fsdb = "fsdb2"; break;
 404:                          case 3: nokiaImsBasicService.Fsdb = "fsdb3"; break;
 405:                          default: nokiaImsBasicService.Fsdb = "fsdb0"; break;
 406:                      }
 407:   
 408:                      nokiaImsBasicService.Fsdb = "fsdb0";
 409:                  }
 410:              }
 411:   
 412:              imsBasicService = new ImsBasicService()
 413:              {
 414:                  PrimarySwitch = nokiaImsBasicService.PrimarySwitch,
 415:                  Fsdb = nokiaImsBasicService.Fsdb,
 416:                  MgcIp = nokiaImsBasicService.MgcIp,
 417:                  MgcSecondaryIp = nokiaImsBasicService.MgcSecondaryIp,
 418:                  MgcSubnetMask = nokiaImsBasicService.MgcSubnetMask,
 419:                  Service = nokiaImsBasicService.Service
 420:              };
 421:   
 422:              return imsBasicService;
 423:          }
 424:   
 425:          ////////////////////////////////////////////////////////////////////////////
 426:          ////////////////////////////////////////////////////////////////////////////
 427:      }
 428:   
 429:      ////////////////////////////////////////////////////////////////////////////
 430:      ////////////////////////////////////////////////////////////////////////////
 431:  }