The class responsible for output (HTML) compression.
Enabling compression doesn't really help much. YetaWF generates fairly compact HTML so savings are typically just 1-10%. This code does JavaScript compression and eliminates excessive spacing (line " ", \r,\n), while preserving formatting in <textarea>, <pre> and <script> tags.
Namespace: YetaWF.Core.ResponseFilter
Assembly: YetaWF.Core
Inheritance
public class WhiteSpaceResponseFilter : System.IO.MemoryStream;
This class cannot be instantiated.
CanRead | Gets a value indicating whether the current stream supports reading. | |
CanSeek | Gets a value indicating whether the current stream supports seeking. | |
CanTimeout | Gets a value that determines whether the current stream can time out. | |
CanWrite | Gets a value indicating whether the current stream supports writing. | |
Capacity | Gets or sets the number of bytes allocated for this stream. | |
Length | Gets the length of the stream in bytes. | |
Position | Gets or sets the current position within the stream. | |
ReadTimeout | Gets or sets a value, in milliseconds, that determines how long the stream will attempt to read before timing out. | |
WriteTimeout | Gets or sets a value, in milliseconds, that determines how long the stream will attempt to write before timing out. |
Null | A Stream with no backing store. |
BeginRead | Begins an asynchronous read operation. (Consider using Int32) instead.) | |
BeginWrite | Begins an asynchronous write operation. (Consider using Int32) instead.) | |
Close | Closes the current stream and releases any resources (such as sockets and file handles) associated with the current stream. Instead of calling this method, ensure that the stream is properly disposed. | |
Compress | Compresses the HTML input buffer which is normally the complete page. | |
CopyTo | Reads the bytes from the current stream and writes them to another stream. | |
CopyToAsync | Asynchronously reads the bytes from the current stream and writes them to another stream. | |
CreateWaitHandle | Allocates a WaitHandle object. | |
Dispose | Releases all resources used by the Stream. | |
DisposeAsync | Asynchronously releases the unmanaged resources used by the Stream. | |
EndRead | Waits for the pending asynchronous read to complete. (Consider using Int32) instead.) | |
EndWrite | Ends an asynchronous write operation. (Consider using Int32) instead.) | |
EnsureAsyncActiveSemaphoreInitialized | (not specified) | |
Equals | Determines whether the specified object is equal to the current object. | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. | |
Flush | Overrides the Flush method so that no action is performed. | |
FlushAsync | Asynchronously clears all buffers for this stream and causes any buffered data to be written to the underlying device. | |
GetBuffer | Returns the array of unsigned bytes from which this stream was created. | |
GetHashCode | Serves as the default hash function. | |
GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. | |
GetType | Gets the Type of the current instance. | |
InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. | |
MemberwiseClone | Creates a shallow copy of the current Object. | |
ObjectInvariant | Provides support for a Contract. | |
Read | Reads a block of bytes from the current stream and writes the data to a buffer. | |
ReadAsync | Asynchronously reads a sequence of bytes from the current stream, advances the position within the stream by the number of bytes read, and monitors cancellation requests. | |
ReadByte | Reads a byte from the current stream. | |
ReferenceEquals | Determines whether the specified Object instances are the same instance. | |
Seek | Sets the position within the current stream to the specified value. | |
SetLength | Sets the length of the current stream to the specified value. | |
Synchronized | Creates a thread-safe (synchronized) wrapper around the specified Stream object. | |
ToArray | Writes the stream contents to a byte array, regardless of the Position property. | |
ToString | Returns a string that represents the current object. | |
TryGetBuffer | Returns the array of unsigned bytes from which this stream was created. The return value indicates whether the conversion succeeded. | |
ValidateBufferArguments | Validates arguments provided to reading and writing methods on Stream. | |
ValidateCopyToArguments | Validates arguments provided to the Int32) or CancellationToken) methods. | |
Write | Writes a block of bytes to the current stream using data read from a buffer. | |
WriteAsync | Asynchronously writes a sequence of bytes to the current stream, advances the current position within this stream by the number of bytes written, and monitors cancellation requests. | |
WriteByte | Writes a byte to the current stream at the current position. | |
WriteTo | Writes the entire contents of this memory stream to another stream. |
See Also YetaWF.Core Overview
Documentation Feedback
© 2024 - Softel vdm, Inc. - YetaWF.com