Exemple #1
0
 /// <summary>
 /// short string of the service
 /// </summary>
 /// <param name="swi">the service ID</param>
 public static string ShortString(this ServiceIDs swi)
 {
     lock (locker)
     {
         if (!shortNames.ContainsKey(swi))
         {
             shortNames.Add(swi, swi.ToString()
                            .Replace("INTERNAL", "Int")
                            .Replace("EXTERNAL", "Ext")
                            .Replace("MANAGER", "Mgr")
                            .Replace("SERVICE", "Serv")
                            .Replace("SYSTEM", "Sys"));
         }
         return(shortNames[swi]);
     }
 }
Exemple #2
0
 /// <summary>
 /// string convertion of service ID
 /// </summary>
 /// <param name="swi">the service ID</param>
 /// <returns>the string of the service ID</returns>
 public static string ServiceID(this ServiceIDs swi)
 {
     return("SER_" + swi.ToString());
 }