• Product Bundles

    DevCraft

    All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:

    • NEW: Design Kits for Figma
    • Online Training
    • Document Processing Library
    • Embedded Reporting for web and desktop
    Web
    Kendo UI UI for jQuery UI for Angular UI for React UI for Vue UI for ASP.NET AJAX UI for ASP.NET MVC UI for ASP.NET Core UI for Blazor UI for Silverlight UI for PHP UI for JSP
    Mobile
    UI for .NET MAUI UI for Xamarin
    Document Management
    Telerik Document Processing
    Desktop
    UI for .NET MAUI UI for WinUI UI for WinForms UI for WPF UI for UWP
    Reporting & Mocking
    Telerik Reporting Telerik Report Server Telerik JustMock
    Automated Testing
    Test Studio Test Studio Dev Edition
    CMS
    Sitefinity
    UI/UX Design
    Unite UX
    Debugging
    Fiddler Fiddler Everywhere Fiddler Classic Fiddler Jam FiddlerCap FiddlerCore
    Extended Reality
    UI for Unity XR
    Free Tools
    JustAssembly JustDecompile VB.NET to C# Converter Testing Framework
    View all products
  • Overview
    • jQuery
    • Angular
    • React
    • Vue
  • Demos
    • What's New
    • Roadmap
    • Release History
  • Docs & Support
  • Pricing
  • Search
  • Shopping cart
    • Account Overview
    • Your Licenses
    • Support Center
    • Forum Profile
    • Payment Methods
    • Edit Profile
    • Log out
  • Login
  • Contact Us
  • Try now

Class WebSocket

The WebSocket class represents a "tunnel" through which WebSocket messages flow. The class' messages may be deserialized from a SAZ file.

Inheritance
System.Object
BaseTunnel
WebSocket
Inherited Members
BaseTunnel.CloseTunnelAsync()
BaseTunnel.MarkClosed()
BaseTunnel.MarkOpened()
BaseTunnel.IsOpen
Namespace: Fiddler
Assembly: FiddlerCore.dll

Syntax

public class WebSocket : BaseTunnel, ITunnel

Constructors

WebSocket(Session, ClientPipe, ServerPipe)

Creates a WebSocket tunnel. External callers instead use the CreateTunnel static method.

Declaration
public WebSocket(Session oSess, ClientPipe oFrom, ServerPipe oTo)
Parameters
Session oSess

The session for which this tunnel was initially created.

ClientPipe oFrom

The client pipe

ServerPipe oTo

The server pipe

Fields

listMessages

Gets the list of captured WebSocket messages

Declaration
public List<WebSocketMessage> listMessages
Field Value
System.Collections.Generic.List<WebSocketMessage>

WebsocketMessageEncodingRegex

Used to check if there is encoding applied to a WebSocket connection by matching text in response headers

Declaration
public static readonly string WebsocketMessageEncodingRegex
Field Value
System.String

Properties

EgressByteCount

Returns number of bytes sent from the Client to the Server on this WebSocket

Declaration
public override long EgressByteCount { get; protected set; }
Property Value
System.Int64

Overrides
BaseTunnel.EgressByteCount

IngressByteCount

Returns number of bytes sent from the Server to the Client on this WebSocket

Declaration
public override long IngressByteCount { get; protected set; }
Property Value
System.Int64

Overrides
BaseTunnel.IngressByteCount

MessageCount

Gets the number of captured WebSocket messages currently

Declaration
public int MessageCount { get; }
Property Value
System.Int32

Methods

DoCloseTunnelAsync()

Interface Method Close the WebSocket and signal the event to let its service thread die. Also called by oSession.Abort() WARNING: This should not be allowed to throw any exceptions, because it will do so on threads that don't catch them, and this will kill the application.

Declaration
public override Task DoCloseTunnelAsync()
Returns
System.Threading.Tasks.Task

Overrides
BaseTunnel.DoCloseTunnelAsync()

StartReceiveFromClient()

Called when we have received data from the local client.

Declaration
protected Task StartReceiveFromClient()
Returns
System.Threading.Tasks.Task

StartReceiveFromServer()

Called when we have received data from the remote host. Incoming data will immediately be forwarded to the local client.

Declaration
protected Task StartReceiveFromServer()
Returns
System.Threading.Tasks.Task

ToString()

Declaration
public override string ToString()
Returns
System.String

Getting Started
  • Try Now
Community
  • Forums
  • Blogs
  • Feedback Portal

Copyright © 2019 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.

Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.