예제 #1
0
        protected override void OnDispose()
        {
            base.OnDispose();

            ChangeOperationalState(OperationalStateEnum.Disposed);

            _newsManager.Dispose();
            _newsManager = null;
        }
        protected override void OnDispose()
        {
            base.OnDispose();

            ChangeOperationalState(OperationalStateEnum.Disposed);

            _newsManager.Dispose();
            _newsManager = null;
        }
예제 #3
0
        protected override bool OnInitialize(Platform platform)
        {
            if (base.OnInitialize(platform) == false)
            {
                return(false);
            }

            if (_newsManager == null)
            {// Only executed after NO serialization has been done and this is a first component run.
                _newsManager = new PlatformNewsManager();
            }

            GeneralHelper.FireAndForget(delegate()
            {
                _newsManager.Initialize(platform);
            });

            ChangeOperationalState(OperationalStateEnum.Operational);
            return(true);
        }
예제 #4
0
 /// <summary>
 ///
 /// </summary>
 public PlatformNews(SerializationInfo info, StreamingContext context)
     : base(info, context)
 {
     _newsManager = (PlatformNewsManager)info.GetValue("platformNewsManager", typeof(PlatformNewsManager));
 }
        protected override bool OnInitialize(Platform platform)
        {
            if (base.OnInitialize(platform) == false)
            {
                return false;
            }

            if (_newsManager == null)
            {// Only executed after NO serialization has been done and this is a first component run.
                _newsManager = new PlatformNewsManager();
            }

            GeneralHelper.FireAndForget(delegate()
            {
                _newsManager.Initialize(platform);
            });

            ChangeOperationalState(OperationalStateEnum.Operational);
            return true;
        }
 /// <summary>
 /// Deserialization constructor.
 /// </summary>
 public PlatformNews(SerializationInfo info, StreamingContext context)
     : base(info, context)
 {
     _newsManager = (PlatformNewsManager)info.GetValue("platformNewsManager", typeof(PlatformNewsManager));
 }