コード例 #1
0
ファイル: Entity.cs プロジェクト: ratiel/Vindictus
 public string ReportOperationTimeReport(EntityGraphIdentifier target)
 {
     if (target.isNull)
     {
         return(OperationTimeReportElement.ReportString(this.OperationTimeReport));
     }
     if (target.isNumeric)
     {
         return("");
     }
     foreach (IEntityProxy entityProxy in this.Callees)
     {
         EntityConnection entityConnection = (EntityConnection)entityProxy;
         if (entityConnection.RemoteCategory == target.category && entityConnection.RemoteID == target.entityID)
         {
             return(entityConnection.OperationReport());
         }
     }
     foreach (IEntityAdapter entityAdapter in this.Callers)
     {
         EntityConnection entityConnection2 = (EntityConnection)entityAdapter;
         if (entityConnection2.RemoteCategory == target.category && entityConnection2.RemoteID == target.entityID)
         {
             return(entityConnection2.OperationReport());
         }
     }
     return("");
 }
コード例 #2
0
 private void Proxy_ProcessorDisposed(OperationProxy proxy)
 {
     if (OperationProxy.IsTimeReportEnabled)
     {
         string text = proxy.RecentOperationName;
         if (text != "")
         {
             if (proxy.IsRequesting)
             {
                 text += "\tout";
             }
             else
             {
                 text += "\tin";
             }
             OperationTimeReportElement operationTimeReportElement;
             if (!this.OperationTimeReport.TryGetValue(text, out operationTimeReportElement))
             {
                 operationTimeReportElement = new OperationTimeReportElement();
             }
             operationTimeReportElement.Add(proxy.TimerResult);
             this.OperationTimeReport[text] = operationTimeReportElement;
         }
     }
     if (this.Proxy != null)
     {
         this.Proxy.Dispose();
         this.Proxy = null;
     }
     if (this.State == EntityConnection.ConnectionState.OutOfEntity)
     {
         this.DoClose();
         return;
     }
     if (this.OperationQueue.Count > 0)
     {
         this.RequestOperation(this.OperationQueue.Dequeue());
         return;
     }
     if (this.IsClosing)
     {
         if (this.State == EntityConnection.ConnectionState.Bound)
         {
             this.SendMessage(new RequestClose());
             return;
         }
         this.DoClose();
     }
 }
コード例 #3
0
ファイル: Service.cs プロジェクト: ratiel/Vindictus
        public override string ReportOperationTimeReport(EntityGraphIdentifier p, EntityGraphIdentifier q)
        {
            IEntityGraphNode node = this.GetNode(p);

            if (node == EntityGraphNode.NullNode)
            {
                return("");
            }
            if (node is Entity)
            {
                Entity entity = node as Entity;
                Log <Service> .Logger.Debug("Found Entity : Request TimeReport");

                return(entity.ReportOperationTimeReport(q));
            }
            return(OperationTimeReportElement.ReportString(this.OperationTimeReport));
        }
コード例 #4
0
 public string OperationReport()
 {
     return(OperationTimeReportElement.ReportString(this.OperationTimeReport));
 }