)>}]
شركة التطبيقات المتكاملة لتصميم وبرمجة البرمجيات الخاصة ش.ش.و.
Integrated Applications Programming Company
Home » Code Library » Service2 (Ia.Ftn.Cl.Models.Ui)

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

Service class for Fixed Telecommunications Network (FTN) UI model.

    1: using System;
    2: using System.Runtime.Serialization;
    3: using System.Text;
    4:  
    5: namespace Ia.Ftn.Cl.Models.Ui
    6: {
    7:     ////////////////////////////////////////////////////////////////////////////
    8:  
    9:     /// <summary publish="true">
   10:     /// Service class for Fixed Telecommunications Network (FTN) UI model.
   11:     /// </summary>
   12:     /// 
   13:     /// <remarks> 
   14:     /// Copyright © 2006-2017 Jasem Y. Al-Shamlan (info@ia.com.kw), Integrated Applications - Kuwait. All Rights Reserved.
   15:     /// </remarks> 
   16:     [DataContract(IsReference = true, Namespace = "kw.com.ia.ftn.api", Name = "apiService")]
   17:     public class Service2
   18:     {
   19:         ////////////////////////////////////////////////////////////////////////////
   20:  
   21:         /// <summary>
   22:         ///
   23:         /// </summary>
   24:         public Service2()
   25:         {
   26:         }
   27:  
   28:         ////////////////////////////////////////////////////////////////////////////
   29:  
   30:         /// <summary>
   31:         /// Constructure will take in a Service type object and will copy its values to the new Ui.Service object.
   32:         /// </summary>
   33:         public Service2(Ia.Ftn.Cl.Models.Service2 service)
   34:         {
   35:             this.AbbriviatedCalling = service.AbbriviatedCalling;
   36:             this.AlarmCall = service.AlarmCall;
   37:             this.CallBarring = service.CallBarring;
   38:             this.CallerId = service.CallerId;
   39:             this.CallForwarding = service.CallForwarding;
   40:             this.CallWaiting = service.CallWaiting;
   41:             this.ConferenceCall = service.ConferenceCall;
   42:             this.Created = service.Created;
   43:             this.InternationalCalling = service.InternationalCalling;
   44:             this.InternationalCallingUserControlled = service.InternationalCallingUserControlled;
   45:             this.Port = service.Port;
   46:             this.Pin = service.Pin;
   47:             this.Service = service.Service;
   48:             this.ServiceSuspension = service.ServiceSuspension;
   49:             this.ServiceTypeName = service.ServiceType.ToString();
   50:             this.Updated = service.Updated;
   51:         }
   52:  
   53:         ////////////////////////////////////////////////////////////////////////////
   54:  
   55:         /// <summary>
   56:         ///
   57:         /// </summary>
   58:         [DataMember(Name = "id")]
   59:         public string Id { get; set; }
   60:  
   61:         ////////////////////////////////////////////////////////////////////////////
   62:  
   63:         /// <summary>
   64:         ///
   65:         /// </summary>
   66:         [DataMember(Name = "service")]
   67:         public string Service { get; set; }
   68:  
   69:         ////////////////////////////////////////////////////////////////////////////
   70:  
   71:         /// <summary>
   72:         ///
   73:         /// </summary>
   74:         [DataMember(Name = "serviceType")]
   75:         public int ServiceType { get; set; }
   76:  
   77:         ////////////////////////////////////////////////////////////////////////////
   78:  
   79:         /// <summary>
   80:         ///
   81:         /// </summary>
   82:         [DataMember(Name = "serviceTypeName")]
   83:         public string ServiceTypeName { get; set; }
   84:  
   85:         ////////////////////////////////////////////////////////////////////////////
   86:  
   87:         /// <summary>
   88:         ///
   89:         /// </summary>
   90:         [DataMember(Name = "callWaiting")]
   91:         public bool CallWaiting { get; set; }
   92:  
   93:         ////////////////////////////////////////////////////////////////////////////
   94:  
   95:         /// <summary>
   96:         ///
   97:         /// </summary>
   98:         [DataMember(Name = "callForwarding")]
   99:         public bool CallForwarding { get; set; }
  100:  
  101:         ////////////////////////////////////////////////////////////////////////////
  102:  
  103:         /// <summary>
  104:         ///
  105:         /// </summary>
  106:         [DataMember(Name = "alarmCall")]
  107:         public bool AlarmCall { get; set; }
  108:  
  109:         ////////////////////////////////////////////////////////////////////////////
  110:  
  111:         /// <summary>
  112:         ///
  113:         /// </summary>
  114:         [DataMember(Name = "internationalCallingUserControlled")]
  115:         public bool InternationalCallingUserControlled { get; set; }
  116:  
  117:         ////////////////////////////////////////////////////////////////////////////
  118:  
  119:         /// <summary>
  120:         ///
  121:         /// </summary>
  122:         [DataMember(Name = "internationalCalling")]
  123:         public bool InternationalCalling { get; set; }
  124:  
  125:         ////////////////////////////////////////////////////////////////////////////
  126:  
  127:         /// <summary>
  128:         ///
  129:         /// </summary>
  130:         [DataMember(Name = "callerId")]
  131:         public bool CallerId { get; set; }
  132:  
  133:         ////////////////////////////////////////////////////////////////////////////
  134:  
  135:         /// <summary>
  136:         ///
  137:         /// </summary>
  138:         [DataMember(Name = "conferenceCall")]
  139:         public bool ConferenceCall { get; set; }
  140:  
  141:         ////////////////////////////////////////////////////////////////////////////
  142:  
  143:         /// <summary>
  144:         ///
  145:         /// </summary>
  146:         [DataMember(Name = "callBarring")]
  147:         public bool CallBarring { get; set; }
  148:  
  149:         ////////////////////////////////////////////////////////////////////////////
  150:  
  151:         /// <summary>
  152:         ///
  153:         /// </summary>
  154:         [DataMember(Name = "serviceSuspension")]
  155:         public bool ServiceSuspension { get; set; }
  156:  
  157:         ////////////////////////////////////////////////////////////////////////////
  158:  
  159:         /// <summary>
  160:         ///
  161:         /// </summary>
  162:         [DataMember(Name = "abbriviatedCalling")]
  163:         public bool AbbriviatedCalling { get; set; }
  164:  
  165:         ////////////////////////////////////////////////////////////////////////////
  166:  
  167:         /// <summary>
  168:         ///
  169:         /// </summary>
  170:         [DataMember(Name = "pin")]
  171:         public int Pin { get; set; }
  172:  
  173:         ////////////////////////////////////////////////////////////////////////////
  174:  
  175:         /// <summary>
  176:         ///
  177:         /// </summary>
  178:         [DataMember(Name = "port")]
  179:         public int Port { get; set; }
  180:  
  181:         ////////////////////////////////////////////////////////////////////////////
  182:  
  183:         /// <summary>
  184:         ///
  185:         /// </summary>
  186:         [DataMember(Name = "accessId")]
  187:         public string AccessId { get; set; }
  188:  
  189:         ////////////////////////////////////////////////////////////////////////////
  190:  
  191:         /// <summary>
  192:         ///
  193:         /// </summary>
  194:         [DataMember(Name = "accessName")]
  195:         public string AccessName
  196:         {
  197:             get
  198:             {
  199:                 return Ia.Ftn.Cl.Models.Business.Access.Name(this.AccessId);
  200:             }
  201:         }
  202:  
  203:         ////////////////////////////////////////////////////////////////////////////
  204:  
  205:         /// <summary>
  206:         ///
  207:         /// </summary>
  208:         [DataMember(Name = "created")]
  209:         public DateTime Created { get; set; }
  210:  
  211:         ////////////////////////////////////////////////////////////////////////////
  212:  
  213:         /// <summary>
  214:         ///
  215:         /// </summary>
  216:         [DataMember(Name = "updated")]
  217:         public DateTime Updated { get; set; }
  218:  
  219:         ////////////////////////////////////////////////////////////////////////////
  220:         ////////////////////////////////////////////////////////////////////////////
  221:  
  222:         /// <summary>
  223:         ///
  224:         /// </summary>
  225:         public string ToSimpleTextString()
  226:         {
  227:             StringBuilder sb;
  228:  
  229:             sb = new StringBuilder();
  230:  
  231:             sb.AppendLine("Service: " + this.Service);
  232:             sb.AppendLine("ServiceType: " + Ia.Ftn.Cl.Models.Data.Service.ServiceType(this.ServiceType).NameArabicName);
  233:             sb.AppendLine("AccessName: " + this.AccessName);
  234:             sb.AppendLine("Port: " + this.Port);
  235:             sb.AppendLine("CallerId: " + Ia.Cl.Models.Default.YesNoText(this.CallerId));
  236:             sb.AppendLine("CallForwarding: " + Ia.Cl.Models.Default.YesNoText(this.CallForwarding));
  237:             sb.AppendLine("CallWaiting: " + Ia.Cl.Models.Default.YesNoText(this.CallWaiting));
  238:             sb.AppendLine("ConferenceCall: " + Ia.Cl.Models.Default.YesNoText(this.ConferenceCall));
  239:             sb.AppendLine("AbbriviatedCalling: " + Ia.Cl.Models.Default.YesNoText(this.AbbriviatedCalling));
  240:             sb.AppendLine("AlarmCall: " + Ia.Cl.Models.Default.YesNoText(this.AlarmCall));
  241:             sb.AppendLine("CallBarring: " + Ia.Cl.Models.Default.YesNoText(this.CallBarring));
  242:             sb.AppendLine("InternationalCalling: " + Ia.Cl.Models.Default.YesNoText(this.InternationalCalling));
  243:             sb.AppendLine("InternationalCallingUserControlled: " + Ia.Cl.Models.Default.YesNoText(this.InternationalCallingUserControlled));
  244:             sb.AppendLine("ServiceSuspension: " + Ia.Cl.Models.Default.YesNoText(this.ServiceSuspension));
  245:  
  246:             return sb.ToString();
  247:         }
  248:  
  249:         ////////////////////////////////////////////////////////////////////////////
  250:         ////////////////////////////////////////////////////////////////////////////
  251:     }
  252:  
  253:     ////////////////////////////////////////////////////////////////////////////
  254:     ////////////////////////////////////////////////////////////////////////////
  255: }