Esempio n. 1
0
            /// <summary>
            /// Report that this connection is finished, and the reason.
            /// </summary>
            internal void FinishConnection(CompletionReason completionReason)
            {
                Log("Connection finishing with reason {0}.", completionReason);

                // Close the pipe, we're done with it.
                pipeStream.Close();
                this.isFinished = true;
            }
Esempio n. 2
0
 public void ConnectionCompleted(CompletionReason reason)
 {
     ConnectionCompletedCollection.Add(reason);
     CompletedCount++;
     if (reason == CompletionReason.ClientDisconnect || reason == CompletionReason.ClientException)
     {
         HasDetectedBadConnection = true;
     }
     LastProcessedTime = DateTime.Now;
 }
Esempio n. 3
0
 internal CompletionData(
     CompletionReason reason,
     TimeSpan?newKeepAlive  = null,
     bool shutdownRequested = false
     )
 {
     Reason          = reason;
     NewKeepAlive    = newKeepAlive;
     ShutdownRequest = shutdownRequested;
 }
Esempio n. 4
0
        private string GetCompletionType(int type)
        {
            CompletionReason rsn = (CompletionReason)type;

            switch (rsn)
            {
            case CompletionReason.SuspendedManually:
            case CompletionReason.SuspendedAutomatically:
                return(LocRM.GetString("Suspended"));

            case CompletionReason.CompletedManually:
                return(LocRM.GetString("CompletedByManager"));

            case CompletionReason.CompletedAutomatically:
                return(LocRM.GetString("CompletedByResource"));

            case CompletionReason.NotCompleted:
                return(LocRM.GetString("NotCompleted"));
            }
            return("");
        }
Esempio n. 5
0
        private static IClientConnection CreateClientConnection(CompletionReason completionReason, TimeSpan?keepAlive = null)
        {
            var task = Task.FromResult(new ConnectionData(completionReason, keepAlive));

            return(CreateClientConnection(task));
        }
Esempio n. 6
0
 public ConnectionData(CompletionReason completionReason, TimeSpan? keepAlive = null)
 {
     CompletionReason = completionReason;
     KeepAlive = keepAlive;
 }
Esempio n. 7
0
 public void ConnectionCompleted(CompletionReason reason)
 {
 }
            /// <summary>
            /// Report that this connection is finished, and the reason.
            /// </summary>
            internal void FinishConnection(CompletionReason completionReason)
            {
                Log("Connection finishing with reason {0}.", completionReason);

                // Close the pipe, we're done with it.
                pipeStream.Close();
                this.isFinished = true;
            }
 public ConnectionData(CompletionReason completionReason, TimeSpan?keepAlive = null)
 {
     CompletionReason = completionReason;
     KeepAlive        = keepAlive;
 }
        private static RazorCompletionContext CreateRazorCompletionContext(RazorSyntaxTree syntaxTree, CompletionReason reason = CompletionReason.Invoked)
        {
            var tagHelperDocumentContext = TagHelperDocumentContext.Create(prefix: string.Empty, Array.Empty <TagHelperDescriptor>());

            return(new RazorCompletionContext(syntaxTree, tagHelperDocumentContext, reason));
        }
Esempio n. 11
0
 private void SpeakCompleted(CompletionReason reason)
 {
 }
Esempio n. 12
0
 public RetrieverDoneArgs(Retriever retriever) : base(retriever)
 {
     this.reason = CompletionReason.Completed;
 }