示例#1
0
        private void InitServiceCreator(BcatServiceType type, string name, AccessControl accessControl)
        {
            lock (_bcatServiceInitLocker)
            {
                Debug.Assert((uint)type < ServiceTypeCount);

                ServiceCreators[(int)type] = new ServiceCreator(this, name, accessControl);
            }
        }
示例#2
0
        private void InitBcatService(BcatServiceType type, string name, AccessControl accessControl)
        {
            InitServiceCreator(type, name, accessControl);

            IServiceCreator service = GetServiceCreator(type);

            Result rc = Hos.Sm.RegisterService(new BcatServiceObject(service), name);

            if (rc.IsFailure())
            {
                throw new HorizonResultException(rc, "Abort");
            }
        }
示例#3
0
        private IServiceCreator GetServiceCreator(BcatServiceType type)
        {
            Debug.Assert((uint)type < ServiceTypeCount);

            return(ServiceCreators[(int)type]);
        }