This document now exists on the official ASP.NET core docs page.
- Application
- Request Handling
| var parser = document.createElement('a'); | |
| parser.href = "http://example.com:3000/pathname/?search=test#hash"; | |
| parser.protocol; // => "http:" | |
| parser.hostname; // => "example.com" | |
| parser.port; // => "3000" | |
| parser.pathname; // => "/pathname/" | |
| parser.search; // => "?search=test" | |
| parser.hash; // => "#hash" | |
| parser.host; // => "example.com:3000" |
| namespace BST | |
| { | |
| using System; | |
| using System.Collections; | |
| public class BloomFilter<T> | |
| { | |
| private readonly int _size; | |
| //how many times to run the hash method |
| myStuff.forEach(function stuff){ | |
| var subStuff = stuff.subStuff; | |
| doSomething({ | |
| success: (function(subStuff) { // creates a function scope | |
| return function(results) { // the actual success callback with subStuff scoped | |
| // subStuff and results are now function scoped | |
| }; |
| // Install System.Threading.Channels | |
| using System; | |
| using System.Collections.Generic; | |
| using System.Diagnostics; | |
| using System.IO; | |
| using System.Text; | |
| using System.Threading.Channels; | |
| using System.Threading.Tasks; |
| <script> | |
| (function() { | |
| var capsLockEnabled = false; | |
| document.onkeypress = function (e) { | |
| e = e || window.event; | |
| var s = String.fromCharCode(e.keyCode || e.which); | |
| if (s.toLowerCase() === s.toUpperCase()) { | |
| return; | |
| } |
| using System; | |
| using System.Threading.Tasks; | |
| namespace System.Collections.Concurrent | |
| { | |
| public static class ConcurrentDictionaryExtensions | |
| { | |
| /// <summary> | |
| /// Provides an alternative to <see cref="ConcurrentDictionary{TKey, TValue}.GetOrAdd(TKey, Func{TKey, TValue})"/> that disposes values that implement <see cref="IDisposable"/>. | |
| /// </summary> |
This document now exists on the official ASP.NET core docs page.
| using SixLabors.ImageSharp; | |
| using SixLabors.ImageSharp.Drawing; | |
| using SixLabors.ImageSharp.Drawing.Processing; | |
| using SixLabors.ImageSharp.PixelFormats; | |
| using SixLabors.ImageSharp.Processing; | |
| var destWidth = 1920; | |
| var destHeight = 1080; | |
| using var image = new Image<Rgba32>(destWidth, destHeight); |
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Text.Json; | |
| using System.Text.Json.Nodes; | |
| namespace CajunCoding | |
| { | |
| public static class SystemTextJsonMergeExtensions | |
| { |