├── RoslynAnalyzers ├── .gitignore ├── build.sh ├── JonSkeet.RoslynAnalyzers │ └── JonSkeet.RoslynAnalyzers.Package │ │ └── README.md └── RoslynAnalyzers.slnx ├── .hgeol ├── Versioning ├── .gitignore ├── ExtractCode │ └── ExtractCode.csproj ├── runall.sh ├── examples │ ├── remove-public-method.txt │ ├── change-readonly.txt │ ├── parameter-renaming.txt │ └── remove-private-method.txt └── index-template.md ├── Diagnostics ├── Example1a │ ├── wwwroot │ │ ├── js │ │ │ ├── site.min.js │ │ │ └── site.js │ │ ├── favicon.ico │ │ └── css │ │ │ └── site.min.css │ ├── Views │ │ ├── _ViewStart.cshtml │ │ ├── _ViewImports.cshtml │ │ ├── Reports │ │ │ └── Index.cshtml │ │ └── Home │ │ │ ├── Privacy.cshtml │ │ │ └── About.cshtml │ ├── Configuration │ │ └── ReportDbConfig.cs │ ├── Models │ │ ├── IReportRepository.cs │ │ ├── ReportLine.cs │ │ ├── ErrorViewModel.cs │ │ └── Report.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── Example1a.csproj │ └── Program.cs ├── Example3a │ ├── NodaTime Release.snk │ └── Program.cs ├── Example1c │ └── Example1c.csproj ├── Example1d │ ├── Example1d.csproj │ └── Program.cs ├── Example3c │ └── Example3c.csproj ├── UnhelpfulDebugger │ └── App.config ├── Example2a │ └── Properties │ │ └── Settings.settings ├── Example2c │ └── Properties │ │ └── Settings.settings ├── Example1b │ └── Example1b.csproj ├── Example2b │ └── Example2b.csproj └── Example3b │ └── Example3b.csproj ├── Drums ├── .gitignore ├── ae01.vdrum ├── ae10.vdrum ├── td07.vdrum ├── td17.vdrum ├── td27.vdrum ├── td-50x.vdrum ├── td17-v2.vdrum ├── td27-v2.vdrum ├── VDrumExplorer.Model │ ├── SchemaResources │ │ ├── TD07 │ │ │ ├── VEdit │ │ │ │ ├── Off.json │ │ │ │ ├── Other.json │ │ │ │ ├── RideCrashSplashChina.json │ │ │ │ └── HiHat.json │ │ │ ├── Physical │ │ │ │ ├── Current.json │ │ │ │ ├── Setup.json │ │ │ │ ├── SetupMisc.json │ │ │ │ └── Trigger.json │ │ │ └── Logical │ │ │ │ ├── Setup.json │ │ │ │ └── Root.json │ │ ├── TD17 │ │ │ ├── VEdit │ │ │ │ ├── Off.json │ │ │ │ ├── Other.json │ │ │ │ └── HiHat.json │ │ │ ├── Physical │ │ │ │ ├── Current.json │ │ │ │ ├── Setup.json │ │ │ │ ├── KitUnitInst.json │ │ │ │ ├── SetupMisc.json │ │ │ │ └── Trigger.json │ │ │ └── Logical │ │ │ │ ├── Setup.json │ │ │ │ └── Root.json │ │ ├── TD50 │ │ │ ├── VEdit │ │ │ │ ├── Off.json │ │ │ │ └── Other.json │ │ │ ├── Physical │ │ │ │ ├── Current.json │ │ │ │ └── SetupControl.json │ │ │ └── Logical │ │ │ │ ├── Root.json │ │ │ │ └── Setup.json │ │ ├── TD50X │ │ │ ├── VEdit │ │ │ │ ├── Off.json │ │ │ │ └── Other.json │ │ │ ├── Physical │ │ │ │ ├── Current.json │ │ │ │ └── SetupControl.json │ │ │ └── Logical │ │ │ │ ├── Root.json │ │ │ │ └── Setup.json │ │ ├── AE10 │ │ │ ├── Chorus │ │ │ │ └── Off.json │ │ │ ├── Reverb │ │ │ │ └── Off.json │ │ │ ├── MultiFx │ │ │ │ └── Off.json │ │ │ ├── Logical │ │ │ │ ├── TemporaryStudioSet.json │ │ │ │ └── Root.json │ │ │ └── Physical │ │ │ │ └── System.json │ │ └── TD27 │ │ │ ├── VEdit │ │ │ ├── Off.json │ │ │ └── Other.json │ │ │ ├── Physical │ │ │ ├── Current.json │ │ │ └── SetupControl.json │ │ │ └── Logical │ │ │ ├── Root.json │ │ │ └── Setup.json │ ├── AssemblyInfo.cs │ ├── Audio │ │ ├── IAudioDeviceManager.cs │ │ └── IAudioOutput.cs │ └── Midi │ │ └── IMidiOutput.cs ├── global.json ├── VDrumExplorer.Blazor │ ├── wwwroot │ │ ├── favicon.ico │ │ └── css │ │ │ └── open-iconic │ │ │ └── font │ │ │ └── fonts │ │ │ ├── open-iconic.eot │ │ │ ├── open-iconic.otf │ │ │ ├── open-iconic.ttf │ │ │ └── open-iconic.woff │ ├── Shared │ │ └── MainLayout.razor │ ├── _Imports.razor │ └── App.razor ├── VDrumExplorer.Proto │ ├── AssemblyInfo.cs │ ├── README.md │ └── VDrumExplorer.Proto.csproj ├── VDrumExplorer.NetFrameworkProfiling │ └── App.config ├── VDrumExplorer.ViewModel.Test │ └── UnitTest1.cs ├── VDrumExplorer.InstrumentParser │ └── VDrumExplorer.InstrumentParser.csproj ├── VDrumExplorer.NAudio │ └── VDrumExplorer.NAudio.csproj ├── VDrumExplorer.ViewModel │ └── Data │ │ └── IDataNodeDetailViewModel.cs └── VDrumExplorer.Benchmarks │ ├── VDrumExplorer.Benchmarks.csproj │ └── Program.cs ├── DigiMixer ├── DigiMixer.Tests │ └── Usings.cs ├── Protocols │ └── ah-sq.md ├── DigiMixer.Wpf │ ├── DigiMixer.ico │ ├── DigiMixer-Icon-512.png │ ├── DigiMixer-Icon-White-512.png │ ├── Versions.cs │ ├── MainWindow.xaml.cs │ ├── DigiMixerAppConfig.cs │ └── MidiDevicePickerViewModel.cs ├── DigiMixer.Mackie.Tools │ ├── Program.cs │ └── dump.proto ├── DigiMixer.UCNet.Tools │ └── Program.cs ├── DigiMixer.UiHttp.Tools │ └── Program.cs ├── DigiMixer.CqSeries.Tools │ └── Program.cs ├── DigiMixer.DmSeries.Tools │ └── Program.cs ├── DigiMixer.QuSeries.Tools │ └── Program.cs ├── DigiMixer.SqSeries.Core │ ├── SqControlClient.cs │ ├── DigiMixer.SqSeries.Core.csproj │ └── SqMessageFormat.cs ├── DigiMixer.SqSeries.Tools │ └── Program.cs ├── DigiMixer.TfSeries.Tools │ ├── Program.cs │ └── DecodingOptions.cs ├── DigiMixer.UiHttp │ ├── AssemblyInfo.cs │ ├── formatted-cur-setup.json.txt │ ├── parameters.txt │ └── DigiMixer.UiHttp.csproj ├── DigiMixer.BehringerWing.Tools │ └── Program.cs ├── DigiMixer.CqSeries │ ├── AssemblyInfo.cs │ ├── CqUnknownMessage.cs │ ├── CqKeepAliveMessage.cs │ ├── CpFullDataRequestMessage.cs │ ├── CqClientInitResponseMessage.cs │ ├── CqVersionRequestMessage.cs │ ├── CqClientInitRequestMessage.cs │ └── DigiMixer.CqSeries.csproj ├── DigiMixer.DmSeries │ ├── AssemblyInfo.cs │ ├── DmMeterClient.cs │ └── DigiMixer.DmSeries.csproj ├── DigiMixer.QuSeries │ ├── AssemblyInfo.cs │ └── DigiMixer.QuSeries.csproj ├── DigiMixer.SqSeries │ ├── AssemblyInfo.cs │ ├── SqUnknownMessage.cs │ ├── SqMixer.cs │ ├── DigiMixer.SqSeries.csproj │ ├── SqMessageType.cs │ ├── SqVersionRequestMessage.cs │ └── SqSimpleRequestMessage.cs ├── DigiMixer.Mackie │ ├── OutputGroup.cs │ └── DigiMixer.Mackie.csproj ├── DigiMixer.Msix │ └── Images │ │ ├── StoreLogo.backup.png │ │ ├── LargeTile.scale-100.png │ │ ├── LargeTile.scale-125.png │ │ ├── LargeTile.scale-150.png │ │ ├── LargeTile.scale-200.png │ │ ├── LargeTile.scale-400.png │ │ ├── SmallTile.scale-100.png │ │ ├── SmallTile.scale-125.png │ │ ├── SmallTile.scale-150.png │ │ ├── SmallTile.scale-200.png │ │ ├── SmallTile.scale-400.png │ │ ├── StoreLogo.scale-100.png │ │ ├── StoreLogo.scale-125.png │ │ ├── StoreLogo.scale-150.png │ │ ├── StoreLogo.scale-200.png │ │ ├── StoreLogo.scale-400.png │ │ ├── SplashScreen.scale-100.png │ │ ├── SplashScreen.scale-125.png │ │ ├── SplashScreen.scale-150.png │ │ ├── SplashScreen.scale-200.png │ │ ├── SplashScreen.scale-400.png │ │ ├── LockScreenLogo.scale-200.png │ │ ├── Square44x44Logo.scale-100.png │ │ ├── Square44x44Logo.scale-125.png │ │ ├── Square44x44Logo.scale-150.png │ │ ├── Square44x44Logo.scale-200.png │ │ ├── Square44x44Logo.scale-400.png │ │ ├── Wide310x150Logo.scale-100.png │ │ ├── Wide310x150Logo.scale-125.png │ │ ├── Wide310x150Logo.scale-150.png │ │ ├── Wide310x150Logo.scale-200.png │ │ ├── Wide310x150Logo.scale-400.png │ │ ├── Square150x150Logo.scale-100.png │ │ ├── Square150x150Logo.scale-125.png │ │ ├── Square150x150Logo.scale-150.png │ │ ├── Square150x150Logo.scale-200.png │ │ ├── Square150x150Logo.scale-400.png │ │ ├── Square44x44Logo.targetsize-16.png │ │ ├── Square44x44Logo.targetsize-24.png │ │ ├── Square44x44Logo.targetsize-256.png │ │ ├── Square44x44Logo.targetsize-32.png │ │ ├── Square44x44Logo.targetsize-48.png │ │ ├── Square44x44Logo.altform-unplated_targetsize-16.png │ │ ├── Square44x44Logo.altform-unplated_targetsize-256.png │ │ ├── Square44x44Logo.altform-unplated_targetsize-32.png │ │ ├── Square44x44Logo.altform-unplated_targetsize-48.png │ │ ├── Square44x44Logo.targetsize-24_altform-unplated.png │ │ ├── Square44x44Logo.altform-lightunplated_targetsize-16.png │ │ ├── Square44x44Logo.altform-lightunplated_targetsize-24.png │ │ ├── Square44x44Logo.altform-lightunplated_targetsize-256.png │ │ ├── Square44x44Logo.altform-lightunplated_targetsize-32.png │ │ └── Square44x44Logo.altform-lightunplated_targetsize-48.png ├── DigiMixer.QuSeries.Core │ ├── AssemblyInfo.cs │ └── DigiMixer.QuSeries.Core.csproj ├── DigiMixer.BehringerWing │ ├── AssemblyInfo.cs │ └── DigiMixer.BehringerWing.csproj ├── DigiMixer.TfSeries │ ├── TfMessages.cs │ └── DigiMixer.TfSeries.csproj ├── DigiMixer.Diagnostics │ ├── MessageDirection.cs │ └── AnnotatedMessage.cs ├── DigiMixer.Yamaha.Core │ ├── RequestResponseFlag.cs │ ├── YamahaSegmentFormat.cs │ ├── DigiMixer.Yamaha.Core.csproj │ └── YamahaSegment.cs ├── DigiMixer.CqSeries.Core │ ├── CqMessageFormat.cs │ └── DigiMixer.CqSeries.Core.csproj ├── DigiMixer.Yamaha │ ├── SchemaPropertyType.cs │ ├── DataSubtypes.cs │ ├── YamahaClientExtensions.cs │ └── DigiMixer.Yamaha.csproj ├── DigiMixer.BehringerWing.Core │ ├── WingProtocolChannel.cs │ ├── WingNodeUnit.cs │ ├── WingNodeType.cs │ ├── DigiMixer.BehringerWing.Core.csproj │ └── WingMeterType.cs ├── DigiMixer.DmSeries.Core │ ├── DmSegmentFormat.cs │ └── DigiMixer.DmSeries.Core.csproj ├── DigiMixer.BehringerWing.WingExplorer │ ├── App.xaml.cs │ ├── ExplorerPanel.xaml.cs │ ├── ProgressPanel.xaml.cs │ ├── MixerDetailsPanel.xaml.cs │ ├── MainWindow.xaml.cs │ └── ExplorerViewModel.cs ├── DigiMixer.Mackie.Core │ ├── MackieMessageType.cs │ ├── MackieCommand.cs │ ├── DigiMixer.Mackie.Core.csproj │ └── MackieResponseException.cs ├── DigiMixer.Core │ ├── IMixerMessage.cs │ ├── ControllerStatus.cs │ └── MixerInfo.cs ├── DigiMixer.UCNet.Core │ ├── Messages │ │ ├── MeterSource.cs │ │ └── MeterStage.cs │ ├── MessageMode.cs │ └── DigiMixer.UCNet.Core.csproj ├── DigiMixer.Controls │ ├── ChannelGroup.xaml.cs │ ├── MixerControlPanel.xaml.cs │ └── ChannelVisibilitySelector.xaml.cs ├── DigiMixer.PeripheralConsole │ ├── DigiMixerAppConfig.cs │ └── DigiMixer.PeripheralConsole.csproj ├── DigiMixer.UCNet │ └── DigiMixer.UCNet.csproj ├── DigiMixer.AllenAndHeath.Core │ ├── DigiMixer.AllenAndHeath.Core.csproj │ └── AHMessageFormat.cs ├── DigiMixer.Osc │ └── DigiMixer.Osc.csproj ├── DigiMixer │ ├── IFader.cs │ └── DigiMixer.csproj └── DigiMixer.Ssc │ └── DigiMixer.Ssc.csproj ├── DialogflowDemo ├── DialogflowDemo │ ├── app.yaml │ ├── appsettings.json │ ├── appsettings.Development.json │ └── Program.cs ├── MentorSearchModels │ └── MentorSearchModels.csproj ├── SearchTest │ └── SearchTest.csproj └── PopulateFirestore │ └── PopulateFirestore.csproj ├── SpiceGirlsApiDesign ├── 18 A-Z.png ├── 01 Intro.png ├── 11 Stopwatch.png ├── 13 Interop.png ├── 15 Versions.png ├── 06 I Wanna Ha.png ├── 16 I Won't Be Hasty.png ├── 03 Gather Requirements.png ├── 05 Avoid Patternitis.png ├── 07 Modelling Failure.png ├── 20 Slam Your Body Down.png ├── 02 Tell Me What You Want.png ├── 08 If You Want My Future.png ├── 14 Make It Last Forever.png ├── 17 Love At First Sight.png ├── 09 Learning From The Past.png ├── 19 Contradictory Requirements.png ├── 04 What You Really Really Want.png ├── 10 Now Don't Go Wasting My Precious Time.png └── 12 If You Wanna Be My Lover, You Gotta Get With My Friends.png ├── Shed ├── Shed.Uwp │ ├── Assets │ │ ├── StoreLogo.png │ │ ├── SplashScreen.scale-200.png │ │ ├── LockScreenLogo.scale-200.png │ │ ├── Square44x44Logo.scale-200.png │ │ ├── Wide310x150Logo.scale-200.png │ │ ├── Square150x150Logo.scale-200.png │ │ └── Square44x44Logo.targetsize-24_altform-unplated.png │ ├── App.xaml │ └── project.json ├── README.md ├── Shed.Controllers │ ├── ICommand.cs │ └── IController.cs └── Shed.CommandLine │ └── Shed.CommandLine.csproj ├── Saving New Developers From Our Battle Scars.pptx ├── Abusing CSharp ├── Code │ ├── FunWithAwaiters │ │ ├── goto.txt │ │ ├── packages.config │ │ ├── App.config │ │ ├── ITransient.cs │ │ ├── IAwaitable.cs │ │ └── Program.cs │ ├── OddsAndEnds │ │ ├── MongolianVowelSeparator.exe │ │ ├── App.config │ │ ├── packages.config │ │ ├── Program.cs │ │ └── SneakyOperatorDemo.cs │ ├── OperatorAbuse │ │ ├── packages.config │ │ ├── App.config │ │ └── Program.cs │ ├── Performance │ │ ├── packages.config │ │ └── Program.cs │ ├── WhatTheHeck │ │ └── packages.config │ ├── WhatTheHeck2 │ │ ├── packages.config │ │ ├── App.config │ │ ├── Program.cs │ │ ├── Demo2.cs │ │ └── Demo1.cs │ ├── WrappingAsync │ │ ├── app.config │ │ ├── packages.config │ │ └── Program.cs │ ├── ExceptionFilters │ │ ├── packages.config │ │ ├── App.config │ │ └── Program.cs │ ├── LinqToOperators │ │ ├── packages.config │ │ ├── App.config │ │ ├── Program.cs │ │ └── Extensions.cs │ ├── NullConditional │ │ ├── packages.config │ │ ├── App.config │ │ └── Program.cs │ ├── VersionDetection │ │ ├── packages.config │ │ └── App.config │ └── StringInterpolation │ │ ├── packages.config │ │ ├── App.config │ │ └── Program.cs └── Text │ ├── intro.txt │ └── agenda.txt ├── Immutability ├── Slides │ ├── 020 Kinds of immutability.txt │ ├── 030 Benefits.txt │ ├── 060 Memory model.txt │ ├── 010 Agenda.txt │ ├── 071 Issues - Antipatterns.txt │ ├── 027 ReallyObviouslyImmutable.cs │ ├── 050 Examples.txt │ └── Scratchpad.cs ├── Builder3 │ ├── notes.txt │ ├── App.config │ ├── PhoneNumberType.cs │ └── Program.cs ├── Builder1 │ ├── App.config │ ├── notes.txt │ └── PhoneNumberType.cs ├── Builder2 │ ├── App.config │ ├── PhoneNumberType.cs │ ├── notes.txt │ ├── FreezableList.cs │ └── Program.cs ├── Record │ ├── App.config │ ├── notes.txt │ └── Entities.cs ├── Withers │ ├── App.config │ └── PhoneNumberType.cs ├── LanguageFeatures │ ├── App.config │ ├── ValueType.cs │ └── Program.cs └── model.txt ├── VersioningBlogPost ├── MultiVersionLoading │ ├── NodaTime-1.3.1.dll │ ├── NodaTime-2.0.0.dll │ └── MultiVersionLoading.csproj └── Diamond │ ├── Lib1 │ ├── Lib1.csproj │ └── Class1.cs │ └── App │ ├── Program.cs │ └── App.csproj ├── MauiBugDemos └── ContextAndType │ ├── Resources │ ├── Images │ │ └── dotnet_bot.png │ ├── Fonts │ │ ├── OpenSans-Regular.ttf │ │ └── OpenSans-Semibold.ttf │ └── AppIcon │ │ └── appicon.svg │ ├── AppShell.xaml.cs │ ├── MainPage.xaml.cs │ ├── App.xaml.cs │ ├── Platforms │ ├── Android │ │ ├── Resources │ │ │ └── values │ │ │ │ └── colors.xml │ │ ├── MainApplication.cs │ │ ├── AndroidManifest.xml │ │ └── MainActivity.cs │ ├── iOS │ │ ├── AppDelegate.cs │ │ └── Program.cs │ ├── MacCatalyst │ │ ├── AppDelegate.cs │ │ └── Program.cs │ ├── Windows │ │ └── App.xaml │ └── Tizen │ │ └── Main.cs │ └── ParentViewModel.cs ├── RoslynTesting ├── packages │ └── repositories.config └── ProductionCode │ └── Attributes │ └── NotNullAttribute.cs ├── MauiPlayground └── MauiPlayground │ ├── Resources │ ├── Fonts │ │ └── OpenSans-Regular.ttf │ └── appicon.svg │ ├── App.xaml.cs │ └── Platforms │ ├── Android │ ├── Resources │ │ └── values │ │ │ └── colors.xml │ ├── MainActivity.cs │ ├── AndroidManifest.xml │ └── MainApplication.cs │ ├── iOS │ └── AppDelegate.cs │ ├── MacCatalyst │ └── AppDelegate.cs │ └── Windows │ └── App.xaml ├── RabbitHole └── Code │ ├── packages │ └── repositories.config │ └── RabbitHole │ ├── packages.config │ ├── App.config │ └── Program.cs ├── AsyncIntro ├── Code │ ├── StockMarket │ │ ├── packages.config │ │ ├── StockPrice.cs │ │ ├── UserStockHolding.cs │ │ └── User.cs │ ├── StockService │ │ ├── app.config │ │ └── Program.cs │ ├── StockViewer │ │ ├── packages.config │ │ ├── App.config │ │ └── Properties │ │ │ └── Settings.settings │ ├── Testing.MsTest │ │ └── packages.config │ ├── AsyncHttpService │ │ ├── packages.config │ │ └── App.config │ ├── UnderTheHood │ │ └── App.config │ ├── Testing.NUnit │ │ └── packages.config │ └── packages │ │ └── repositories.config └── readme.md ├── DemoUtil ├── JonSkeet.DemoUtil │ └── targets │ │ └── JonSkeet.DemoUtil.props └── JonSkeet.DemoUtil.Test │ ├── Program.cs │ ├── DemoWithException.cs │ ├── DemoWithoutDescription.cs │ ├── DemoWithDescription.cs │ ├── DemoWithAsyncMain.cs │ └── JonSkeet.DemoUtil.Test.csproj ├── PclPal └── PclPal.Tool │ └── App.config ├── CSharp7 └── CSharp7 │ ├── App.config │ ├── Scratchpad.cs │ ├── packages.config │ ├── Program.cs │ └── CSharp7.csproj ├── CSharp8 ├── Nullability │ ├── App.config │ ├── AnnotationsOnlyContext.cs │ └── Nullability.csproj ├── Async │ └── Async.csproj ├── Patterns │ ├── DateTimeExtensions.cs │ ├── Patterns.csproj │ └── NotExhaustive.cs ├── IndexAndRange │ └── IndexAndRange.csproj ├── MinorFeatures │ ├── MinorFeatures.csproj │ ├── NullCoalescingAssignment.cs │ ├── VerbatimInterpolatedStringLiterals.cs │ └── StackallocInNestedContexts.cs └── DefaultInterfaceMethods │ └── DefaultInterfaceMethods.csproj ├── TravisConsole ├── TravisConsole.csproj └── Program.cs ├── IconPlatform ├── IconPlatform.Model │ ├── ButtonType.cs │ ├── FaderEventArgs.cs │ └── IconPlatform.Model.csproj ├── IconPlatform.ConsoleDemo │ └── IconPlatform.ConsoleDemo.csproj ├── IconPlatform.MixerControl │ └── IconPlatform.MixerControl.csproj └── IconPlatform.slnx ├── .hgignore ├── DateTimeDemos └── TimeZoneInfoExplorer │ └── Properties │ └── Settings.settings ├── DmxLighting ├── DmxLighting.WpfGui │ ├── FixtureViewModel.cs │ ├── App.xaml │ ├── App.xaml.cs │ └── DmxLighting.WpfGui.csproj └── DmxLighting.ConsoleApp │ └── DmxLighting.ConsoleApp.csproj ├── OscMixerControl ├── OscMixerControl │ ├── OscMixerControl.csproj │ └── IOscClient.cs ├── OscMixerControl.Console │ └── OscMixerControl.Console.csproj ├── OscMixerControl.Proxy │ └── OscMixerControl.Proxy.csproj ├── OscMixerControl.Wpf │ └── App.xaml.cs └── OscMixerControl.slnx ├── Functions ├── HelloWorld │ └── HelloWorld.csproj └── ZoneClock │ └── ZoneClock.csproj ├── WpfUtil ├── WpfUtil.slnx ├── JonSkeet.CoreAppUtil │ ├── IUpdatable.cs │ └── IReorderableList.cs ├── JonSkeet.WpfLogging │ ├── JonSkeet.WpfLogging.csproj │ └── LogWindow.xaml.cs └── JonSkeet.WpfUtil │ └── JonSkeet.WpfUtil.csproj ├── CameraControl ├── CameraControl.Visca │ ├── PowerStatus.cs │ ├── CameraControl.Visca.csproj │ ├── CallerArgumentExpressionAttribute.cs │ └── ViscaMessageType.cs ├── CameraControl.Visca.Demo │ ├── App.xaml.cs │ └── CameraControl.Visca.Demo.csproj ├── CameraControl.Visca.StressTest │ └── CameraControl.Visca.StressTest.csproj └── CameraControl.slnx ├── XTouchMini ├── XTouchMini.Console │ └── XTouchMini.Console.csproj ├── XTouchMini.Model │ └── XTouchMini.Model.csproj ├── XTouchMini.MixerControl │ └── XTouchMini.MixerControl.csproj └── XTouchMini.slnx ├── NdiStreamDeck ├── NdiStreamDeck │ ├── App.xaml │ └── App.xaml.cs └── NdiStreamDeck.slnx └── EvChargerTiming └── EvChargerTiming.csproj /RoslynAnalyzers/.gitignore: -------------------------------------------------------------------------------- 1 | *.nupkg 2 | -------------------------------------------------------------------------------- /.hgeol: -------------------------------------------------------------------------------- 1 | [patterns] 2 | ** = native 3 | 4 | -------------------------------------------------------------------------------- /Versioning/.gitignore: -------------------------------------------------------------------------------- 1 | output 2 | pages 3 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/wwwroot/js/site.min.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /Drums/.gitignore: -------------------------------------------------------------------------------- 1 | VDrumExplorer.Data.Test/td50.vdrum 2 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Tests/Usings.cs: -------------------------------------------------------------------------------- 1 | global using NUnit.Framework; -------------------------------------------------------------------------------- /DigiMixer/Protocols/ah-sq.md: -------------------------------------------------------------------------------- 1 | # Allen and Heath SQ protocol 2 | 3 | -------------------------------------------------------------------------------- /Drums/ae01.vdrum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/ae01.vdrum -------------------------------------------------------------------------------- /Drums/ae10.vdrum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/ae10.vdrum -------------------------------------------------------------------------------- /Drums/td07.vdrum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/td07.vdrum -------------------------------------------------------------------------------- /Drums/td17.vdrum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/td17.vdrum -------------------------------------------------------------------------------- /Drums/td27.vdrum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/td27.vdrum -------------------------------------------------------------------------------- /Diagnostics/Example1a/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Drums/td-50x.vdrum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/td-50x.vdrum -------------------------------------------------------------------------------- /DialogflowDemo/DialogflowDemo/app.yaml: -------------------------------------------------------------------------------- 1 | runtime: aspnetcore 2 | env: flex 3 | service: gdg 4 | -------------------------------------------------------------------------------- /Drums/td17-v2.vdrum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/td17-v2.vdrum -------------------------------------------------------------------------------- /Drums/td27-v2.vdrum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/td27-v2.vdrum -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD07/VEdit/Off.json: -------------------------------------------------------------------------------- 1 | { 2 | "fields": [ 3 | ] 4 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD17/VEdit/Off.json: -------------------------------------------------------------------------------- 1 | { 2 | "fields": [ 3 | ] 4 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50/VEdit/Off.json: -------------------------------------------------------------------------------- 1 | { 2 | "fields": [ 3 | ] 4 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50/VEdit/Other.json: -------------------------------------------------------------------------------- 1 | { 2 | "fields": [ 3 | ] 4 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50X/VEdit/Off.json: -------------------------------------------------------------------------------- 1 | { 2 | "fields": [ 3 | ] 4 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50X/VEdit/Other.json: -------------------------------------------------------------------------------- 1 | { 2 | "fields": [ 3 | ] 4 | } -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/18 A-Z.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/18 A-Z.png -------------------------------------------------------------------------------- /Drums/global.json: -------------------------------------------------------------------------------- 1 | { 2 | "sdk": { 3 | "version": "3.1", 4 | "rollForward": "latestMinor" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/01 Intro.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/01 Intro.png -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/AE10/Chorus/Off.json: -------------------------------------------------------------------------------- 1 | { 2 | "description": "Off", 3 | "fields": [ 4 | ] 5 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/AE10/Reverb/Off.json: -------------------------------------------------------------------------------- 1 | { 2 | "description": "Off", 3 | "fields": [ 4 | ] 5 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD27/VEdit/Off.json: -------------------------------------------------------------------------------- 1 | { 2 | "description": "Off", 3 | "fields": [] 4 | } 5 | -------------------------------------------------------------------------------- /Shed/Shed.Uwp/Assets/StoreLogo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Shed/Shed.Uwp/Assets/StoreLogo.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/11 Stopwatch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/11 Stopwatch.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/13 Interop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/13 Interop.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/15 Versions.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/15 Versions.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Wpf/DigiMixer.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Wpf/DigiMixer.ico -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/AE10/MultiFx/Off.json: -------------------------------------------------------------------------------- 1 | { 2 | "description": "Off", 3 | "fields": [ 4 | ] 5 | } -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/06 I Wanna Ha.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/06 I Wanna Ha.png -------------------------------------------------------------------------------- /Diagnostics/Example1a/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Diagnostics/Example1a/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Diagnostics/Example3a/NodaTime Release.snk: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Diagnostics/Example3a/NodaTime Release.snk -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/16 I Won't Be Hasty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/16 I Won't Be Hasty.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Mackie.Tools/Program.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Diagnostics; 2 | 3 | await Tool.ExecuteFromCommandLine(args, typeof(Program)); 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.UCNet.Tools/Program.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Diagnostics; 2 | 3 | await Tool.ExecuteFromCommandLine(args, typeof(Program)); 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.UiHttp.Tools/Program.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Diagnostics; 2 | 3 | await Tool.ExecuteFromCommandLine(args, typeof(Program)); 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Wpf/DigiMixer-Icon-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Wpf/DigiMixer-Icon-512.png -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Blazor/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/VDrumExplorer.Blazor/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Proto/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Runtime.CompilerServices; 2 | 3 | [assembly:InternalsVisibleTo("VDrumExplorer.Console")] -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/03 Gather Requirements.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/03 Gather Requirements.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/05 Avoid Patternitis.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/05 Avoid Patternitis.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/07 Modelling Failure.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/07 Modelling Failure.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/20 Slam Your Body Down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/20 Slam Your Body Down.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.CqSeries.Tools/Program.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Diagnostics; 2 | 3 | await Tool.ExecuteFromCommandLine(args, typeof(Program)); 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.DmSeries.Tools/Program.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Diagnostics; 2 | 3 | await Tool.ExecuteFromCommandLine(args, typeof(Program)); 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.QuSeries.Tools/Program.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Diagnostics; 2 | 3 | await Tool.ExecuteFromCommandLine(args, typeof(Program)); 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.SqSeries.Core/SqControlClient.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.SqSeries.Core; 2 | 3 | public sealed class SqControlClient 4 | { 5 | } 6 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.SqSeries.Tools/Program.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Diagnostics; 2 | 3 | await Tool.ExecuteFromCommandLine(args, typeof(Program)); 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.TfSeries.Tools/Program.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Diagnostics; 2 | 3 | await Tool.ExecuteFromCommandLine(args, typeof(Program)); 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.UiHttp/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Runtime.CompilerServices; 2 | 3 | [assembly: InternalsVisibleTo("DigiMixer.UiHttp.Tools")] -------------------------------------------------------------------------------- /Saving New Developers From Our Battle Scars.pptx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Saving New Developers From Our Battle Scars.pptx -------------------------------------------------------------------------------- /Shed/Shed.Uwp/Assets/SplashScreen.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Shed/Shed.Uwp/Assets/SplashScreen.scale-200.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/02 Tell Me What You Want.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/02 Tell Me What You Want.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/08 If You Want My Future.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/08 If You Want My Future.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/14 Make It Last Forever.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/14 Make It Last Forever.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/17 Love At First Sight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/17 Love At First Sight.png -------------------------------------------------------------------------------- /Diagnostics/Example1a/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Example1a 2 | @using Example1a.Models 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.Tools/Program.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Diagnostics; 2 | 3 | await Tool.ExecuteFromCommandLine(args, typeof(Program)); 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.CqSeries/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Runtime.CompilerServices; 2 | 3 | [assembly: InternalsVisibleTo("DigiMixer.CqSeries.Tools")] -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.DmSeries/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Runtime.CompilerServices; 2 | 3 | [assembly: InternalsVisibleTo("DigiMixer.DmSeries.Tools")] -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.QuSeries/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Runtime.CompilerServices; 2 | 3 | [assembly: InternalsVisibleTo("DigiMixer.QuSeries.Tools")] -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.SqSeries/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Runtime.CompilerServices; 2 | 3 | [assembly: InternalsVisibleTo("DigiMixer.SqSeries.Tools")] -------------------------------------------------------------------------------- /Shed/Shed.Uwp/Assets/LockScreenLogo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Shed/Shed.Uwp/Assets/LockScreenLogo.scale-200.png -------------------------------------------------------------------------------- /Shed/Shed.Uwp/Assets/Square44x44Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Shed/Shed.Uwp/Assets/Square44x44Logo.scale-200.png -------------------------------------------------------------------------------- /Shed/Shed.Uwp/Assets/Wide310x150Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Shed/Shed.Uwp/Assets/Wide310x150Logo.scale-200.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/09 Learning From The Past.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/09 Learning From The Past.png -------------------------------------------------------------------------------- /Abusing CSharp/Code/FunWithAwaiters/goto.txt: -------------------------------------------------------------------------------- 1 | 10 PRINT "Hello" 2 | 20 INPUT "Keep going"; LINE 3 | 30 IF LINE = "y" THEN GOTO 20 4 | 40 PRINT "Finished!" 5 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Mackie/OutputGroup.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Mackie; 2 | 3 | internal enum OutputGroup 4 | { 5 | Main, 6 | Aux, 7 | Fx 8 | } 9 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/StoreLogo.backup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/StoreLogo.backup.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.QuSeries.Core/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Runtime.CompilerServices; 2 | 3 | [assembly: InternalsVisibleTo("DigiMixer.QuSeries.Tools")] -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Wpf/DigiMixer-Icon-White-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Wpf/DigiMixer-Icon-White-512.png -------------------------------------------------------------------------------- /Immutability/Slides/020 Kinds of immutability.txt: -------------------------------------------------------------------------------- 1 | - Mutability isn't as Boolean as we might expect 2 | - Some examples of points along the spectrum... 3 | -------------------------------------------------------------------------------- /Shed/Shed.Uwp/Assets/Square150x150Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Shed/Shed.Uwp/Assets/Square150x150Logo.scale-200.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/19 Contradictory Requirements.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/19 Contradictory Requirements.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Runtime.CompilerServices; 2 | 3 | [assembly: InternalsVisibleTo("DigiMixer.BehringerWing.Tools")] -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/LargeTile.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/LargeTile.scale-100.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/LargeTile.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/LargeTile.scale-125.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/LargeTile.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/LargeTile.scale-150.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/LargeTile.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/LargeTile.scale-200.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/LargeTile.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/LargeTile.scale-400.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/SmallTile.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/SmallTile.scale-100.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/SmallTile.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/SmallTile.scale-125.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/SmallTile.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/SmallTile.scale-150.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/SmallTile.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/SmallTile.scale-200.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/SmallTile.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/SmallTile.scale-400.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/StoreLogo.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/StoreLogo.scale-100.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/StoreLogo.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/StoreLogo.scale-125.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/StoreLogo.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/StoreLogo.scale-150.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/StoreLogo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/StoreLogo.scale-200.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/StoreLogo.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/StoreLogo.scale-400.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.TfSeries/TfMessages.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Yamaha.Core; 2 | 3 | namespace DigiMixer.TfSeries; 4 | 5 | public class TfMessages 6 | { 7 | } 8 | -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/04 What You Really Really Want.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/04 What You Really Really Want.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/SplashScreen.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/SplashScreen.scale-100.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/SplashScreen.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/SplashScreen.scale-125.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/SplashScreen.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/SplashScreen.scale-150.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/SplashScreen.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/SplashScreen.scale-200.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/SplashScreen.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/SplashScreen.scale-400.png -------------------------------------------------------------------------------- /VersioningBlogPost/MultiVersionLoading/NodaTime-1.3.1.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/VersioningBlogPost/MultiVersionLoading/NodaTime-1.3.1.dll -------------------------------------------------------------------------------- /VersioningBlogPost/MultiVersionLoading/NodaTime-2.0.0.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/VersioningBlogPost/MultiVersionLoading/NodaTime-2.0.0.dll -------------------------------------------------------------------------------- /Abusing CSharp/Code/OddsAndEnds/MongolianVowelSeparator.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Abusing CSharp/Code/OddsAndEnds/MongolianVowelSeparator.exe -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/LockScreenLogo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/LockScreenLogo.scale-200.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.scale-100.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.scale-125.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.scale-150.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.scale-200.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.scale-400.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Wide310x150Logo.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Wide310x150Logo.scale-100.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Wide310x150Logo.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Wide310x150Logo.scale-125.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Wide310x150Logo.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Wide310x150Logo.scale-150.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Wide310x150Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Wide310x150Logo.scale-200.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Wide310x150Logo.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Wide310x150Logo.scale-400.png -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Resources/Images/dotnet_bot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/MauiBugDemos/ContextAndType/Resources/Images/dotnet_bot.png -------------------------------------------------------------------------------- /RoslynTesting/packages/repositories.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square150x150Logo.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square150x150Logo.scale-100.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square150x150Logo.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square150x150Logo.scale-125.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square150x150Logo.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square150x150Logo.scale-150.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square150x150Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square150x150Logo.scale-200.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square150x150Logo.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square150x150Logo.scale-400.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Wpf/Versions.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Wpf; 2 | 3 | internal static class Versions 4 | { 5 | internal const string AppVersion = "Development"; 6 | } 7 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-16.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-24.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-24.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-256.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-32.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-48.png -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Resources/Fonts/OpenSans-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/MauiBugDemos/ContextAndType/Resources/Fonts/OpenSans-Regular.ttf -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Resources/Fonts/OpenSans-Semibold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/MauiBugDemos/ContextAndType/Resources/Fonts/OpenSans-Semibold.ttf -------------------------------------------------------------------------------- /MauiPlayground/MauiPlayground/Resources/Fonts/OpenSans-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/MauiPlayground/MauiPlayground/Resources/Fonts/OpenSans-Regular.ttf -------------------------------------------------------------------------------- /RabbitHole/Code/packages/repositories.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/10 Now Don't Go Wasting My Precious Time.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/10 Now Don't Go Wasting My Precious Time.png -------------------------------------------------------------------------------- /RoslynAnalyzers/build.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | dotnet build -c Release RoslynAnalyzers.slnx 4 | dotnet pack -c Release -o $PWD JonSkeet.RoslynAnalyzers/JonSkeet.RoslynAnalyzers.Package 5 | -------------------------------------------------------------------------------- /AsyncIntro/Code/StockMarket/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /AsyncIntro/Code/StockService/app.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /AsyncIntro/Code/StockViewer/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /AsyncIntro/Code/Testing.MsTest/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Diagnostics/MessageDirection.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Diagnostics; 2 | 3 | public enum MessageDirection 4 | { 5 | ClientToMixer = 0, 6 | MixerToClient = 1 7 | } 8 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Blazor/Shared/MainLayout.razor: -------------------------------------------------------------------------------- 1 | @inherits LayoutComponentBase 2 | 3 |
4 |
5 | @Body 6 |
7 |
8 | -------------------------------------------------------------------------------- /RabbitHole/Code/RabbitHole/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Shed/Shed.Uwp/Assets/Square44x44Logo.targetsize-24_altform-unplated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Shed/Shed.Uwp/Assets/Square44x44Logo.targetsize-24_altform-unplated.png -------------------------------------------------------------------------------- /Abusing CSharp/Code/OperatorAbuse/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/Performance/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/WhatTheHeck/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/WhatTheHeck2/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/WrappingAsync/app.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/WrappingAsync/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /AsyncIntro/Code/AsyncHttpService/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Immutability/Builder3/notes.txt: -------------------------------------------------------------------------------- 1 | - Now the "main" type is the mutable type... 2 | - And the ToImmutable needs to go through and make everything immutable 3 | - Unlikely that many things would use it -------------------------------------------------------------------------------- /Abusing CSharp/Code/ExceptionFilters/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/FunWithAwaiters/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/LinqToOperators/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/NullConditional/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/VersionDetection/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /DemoUtil/JonSkeet.DemoUtil/targets/JonSkeet.DemoUtil.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | true 5 | 6 | 7 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/Views/Reports/Index.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Reports"; 3 | } 4 | 5 |

