Beispiel #1
0
        public ServiceBase(string name, ServiceCreationInfo info)
        {
            if (name == null || name.Length == 0)
            {
                throw new ArgumentException("Missing name on service");
            }

            mName = name;
        }
Beispiel #2
0
        public ServiceBase(ServiceCreationInfo info)
        {
            string name;

            try
            {
                name = info.Configuration.Name;
            }
            catch (RuntimeBinderException)
            {
                throw new ArgumentException("Missing name of service");
            }

            if (name.Length == 0)
            {
                throw new ArgumentException("Missing name on service");
            }

            mName = name;
        }
 public DeviceManagerService(ServiceCreationInfo info)
     : base("device", info)
 {
     mDeviceManager = info.DeviceManager;
 }