示例#1
0
        public void SetResultError()
        {
            var collectResultFactory = new CollectResultFactory();
            var collectResult        = collectResultFactory.CreateCollectResult(CollectStatus.Error, null);

            this.Result = collectResult;
        }
示例#2
0
        /// <summary>
        /// Build the SystemCharacteristics for this collectRequest.
        /// It is necessary because the SystemCharacteristics, in this case,
        /// must be a merge of results of the all probeExecutions.
        /// The systemCharacteristics, must be have all the object collected by all probes.
        /// </summary>
        private void BuildSystemCharacteristics(IDocumentSession session)
        {
            var systemCharacteristics = this.GetCompleteSystemCharacteristics(session);
            var collectResultFactory  = new CollectResultFactory();

            if (systemCharacteristics != null)
            {
                var systemCharacteristicsInXML = systemCharacteristics.GetSystemCharacteristicsXML();
                var result = collectResultFactory.CreateCollectResult(CollectStatus.Partial, systemCharacteristicsInXML);

                //result.CollectRequestId = Oid;
                //if (Results.Count() > 0)
                //    Results.Remove(Result);

                Result = result;
                session.SaveChanges();
            }
        }
示例#3
0
        /// <summary>
        /// Build the SystemCharacteristics for this collectRequest.
        /// It is necessary because the SystemCharacteristics, in this case,
        /// must be a merge of results of the all probeExecutions.
        /// The systemCharacteristics, must be have all the object collected by all probes.
        /// </summary>
        private void BuildSystemCharacteristics(IDocumentSession session)
        {
            var systemCharacteristics = this.GetCompleteSystemCharacteristics(session);
            var collectResultFactory = new CollectResultFactory();

            if (systemCharacteristics != null)
            {               
                var systemCharacteristicsInXML = systemCharacteristics.GetSystemCharacteristicsXML();
                var result = collectResultFactory.CreateCollectResult(CollectStatus.Partial, systemCharacteristicsInXML);

                //result.CollectRequestId = Oid;
                //if (Results.Count() > 0)
                //    Results.Remove(Result);

                Result = result;
                session.SaveChanges();
            }           
        }
示例#4
0
 public void SetResultError()
 {
     var collectResultFactory = new CollectResultFactory();
     var collectResult = collectResultFactory.CreateCollectResult(CollectStatus.Error, null);
     this.Result = collectResult;
 }