6 | Download the report 7 |

8 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Yamaha.Core/RequestResponseFlag.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Yamaha.Core; 2 | 3 | public enum RequestResponseFlag : byte 4 | { 5 | Request = 0x01, 6 | Response = 0x10 7 | } 8 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/StringInterpolation/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/Views/Home/Privacy.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Privacy Policy"; 3 | } 4 |

@ViewData["Title"]

5 | 6 |

Use this page to detail your site's privacy policy.

7 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.CqSeries.Core/CqMessageFormat.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.CqSeries.Core; 2 | 3 | public enum CqMessageFormat 4 | { 5 | VariableLength, 6 | FixedLength8, 7 | FixedLength9 8 | } 9 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Blazor/wwwroot/css/open-iconic/font/fonts/open-iconic.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/VDrumExplorer.Blazor/wwwroot/css/open-iconic/font/fonts/open-iconic.eot -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Blazor/wwwroot/css/open-iconic/font/fonts/open-iconic.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/VDrumExplorer.Blazor/wwwroot/css/open-iconic/font/fonts/open-iconic.otf -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Blazor/wwwroot/css/open-iconic/font/fonts/open-iconic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/VDrumExplorer.Blazor/wwwroot/css/open-iconic/font/fonts/open-iconic.ttf -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Blazor/wwwroot/css/open-iconic/font/fonts/open-iconic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/Drums/VDrumExplorer.Blazor/wwwroot/css/open-iconic/font/fonts/open-iconic.woff -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Yamaha/SchemaPropertyType.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Yamaha; 2 | 3 | public enum SchemaPropertyType : byte 4 | { 5 | Text = 0, 6 | SignedInteger = 1, 7 | UnsignedInteger= 2 8 | } 9 | -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/AppShell.xaml.cs: -------------------------------------------------------------------------------- 1 | namespace ContextAndType; 2 | 3 | public partial class AppShell : Shell 4 | { 5 | public AppShell() 6 | { 7 | InitializeComponent(); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/Configuration/ReportDbConfig.cs: -------------------------------------------------------------------------------- 1 | namespace Example1a.Configuration 2 | { 3 | public class ReportDbConfig 4 | { 5 | public string ConnectionString { get; set; } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-unplated_targetsize-16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-unplated_targetsize-16.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-unplated_targetsize-256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-unplated_targetsize-256.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-unplated_targetsize-32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-unplated_targetsize-32.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-unplated_targetsize-48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-unplated_targetsize-48.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-24_altform-unplated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.targetsize-24_altform-unplated.png -------------------------------------------------------------------------------- /SpiceGirlsApiDesign/12 If You Wanna Be My Lover, You Gotta Get With My Friends.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/SpiceGirlsApiDesign/12 If You Wanna Be My Lover, You Gotta Get With My Friends.png -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/MainPage.xaml.cs: -------------------------------------------------------------------------------- 1 | namespace ContextAndType; 2 | 3 | public partial class MainPage : ContentPage 4 | { 5 | public MainPage() 6 | { 7 | InitializeComponent(); 8 | } 9 | } 10 | 11 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/Views/Home/About.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "About"; 3 | } 4 |

@ViewData["Title"]

5 |

@ViewData["Message"]

6 | 7 |

Use this area to provide additional information.

8 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-lightunplated_targetsize-16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-lightunplated_targetsize-16.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-lightunplated_targetsize-24.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-lightunplated_targetsize-24.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-lightunplated_targetsize-256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-lightunplated_targetsize-256.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-lightunplated_targetsize-32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-lightunplated_targetsize-32.png -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-lightunplated_targetsize-48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jskeet/DemoCode/HEAD/DigiMixer/DigiMixer.Msix/Images/Square44x44Logo.altform-lightunplated_targetsize-48.png -------------------------------------------------------------------------------- /PclPal/PclPal.Tool/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /CSharp7/CSharp7/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /CSharp8/Nullability/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/Models/IReportRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Example1a.Models 4 | { 5 | public interface IReportRepository 6 | { 7 | Report GetReport(DateTime date); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /DialogflowDemo/DialogflowDemo/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Warning" 5 | } 6 | }, 7 | "AllowedHosts": "*", 8 | "FirestoreProject": "jonskeet-personal" 9 | } 10 | -------------------------------------------------------------------------------- /Immutability/Builder1/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Immutability/Builder2/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Immutability/Builder3/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Immutability/Record/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Immutability/Withers/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /AsyncIntro/Code/StockViewer/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /AsyncIntro/Code/UnderTheHood/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.Core/WingProtocolChannel.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.BehringerWing.Core; 2 | 3 | public enum WingProtocolChannel : byte 4 | { 5 | None = 0, 6 | AudioEngine = 1, 7 | MeterDataRequests = 3 8 | } 9 | -------------------------------------------------------------------------------- /RabbitHole/Code/RabbitHole/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /TravisConsole/TravisConsole.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp3.1 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/OddsAndEnds/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/OperatorAbuse/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/WhatTheHeck2/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /AsyncIntro/Code/AsyncHttpService/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Diagnostics/Example1c/Example1c.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp2.0 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Diagnostics/Example1d/Example1d.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp2.0 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Diagnostics/Example3c/Example3c.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp1.0 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Diagnostics/UnhelpfulDebugger/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /DialogflowDemo/DialogflowDemo/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Debug", 5 | "System": "Information", 6 | "Microsoft": "Information" 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Immutability/LanguageFeatures/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/App.xaml.cs: -------------------------------------------------------------------------------- 1 | namespace ContextAndType; 2 | 3 | public partial class App : Application 4 | { 5 | public App() 6 | { 7 | InitializeComponent(); 8 | 9 | MainPage = new AppShell(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Versioning/ExtractCode/ExtractCode.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp2.1 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/ExceptionFilters/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/FunWithAwaiters/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/LinqToOperators/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/NullConditional/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/VersionDetection/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Immutability/LanguageFeatures/ValueType.cs: -------------------------------------------------------------------------------- 1 | public struct Point 2 | { 3 | public int X { get; } 4 | public int Y { get; } 5 | 6 | public Point(int x, int y) 7 | { 8 | X = x; 9 | Y = y; 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/StringInterpolation/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /DemoUtil/JonSkeet.DemoUtil.Test/Program.cs: -------------------------------------------------------------------------------- 1 | namespace JonSkeet.DemoUtil.Test 2 | { 3 | class Program 4 | { 5 | static void Main(string[] args) 6 | { 7 | ApplicationChooser.Run(); 8 | } 9 | } 10 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.NetFrameworkProfiling/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Immutability/Builder1/notes.txt: -------------------------------------------------------------------------------- 1 | - No public constructors in immutable class; private constructor accepts builder 2 | - Builder properties all take immutable classes 3 | - Builder uses List, pre-initialized 4 | - New object created each time 5 | 6 | -------------------------------------------------------------------------------- /AsyncIntro/Code/Testing.NUnit/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /Versioning/runall.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -e 4 | 5 | rm -rf output 6 | for i in examples/*.txt; do 7 | echo $i 8 | dotnet run -p ExtractCode -- $i output 9 | ./runcode.sh output/$(echo $i | sed s/examples//g | sed s/.txt//g) 10 | done 11 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Proto/README.md: -------------------------------------------------------------------------------- 1 | To generate the code, run: 2 | 3 | ```sh 4 | $PROTOC -I $PROTOROOT -I . DrumFiles.proto --csharp_out=. --csharp_opt=internal_access,file_extension=.g.cs 5 | ``` 6 | 7 | ... with a suitable value for PROTOC and PROTOROOT. 8 | -------------------------------------------------------------------------------- /IconPlatform/IconPlatform.Model/ButtonType.cs: -------------------------------------------------------------------------------- 1 | namespace IconPlatform.Model 2 | { 3 | public enum ButtonType 4 | { 5 | Sel, 6 | Mute, 7 | Solo, 8 | Record, 9 | Knob, 10 | Fader 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /Immutability/Builder1/PhoneNumberType.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. All Rights Reserved. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | public enum PhoneNumberType 5 | { 6 | Mobile = 0, 7 | Home = 1, 8 | Work = 2 9 | } 10 | -------------------------------------------------------------------------------- /Immutability/Builder2/PhoneNumberType.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. All Rights Reserved. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | public enum PhoneNumberType 5 | { 6 | Mobile = 0, 7 | Home = 1, 8 | Work = 2 9 | } 10 | -------------------------------------------------------------------------------- /Immutability/Builder3/PhoneNumberType.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. All Rights Reserved. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | public enum PhoneNumberType 5 | { 6 | Mobile = 0, 7 | Home = 1, 8 | Work = 2 9 | } 10 | -------------------------------------------------------------------------------- /Immutability/Withers/PhoneNumberType.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. All Rights Reserved. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | public enum PhoneNumberType 5 | { 6 | Mobile = 0, 7 | Home = 1, 8 | Work = 2 9 | } 10 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "LogLevel": { 5 | "Default": "Debug", 6 | "System": "Information", 7 | "Microsoft": "Information" 8 | } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /MauiPlayground/MauiPlayground/App.xaml.cs: -------------------------------------------------------------------------------- 1 | namespace MauiPlayground; 2 | 3 | public partial class App : Application 4 | { 5 | public App() 6 | { 7 | InitializeComponent(); 8 | 9 | MainPage = new ListViewDemo(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "LogLevel": { 5 | "Default": "Warning" 6 | } 7 | }, 8 | "ReportDb": { 9 | "ConnectionString": "Not a real connection string" 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.DmSeries.Core/DmSegmentFormat.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.DmSeries.Core; 2 | 3 | public enum DmSegmentFormat : byte 4 | { 5 | Binary = 0x11, 6 | UInt16 = 0x12, 7 | UInt32 = 0x14, 8 | Int32 = 0x24, 9 | Text = 0x31, 10 | } 11 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.UiHttp/formatted-cur-setup.json.txt: -------------------------------------------------------------------------------- 1 | { 2 | input: 24, 3 | fx: 4, 4 | aux: 10, 5 | bankSize: 8, 6 | sub: 6, 7 | maxx: false, 8 | rec: true, 9 | phantom: 20, 10 | linein: 2, 11 | uniqueid: "8100C002204620952082107914052408" 12 | } -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Yamaha.Core/YamahaSegmentFormat.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Yamaha.Core; 2 | 3 | public enum YamahaSegmentFormat : byte 4 | { 5 | Binary = 0x11, 6 | UInt16 = 0x12, 7 | UInt32 = 0x14, 8 | Int32 = 0x24, 9 | Text = 0x31, 10 | } 11 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Yamaha/DataSubtypes.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Yamaha; 2 | 3 | public static class DataSubtypes 4 | { 5 | // For MMIX 6 | public const string Mixing = "Mixing"; 7 | // For MPRO 8 | public const string Property = "Property"; 9 | } 10 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Please see documentation at https://docs.microsoft.com/aspnet/core/client-side/bundling-and-minification 2 | // for details on configuring this project to bundle and minify static web assets. 3 | 4 | // Write your JavaScript code. 5 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.WingExplorer/App.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows; 2 | 3 | namespace DigiMixer.BehringerWing.WingExplorer; 4 | /// 5 | /// Interaction logic for App.xaml 6 | /// 7 | public partial class App : Application 8 | { 9 | } 10 | 11 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.UiHttp/parameters.txt: -------------------------------------------------------------------------------- 1 | // This is the format of /js/initparams.js: 2 | 3 | curSetup = /* see formatted-cur-setup.json */;function staticInitDataArray() {dataValue=/* see formatted-data-config.json */; 4 | 5 | netConfig=/* see formatted-net-config.json */; 6 | 7 | } -------------------------------------------------------------------------------- /Abusing CSharp/Code/OddsAndEnds/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/Models/ReportLine.cs: -------------------------------------------------------------------------------- 1 | namespace Example1a.Models 2 | { 3 | public class ReportLine 4 | { 5 | public string ProductName { get; set; } 6 | public decimal Price { get; set; } 7 | public int Quantity { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.Core/WingNodeUnit.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.BehringerWing.Core; 2 | 3 | public enum WingNodeUnit 4 | { 5 | None, 6 | Decibels, 7 | Percent, 8 | Milliseconds, 9 | Hertz, 10 | Meters, 11 | Seconds, 12 | Octaves 13 | } 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Mackie.Core/MackieMessageType.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Mackie.Core; 2 | 3 | public enum MackieMessageType : byte 4 | { 5 | Request = 0, 6 | Response = 1, 7 | Error = 5, // Seen when requesting info that isn't available. 8 | Broadcast = 8 9 | } 10 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD07/Physical/Current.json: -------------------------------------------------------------------------------- 1 | { 2 | "size": "0x1", 3 | "fields": [ 4 | { 5 | "description": "Current kit", 6 | "type": "range8", 7 | "valueOffset": 1, 8 | "min": 0, 9 | "max": 49 10 | } 11 | ] 12 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD17/Physical/Current.json: -------------------------------------------------------------------------------- 1 | { 2 | "size": "0x1", 3 | "fields": [ 4 | { 5 | "description": "Current kit", 6 | "type": "range8", 7 | "valueOffset": 1, 8 | "min": 0, 9 | "max": 99 10 | } 11 | ] 12 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD27/Physical/Current.json: -------------------------------------------------------------------------------- 1 | { 2 | "size": "0x1", 3 | "fields": [ 4 | { 5 | "description": "Current kit", 6 | "type": "range8", 7 | "valueOffset": 1, 8 | "min": 0, 9 | "max": 99 10 | } 11 | ] 12 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50/Physical/Current.json: -------------------------------------------------------------------------------- 1 | { 2 | "size": "0x1", 3 | "fields": [ 4 | { 5 | "description": "Current kit", 6 | "type": "range8", 7 | "valueOffset": 1, 8 | "min": 0, 9 | "max": 99 10 | } 11 | ] 12 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50X/Physical/Current.json: -------------------------------------------------------------------------------- 1 | { 2 | "size": "0x1", 3 | "fields": [ 4 | { 5 | "description": "Current kit", 6 | "type": "range8", 7 | "valueOffset": 1, 8 | "min": 0, 9 | "max": 99 10 | } 11 | ] 12 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.ViewModel.Test/UnitTest1.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using Xunit; 3 | 4 | namespace VDrumExplorer.ViewModel.Test 5 | { 6 | public class UnitTest1 7 | { 8 | [Fact] 9 | public void Test1() 10 | { 11 | 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /MauiPlayground/MauiPlayground/Resources/appicon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/FunWithAwaiters/ITransient.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | 3 | namespace FunWithAwaiters 4 | { 5 | interface ITransient 6 | { 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /Immutability/model.txt: -------------------------------------------------------------------------------- 1 | Basic data model: 2 | 3 | Person 4 | - Name 5 | - Address 6 | - Phone numbers 7 | - Friends (stretch goal) 8 | 9 | Address 10 | - Street 11 | - City 12 | 13 | Phone number: 14 | - Number 15 | - Type (enum) 16 | 17 | Number type: 18 | - Home, Mobile, Work 19 | -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Resources/AppIcon/appicon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.CqSeries/CqUnknownMessage.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.CqSeries.Core; 2 | 3 | namespace DigiMixer.CqSeries; 4 | 5 | internal sealed class CqUnknownMessage : CqMessage 6 | { 7 | internal CqUnknownMessage(CqRawMessage rawMessage) : base(rawMessage) 8 | { 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD27/Physical/SetupControl.json: -------------------------------------------------------------------------------- 1 | { 2 | "size": "0x01", 3 | "fields": [ 4 | { 5 | "description": "Trigger Bank Number", 6 | "type": "range8", 7 | "min": 0, 8 | "max": 7, 9 | "valueOffset": 1 10 | } 11 | ] 12 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50/Physical/SetupControl.json: -------------------------------------------------------------------------------- 1 | { 2 | "size": "0x01", 3 | "fields": [ 4 | { 5 | "description": "Trigger Bank Number", 6 | "type": "range8", 7 | "min": 0, 8 | "max": 7, 9 | "valueOffset": 1 10 | } 11 | ] 12 | } -------------------------------------------------------------------------------- /Immutability/Slides/030 Benefits.txt: -------------------------------------------------------------------------------- 1 | So why do we want immutability? 2 | 3 | - Java programmers: worst bits of the standard library? 4 | - Thread safety - more later 5 | - Efficiency (potentially) - no defensive copying 6 | - Easier to reason about code 7 | - Mutable structs behave plain weirdly 8 | -------------------------------------------------------------------------------- /Immutability/Slides/060 Memory model.txt: -------------------------------------------------------------------------------- 1 | Memory model in C# 2 | - Doesn't really have one... 3 | - Bits of it are specified... 4 | - ECMA-335 has a weak memory model 5 | - Blog posts have more details 6 | - But even so, too weak to reason about 7 | - ... except that reality is actually okay, I think -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Platforms/Android/Resources/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #512BD4 4 | #2B0B98 5 | #2B0B98 6 | -------------------------------------------------------------------------------- /MauiPlayground/MauiPlayground/Platforms/Android/Resources/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #512BD4 4 | #2B0B98 5 | #2B0B98 6 | -------------------------------------------------------------------------------- /Shed/Shed.Uwp/App.xaml: -------------------------------------------------------------------------------- 1 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Example1a.Models 4 | { 5 | public class ErrorViewModel 6 | { 7 | public string RequestId { get; set; } 8 | 9 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 10 | } 11 | } -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Core/IMixerMessage.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Core; 2 | 3 | public interface IMixerMessage where TSelf : class, IMixerMessage 4 | { 5 | static abstract TSelf? TryParse(ReadOnlySpan data); 6 | int Length { get; } 7 | void CopyTo(Span buffer); 8 | } 9 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.SqSeries/SqUnknownMessage.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.AllenAndHeath.Core; 2 | 3 | namespace DigiMixer.SqSeries; 4 | 5 | internal sealed class SqUnknownMessage : SqMessage 6 | { 7 | internal SqUnknownMessage(AHRawMessage rawMessage) : base(rawMessage) 8 | { 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD17/Physical/Setup.json: -------------------------------------------------------------------------------- 1 | { 2 | "containers": [ 3 | { 4 | "name": "Click", 5 | "offset": "0x02_00" 6 | }, 7 | { 8 | "name": "Misc", 9 | "offset": "0x03_00", 10 | "container": "SetupMisc" 11 | } 12 | ] 13 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50X/Physical/SetupControl.json: -------------------------------------------------------------------------------- 1 | { 2 | "size": "0x01", 3 | "fields": [ 4 | { 5 | "description": "Trigger Bank Number", 6 | "type": "range8", 7 | "min": 0, 8 | "max": 7, 9 | "valueOffset": 1 10 | } 11 | ] 12 | } -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Platforms/iOS/AppDelegate.cs: -------------------------------------------------------------------------------- 1 | using Foundation; 2 | 3 | namespace ContextAndType; 4 | 5 | [Register("AppDelegate")] 6 | public class AppDelegate : MauiUIApplicationDelegate 7 | { 8 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp(); 9 | } 10 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.UCNet.Core/Messages/MeterSource.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.UCNet.Core.Messages; 2 | 3 | public enum MeterSource 4 | { 5 | Input = 0, 6 | Return = 1, 7 | FxReturn = 2, 8 | TalkBack = 3, 9 | Aux = 4, 10 | Fx = 5, 11 | Unknown = 6, 12 | Main = 7 13 | } 14 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD07/Physical/Setup.json: -------------------------------------------------------------------------------- 1 | { 2 | "containers": [ 3 | { 4 | "name": "Metronome", 5 | "offset": "0x00_00" 6 | }, 7 | { 8 | "name": "Misc", 9 | "offset": "0x01_00", 10 | "container": "SetupMisc" 11 | } 12 | ] 13 | } -------------------------------------------------------------------------------- /VersioningBlogPost/Diamond/Lib1/Lib1.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net471 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /AsyncIntro/Code/StockService/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace StockService 7 | { 8 | class Program 9 | { 10 | static void Main(string[] args) 11 | { 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Diagnostics/Example2a/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /Diagnostics/Example2c/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Platforms/MacCatalyst/AppDelegate.cs: -------------------------------------------------------------------------------- 1 | using Foundation; 2 | 3 | namespace ContextAndType; 4 | 5 | [Register("AppDelegate")] 6 | public class AppDelegate : MauiUIApplicationDelegate 7 | { 8 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp(); 9 | } 10 | -------------------------------------------------------------------------------- /TravisConsole/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | class Program 4 | { 5 | static void Main(string[] args) 6 | { 7 | int count = int.Parse(args[0]); 8 | for (int i = 1; i <= count; i++) 9 | { 10 | Console.WriteLine($"Line {i}"); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /.hgignore: -------------------------------------------------------------------------------- 1 | syntax: glob 2 | 3 | # User-specific files 4 | *.suo 5 | *.user 6 | *.sln.docstates 7 | 8 | # Roslyn (?) files 9 | *.sln.ide 10 | 11 | syntax:regexp 12 | 13 | # Nuget 14 | packages/.*/ 15 | 16 | # Build results 17 | 18 | [Dd]ebug/ 19 | [Rr]elease/ 20 | x64/ 21 | build/ 22 | [Bb]in/ 23 | [Oo]bj/ -------------------------------------------------------------------------------- /AsyncIntro/Code/StockViewer/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Core/ControllerStatus.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Core; 2 | 3 | /// 4 | /// Common controller statuses. 5 | /// 6 | public enum ControllerStatus 7 | { 8 | NotConnected = 0, 9 | Connected = 1, 10 | Running = 2, 11 | Faulted = 3, 12 | Disposed = 4 13 | } 14 | -------------------------------------------------------------------------------- /Immutability/Record/notes.txt: -------------------------------------------------------------------------------- 1 | - Wow, that's neat! 2 | - "with" syntax allows multiple properties to be set at once (clean and efficient) 3 | - Oh, and generates equality and ToString checks, like anonymous classes 4 | - Unclear whether it's possible to restrict construction 5 | (e.g. private constructor, public type) -------------------------------------------------------------------------------- /Shed/README.md: -------------------------------------------------------------------------------- 1 | # Building the Shed Voice Control System 2 | 3 | This probably isn't useful for anyone other than me (Jon Skeet), but 4 | if you *do* want to build and run this code, open it in Visual 5 | Studio 2017 - it won't work in VS2015, as it relies on the new 6 | tooling for .NET Core projects via MSBuild. 7 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/Example1a.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netcoreapp2.1 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/Models/Report.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace Example1a.Models 5 | { 6 | public class Report 7 | { 8 | public DateTime Date { get; set; } 9 | public List Lines { get; } = new List(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.UCNet.Core/MessageMode.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.UCNet.Core; 2 | 3 | public enum MessageMode : uint 4 | { 5 | UdpMeters = 0x00_65_00_00, 6 | ClientRequest = 0x00_65_00_6a, 7 | Compressed = 0x00_6a_00_65, 8 | MixerUpdate = 0x00_6b_00_65, 9 | FileRequest = 0x00_65_00_6b 10 | } 11 | -------------------------------------------------------------------------------- /CSharp7/CSharp7/Scratchpad.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2017 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | namespace CSharp7 3 | { 4 | class Scratchpad 5 | { 6 | static void Main() 7 | { 8 | } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /DateTimeDemos/TimeZoneInfoExplorer/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Core/MixerInfo.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Core; 2 | 3 | public sealed record MixerInfo(string? Model, string? Name, string? Version) 4 | { 5 | public override string ToString() => $"{Name} ({Model}: {Version})"; 6 | 7 | public static MixerInfo Empty { get; } = new MixerInfo(null, null, null); 8 | } 9 | -------------------------------------------------------------------------------- /Immutability/Builder2/notes.txt: -------------------------------------------------------------------------------- 1 | - Still no public constructor in immutable class 2 | - Builder has a reference to the "immutable" class; only exposes it when frozen 3 | - Collection is frozen on publication too 4 | - More efficient when there are lots of properties 5 | - Feels significantly less robust in terms of threading 6 | -------------------------------------------------------------------------------- /MauiPlayground/MauiPlayground/Platforms/iOS/AppDelegate.cs: -------------------------------------------------------------------------------- 1 | using Foundation; 2 | 3 | namespace MauiPlayground 4 | { 5 | [Register("AppDelegate")] 6 | public class AppDelegate : MauiUIApplicationDelegate 7 | { 8 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp(); 9 | } 10 | } -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.Core/WingNodeType.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.BehringerWing.Core; 2 | 3 | public enum WingNodeType 4 | { 5 | Node = 0, 6 | LinearFloat = 1, 7 | LogFloat = 2, 8 | FaderLevel = 3, 9 | Integer = 4, 10 | StringEnum = 5, 11 | FloatEnum = 6, 12 | String = 7 13 | } 14 | -------------------------------------------------------------------------------- /Immutability/Slides/010 Agenda.txt: -------------------------------------------------------------------------------- 1 | Code at https://github.com/jskeet/DemoCode/Immutability 2 | 3 | - What is immutability? 4 | - Why do we like immutability? 5 | - C# evolution in immutability 6 | - Interlude: memory models 7 | - Examples with a common data model 8 | - Opposing forces and anti-patterns 9 | - The future 10 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Wpf/MainWindow.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows; 2 | 3 | namespace DigiMixer.Wpf; 4 | /// 5 | /// Interaction logic for MainWindow.xaml 6 | /// 7 | public partial class MainWindow : Window 8 | { 9 | public MainWindow() 10 | { 11 | InitializeComponent(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /MauiPlayground/MauiPlayground/Platforms/MacCatalyst/AppDelegate.cs: -------------------------------------------------------------------------------- 1 | using Foundation; 2 | 3 | namespace MauiPlayground 4 | { 5 | [Register("AppDelegate")] 6 | public class AppDelegate : MauiUIApplicationDelegate 7 | { 8 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp(); 9 | } 10 | } -------------------------------------------------------------------------------- /CSharp7/CSharp7/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Versioning/examples/remove-public-method.txt: -------------------------------------------------------------------------------- 1 | #class 2 | public static void Method() => Console.WriteLine("Output"); 3 | ---- 4 | #class 5 | ---- 6 | #main 7 | LibraryClass.Method(); 8 | ---- 9 | # Removing a public method 10 | 11 | Removing a public method is a simple breaking change for both source 12 | and binary compatibility. 13 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD17/Logical/Setup.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Setup", 3 | "format": "Setup", 4 | "path": "Setup", 5 | "details": [ 6 | { 7 | "description": "Click", 8 | "path": "Click" 9 | }, 10 | { 11 | "description": "Misc", 12 | "path": "Misc" 13 | } 14 | ] 15 | } 16 | -------------------------------------------------------------------------------- /CSharp7/CSharp7/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using JonSkeet.DemoUtil; 3 | 4 | namespace CSharp7 5 | { 6 | class Program 7 | { 8 | static void Main() => ApplicationChooser.Run(); 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /CSharp8/Async/Async.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp3.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /CSharp8/Patterns/DateTimeExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace PatternsAndRanges 4 | { 5 | static class DateTimeExtensions 6 | { 7 | public static void Deconstruct(this DateTime date, out int year, out int month, out int day) => 8 | (year, month, day) = (date.Year, date.Month, date.Day); 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /DemoUtil/JonSkeet.DemoUtil.Test/DemoWithException.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace JonSkeet.DemoUtil.Test 6 | { 7 | class DemoWithException 8 | { 9 | static void Main() 10 | { 11 | throw new Exception("Bang!"); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD07/Logical/Setup.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Setup", 3 | "format": "Setup", 4 | "path": "Setup", 5 | "details": [ 6 | { 7 | "description": "Metronome", 8 | "path": "Metronome" 9 | }, 10 | { 11 | "description": "Misc", 12 | "path": "Misc" 13 | } 14 | ] 15 | } 16 | -------------------------------------------------------------------------------- /Immutability/LanguageFeatures/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace LanguageFeatures 8 | { 9 | class Program 10 | { 11 | static void Main(string[] args) 12 | { 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /CSharp8/Patterns/Patterns.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp3.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DialogflowDemo/MentorSearchModels/MentorSearchModels.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netcoreapp2.1 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /DmxLighting/DmxLighting.WpfGui/FixtureViewModel.cs: -------------------------------------------------------------------------------- 1 | using DmxLighting.Data; 2 | 3 | namespace DmxLighting.WpfGui 4 | { 5 | internal class FixtureViewModel 6 | { 7 | public FixtureData Data { get; set; } 8 | public StreamingAcnSender Sender { get; set; } 9 | public DmxUniverse Universe { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /OscMixerControl/OscMixerControl/OscMixerControl.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netstandard2.1 5 | 10.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /IconPlatform/IconPlatform.Model/FaderEventArgs.cs: -------------------------------------------------------------------------------- 1 | namespace IconPlatform.Model 2 | { 3 | public sealed record FaderEventArgs 4 | { 5 | public int Channel { get; } 6 | 7 | public int Position { get; } 8 | 9 | public FaderEventArgs(int channel, int position) => (Channel, Position) = (channel, position); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /RoslynAnalyzers/JonSkeet.RoslynAnalyzers/JonSkeet.RoslynAnalyzers.Package/README.md: -------------------------------------------------------------------------------- 1 | Roslyn analyzers developed by Jon Skeet. 2 | 3 | Source code is at 4 | https://github.com/jskeet/DemoCode/tree/main/RoslynAnalyzers 5 | 6 | Licensed under Apache-2.0 license. 7 | 8 | Currently I make no guarantees about analyzer stability etc. These 9 | are mostly for personal use. -------------------------------------------------------------------------------- /VersioningBlogPost/Diamond/Lib1/Class1.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using NodaTime; 3 | 4 | namespace Lib1 5 | { 6 | public class Class1 7 | { 8 | public static LocalDate GetFixedDate() => 9 | new LocalDate(2019, 6, 29); 10 | 11 | public static Instant GetNow(IClock clock) => 12 | clock.Now; 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /CSharp8/IndexAndRange/IndexAndRange.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp3.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /CSharp8/MinorFeatures/MinorFeatures.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp3.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /Diagnostics/Example1b/Example1b.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp2.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Controls/ChannelGroup.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Controls; 2 | 3 | namespace DigiMixer.Controls; 4 | /// 5 | /// Interaction logic for ChannelGroup.xaml 6 | /// 7 | public partial class ChannelGroup : UserControl 8 | { 9 | public ChannelGroup() 10 | { 11 | InitializeComponent(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Functions/HelloWorld/HelloWorld.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | Exe 4 | netcoreapp3.1 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /WpfUtil/WpfUtil.slnx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Diagnostics/Example2b/Example2b.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp2.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.SqSeries/SqMixer.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Core; 2 | using Microsoft.Extensions.Logging; 3 | 4 | namespace DigiMixer.SqSeries; 5 | 6 | public class SqMixer 7 | { 8 | public static IMixerApi CreateMixerApi(ILogger logger, string host, int port = 51326, MixerApiOptions? options = null) => 9 | throw new NotImplementedException(); 10 | } 11 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Wpf/DigiMixerAppConfig.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.AppCore; 2 | using JonSkeet.WpfLogging; 3 | 4 | namespace DigiMixer.Wpf; 5 | 6 | public class DigiMixerAppConfig 7 | { 8 | public LoggingConfig Logging { get; set; } = new(); 9 | public DigiMixerConfig Mixer { get; set; } = new(); 10 | public bool EnablePeripherals { get; set; } 11 | } 12 | -------------------------------------------------------------------------------- /Versioning/index-template.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Index of versioning examples 3 | --- 4 | 5 | This area of the democode site contains examples of breaking and 6 | non-breaking changes. 7 | 8 | These are generated from [these 9 | files](https://github.com/jskeet/DemoCode/tree/master/Versioning/examples). 10 | Very much a work in progress! 11 | 12 | List of pages: 13 | -------------------------------------------------------------------------------- /CameraControl/CameraControl.Visca/PowerStatus.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2020 Jon Skeet. All rights reserved. 2 | // Use of this source code is governed by the Apache License 2.0, 3 | // as found in the LICENSE.txt file. 4 | 5 | namespace CameraControl.Visca; 6 | 7 | public enum PowerStatus 8 | { 9 | On = 2, 10 | Standby = 3, 11 | InternalPowerCircuitError = 4 12 | } 13 | -------------------------------------------------------------------------------- /DemoUtil/JonSkeet.DemoUtil.Test/DemoWithoutDescription.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace JonSkeet.DemoUtil.Test 6 | { 7 | class DemoWithoutDescription 8 | { 9 | static void Main() 10 | { 11 | Console.WriteLine("This demo has no description"); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/ParentViewModel.cs: -------------------------------------------------------------------------------- 1 | namespace ContextAndType; 2 | 3 | public class ParentViewModel 4 | { 5 | public string Text => "ParentText"; 6 | public ChildViewModel Child { get; } = new ChildViewModel(); 7 | } 8 | 9 | public class ChildViewModel 10 | { 11 | public string Text => "ChildText"; 12 | public string Text2 => "ChildText2"; 13 | } -------------------------------------------------------------------------------- /Shed/Shed.Uwp/project.json: -------------------------------------------------------------------------------- 1 | { 2 | "dependencies": { 3 | "Microsoft.NETCore.UniversalWindowsPlatform": "5.2.2" 4 | }, 5 | "frameworks": { 6 | "uap10.0": {} 7 | }, 8 | "runtimes": { 9 | "win10-arm": {}, 10 | "win10-arm-aot": {}, 11 | "win10-x86": {}, 12 | "win10-x86-aot": {}, 13 | "win10-x64": {}, 14 | "win10-x64-aot": {} 15 | } 16 | } -------------------------------------------------------------------------------- /CSharp8/DefaultInterfaceMethods/DefaultInterfaceMethods.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp3.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Controls/MixerControlPanel.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Controls; 2 | 3 | namespace DigiMixer.Controls; 4 | /// 5 | /// Interaction logic for MixerControlPanel.xaml 6 | /// 7 | public partial class MixerControlPanel : UserControl 8 | { 9 | public MixerControlPanel() 10 | { 11 | InitializeComponent(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.UCNet.Core/Messages/MeterStage.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.UCNet.Core.Messages; 2 | 3 | // TODO: Validate these against different sources... 4 | public enum MeterStage 5 | { 6 | Raw = 0, 7 | PostHpf = 1, 8 | PostGate = 2, 9 | PostCompressor = 3, 10 | PostEQ = 4, 11 | PostLimiter = 5, 12 | PostFader = 6, 13 | Unknonw = 7 14 | } 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Yamaha/YamahaClientExtensions.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Yamaha.Core; 2 | 3 | namespace DigiMixer.Yamaha; 4 | 5 | public static class YamahaClientExtensions 6 | { 7 | public static Task SendAsync(this YamahaClient client, WrappedMessage message, CancellationToken cancellationToken) => 8 | client.SendAsync(message.RawMessage, cancellationToken); 9 | } 10 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD07/VEdit/Other.json: -------------------------------------------------------------------------------- 1 | { 2 | "fields": [ 3 | { 4 | "description": "Pitch", 5 | "type": "range16", 6 | "min": -100, 7 | "max": 100 8 | }, 9 | { 10 | "description": "Decay", 11 | "type": "range16", 12 | "min": 1, 13 | "max": 100, 14 | "default": 100 15 | } 16 | ] 17 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD17/VEdit/Other.json: -------------------------------------------------------------------------------- 1 | { 2 | "fields": [ 3 | { 4 | "description": "Pitch", 5 | "type": "range32", 6 | "min": -4800, 7 | "max": 4800 8 | }, 9 | { 10 | "description": "Decay", 11 | "type": "range32", 12 | "min": 1, 13 | "max": 100, 14 | "default": 100 15 | } 16 | ] 17 | } -------------------------------------------------------------------------------- /VersioningBlogPost/Diamond/App/Program.cs: -------------------------------------------------------------------------------- 1 | using Lib1; 2 | using NodaTime; 3 | using System; 4 | 5 | namespace App 6 | { 7 | class Program 8 | { 9 | static void Main(string[] args) 10 | { 11 | Console.WriteLine(Class1.GetFixedDate()); 12 | Console.WriteLine(Class1.GetNow(SystemClock.Instance)); 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /XTouchMini/XTouchMini.Console/XTouchMini.Console.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | net10.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DmxLighting/DmxLighting.ConsoleApp/DmxLighting.ConsoleApp.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp3.1 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.InstrumentParser/VDrumExplorer.InstrumentParser.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | net6.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Platforms/Windows/App.xaml: -------------------------------------------------------------------------------- 1 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /MauiPlayground/MauiPlayground/Platforms/Windows/App.xaml: -------------------------------------------------------------------------------- 1 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /AsyncIntro/Code/StockMarket/StockPrice.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | namespace StockMarket 3 | { 4 | internal sealed class StockPrice 5 | { 6 | internal string Ticker { get; set; } 7 | internal decimal Price { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /DemoUtil/JonSkeet.DemoUtil.Test/DemoWithDescription.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.ComponentModel; 3 | 4 | namespace JonSkeet.DemoUtil.Test 5 | { 6 | [Description("This is a description")] 7 | class DemoWithDescription 8 | { 9 | static void Main() 10 | { 11 | Console.WriteLine("This demo has a description"); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /OscMixerControl/OscMixerControl.Console/OscMixerControl.Console.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | net10.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.TfSeries.Tools/DecodingOptions.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.TfSeries.Tools; 2 | 3 | internal record DecodingOptions(bool SkipKeepAlive, bool DecodeSchema, bool DecodeData, bool ShowAllSegments) 4 | { 5 | internal static DecodingOptions Simple { get; } = new(false, false, false, false); 6 | internal static DecodingOptions Investigative { get; } = new(false, false, false, true); 7 | } -------------------------------------------------------------------------------- /IconPlatform/IconPlatform.ConsoleDemo/IconPlatform.ConsoleDemo.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | net10.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /VersioningBlogPost/Diamond/App/App.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | Exe 4 | net471 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /Abusing CSharp/Text/intro.txt: -------------------------------------------------------------------------------- 1 | 2 | Abusing C# (more) 3 | Jon Skeet 4 | 5 | 6 | Welcome! 7 | 8 | Code is all at https://github.com/jskeet/democode 9 | (under Abusing CSharp) 10 | 11 | Do not use any of this code in production! 12 | 13 | Me: 14 | Twitter: @jonskeet 15 | Code blog: https://codeblog.jonskeet.uk 16 | Non-code blog: https://blog.jonskeet.uk 17 | -------------------------------------------------------------------------------- /AsyncIntro/readme.md: -------------------------------------------------------------------------------- 1 | This is the source code I've used in multiple talks, as well as 2 | the [Tekpub Async series](http://tekpub.com/products/async) and the 3 | third edition of [C# in Depth](http://csharpindepth.com). 4 | 5 | Still to come: notes to make sense of the code! These won't be nearly 6 | as detailed as the talks, screencasts or book, but they should at 7 | least give a reasonable starting point. -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.WingExplorer/ExplorerPanel.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Controls; 2 | 3 | namespace DigiMixer.BehringerWing.WingExplorer; 4 | /// 5 | /// Interaction logic for ExplorerPanel.xaml 6 | /// 7 | public partial class ExplorerPanel : UserControl 8 | { 9 | public ExplorerPanel() 10 | { 11 | InitializeComponent(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.WingExplorer/ProgressPanel.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Controls; 2 | 3 | namespace DigiMixer.BehringerWing.WingExplorer; 4 | /// 5 | /// Interaction logic for ProgressPanel.xaml 6 | /// 7 | public partial class ProgressPanel : UserControl 8 | { 9 | public ProgressPanel() 10 | { 11 | InitializeComponent(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.PeripheralConsole/DigiMixerAppConfig.cs: -------------------------------------------------------------------------------- 1 | 2 | // Copied from DigiMixer.Wpf (and trimmed) so the same config can be used in both apps. 3 | using DigiMixer.AppCore; 4 | 5 | namespace DigiMixer.PeripheralConsole; 6 | 7 | public class DigiMixerAppConfig 8 | { 9 | public LoggingConfig Logging { get; set; } = new(); 10 | public DigiMixerConfig Mixer { get; set; } = new(); 11 | } 12 | -------------------------------------------------------------------------------- /AsyncIntro/Code/packages/repositories.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Controls/ChannelVisibilitySelector.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Controls; 2 | 3 | namespace DigiMixer.Controls; 4 | /// 5 | /// Interaction logic for ChannelVisibilitySelector.xaml 6 | /// 7 | public partial class ChannelVisibilitySelector : UserControl 8 | { 9 | public ChannelVisibilitySelector() 10 | { 11 | InitializeComponent(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Mackie.Core/MackieCommand.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Mackie.Core; 2 | 3 | public enum MackieCommand : byte 4 | { 5 | KeepAlive = 0x01, 6 | ClientHandshake = 0x03, 7 | FirmwareInfo = 0x04, 8 | ChannelInfoControl = 0x06, 9 | GeneralInfo = 0x0e, 10 | ChannelValues = 0x13, 11 | BroadcastControl = 0x15, 12 | MeterLayout = 0x16, 13 | ChannelNames = 0x18 14 | } 15 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Blazor/_Imports.razor: -------------------------------------------------------------------------------- 1 | @using System.Net.Http 2 | @using System.Net.Http.Json 3 | @using Microsoft.AspNetCore.Components.Forms 4 | @using Microsoft.AspNetCore.Components.Routing 5 | @using Microsoft.AspNetCore.Components.Web 6 | @using Microsoft.AspNetCore.Components.WebAssembly.Http 7 | @using Microsoft.JSInterop 8 | @using VDrumExplorer.Blazor 9 | @using VDrumExplorer.Blazor.Shared 10 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD07/Logical/Root.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Root", 3 | "format": "Root", 4 | "path": ".", 5 | "details": [ 6 | { 7 | "description": "Current kit", 8 | "path": "Current" 9 | } 10 | ], 11 | "children": [ 12 | "$resource:Logical/Setup.json", 13 | "$resource:Logical/Kits.json", 14 | "$resource:Logical/Triggers.json" 15 | ] 16 | } 17 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD17/Logical/Root.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Root", 3 | "format": "Root", 4 | "path": ".", 5 | "details": [ 6 | { 7 | "description": "Current kit", 8 | "path": "Current" 9 | } 10 | ], 11 | "children": [ 12 | "$resource:Logical/Setup.json", 13 | "$resource:Logical/Kits.json", 14 | "$resource:Logical/Triggers.json" 15 | ] 16 | } 17 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD27/VEdit/Other.json: -------------------------------------------------------------------------------- 1 | { 2 | "description": "Other", 3 | "fields": [ 4 | { 5 | "description": "Pitch", 6 | "type": "range16", 7 | "min": -100, 8 | "max": 100 9 | }, 10 | { 11 | "description": "Decay", 12 | "type": "range16", 13 | "min": 1, 14 | "max": 100, 15 | "default": 100 16 | } 17 | ] 18 | } -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Platforms/Tizen/Main.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using Microsoft.Maui; 3 | using Microsoft.Maui.Hosting; 4 | 5 | namespace ContextAndType; 6 | 7 | class Program : MauiApplication 8 | { 9 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp(); 10 | 11 | static void Main(string[] args) 12 | { 13 | var app = new Program(); 14 | app.Run(args); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.WingExplorer/MixerDetailsPanel.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Controls; 2 | 3 | namespace DigiMixer.BehringerWing.WingExplorer; 4 | /// 5 | /// Interaction logic for MixerDetailsPanel.xaml 6 | /// 7 | public partial class MixerDetailsPanel : UserControl 8 | { 9 | public MixerDetailsPanel() 10 | { 11 | InitializeComponent(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.DmSeries/DmMeterClient.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Core; 2 | using Microsoft.Extensions.Logging; 3 | 4 | namespace DigiMixer.DmSeries; 5 | internal class DmMeterClient : UdpControllerBase 6 | { 7 | public DmMeterClient(ILogger logger) : base(logger, 50272) 8 | { 9 | } 10 | 11 | protected override void ProcessData(ReadOnlySpan data) 12 | { 13 | // TODO 14 | } 15 | } -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.UiHttp/DigiMixer.UiHttp.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.NAudio/VDrumExplorer.NAudio.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net48;net6.0 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /RoslynTesting/ProductionCode/Attributes/NotNullAttribute.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2014 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using System; 3 | 4 | namespace ProductionCode.Attributes 5 | { 6 | [AttributeUsage(AttributeTargets.Parameter)] 7 | public sealed class NotNullAttribute : Attribute 8 | { 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /VersioningBlogPost/MultiVersionLoading/MultiVersionLoading.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp2.0;net471 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DemoUtil/JonSkeet.DemoUtil.Test/DemoWithAsyncMain.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Threading.Tasks; 3 | 4 | namespace JonSkeet.DemoUtil.Test 5 | { 6 | class DemoWithAsyncMain 7 | { 8 | static async Task Main() 9 | { 10 | Console.WriteLine("Before delay"); 11 | await Task.Delay(1000); 12 | Console.WriteLine("After delay"); 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.WingExplorer/MainWindow.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows; 2 | 3 | namespace DigiMixer.BehringerWing.WingExplorer; 4 | /// 5 | /// Interaction logic for MainWindow.xaml 6 | /// 7 | public partial class MainWindow : Window 8 | { 9 | public MainWindow() 10 | { 11 | InitializeComponent(); 12 | DataContext = new MainWindowViewModel(); 13 | } 14 | } -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.CqSeries/CqKeepAliveMessage.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.CqSeries.Core; 2 | 3 | namespace DigiMixer.CqSeries; 4 | 5 | public class CqKeepAliveMessage : CqMessage 6 | { 7 | public CqKeepAliveMessage() : base(CqMessageFormat.VariableLength, CqMessageType.KeepAlive, []) 8 | { 9 | } 10 | 11 | internal CqKeepAliveMessage(CqRawMessage rawMessage) : base(rawMessage) 12 | { 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Yamaha.Core/DigiMixer.Yamaha.Core.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Yamaha/DigiMixer.Yamaha.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /Functions/ZoneClock/ZoneClock.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | Exe 4 | netcoreapp3.1 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Mackie.Core/DigiMixer.Mackie.Core.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.QuSeries.Core/DigiMixer.QuSeries.Core.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.SqSeries.Core/DigiMixer.SqSeries.Core.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net9.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.UCNet/DigiMixer.UCNet.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Blazor/App.razor: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 |

Sorry, there's nothing at this address.

8 |
9 |
10 |
11 | -------------------------------------------------------------------------------- /WpfUtil/JonSkeet.CoreAppUtil/IUpdatable.cs: -------------------------------------------------------------------------------- 1 | namespace JonSkeet.CoreAppUtil; 2 | 3 | /// 4 | /// Indicates that an item can have its status updated from another one. 5 | /// Used by to merge incoming items. 6 | /// 7 | /// The element to update from 8 | public interface IUpdatable 9 | { 10 | void UpdateFrom(T other); 11 | } 12 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.AllenAndHeath.Core/DigiMixer.AllenAndHeath.Core.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Mackie/DigiMixer.Mackie.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /Immutability/Builder2/FreezableList.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. All Rights Reserved. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | using System.Collections.Generic; 5 | 6 | internal sealed class FreezableList : List 7 | { 8 | // This would actually just implement IList, 9 | // and prohibit changes after a Freeze call. 10 | 11 | internal void Freeze() 12 | { 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /RabbitHole/Code/RabbitHole/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2014 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using MiscUtil; 3 | 4 | namespace RabbitHole 5 | { 6 | class Program 7 | { 8 | static void Main(string[] args) 9 | { 10 | ApplicationChooser.Run(typeof(Program), args); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /XTouchMini/XTouchMini.Model/XTouchMini.Model.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netstandard2.1 5 | 9 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/OddsAndEnds/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using MiscUtil; 3 | 4 | namespace OddsAndEnds 5 | { 6 | class Program 7 | { 8 | static void Main(string[] args) 9 | { 10 | ApplicationChooser.Run(typeof(Program), args); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/Performance/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using MiscUtil; 3 | 4 | namespace Performance 5 | { 6 | class Program 7 | { 8 | static void Main(string[] args) 9 | { 10 | ApplicationChooser.Run(typeof(Program), args); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2019 Jon Skeet. All rights reserved. 2 | // Use of this source code is governed by the Apache License 2.0, 3 | // as found in the LICENSE.txt file. 4 | 5 | using System.Runtime.CompilerServices; 6 | [assembly:InternalsVisibleTo("VDrumExplorer.Model.Test")] 7 | [assembly:InternalsVisibleTo("VDrumExplorer.Console")] 8 | [assembly:InternalsVisibleTo("VDrumExplorer.NetFrameworkProfiling")] 9 | -------------------------------------------------------------------------------- /Immutability/Builder3/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. All Rights Reserved. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | class Program 5 | { 6 | static void Main(string[] args) 7 | { 8 | var jon = new Person 9 | { 10 | Name = "Jon", 11 | Address = new Address { City = "Reading", Street = "..." }, 12 | Phones = { } 13 | }; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /OscMixerControl/OscMixerControl.Proxy/OscMixerControl.Proxy.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | net10.0 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/OperatorAbuse/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using MiscUtil; 3 | 4 | namespace OperatorAbuse 5 | { 6 | class Program 7 | { 8 | static void Main(string[] args) 9 | { 10 | ApplicationChooser.Run(typeof(Program), args); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/WhatTheHeck2/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using MiscUtil; 3 | 4 | namespace WhatTheHeck2 5 | { 6 | class Program 7 | { 8 | static void Main(string[] args) 9 | { 10 | ApplicationChooser.Run(typeof(Program), args); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/WrappingAsync/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using MiscUtil; 3 | 4 | namespace WrappingAsync 5 | { 6 | class Program 7 | { 8 | static void Main(string[] args) 9 | { 10 | ApplicationChooser.Run(typeof(Program), args); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /CSharp8/MinorFeatures/NullCoalescingAssignment.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace MinorFeatures 4 | { 5 | class NullCoalescingAssignment 6 | { 7 | static void Main() 8 | { 9 | string x = null; 10 | 11 | // Before... 12 | x = x ?? "foo"; 13 | // With C# 8 14 | x ??= "bar"; 15 | 16 | Console.WriteLine(x); 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /CSharp8/MinorFeatures/VerbatimInterpolatedStringLiterals.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace MinorFeatures 4 | { 5 | class VerbatimInterpolatedStringLiterals 6 | { 7 | static void Main() 8 | { 9 | // Only of these was valid in C# 7. I can't remember which. 10 | Console.WriteLine(@$"This is valid"); 11 | Console.WriteLine($@"This is valid too"); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.Core/DigiMixer.BehringerWing.Core.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.QuSeries/DigiMixer.QuSeries.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD07/VEdit/RideCrashSplashChina.json: -------------------------------------------------------------------------------- 1 | { 2 | "fields": [ 3 | { 4 | "description": "Size", 5 | "type": "range16", 6 | "min": 0, 7 | "max": 78, 8 | "valueOffset": 2, 9 | "divisor": 2 10 | }, 11 | { 12 | "description": "Muffling", 13 | "type": "range16", 14 | "min": 0, 15 | "max": 19, 16 | "off": 0 17 | } 18 | ] 19 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD17/Physical/KitUnitInst.json: -------------------------------------------------------------------------------- 1 | { 2 | "size": "0x9", 3 | "fields": [ 4 | { 5 | "description": "Instrument", 6 | "type": "instrument", 7 | "bankOffset": "0x08" 8 | }, 9 | { 10 | "description": "Volume", 11 | "type": "volume32" 12 | }, 13 | { 14 | "description": "Instrument bank", 15 | "type": "placeholder8" 16 | } 17 | ] 18 | } -------------------------------------------------------------------------------- /IconPlatform/IconPlatform.Model/IconPlatform.Model.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netstandard2.1 5 | 9 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /NdiStreamDeck/NdiStreamDeck/App.xaml: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /NdiStreamDeck/NdiStreamDeck/App.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Configuration; 4 | using System.Data; 5 | using System.Linq; 6 | using System.Threading.Tasks; 7 | using System.Windows; 8 | 9 | namespace NdiStreamDeck 10 | { 11 | /// 12 | /// Interaction logic for App.xaml 13 | /// 14 | public partial class App : Application 15 | { 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/FunWithAwaiters/IAwaitable.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | 3 | namespace FunWithAwaiters 4 | { 5 | public interface IAwaitable 6 | { 7 | IAwaiter GetAwaiter(); 8 | } 9 | 10 | public interface IAwaitable 11 | { 12 | IAwaiter GetAwaiter(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/LinqToOperators/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using MiscUtil; 3 | 4 | namespace LinqToOperators 5 | { 6 | class Program 7 | { 8 | static void Main(string[] args) 9 | { 10 | ApplicationChooser.Run(typeof(Program), args); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/StringInterpolation/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2017 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using MiscUtil; 3 | 4 | namespace StringInterpolation 5 | { 6 | class Program 7 | { 8 | static void Main(string[] args) 9 | { 10 | ApplicationChooser.Run(typeof(Program), args); 11 | } 12 | } 13 | } -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Osc/DigiMixer.Osc.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | net10.0 4 | enable 5 | enable 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /Immutability/Slides/071 Issues - Antipatterns.txt: -------------------------------------------------------------------------------- 1 | Naming: 2 | - IReadOnlyCollection isn't 3 | 4 | Freezing: 5 | - Feels good, but introduces complexity: reasoning is hard 6 | 7 | Mutable/immutable variants: 8 | - Joda Time type hierarchy (simplified): 9 | 10 | ReadableInstant 11 | / \ 12 | Instant MutableInstant 13 | - What do you accept as a method parameter? What do you return? 14 | -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Platforms/Android/MainApplication.cs: -------------------------------------------------------------------------------- 1 | using Android.App; 2 | using Android.Runtime; 3 | 4 | namespace ContextAndType; 5 | 6 | [Application] 7 | public class MainApplication : MauiApplication 8 | { 9 | public MainApplication(IntPtr handle, JniHandleOwnership ownership) 10 | : base(handle, ownership) 11 | { 12 | } 13 | 14 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp(); 15 | } 16 | -------------------------------------------------------------------------------- /Shed/Shed.Controllers/ICommand.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | namespace Shed.Controllers 5 | { 6 | /// 7 | /// A command within a controller. 8 | /// 9 | public interface ICommand 10 | { 11 | string Name { get; } 12 | string Description { get; } 13 | 14 | void Execute(params string[] arguments); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /WpfUtil/JonSkeet.CoreAppUtil/IReorderableList.cs: -------------------------------------------------------------------------------- 1 | namespace JonSkeet.CoreAppUtil; 2 | 3 | /// 4 | /// Interface to support extension methods in JonSkeet.WpfUtil.ReorderableLists. 5 | /// (It's in CoreAppUtil so that SelectableCollection can implement it.) 6 | /// 7 | public interface IReorderableList 8 | { 9 | void MoveSelectedItemUp(); 10 | void MoveSelectedItemDown(); 11 | void DeleteSelectedItem(); 12 | } 13 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/ExceptionFilters/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2017 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | 3 | using MiscUtil; 4 | 5 | namespace ExceptionFilters 6 | { 7 | class Program 8 | { 9 | static void Main(string[] args) 10 | { 11 | ApplicationChooser.Run(typeof(Program), args); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/FunWithAwaiters/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | 3 | using MiscUtil; 4 | 5 | namespace FunWithAwaiters 6 | { 7 | class Program 8 | { 9 | static void Main(string[] args) 10 | { 11 | ApplicationChooser.Run(typeof(Program), args); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/NullConditional/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2017 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | 3 | using MiscUtil; 4 | 5 | namespace NullConditional 6 | { 7 | class Program 8 | { 9 | static void Main(string[] args) 10 | { 11 | ApplicationChooser.Run(typeof(Program), args); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/WhatTheHeck2/Demo2.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using System; 3 | 4 | namespace WhatTheHeck2 5 | { 6 | class Demo2 7 | { 8 | static void Main() 9 | { 10 | dynamic x = Mystery.GetValue(); 11 | Console.WriteLine(x.Count()); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /CameraControl/CameraControl.Visca/CameraControl.Visca.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | net9.0 4 | Enable 5 | enable 6 | 10 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.CqSeries/CpFullDataRequestMessage.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.CqSeries.Core; 2 | 3 | namespace DigiMixer.CqSeries; 4 | 5 | internal class CqFullDataRequestMessage : CqMessage 6 | { 7 | internal CqFullDataRequestMessage() : base(CqMessageFormat.VariableLength, CqMessageType.FullDataRequest, []) 8 | { 9 | } 10 | 11 | internal CqFullDataRequestMessage(CqRawMessage message) : base(message) 12 | { 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.CqSeries/CqClientInitResponseMessage.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.CqSeries.Core; 2 | 3 | namespace DigiMixer.CqSeries; 4 | 5 | public class CqClientInitResponseMessage : CqMessage 6 | { 7 | // We don't know what this means at the moment, but it's always 1... 8 | public ushort MixerValue => GetUInt16(0); 9 | 10 | internal CqClientInitResponseMessage(CqRawMessage rawMessage) : base(rawMessage) 11 | { 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.CqSeries/CqVersionRequestMessage.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.CqSeries.Core; 2 | 3 | namespace DigiMixer.CqSeries; 4 | 5 | internal class CqVersionRequestMessage : CqMessage 6 | { 7 | public CqVersionRequestMessage() : base(CqMessageFormat.VariableLength, CqMessageType.VersionRequest, []) 8 | { 9 | } 10 | 11 | internal CqVersionRequestMessage(CqRawMessage rawMessage) : base(rawMessage) 12 | { 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.SqSeries/DigiMixer.SqSeries.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /DmxLighting/DmxLighting.WpfGui/App.xaml: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /DmxLighting/DmxLighting.WpfGui/App.xaml.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2021 Jon Skeet. All rights reserved. 2 | // Use of this source code is governed by the Apache License 2.0, 3 | // as found in the LICENSE.txt file. 4 | 5 | using System.Windows; 6 | 7 | namespace DmxLighting.WpfGui 8 | { 9 | /// 10 | /// Interaction logic for App.xaml 11 | /// 12 | public partial class App : Application 13 | { 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/AE10/Logical/TemporaryStudioSet.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "TemporaryStudioSet", 3 | "path": "TemporaryStudioSet", 4 | "formatPaths": [ 5 | "Common/StudioSetName" 6 | ], 7 | "format": "Temporary Studio Set", 8 | "details": [ 9 | { 10 | "description": "Studio Set Common", 11 | "path": "Common" 12 | } 13 | ], 14 | "children": "$resource:Logical/StudioSetChildren.json" 15 | } 16 | -------------------------------------------------------------------------------- /Immutability/Slides/027 ReallyObviouslyImmutable.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. All Rights Reserved. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | public sealed class ReallyObviouslyImmutable 5 | { 6 | public string Name { get; } 7 | 8 | public int Value { get; } 9 | 10 | public ReallyObviouslyImmutable(string name, int value) 11 | { 12 | this.Name = name; 13 | this.Value = value; 14 | } 15 | } -------------------------------------------------------------------------------- /CSharp8/Nullability/AnnotationsOnlyContext.cs: -------------------------------------------------------------------------------- 1 | #nullable disable warnings 2 | #nullable enable annotations 3 | 4 | using System; 5 | 6 | namespace Nullability 7 | { 8 | class AnnotationsOnlyContext 9 | { 10 | static void Main() 11 | { 12 | string? x = null; 13 | string y = null; 14 | Console.WriteLine(x.Length); 15 | Console.WriteLine(y.Length); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /CSharp8/Patterns/NotExhaustive.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace PatternsAndRanges 4 | { 5 | class NotExhaustive 6 | { 7 | static void Main() 8 | { 9 | int input = 5; 10 | int value = input switch 11 | { 12 | 0 => 1, 13 | 1 => 2, 14 | _ => 0 15 | }; 16 | 17 | Console.WriteLine(value); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing/DigiMixer.BehringerWing.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Diagnostics/AnnotatedMessage.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Core; 2 | using System.Net; 3 | 4 | namespace DigiMixer.Diagnostics; 5 | 6 | public record AnnotatedMessage( 7 | TMessage Message, 8 | DateTimeOffset Timestamp, 9 | MessageDirection Direction, 10 | int StreamOffset, 11 | IPAddress SourceAddress, 12 | IPAddress DestinationAddress) where TMessage : class, IMixerMessage 13 | { 14 | } 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.TfSeries/DigiMixer.TfSeries.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | latest 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD07/Physical/SetupMisc.json: -------------------------------------------------------------------------------- 1 | { 2 | "size": "0x04", 3 | "fields": [ 4 | { 5 | "description": "USB Input Gain", 6 | "type": "range16", 7 | "min": -36, 8 | "max": 12, 9 | "suffix": "dB" 10 | }, 11 | { 12 | "description": "USB Output Gain", 13 | "type": "range16", 14 | "min": -24, 15 | "max": 24, 16 | "suffix": "dB" 17 | } 18 | ] 19 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD17/Physical/SetupMisc.json: -------------------------------------------------------------------------------- 1 | { 2 | "size": "0x04", 3 | "fields": [ 4 | { 5 | "description": "USB Input Gain", 6 | "type": "range16", 7 | "min": -36, 8 | "max": 12, 9 | "suffix": "dB" 10 | }, 11 | { 12 | "description": "USB Output Gain", 13 | "type": "range16", 14 | "min": -24, 15 | "max": 24, 16 | "suffix": "dB" 17 | } 18 | ] 19 | } -------------------------------------------------------------------------------- /OscMixerControl/OscMixerControl.Wpf/App.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Configuration; 4 | using System.Data; 5 | using System.Linq; 6 | using System.Threading.Tasks; 7 | using System.Windows; 8 | 9 | namespace OscMixerControl.Wpf 10 | { 11 | /// 12 | /// Interaction logic for App.xaml 13 | /// 14 | public partial class App : Application 15 | { 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /CameraControl/CameraControl.Visca.Demo/App.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Configuration; 4 | using System.Data; 5 | using System.Linq; 6 | using System.Threading.Tasks; 7 | using System.Windows; 8 | 9 | namespace CameraControl.Visca.Demo 10 | { 11 | /// 12 | /// Interaction logic for App.xaml 13 | /// 14 | public partial class App : Application 15 | { 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer/IFader.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.Core; 2 | using System.ComponentModel; 3 | 4 | namespace DigiMixer; 5 | 6 | public interface IFader : INotifyPropertyChanged 7 | { 8 | FaderLevel FaderLevel { get; } 9 | void SetFaderLevel(FaderLevel level); 10 | 11 | /// 12 | /// The scale of the fader, which is always the same as the scale for the overall mixer. 13 | /// 14 | IFaderScale Scale { get; } 15 | } 16 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD27/Logical/Root.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Root", 3 | "format": "Root", 4 | "path": ".", 5 | "details": [ 6 | { 7 | "description": "Current kit", 8 | "path": "Current" 9 | } 10 | ], 11 | "children": [ 12 | "$resource:Logical/Setup.json", 13 | "$resource:Logical/Kits.json", 14 | "$resource:Logical/SetLists.json", 15 | "$resource:Logical/TriggerBanks.json" 16 | ] 17 | } 18 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50/Logical/Root.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Root", 3 | "format": "Root", 4 | "path": ".", 5 | "details": [ 6 | { 7 | "description": "Current kit", 8 | "path": "Current" 9 | } 10 | ], 11 | "children": [ 12 | "$resource:Logical/Setup.json", 13 | "$resource:Logical/Kits.json", 14 | "$resource:Logical/SetLists.json", 15 | "$resource:Logical/TriggerBanks.json" 16 | ] 17 | } 18 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50X/Logical/Root.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Root", 3 | "format": "Root", 4 | "path": ".", 5 | "details": [ 6 | { 7 | "description": "Current kit", 8 | "path": "Current" 9 | } 10 | ], 11 | "children": [ 12 | "$resource:Logical/Setup.json", 13 | "$resource:Logical/Kits.json", 14 | "$resource:Logical/SetLists.json", 15 | "$resource:Logical/TriggerBanks.json" 16 | ] 17 | } 18 | -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Platforms/iOS/Program.cs: -------------------------------------------------------------------------------- 1 | using ObjCRuntime; 2 | using UIKit; 3 | 4 | namespace ContextAndType; 5 | 6 | public class Program 7 | { 8 | // This is the main entry point of the application. 9 | static void Main(string[] args) 10 | { 11 | // if you want to use a different Application Delegate class from "AppDelegate" 12 | // you can specify it here. 13 | UIApplication.Main(args, null, typeof(AppDelegate)); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Abusing CSharp/Text/agenda.txt: -------------------------------------------------------------------------------- 1 | (Odds and Ends) 2 | Mongolian Vowel Separator 3 | nameof anything 4 | Date deconstruction 5 | ASCII art separators 6 | Preprocessor oddities 7 | 8 | (String interpolation) 9 | Lambda expressions 10 | Regular then lazy evaluation 11 | Parameterized SQL 12 | 13 | (Performance) 14 | Large structs 15 | 16 | (Null conditional) 17 | Preconditions 18 | Logging 19 | 20 | (Exception filters) 21 | Direct vs reflection 22 | Exception context -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.SqSeries.Core/SqMessageFormat.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.SqSeries.Core; 2 | 3 | public enum SqMessageFormat 4 | { 5 | VariableLength, 6 | 7 | /// 8 | /// Total of 8 bytes: the fixed-length indicator and 7 bytes of data 9 | /// 10 | FixedLength8, 11 | 12 | /// 13 | /// Total of 9 bytes: the fixed-length indicator and 8 bytes of data 14 | /// 15 | FixedLength9 16 | } 17 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Ssc/DigiMixer.Ssc.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /Immutability/Slides/050 Examples.txt: -------------------------------------------------------------------------------- 1 | Basic data model: 2 | 3 | Person 4 | - Name 5 | - Address 6 | - Phone numbers 7 | - Friends (stretch goal - not implemented) 8 | 9 | Address 10 | - Street 11 | - City 12 | 13 | Phone number: 14 | - Number (string, currently; should be E164) 15 | - Type (enum) 16 | 17 | Number type: 18 | - Home, Mobile, Work 19 | 20 | 21 | Examples of: 22 | - Builder pattern 23 | - Discuss pros and cons of multiple types 24 | - Withers -------------------------------------------------------------------------------- /Shed/Shed.Controllers/IController.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | using System.Collections.Immutable; 5 | 6 | namespace Shed.Controllers 7 | { 8 | /// 9 | /// A controller, e.g. for lights or music. 10 | /// 11 | public interface IController 12 | { 13 | string Name { get; } 14 | IImmutableList Commands { get; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /AsyncIntro/Code/StockMarket/UserStockHolding.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using System; 3 | 4 | namespace StockMarket 5 | { 6 | internal sealed class UserStockHolding 7 | { 8 | internal Guid UserId { get; set; } 9 | internal string Ticker { get; set; } 10 | internal int Quantity { get; set; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /CSharp7/CSharp7/CSharp7.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp2.0 6 | CSharp7.Program 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /CameraControl/CameraControl.Visca/CallerArgumentExpressionAttribute.cs: -------------------------------------------------------------------------------- 1 | namespace System.RuntimeCompilerServices; 2 | 3 | [AttributeUsage(AttributeTargets.Parameter, AllowMultiple = false, Inherited = false)] 4 | internal sealed class CallerArgumentExpressionAttribute : Attribute 5 | { 6 | public string ParameterName { get; set; } 7 | 8 | public CallerArgumentExpressionAttribute(string parameterName) => 9 | ParameterName = parameterName; 10 | } 11 | -------------------------------------------------------------------------------- /Diagnostics/Example3a/Program.cs: -------------------------------------------------------------------------------- 1 | using NUnit.Common; 2 | using NUnitLite; 3 | using System; 4 | using System.Reflection; 5 | 6 | namespace Example3a 7 | { 8 | class Program 9 | { 10 | public static int Main(string[] args) 11 | { 12 | var writer = new ExtendedTextWrapper(Console.Out); 13 | return new AutoRun(typeof(Program).GetTypeInfo().Assembly).Execute(args, writer, Console.In); 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.CqSeries.Core/DigiMixer.CqSeries.Core.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | latest 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.CqSeries/CqClientInitRequestMessage.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.CqSeries.Core; 2 | 3 | namespace DigiMixer.CqSeries; 4 | 5 | internal class CqClientInitRequestMessage : CqMessage 6 | { 7 | internal CqClientInitRequestMessage() : base(CqMessageFormat.VariableLength, CqMessageType.ClientInitRequest, [2, 0]) 8 | { 9 | } 10 | 11 | internal CqClientInitRequestMessage(CqRawMessage rawMessage) : base(rawMessage) 12 | { 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Immutability/Builder2/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. All Rights Reserved. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | class Program 5 | { 6 | static void Main(string[] args) 7 | { 8 | var jon = new Person.Builder 9 | { 10 | Name = "Jon", 11 | Address = new Address.Builder { City = "Reading", Street = "..." }.Build(), 12 | Phones = { } 13 | }.Build(); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Platforms/MacCatalyst/Program.cs: -------------------------------------------------------------------------------- 1 | using ObjCRuntime; 2 | using UIKit; 3 | 4 | namespace ContextAndType; 5 | 6 | public class Program 7 | { 8 | // This is the main entry point of the application. 9 | static void Main(string[] args) 10 | { 11 | // if you want to use a different Application Delegate class from "AppDelegate" 12 | // you can specify it here. 13 | UIApplication.Main(args, null, typeof(AppDelegate)); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/WhatTheHeck2/Demo1.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using System; 3 | using System.Linq; 4 | 5 | namespace WhatTheHeck2 6 | { 7 | class Demo1 8 | { 9 | static void Main() 10 | { 11 | dynamic x = Mystery.GetValue(); 12 | Console.WriteLine(x.Count()); 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /CameraControl/CameraControl.Visca.Demo/CameraControl.Visca.Demo.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | WinExe 5 | net10.0-windows 6 | true 7 | NU1701 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.AllenAndHeath.Core/AHMessageFormat.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.AllenAndHeath.Core; 2 | 3 | public enum AHMessageFormat 4 | { 5 | VariableLength, 6 | 7 | /// 8 | /// Total of 8 bytes: the fixed-length indicator and 7 bytes of data 9 | /// 10 | FixedLength8, 11 | 12 | /// 13 | /// Total of 9 bytes: the fixed-length indicator and 8 bytes of data 14 | /// 15 | FixedLength9 16 | } 17 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.CqSeries/DigiMixer.CqSeries.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | latest 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.DmSeries.Core/DigiMixer.DmSeries.Core.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | latest 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Wpf/MidiDevicePickerViewModel.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Wpf; 2 | 3 | public class MidiDevicePickerViewModel 4 | { 5 | public IReadOnlyList DeviceNames { get; } 6 | 7 | // No need for event notifications here, as only the UI will set this. 8 | public string SelectedName { get; set; } 9 | 10 | public MidiDevicePickerViewModel(IReadOnlyList deviceNames) 11 | { 12 | DeviceNames = deviceNames; 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /NdiStreamDeck/NdiStreamDeck.slnx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.DmSeries/DigiMixer.DmSeries.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | latest 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Mackie.Tools/dump.proto: -------------------------------------------------------------------------------- 1 | syntax = "proto3"; 2 | 3 | option csharp_namespace = "DigiMixer.Mackie.Tools"; 4 | 5 | import "google/protobuf/timestamp.proto"; 6 | 7 | message MessageCollection { 8 | repeated Message messages = 1; 9 | } 10 | 11 | message Message { 12 | bool outbound = 1; 13 | int32 command = 2; 14 | int32 sequence = 3; 15 | int32 type = 4; 16 | 17 | bytes data = 5; 18 | 19 | google.protobuf.Timestamp timestamp = 6; 20 | } 21 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/AE10/Logical/Root.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Root", 3 | "format": "Root", 4 | "path": ".", 5 | "details": [ 6 | { 7 | "description": "Setup", 8 | "path": "Setup" 9 | }, 10 | { 11 | "description": "System", 12 | "path": "System/SystemCommon" 13 | } 14 | ], 15 | "children": [ 16 | "$resource:Logical/TemporaryStudioSet.json", 17 | "$resource:Logical/StudioSets.json" 18 | ] 19 | } 20 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.ViewModel/Data/IDataNodeDetailViewModel.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2020 Jon Skeet. All rights reserved. 2 | // Use of this source code is governed by the Apache License 2.0, 3 | // as found in the LICENSE.txt file. 4 | 5 | namespace VDrumExplorer.ViewModel.Data 6 | { 7 | // Experiment: use a simple interface here instead of a base class. 8 | public interface IDataNodeDetailViewModel 9 | { 10 | public string Description { get; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /CameraControl/CameraControl.Visca/ViscaMessageType.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2023 Jon Skeet. All rights reserved. 2 | // Use of this source code is governed by the Apache License 2.0, 3 | // as found in the LICENSE.txt file. 4 | 5 | namespace CameraControl.Visca; 6 | 7 | internal enum ViscaMessageType 8 | { 9 | Command = 0x01_00, 10 | Inquiry = 0x01_10, 11 | Reply = 0x01_11, 12 | DeviceSetting = 0x01_20, 13 | Control = 0x02_00, 14 | ControlReply = 0x02_01 15 | } 16 | -------------------------------------------------------------------------------- /Diagnostics/Example1d/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Globalization; 3 | 4 | namespace Example1d 5 | { 6 | class Program 7 | { 8 | static void Main() 9 | { 10 | string date = "05/06/2017"; 11 | DateTime dateTime = DateTime.Parse(date); 12 | Console.WriteLine(dateTime); 13 | Console.WriteLine(dateTime.ToString("yyyy-MM-dd HH:mm:ss", CultureInfo.InvariantCulture)); 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.WingExplorer/ExplorerViewModel.cs: -------------------------------------------------------------------------------- 1 | using JonSkeet.CoreAppUtil; 2 | using System.Collections.ObjectModel; 3 | 4 | namespace DigiMixer.BehringerWing.WingExplorer; 5 | 6 | public class ExplorerViewModel : ViewModelBase 7 | { 8 | public ObservableCollection RootNodes { get; } = new(); 9 | 10 | public void SetRoot(MixerTreeNode node) 11 | { 12 | RootNodes.Clear(); 13 | RootNodes.Add(node); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.SqSeries/SqMessageType.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.SqSeries; 2 | 3 | public enum SqMessageType : byte 4 | { 5 | UdpHandshake = 0, 6 | VersionRequest = 1, 7 | VersionResponse = 2, 8 | FullDataRequest = 3, 9 | FullDataResponse = 4, 10 | ClientInitRequest = 11, 11 | ClientInitResponse = 12, 12 | UsersRequest = 20, 13 | UsersResponse = 21, 14 | Type13Request = 13, 15 | Type15Request = 15, 16 | Type17Request = 17, 17 | } 18 | -------------------------------------------------------------------------------- /EvChargerTiming/EvChargerTiming.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net6.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.SqSeries/SqVersionRequestMessage.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.AllenAndHeath.Core; 2 | 3 | namespace DigiMixer.SqSeries; 4 | 5 | internal class SqVersionRequestMessage : SqMessage 6 | { 7 | public SqVersionRequestMessage() : base(SqMessageType.VersionRequest, []) 8 | { 9 | } 10 | 11 | internal SqVersionRequestMessage(AHRawMessage rawMessage) : base(rawMessage) 12 | { 13 | } 14 | 15 | public override string ToString() => $"Type={Type}"; 16 | } 17 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD07/Physical/Trigger.json: -------------------------------------------------------------------------------- 1 | { 2 | "containers": [ 3 | { 4 | "name": "TrigMisc", 5 | "offset": "0x00", 6 | "description": "Trigger Misc" 7 | }, 8 | { 9 | "name": "Trigger", 10 | "offset": "0x01_00", 11 | "description": "{item} Trigger", 12 | "container": "Trig", 13 | "repeat": 14 | { 15 | "items": "pads", 16 | "gap": "0x1_00" 17 | } 18 | } 19 | ] 20 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD17/Physical/Trigger.json: -------------------------------------------------------------------------------- 1 | { 2 | "containers": [ 3 | { 4 | "name": "TrigMisc", 5 | "offset": "0x00", 6 | "description": "Trigger Misc" 7 | }, 8 | { 9 | "name": "Trigger", 10 | "offset": "0x01_00", 11 | "description": "{item} Trigger", 12 | "container": "Trig", 13 | "repeat": 14 | { 15 | "items": "pads", 16 | "gap": "0x1_00" 17 | } 18 | } 19 | ] 20 | } -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Platforms/Android/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /Shed/Shed.CommandLine/Shed.CommandLine.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | Exe 4 | netcoreapp1.0 5 | $(PackageTargetFallback);portable-net45+win8+wp8+wpa81;dotnet 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /WpfUtil/JonSkeet.WpfLogging/JonSkeet.WpfLogging.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0-windows 5 | True 6 | x64 7 | win-x64;win-x86 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /XTouchMini/XTouchMini.MixerControl/XTouchMini.MixerControl.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | net10.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/LinqToOperators/Extensions.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using System.Collections; 3 | 4 | namespace LinqToOperators 5 | { 6 | public static class Extensions 7 | { 8 | public static OperatorEnumerable Evil(this IEnumerable source) 9 | { 10 | return new OperatorEnumerable(source); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /CSharp8/Nullability/Nullability.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netcoreapp3.0 5 | Exe 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /CameraControl/CameraControl.Visca.StressTest/CameraControl.Visca.StressTest.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | net10.0 6 | enable 7 | enable 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /DemoUtil/JonSkeet.DemoUtil.Test/JonSkeet.DemoUtil.Test.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp3.1 6 | JonSkeet.DemoUtil.Test.Program 7 | false 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.BehringerWing.Core/WingMeterType.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.BehringerWing.Core; 2 | 3 | public enum WingMeterType : byte 4 | { 5 | InputChannel = 0xa0, 6 | Aux = 0xa1, 7 | Bus = 0xa2, 8 | Main = 0xa3, 9 | Matrix = 0xa4, 10 | Dca = 0xa5, 11 | Fx = 0xa6, 12 | SourceDevice = 0xa7, 13 | OutputDevice = 0xa8, 14 | InputChannelV2 = 0xab, 15 | AuxV2 = 0xac, 16 | BusV2 = 0xad, 17 | MainV2 = 0xae, 18 | MatrixV2 = 0xaf 19 | } 20 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Benchmarks/VDrumExplorer.Benchmarks.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | net6.0 6 | False 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/Audio/IAudioDeviceManager.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2020 Jon Skeet. All rights reserved. 2 | // Use of this source code is governed by the Apache License 2.0, 3 | // as found in the LICENSE.txt file. 4 | 5 | using System.Collections.Generic; 6 | 7 | namespace VDrumExplorer.Model.Audio 8 | { 9 | public interface IAudioDeviceManager 10 | { 11 | IReadOnlyList GetInputs(); 12 | IReadOnlyList GetOutputs(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /MauiPlayground/MauiPlayground/Platforms/Android/MainActivity.cs: -------------------------------------------------------------------------------- 1 | using Android.App; 2 | using Android.Content.PM; 3 | using Android.OS; 4 | 5 | namespace MauiPlayground 6 | { 7 | [Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize)] 8 | public class MainActivity : MauiAppCompatActivity 9 | { 10 | } 11 | } -------------------------------------------------------------------------------- /WpfUtil/JonSkeet.WpfUtil/JonSkeet.WpfUtil.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0-windows 5 | True 6 | win-x64;win-x86 7 | true 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /Diagnostics/Example3b/Example3b.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp1.0 6 | $(PackageTargetFallback);dotnet 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/AE10/Physical/System.json: -------------------------------------------------------------------------------- 1 | { 2 | // While it's really odd to have a container (System) that just contains 3 | // one other container (System Common) we might as well 4 | // represent the documented structure from the start. The logical 5 | // tree can skip the extraneous level of indirection. 6 | "containers": [ 7 | { 8 | "name": "SystemCommon", 9 | "description": "System Common", 10 | "offset": "0x0" 11 | } 12 | ] 13 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Proto/VDrumExplorer.Proto.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netstandard2.0 5 | Enable 6 | 8.0 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /IconPlatform/IconPlatform.MixerControl/IconPlatform.MixerControl.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | net10.0 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /Immutability/Record/Entities.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. All Rights Reserved. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | public sealed class Address( 5 | string street: Street, 6 | string city: City); 7 | 8 | public sealed class Person( 9 | string name: Name, 10 | Address address: Address, 11 | IImmutableList phones: Phones); 12 | 13 | public sealed class PhoneNumber( 14 | string number: Number, 15 | PhoneNumberType type: Type); 16 | -------------------------------------------------------------------------------- /Immutability/Slides/Scratchpad.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Jon Skeet. All Rights Reserved. 2 | // Licensed under the Apache License Version 2.0. 3 | 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | 10 | namespace Slides 11 | { 12 | class Scratchpad 13 | { 14 | // Code to mess with during the talk goes here 15 | 16 | static void Main() 17 | { 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /MauiBugDemos/ContextAndType/Platforms/Android/MainActivity.cs: -------------------------------------------------------------------------------- 1 | using Android.App; 2 | using Android.Content.PM; 3 | using Android.OS; 4 | 5 | namespace ContextAndType; 6 | 7 | [Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)] 8 | public class MainActivity : MauiAppCompatActivity 9 | { 10 | } 11 | -------------------------------------------------------------------------------- /MauiPlayground/MauiPlayground/Platforms/Android/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /MauiPlayground/MauiPlayground/Platforms/Android/MainApplication.cs: -------------------------------------------------------------------------------- 1 | using Android.App; 2 | using Android.Runtime; 3 | 4 | namespace MauiPlayground 5 | { 6 | [Application] 7 | public class MainApplication : MauiApplication 8 | { 9 | public MainApplication(IntPtr handle, JniHandleOwnership ownership) 10 | : base(handle, ownership) 11 | { 12 | } 13 | 14 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp(); 15 | } 16 | } -------------------------------------------------------------------------------- /Versioning/examples/change-readonly.txt: -------------------------------------------------------------------------------- 1 | #class 2 | public static readonly string StaticReadOnlyField = "Static read-only field before"; 3 | ---- 4 | #class 5 | public static readonly string StaticReadOnlyField = "Static read-only field after"; 6 | ---- 7 | #main 8 | Console.WriteLine(LibraryClass.StaticReadOnlyField); 9 | ---- 10 | # Changing a read-only static field 11 | 12 | Unlike a change to a `const` field, a change to a `static readonly` 13 | field will be detected without recompilation. 14 | -------------------------------------------------------------------------------- /Versioning/examples/parameter-renaming.txt: -------------------------------------------------------------------------------- 1 | #class 2 | public static void Method(int x) => Console.WriteLine(x); 3 | ---- 4 | #class 5 | public static void Method(int y) => Console.WriteLine(y); 6 | ---- 7 | #main 8 | LibraryClass.Method(x: 20); 9 | ---- 10 | # Renaming a public method parameter 11 | 12 | Parameters are effectively part of the API in C#, due to named 13 | arguments. Changing the name of a parameter doesn't break binary 14 | compatibility, but it does break source compatibility. 15 | -------------------------------------------------------------------------------- /Abusing CSharp/Code/OddsAndEnds/SneakyOperatorDemo.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2014 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using System; 3 | /* 4 | namespace OddsAndEnds 5 | { 6 | class SneakyOperatorDemo 7 | { 8 | static void Main() 9 | { 10 | ArithmeticOperator op = SneakyOperator.GetInstance(); 11 | Console.WriteLine(op.Apply(2, 5)); 12 | } 13 | } 14 | } 15 | */ -------------------------------------------------------------------------------- /AsyncIntro/Code/StockMarket/User.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2013 Jon Skeet. All rights reserved. Use of this source code is governed by the Apache License 2.0, as found in the LICENSE.txt file. 2 | using System; 3 | 4 | namespace StockMarket 5 | { 6 | internal sealed class User 7 | { 8 | internal string UserName { get; set; } 9 | internal Guid Id { get; set; } 10 | // No, we would never *really* do this... 11 | internal string Password { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /DialogflowDemo/SearchTest/SearchTest.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp2.1 6 | latest 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Benchmarks/Program.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2020 Jon Skeet. All rights reserved. 2 | // Use of this source code is governed by the Apache License 2.0, 3 | // as found in the LICENSE.txt file. 4 | 5 | using BenchmarkDotNet.Running; 6 | using System; 7 | 8 | namespace VDrumExplorer.Benchmarks 9 | { 10 | class Program 11 | { 12 | static void Main(string[] args) 13 | { 14 | BenchmarkRunner.Run(typeof(Program).Assembly); 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /OscMixerControl/OscMixerControl.slnx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /XTouchMini/XTouchMini.slnx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /DmxLighting/DmxLighting.WpfGui/DmxLighting.WpfGui.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | WinExe 5 | net6.0-windows 6 | x64 7 | win-x64 8 | true 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD07/VEdit/HiHat.json: -------------------------------------------------------------------------------- 1 | { 2 | "fields": [ 3 | { 4 | "description": "Size", 5 | "type": "range16", 6 | "min": 0, 7 | "max": 78, 8 | "valueOffset": 2, 9 | "divisor": 2 10 | }, 11 | { 12 | "description": "Fixed", 13 | "type": "enum32", 14 | "values": [ 15 | "Normal", 16 | "Fixed 1", 17 | "Fixed 2", 18 | "Fixed 3", 19 | "Fixed 4" 20 | ] 21 | } 22 | ] 23 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD17/VEdit/HiHat.json: -------------------------------------------------------------------------------- 1 | { 2 | "fields": [ 3 | { 4 | "description": "Size", 5 | "type": "range32", 6 | "min": 0, 7 | "max": 78, 8 | "valueOffset": 2, 9 | "divisor": 2 10 | }, 11 | { 12 | "description": "Fixed", 13 | "type": "enum32", 14 | "values": [ 15 | "Normal", 16 | "Fixed 1", 17 | "Fixed 2", 18 | "Fixed 3", 19 | "Fixed 4" 20 | ] 21 | } 22 | ] 23 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD27/Logical/Setup.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Setup", 3 | "format": "Setup", 4 | "path": "Setup", 5 | "details": [ 6 | { 7 | "description": "Output", 8 | "path": "Output" 9 | }, 10 | { 11 | "description": "Control", 12 | "path": "Control" 13 | }, 14 | { 15 | "description": "Click", 16 | "path": "Click" 17 | }, 18 | { 19 | "description": "Misc", 20 | "path": "Misc" 21 | } 22 | ] 23 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50/Logical/Setup.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Setup", 3 | "format": "Setup", 4 | "path": "Setup", 5 | "details": [ 6 | { 7 | "description": "Output", 8 | "path": "Output" 9 | }, 10 | { 11 | "description": "Control", 12 | "path": "Control" 13 | }, 14 | { 15 | "description": "Click", 16 | "path": "Click" 17 | }, 18 | { 19 | "description": "Misc", 20 | "path": "Misc" 21 | } 22 | ] 23 | } -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/SchemaResources/TD50X/Logical/Setup.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Setup", 3 | "format": "Setup", 4 | "path": "Setup", 5 | "details": [ 6 | { 7 | "description": "Output", 8 | "path": "Output" 9 | }, 10 | { 11 | "description": "Control", 12 | "path": "Control" 13 | }, 14 | { 15 | "description": "Click", 16 | "path": "Click" 17 | }, 18 | { 19 | "description": "Misc", 20 | "path": "Misc" 21 | } 22 | ] 23 | } -------------------------------------------------------------------------------- /CSharp8/MinorFeatures/StackallocInNestedContexts.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace MinorFeatures 4 | { 5 | class StackallocInNestedContexts 6 | { 7 | static void Main() 8 | { 9 | // Fine before C# 8 10 | Span span = stackalloc int[5]; 11 | M(span); 12 | 13 | // Only valid in C# 8 14 | M(stackalloc int[10]); 15 | } 16 | 17 | static void M(Span span) 18 | { 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /DialogflowDemo/PopulateFirestore/PopulateFirestore.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp2.1 6 | latest 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Mackie.Core/MackieResponseException.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Mackie.Core; 2 | 3 | /// 4 | /// An exception thrown to indicate an error response to a request message. 5 | /// 6 | public class MackieResponseException : Exception 7 | { 8 | public MackieMessage ErrorMessage { get; } 9 | 10 | public MackieResponseException(MackieMessage errorMessage) : base("Received error response to request") 11 | { 12 | ErrorMessage = errorMessage; 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.Yamaha.Core/YamahaSegment.cs: -------------------------------------------------------------------------------- 1 | namespace DigiMixer.Yamaha.Core; 2 | 3 | /// 4 | /// A segment within a . 5 | /// 6 | public abstract class YamahaSegment 7 | { 8 | internal YamahaSegment() 9 | { 10 | } 11 | 12 | /// 13 | /// The length of the segment, including the format. 14 | /// 15 | internal abstract int Length { get; } 16 | 17 | internal abstract void WriteTo(Span buffer); 18 | } 19 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer/DigiMixer.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | Mixer.cs 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /OscMixerControl/OscMixerControl/IOscClient.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2021 Jon Skeet. All rights reserved. 2 | // Use of this source code is governed by the Apache License 2.0, 3 | // as found in the LICENSE.txt file. 4 | 5 | using OscCore; 6 | using System; 7 | using System.Threading.Tasks; 8 | 9 | namespace OscMixerControl 10 | { 11 | internal interface IOscClient : IDisposable 12 | { 13 | Task SendAsync(OscPacket packet); 14 | event EventHandler PacketReceived; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /WpfUtil/JonSkeet.WpfLogging/LogWindow.xaml.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2024 Jon Skeet. All rights reserved. 2 | // Use of this source code is governed by the Apache License 2.0, 3 | // as found in the LICENSE.txt file. 4 | 5 | using System.Windows; 6 | 7 | namespace JonSkeet.WpfLogging; 8 | 9 | /// 10 | /// Interaction logic for LogWindow.xaml 11 | /// 12 | public partial class LogWindow : Window 13 | { 14 | public LogWindow() 15 | { 16 | InitializeComponent(); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Diagnostics/Example1a/Program.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.AspNetCore; 2 | using Microsoft.AspNetCore.Hosting; 3 | 4 | namespace Example1a 5 | { 6 | public class Program 7 | { 8 | public static void Main(string[] args) 9 | { 10 | CreateWebHostBuilder(args).Build().Run(); 11 | } 12 | 13 | public static IWebHostBuilder CreateWebHostBuilder(string[] args) => 14 | WebHost.CreateDefaultBuilder(args) 15 | .UseStartup(); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Versioning/examples/remove-private-method.txt: -------------------------------------------------------------------------------- 1 | #class 2 | public static void PublicMethod() => PrivateMethod(); 3 | 4 | private static void PrivateMethod() => Console.WriteLine("Output"); 5 | ---- 6 | #class 7 | public static void PublicMethod() => Console.WriteLine("Output"); 8 | ---- 9 | #main 10 | LibraryClass.PublicMethod(); 11 | ---- 12 | # Removing a private method 13 | 14 | Removing a private method is not a breaking change, so long as 15 | anything calling it before is changed to have the same result. 16 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.PeripheralConsole/DigiMixer.PeripheralConsole.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | net10.0 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.SqSeries/SqSimpleRequestMessage.cs: -------------------------------------------------------------------------------- 1 | using DigiMixer.AllenAndHeath.Core; 2 | 3 | namespace DigiMixer.SqSeries; 4 | 5 | /// 6 | /// A simple request message with no additional data. 7 | /// 8 | public class SqSimpleRequestMessage : SqMessage 9 | { 10 | internal SqSimpleRequestMessage(SqMessageType type) : base(type, Array.Empty()) 11 | { 12 | } 13 | 14 | internal SqSimpleRequestMessage(AHRawMessage rawMessage) : base(rawMessage) 15 | { 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /DialogflowDemo/DialogflowDemo/Program.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.AspNetCore; 2 | using Microsoft.AspNetCore.Hosting; 3 | 4 | namespace DialogflowDemo 5 | { 6 | public class Program 7 | { 8 | public static void Main(string[] args) 9 | { 10 | CreateWebHostBuilder(args).Build().Run(); 11 | } 12 | 13 | public static IWebHostBuilder CreateWebHostBuilder(string[] args) => 14 | WebHost.CreateDefaultBuilder(args) 15 | .UseStartup(); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /IconPlatform/IconPlatform.slnx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /RoslynAnalyzers/RoslynAnalyzers.slnx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /CameraControl/CameraControl.slnx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /DigiMixer/DigiMixer.UCNet.Core/DigiMixer.UCNet.Core.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net10.0 5 | enable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/Audio/IAudioOutput.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2020 Jon Skeet. All rights reserved. 2 | // Use of this source code is governed by the Apache License 2.0, 3 | // as found in the LICENSE.txt file. 4 | 5 | using System.Threading; 6 | using System.Threading.Tasks; 7 | 8 | namespace VDrumExplorer.Model.Audio 9 | { 10 | public interface IAudioOutput 11 | { 12 | string Name { get; } 13 | Task PlayAudioAsync(AudioFormat format, byte[] bytes, CancellationToken cancellationToken); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Drums/VDrumExplorer.Model/Midi/IMidiOutput.cs: -------------------------------------------------------------------------------- 1 | // Copyright 2020 Jon Skeet. All rights reserved. 2 | // Use of this source code is governed by the Apache License 2.0, 3 | // as found in the LICENSE.txt file. 4 | 5 | using System; 6 | 7 | namespace VDrumExplorer.Model.Midi 8 | { 9 | /// 10 | /// Abstraction of what V-Drum Explorer needs for a MIDI output device. 11 | /// 12 | public interface IMidiOutput : IDisposable 13 | { 14 | void Send(MidiMessage message); 15 | } 16 | } 17 | --------------------------------------------------------------------------------