doc_id stringlengths 36 36 | metadata dict | input stringlengths 28 4.3k | output stringlengths 11 5.45k |
|---|---|---|---|
3399da97-8c2c-4e37-ba6d-1490ad9e5f9d | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Threading;
using osu.Game.Rulesets.Judgements;
using osu.Game.Rulesets.Objects.Types;
namespace osu.Game.Rulesets.Catch.Objects
{
public class Ba... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Threading;
using osu.Game.Rulesets.Judgements;
using osu.Game.Rulesets.Objects.Types;
namespace osu.Game.Rulesets.Catch.Objects
{
public class Ba... |
a4e2ecf2-c90b-4ed2-9aa4-4291929bd39a | {
"language": "C#"
} | ```c#
using System.Reflection;
using System.Runtime.InteropServices;
[assembly: AssemblyTitle("ScriptCs.Octokit")]
[assembly: AssemblyDescription("Octokit Script Pack for ScriptCs.")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Henrik Andersson")]
[assembly: AssemblyProduct("ScriptCs.Octokit")]
... | ```c#
using System.Reflection;
using System.Runtime.InteropServices;
[assembly: AssemblyTitle("ScriptCs.Octokit")]
[assembly: AssemblyDescription("Octokit Script Pack for ScriptCs.")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Henrik Andersson")]
[assembly: AssemblyProduct("ScriptCs.Octokit")]
... |
b3cd0ade-19e3-4447-be2f-a6adf7f0340e | {
"language": "C#"
} | ```c#
using System.Collections;
using System.Reflection;
using Assets.Scripts.Props;
/// <summary>Commands for the alarm clock.</summary>
public static class AlarmClockCommands
{
[Command(@"snooze")]
public static IEnumerator Snooze(AlarmClock clock, string user, bool isWhisper)
{
var onField = typeof(AlarmCloc... | ```c#
using System.Collections;
using System.Reflection;
using Assets.Scripts.Props;
/// <summary>Commands for the alarm clock.</summary>
public static class AlarmClockCommands
{
[Command("snooze")]
public static IEnumerator Snooze(TwitchHoldable holdable, string user, bool isWhisper) =>
holdable.RespondToCommand... |
8d45e432-71de-40eb-a6ab-75ccef42b6a8 | {
"language": "C#"
} | ```c#
namespace SCPI.Extensions
{
public static class ValueTypeExtensions
{
/// <summary>
/// Checks that the value is within specified range
/// </summary>
/// <param name="value">Value to check</param>
/// <param name="minValue">The inclusive lower bound</param>
... | ```c#
using System.Globalization;
namespace SCPI.Extensions
{
public static class ValueTypeExtensions
{
/// <summary>
/// Checks that the value is within specified range
/// </summary>
/// <param name="value">Value to check</param>
/// <param name="minValue">The inclusi... |
7f2c3ba5-a33a-4948-a54b-d3681cfd6b42 | {
"language": "C#"
} | ```c#
namespace HOLMS.Platform.Support.ReservationTags {
class MigratedReservationTag : ReservationTagBase {
protected override string[] GetDescriptorPartsAfterCategory() =>
new string[] { };
protected override string GetCategoryDescriptor() => MigratedBookingCategory;
public ... | ```c#
namespace HOLMS.Platform.Support.ReservationTags {
public class MigratedReservationTag : ReservationTagBase {
protected override string[] GetDescriptorPartsAfterCategory() =>
new string[] { };
protected override string GetCategoryDescriptor() => MigratedBookingCategory;
... |
0c8b277f-6109-428f-b1ca-9bd5370bafe1 | {
"language": "C#"
} | ```c#
#if NET471
namespace Fixie.Tests.Execution
{
using System;
using System.Configuration;
using System.Linq;
using System.Runtime.Versioning;
using Assertions;
public class ExecutionEnvironmentTests
{
public void ShouldEnableAccessToTestAssemblyConfigFile()
{
... | ```c#
#if NET471
namespace Fixie.Tests.Execution
{
using System;
using System.Configuration;
using System.Linq;
using System.Runtime.Versioning;
using Assertions;
public class ExecutionEnvironmentTests
{
public void ShouldEnableAccessToTestAssemblyConfigFile()
{
... |
d8ec33f6-054a-400d-a655-29e26e1763d2 | {
"language": "C#"
} | ```c#
namespace SFA.DAS.EmployerUsers.Web.Models
{
public class LoginViewModel
{
public string EmailAddress { get; set; }
public string Password { get; set; }
public string OriginatingAddress { get; set; }
public bool InvalidLoginAttempt { get; set; }
public st... | ```c#
namespace SFA.DAS.EmployerUsers.Web.Models
{
public class LoginViewModel : ViewModelBase
{
public string EmailAddress { get; set; }
public string Password { get; set; }
public string OriginatingAddress { get; set; }
public string ReturnUrl { get; set; }
... |
cee10cbc-87e1-4efe-ba0e-5993155ec6be | {
"language": "C#"
} | ```c#
using System;
using System.Diagnostics;
using System.Linq;
using NUnit.Framework;
using NinjaNye.SearchExtensions.Levenshtein;
namespace NinjaNye.SearchExtensions.Tests.LevenshteinTests
{
[TestFixture]
public class LevenshteinDistancePerformanceTests : BuildStringTestsBase
{
#if DEBUG
... | ```c#
using System;
using System.Diagnostics;
using System.Linq;
using NUnit.Framework;
using NinjaNye.SearchExtensions.Levenshtein;
namespace NinjaNye.SearchExtensions.Tests.LevenshteinTests
{
#if DEBUG
// Performance test will always fail in debug mode
[Ignore]
#endif
[TestFixture]
public class Leve... |
82cb3f39-426f-470c-9ed7-6bc225191d2a | {
"language": "C#"
} | ```c#
using System.Reflection;
[assembly: AssemblyTitle("DoTheMath.Linear")]
[assembly: AssemblyDescription("A bunch of stuff for Linear Algebra.")]
```
Mark assembly as CLS compliant | ```c#
using System;
using System.Reflection;
[assembly: AssemblyTitle("DoTheMath.Linear")]
[assembly: AssemblyDescription("A bunch of stuff for Linear Algebra.")]
[assembly: CLSCompliant(true)]
``` |
593a8e90-4d06-4ac6-8bb9-86cd57a1de97 | {
"language": "C#"
} | ```c#
using System;
using System.Threading;
using Leak.Client.Tracker;
using Leak.Common;
using Pargos;
namespace Leak.Announce
{
public static class Program
{
public static void Main(string[] args)
{
Options options = Argument.Parse<Options>(args);
if (options.IsValid... | ```c#
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using Leak.Client.Tracker;
using Leak.Common;
using Pargos;
namespace Leak.Announce
{
public static class Program
{
public static void Main(string[] args)
{
Options options = Argument.Parse<Options>... |
4cb91703-5b4e-438a-a292-4a212604fae7 | {
"language": "C#"
} | ```c#
using System.ComponentModel;
using System.IO;
namespace Sakuno.IO
{
[EditorBrowsable(EditorBrowsableState.Never)]
public static class StreamExtensions
{
public static int FillBuffer(this Stream stream, byte[] buffer, int offset, int count)
{
var remaining = count;
... | ```c#
using System;
using System.ComponentModel;
using System.IO;
using System.Threading;
using System.Threading.Tasks;
namespace Sakuno.IO
{
[EditorBrowsable(EditorBrowsableState.Never)]
public static class StreamExtensions
{
public static int FillBuffer(this Stream stream, byte[] buffer, int off... |
8546dcd0-924d-4575-b5a9-a8c978dc24b7 | {
"language": "C#"
} | ```c#
// Copyright (c) Martin Costello, 2016. All rights reserved.
// Licensed under the Apache 2.0 license. See the LICENSE file in the project root for full license information.
namespace MartinCostello.Website
{
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.Configuration;
using Microso... | ```c#
// Copyright (c) Martin Costello, 2016. All rights reserved.
// Licensed under the Apache 2.0 license. See the LICENSE file in the project root for full license information.
namespace MartinCostello.Website
{
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.Configuration;
using Microso... |
a602ca4d-c95a-44eb-bd5d-8d4d6d81145b | {
"language": "C#"
} | ```c#
using System.IO;
namespace Microsoft.Diagnostics.Runtime
{
/// <summary>
/// Thrown when we fail to read memory from the target process.
/// </summary>
public class MemoryReadException : IOException
{
/// <summary>
/// The address of memory that could not be read.
///... | ```c#
using System.IO;
namespace Microsoft.Diagnostics.Runtime
{
/// <summary>
/// Thrown when we fail to read memory from the target process.
/// </summary>
public class MemoryReadException : IOException
{
/// <summary>
/// The address of memory that could not be read.
///... |
c83e76c0-608e-4654-88fc-613442344652 | {
"language": "C#"
} | ```c#
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Http;
using Microsoft.Extensions.Logging;
using System;
namespace DotNetRu.Azure
{
[Route("diagnostics")]
public class DiagnosticsController : ControllerBase
{
private readonly ILogger logger;
pu... | ```c#
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Logging;
using DotNetRu.AzureService;
namespace DotNetRu.Azure
{
[Route("diagnostics")]
public class DiagnosticsController : ControllerBase
{
private readonly ILogger logger;
private readonly RealmSettings realmSettings;
... |
256157b8-cf28-49a2-a11b-ce39de19274d | {
"language": "C#"
} | ```c#
using System.Reflection;
using System.Runtime.CompilerServices;
// Information about this assembly is defined by the following attributes.
// Change them to the values specific to your project.
[assembly: AssemblyTitle("UpdateVersion")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]... | ```c#
using System.Reflection;
using System.Runtime.CompilerServices;
// Information about this assembly is defined by the following attributes.
// Change them to the values specific to your project.
[assembly: AssemblyTitle("UpdateVersion")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
... |
f2611a01-4701-4013-acc9-13de216bcced | {
"language": "C#"
} | ```c#
namespace TraktApiSharp.Objects.Get.People
{
using Extensions;
using Newtonsoft.Json;
using System;
public class TraktPerson
{
[JsonProperty(PropertyName = "name")]
public string Name { get; set; }
[JsonProperty(PropertyName = "ids")]
public TraktPersonIds Id... | ```c#
namespace TraktApiSharp.Objects.Get.People
{
using Extensions;
using Newtonsoft.Json;
using System;
/// <summary>A Trakt person.</summary>
public class TraktPerson
{
/// <summary>Gets or sets the person name.</summary>
[JsonProperty(PropertyName = "name")]
public ... |
00357476-dda9-4b1a-a7bb-4ade714db2a4 | {
"language": "C#"
} | ```c#
#pragma warning disable CA1304
#pragma warning disable MA0011
using System.Globalization;
using TestUtilities;
using Xunit;
namespace Meziantou.Framework.ResxSourceGenerator.GeneratorTests;
public class ResxGeneratorTests
{
[RunIfFact(globalizationMode: FactInvariantGlobalizationMode.Disabled)]
public ... | ```c#
#pragma warning disable CA1304
#pragma warning disable MA0011
using System.Globalization;
using TestUtilities;
using Xunit;
namespace Meziantou.Framework.ResxSourceGenerator.GeneratorTests;
public class ResxGeneratorTests
{
[RunIfFact(globalizationMode: FactInvariantGlobalizationMode.Disabled)]
public ... |
6994958c-d88b-4243-b7fe-9a132e46ed64 | {
"language": "C#"
} | ```c#
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Diploms.Core;
namespace Diploms.WebUI.Controllers
{
[Route("api/[controller]")]
public class DepartmentsController : Controller
{
[HttpGet("")]
public... | ```c#
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Diploms.Core;
namespace Diploms.WebUI.Controllers
{
[Route("api/[controller]")]
public class DepartmentsController : Controller
{
private readonly IRepository... |
104ab064-0af0-42c3-afad-a12c22f44e41 | {
"language": "C#"
} | ```c#
using System;
using NHibernate;
using NUnit.Framework;
namespace NHibernate.Test.TypesTest
{
/// <summary>
/// Summary description for BinaryBlobTypeFixture.
/// </summary>
[TestFixture]
public class BinaryBlobTypeFixture : TypeFixtureBase
{
protected override string TypeName
{
get { return "Binar... | ```c#
using System;
using NHibernate;
using NUnit.Framework;
namespace NHibernate.Test.TypesTest
{
/// <summary>
/// Summary description for BinaryBlobTypeFixture.
/// </summary>
[TestFixture]
public class BinaryBlobTypeFixture : TypeFixtureBase
{
protected override string TypeName
{
get { return "Binar... |
ad7b8540-be45-45d5-b066-be9ee80f0b6d | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Runtime;
using osu.Framework.Caching;
namespace osu.Framework.Configuration
{
public class FrameworkDebugConfigManager : IniConfigManager<DebugSe... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Runtime;
using osu.Framework.Caching;
namespace osu.Framework.Configuration
{
public class FrameworkDebugConfigManager : IniConfigManager<DebugSe... |
35f8811b-a914-40e4-8b3c-67cfff02dfa0 | {
"language": "C#"
} | ```c#
public static unsafe class Program
{
public static extern void* malloc(ulong size);
public static extern void free(void* data);
public static extern int puts(byte* str);
public static int Main()
{
byte* str = (byte*)malloc(3);
*str = (byte)'h';
*(str + 1) = (byte)'i';
... | ```c#
public static unsafe class Program
{
public static extern void* malloc(ulong size);
public static extern void free(void* data);
public static extern int puts(byte* str);
public static void FillString(byte* str)
{
*str = (byte)'h';
*(str + 1) = (byte)'i';
*(str + 2) = (... |
4409d9d6-4eef-40f1-bd04-1761c03854d7 | {
"language": "C#"
} | ```c#
using System.Collections.Generic;
using JetBrains.ReSharper.Feature.Services.Daemon;
using JetBrains.ReSharper.Plugins.Unity.Json.Daemon.Errors;
using JetBrains.ReSharper.Plugins.Unity.Json.Psi.Resolve;
using JetBrains.ReSharper.Psi;
using JetBrains.ReSharper.Psi.JavaScript.LanguageImpl.JSon;
using JetBrains.ReS... | ```c#
using System.Collections.Generic;
using JetBrains.ReSharper.Feature.Services.Daemon;
using JetBrains.ReSharper.Plugins.Unity.Json.Daemon.Errors;
using JetBrains.ReSharper.Plugins.Unity.Json.Psi.Resolve;
using JetBrains.ReSharper.Psi;
using JetBrains.ReSharper.Psi.JavaScript.LanguageImpl.JSon;
using JetBrains.ReS... |
41d9df11-8781-44aa-aedc-eae7c9750276 | {
"language": "C#"
} | ```c#
using Newtonsoft.Json;
namespace Digirati.IIIF.Model.Types.ImageApi
{
public class ImageServiceProfile : IProfile
{
[JsonProperty(Order = 1, PropertyName = "formats")]
public string[] Formats { get; set; }
[JsonProperty(Order = 2, PropertyName = "qualities")]
public stri... | ```c#
using Newtonsoft.Json;
namespace Digirati.IIIF.Model.Types.ImageApi
{
public class ImageServiceProfile : IProfile
{
[JsonProperty(Order = 1, PropertyName = "formats")]
public string[] Formats { get; set; }
[JsonProperty(Order = 2, PropertyName = "qualities")]
public stri... |
aa6b4270-40ae-479b-8263-63573ae751f8 | {
"language": "C#"
} | ```c#
using System;
using JetBrains.Application;
using JetBrains.Application.Settings;
using JetBrains.ReSharper.Feature.Services.CSharp.FileLayout;
using JetBrains.ReSharper.Plugins.Unity.Core.ProjectModel;
using JetBrains.ReSharper.Psi.CSharp.CodeStyle;
using JetBrains.ReSharper.Psi.CSharp.Impl.CodeStyle.MemberReorde... | ```c#
using System;
using JetBrains.Application;
using JetBrains.Application.Settings;
using JetBrains.ReSharper.Feature.Services.CSharp.FileLayout;
using JetBrains.ReSharper.Plugins.Unity.Core.ProjectModel;
using JetBrains.ReSharper.Psi.CSharp.CodeStyle;
using JetBrains.ReSharper.Psi.CSharp.Impl.CodeStyle.MemberReorde... |
b354a360-8b4f-472e-a0e1-13a15e99e18b | {
"language": "C#"
} | ```c#
using System;
using System.Linq;
using System.Net;
using AngleSharp.Dom;
using PreMailer.Net.Downloaders;
namespace PreMailer.Net.Sources
{
public class LinkTagCssSource : ICssSource
{
private readonly Uri _downloadUri;
private string _cssContents;
public LinkTagCssSource(IElement node, Uri baseUri)
... | ```c#
using System;
using System.Linq;
using System.Net;
using AngleSharp.Dom;
using PreMailer.Net.Downloaders;
namespace PreMailer.Net.Sources
{
public class LinkTagCssSource : ICssSource
{
private readonly Uri _downloadUri;
private string _cssContents;
public LinkTagCssSource(IElement node, Uri baseUri)
... |
96d839d3-97b3-424d-83e0-fd9685d39bb9 | {
"language": "C#"
} | ```c#
using System;
using System.Collections.Generic;
using System.Linq;
using System.ServiceModel.Syndication;
using System.Web;
using Firehose.Web.Infrastructure;
namespace Firehose.Web.Authors
{
public class KevinMarquette : IAmAMicrosoftMVP
{
public string FirstName => "Kevin";
public strin... | ```c#
using System;
using System.Collections.Generic;
using System.Linq;
using System.ServiceModel.Syndication;
using System.Web;
using Firehose.Web.Infrastructure;
namespace Firehose.Web.Authors
{
public class KevinMarquette : IAmAMicrosoftMVP
{
public string FirstName => "Kevin";
public strin... |
6d2dfbef-d5ff-4848-b988-48c4b6f13fbe | {
"language": "C#"
} | ```c#
using System;
using System.Text;
using System.Web.Security;
using Newtonsoft.Json;
using NLog;
namespace SFA.DAS.EmployerUsers.Web.Authentication
{
public class IdsContext
{
public string ReturnUrl { get; set; }
public string ClientId { get; set; }
public static string CookieName =>... | ```c#
using System;
using System.Text;
using System.Web.Security;
using Newtonsoft.Json;
using NLog;
namespace SFA.DAS.EmployerUsers.Web.Authentication
{
public class IdsContext
{
public string ReturnUrl { get; set; }
public string ClientId { get; set; }
public static string CookieName =>... |
c18ae732-03a8-4cf1-8285-7f985f5f690e | {
"language": "C#"
} | ```c#
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
namespace AspNetCore.RouteAnalyzer.SampleWebProject
{
... | ```c#
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using System.Diagnostics;
namespace AspNetCore.RouteAn... |
aeb712b4-016c-49b5-8cfd-5f8f47e56ab8 | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Game.Tournament.Models;
using osu.Game.Tournament.Screens.TeamIntro;
namespace osu.Game.Tou... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Linq;
using NUnit.Framework;
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Testing;
using osu.Game.Tournament.Model... |
03725afe-bdee-4630-b9e0-d1426e98fbb0 | {
"language": "C#"
} | ```c#
// Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using System;
using System.Runtime;
using osu.Framework.Allocation;
using osu.Framework.Configuration;
using osu.Framework.Graphics;
namespace osu.Game.Overlays.... | ```c#
// Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using System;
using System.Runtime;
using osu.Framework.Allocation;
using osu.Framework.Configuration;
using osu.Framework.Graphics;
namespace osu.Game.Overlays.... |
320ac22f-281d-4a0c-a030-84f054ccd6ac | {
"language": "C#"
} | ```c#
using System;
using Newtonsoft.Json;
using System.Collections.Generic;
using System.Linq;
namespace Alexa.NET.Response
{
public class ResponseBody
{
[JsonProperty("outputSpeech", NullValueHandling = NullValueHandling.Ignore)]
public IOutputSpeech OutputSpeech { get; set; }
[Json... | ```c#
using System;
using Newtonsoft.Json;
using System.Collections.Generic;
using System.Linq;
namespace Alexa.NET.Response
{
public class ResponseBody
{
[JsonProperty("outputSpeech", NullValueHandling = NullValueHandling.Ignore)]
public IOutputSpeech OutputSpeech { get; set; }
[Json... |
bee3be1f-a232-4e2a-af3b-908b2c68e5cf | {
"language": "C#"
} | ```c#
using System.Collections.Generic;
using System.Xml;
namespace PROProtocol
{
public class Language
{
private Dictionary<string, string> _texts;
public Language()
{
XmlDocument xml = new XmlDocument();
xml.Load("Resources/Lang.xml");
... | ```c#
using System.Collections.Generic;
using System.IO;
using System.Xml;
namespace PROProtocol
{
public class Language
{
private const string FileName = "Resources/Lang.xml";
private Dictionary<string, string> _texts = new Dictionary<string, string>();
public Language()... |
4fb5fd82-731f-48e9-a065-e392869fec7d | {
"language": "C#"
} | ```c#
using Ploeh.AutoFixture.Xunit;
using Xunit;
using Xunit.Extensions;
namespace BobTheBuilder.Tests
{
public class BuildFacts
{
[Fact]
public void CreateADynamicInstanceOfTheRequestedType()
{
var sut = A.BuilderFor<SampleType>();
var result = sut.Build();
... | ```c#
using Ploeh.AutoFixture.Xunit;
using Xunit;
using Xunit.Extensions;
namespace BobTheBuilder.Tests
{
public class BuildFacts
{
[Fact]
public void CreateADynamicInstanceOfTheRequestedType()
{
var sut = A.BuilderFor<SampleType>();
var result = sut.Build();
... |
3d6332f9-e68e-4154-8d6d-6fba8197a2d1 | {
"language": "C#"
} | ```c#
using System;
using System.Collections.Generic;
using JetBrains.Application;
using JetBrains.Diagnostics;
using JetBrains.Metadata.Utils;
using JetBrains.ReSharper.Psi.ExtensionsAPI.ExternalAnnotations;
using JetBrains.TestFramework.Utils;
using JetBrains.Util;
namespace JetBrains.ReSharper.Plugins.Unity.Tests
... | ```c#
using System;
using System.Collections.Generic;
using JetBrains.Application;
using JetBrains.Diagnostics;
using JetBrains.Metadata.Utils;
using JetBrains.ReSharper.Psi.ExtensionsAPI.ExternalAnnotations;
using JetBrains.TestFramework.Utils;
using JetBrains.Util;
namespace JetBrains.ReSharper.Plugins.Unity.Tests
... |
7f1021f6-90f3-4673-a01c-88c75ddee3cb | {
"language": "C#"
} | ```c#
using System.Collections.ObjectModel;
namespace Espera.Network
{
public class NetworkPlaylist
{
public int? CurrentIndex { get; set; }
public string Name { get; set; }
public int? RemainingVotes { get; set; }
public ReadOnlyCollection<NetworkSong> Songs { get; set; }
... | ```c#
using System.Collections.ObjectModel;
namespace Espera.Network
{
public class NetworkPlaylist
{
public int? CurrentIndex { get; set; }
public string Name { get; set; }
public NetworkPlaybackState PlaybackState { get; set; }
public int? RemainingVotes { get; set; }
... |
9bdff48c-d45a-445e-9914-5fbdf075bd7f | {
"language": "C#"
} | ```c#
using JoinRpg.DataModel;
using JoinRpg.Domain;
using Microsoft.AspNetCore.Mvc;
namespace JoinRpg.Portal.Controllers.Comments
{
internal static class CommentRedirectHelper
{
public static ActionResult RedirectToDiscussion(IUrlHelper Url, CommentDiscussion discussion, int? commentId = null)
... | ```c#
using JoinRpg.DataModel;
using JoinRpg.Domain;
using Microsoft.AspNetCore.Mvc;
namespace JoinRpg.Portal.Controllers.Comments
{
internal static class CommentRedirectHelper
{
public static ActionResult RedirectToDiscussion(IUrlHelper Url, CommentDiscussion discussion, int? commentId = null)
... |
e2a9d489-949f-4caa-93fe-649a9db6e755 | {
"language": "C#"
} | ```c#
//
// Copyright (c) Microsoft. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applica... | ```c#
//
// Copyright (c) Microsoft. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applica... |
8e6e88b7-9017-419f-b5ef-b82617ebea98 | {
"language": "C#"
} | ```c#
using Newtonsoft.Json;
namespace Nest
{
[JsonObject]
public class AnalyzeToken
{
[JsonProperty(PropertyName = "token")]
public string Token { get; internal set; }
[JsonProperty(PropertyName = "type")]
public string Type { get; internal set; }
//TODO change to long in 6.0
[JsonProperty(PropertyN... | ```c#
using System;
using Newtonsoft.Json;
namespace Nest
{
[JsonObject]
public class AnalyzeToken
{
[JsonProperty("token")]
public string Token { get; internal set; }
[JsonProperty("type")]
public string Type { get; internal set; }
//TODO change to long in 6.0... RC: (this is int in Elasticsearch code... |
ca1ad6c5-f595-4b7f-94fe-a1ee760d7c9c | {
"language": "C#"
} | ```c#
using System;
using System.Linq;
using FluentValidation;
using SFA.DAS.CommitmentsV2.Models;
namespace SFA.DAS.CommitmentsV2.Application.Queries.GetApprenticeships
{
public class GetApprenticeshipsQueryValidator : AbstractValidator<GetApprenticeshipsQuery>
{
public GetApprenticeshipsQueryValidat... | ```c#
using System;
using System.Linq;
using FluentValidation;
using SFA.DAS.CommitmentsV2.Models;
namespace SFA.DAS.CommitmentsV2.Application.Queries.GetApprenticeships
{
public class GetApprenticeshipsQueryValidator : AbstractValidator<GetApprenticeshipsQuery>
{
public GetApprenticeshipsQueryValidat... |
de45f8d3-ce19-4ef9-9aef-04d929e2ba3f | {
"language": "C#"
} | ```c#
@model Portal.CMS.Web.Areas.Builder.ViewModels.Container.EditViewModel
@{
Layout = "";
}
<script type="text/javascript">
function Delete()
{
$('#@Model.ContainerElementId').remove();
var dataParams = { "pageSectionId": @Model.PageSectionId , "componentId": "@Model.ContainerElementId... | ```c#
@model Portal.CMS.Web.Areas.Builder.ViewModels.Container.EditViewModel
@{
Layout = "";
}
<script type="text/javascript">
function Delete()
{
$('#@Model.ContainerElementId').remove();
var dataParams = { "pageSectionId": @Model.PageSectionId , "componentId": "@Model.ContainerElementId... |
a9f0887a-3478-47ea-bb5e-027bf8a74271 | {
"language": "C#"
} | ```c#
using UnityEngine;
using System.Collections.Generic;
public class PlayerMovement
{
private const float Gravity = -1.0f;
public bool IsOnGround { get; set; }
public Vector3 Update()
{
if (IsOnGround)
{
return Vector2.zero;
}
return new Vect... | ```c#
using UnityEngine;
using System.Collections.Generic;
public class PlayerMovement
{
private const float Gravity = -1.0f;
public bool IsOnGround { get; set; }
private Vector3 currentVelocity;
public Vector3 Update()
{
if (IsOnGround)
{
return Vector2.z... |
07316c2d-38c1-494f-a1d4-b737e53bf4aa | {
"language": "C#"
} | ```c#
using System.Reflection;
using System.Runtime.CompilerServices;
// Information about this assembly is defined by the following attributes.
// Change them to the values specific to your project.
[assembly: AssemblyTitle ("Eve.NET.Net4")]
[assembly: AssemblyDescription ("")]
[assembly: AssemblyConfiguration ("")... | ```c#
using System.Reflection;
using System.Runtime.CompilerServices;
// Information about this assembly is defined by the following attributes.
// Change them to the values specific to your project.
[assembly: AssemblyTitle ("Eve.NET.Net4")]
[assembly: AssemblyDescription ("")]
[assembly: AssemblyConfiguration ("")... |
3a7612bb-41d3-4d49-bd90-5054cb0cc48a | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
#nullable disable
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Localisation;
using osu.Game.Graphics.UserInterfaceV2;
using os... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
#nullable disable
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Localisation;
using osu.Game.Graphics.UserInterfaceV2;
using os... |
1f7d5260-05a2-4ce4-a22d-6e4af846e3d4 | {
"language": "C#"
} | ```c#
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Diagnostics;
using Microsoft.CodeAnalysis.Text;
using NUnit.Framework;
using RoslynNUnitLight;
using UnityEngineAnalyzer.Coroutines;
namespace UnityEngineAnalyzer.Test.Coroutines
{
[TestFixture]
sealed class DoNotUseCoroutinesAnalyzerTests : Ana... | ```c#
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Diagnostics;
using Microsoft.CodeAnalysis.Text;
using NUnit.Framework;
using RoslynNUnitLight;
using UnityEngineAnalyzer.Coroutines;
namespace UnityEngineAnalyzer.Test.Coroutines
{
[TestFixture]
sealed class DoNotUseCoroutinesAnalyzerTests : Ana... |
0761178b-176c-4561-902a-688fec1214db | {
"language": "C#"
} | ```c#
using IdentityModel.Client;
using System;
using System.Collections.Generic;
namespace eShopOnContainers.Core.Services.Identity
{
public class IdentityService : IIdentityService
{
public string CreateAuthorizationRequest()
{
// Create URI to authorization endpoint
... | ```c#
using IdentityModel.Client;
using System;
using System.Collections.Generic;
namespace eShopOnContainers.Core.Services.Identity
{
public class IdentityService : IIdentityService
{
public string CreateAuthorizationRequest()
{
// Create URI to authorization endpoint
... |
12b4e68d-93f4-4279-bb6d-554f90226fa7 | {
"language": "C#"
} | ```c#
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace Engine.Game.Actor {
public class NavMeshAgentFollowController : MonoBehaviour {
public NavMeshAgent agent;
public Transform targetFollow;
// Use this for initializatio... | ```c#
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace Engine.Game.Actor {
public class NavMeshAgentFollowController : MonoBehaviour {
public NavMeshAgent agent;
public Transform targetFollow;
// Use this for initialization
pr... |
adbd7939-4cd9-498a-9b83-1c3aa6f0f5dd | {
"language": "C#"
} | ```c#
using System;
using System.Collections.Generic;
using System.Text;
namespace MediaManager
{
public abstract class NotificationManagerBase : INotificationManager
{
protected NotificationManagerBase()
{
Enabled = true;
}
private bool _enabled = true;
... | ```c#
using System;
using System.Collections.Generic;
using System.Text;
namespace MediaManager
{
public abstract class NotificationManagerBase : INotificationManager
{
protected NotificationManagerBase()
{
Enabled = true;
ShowPlayPauseControls = true;
ShowN... |
dc6ed7c3-2ca3-480e-8475-9ace8bfe98be | {
"language": "C#"
} | ```c#
using LearnWordsFast.API.Exceptions;
using LearnWordsFast.API.Services;
using LearnWordsFast.API.ViewModels.TrainingController;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Logging;
namespace LearnWordsFast.API.Controllers
{
[Route("api/Training")]
... | ```c#
using LearnWordsFast.API.Exceptions;
using LearnWordsFast.API.Services;
using LearnWordsFast.API.ViewModels.TrainingController;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Logging;
namespace LearnWordsFast.API.Controllers
{
[Route("api/Training")]
... |
6378917e-ddde-4be1-91fd-04bab6450085 | {
"language": "C#"
} | ```c#
using System;
using System.Collections.Generic;
namespace WinRSJS
{
public sealed class Collections
{
static public object /* IMap<?, ?> */ createMap(string keyTypeName, string valTypeName)
{
Type typeKey = Type.GetType(keyTypeName);
if (typeKey == null)... | ```c#
using System;
using System.Collections.Generic;
namespace WinRSJS
{
public sealed class Collections
{
static public object /* IMap<?, ?> */ CreateMap(string keyTypeName, string valTypeName)
{
Type typeKey = Type.GetType(keyTypeName);
if (typeKey == null)... |
bdf12358-2842-41c9-a833-708c3a15132e | {
"language": "C#"
} | ```c#
using System.IO;
using System.Windows.Controls;
using System.Windows.Media.Imaging;
using NuGetPackageExplorer.Types;
namespace PackageExplorer {
[PackageContentViewerMetadata(99, ".jpg", ".gif", ".png", ".tif")]
internal class ImageFileViewer : IPackageContentViewer {
public object GetV... | ```c#
using System.IO;
using System.Windows.Controls;
using System.Windows.Media.Imaging;
using NuGetPackageExplorer.Types;
namespace PackageExplorer {
[PackageContentViewerMetadata(99, ".jpg", ".gif", ".png", ".tif", ".bmp", ".ico")]
internal class ImageFileViewer : IPackageContentViewer {
pu... |
39861abf-6412-499a-835b-1f1aec5a4dd8 | {
"language": "C#"
} | ```c#
using AnimalHope.Web.Infrastructure.Mapping;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using System.Web.Optimization;
using System.Web.Routing;
namespace AnimalHope.Web
{
public class MvcApplication : System.Web.HttpApplication
{
p... | ```c#
using AnimalHope.Web.Infrastructure.Mapping;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using System.Web.Optimization;
using System.Web.Routing;
namespace AnimalHope.Web
{
public class MvcApplication : System.Web.HttpApplication
{
p... |
200e2496-9edc-4a41-9be7-ae3629fc9666 | {
"language": "C#"
} | ```c#
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
namespace Archaius
{
public class EnvironmentConfiguration : DictionaryConfiguration
{
public EnvironmentConfiguration()
: base(GetEnvironmentVariables())
{
}
public ... | ```c#
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
namespace Archaius
{
public class EnvironmentConfiguration : DictionaryConfiguration
{
public EnvironmentConfiguration()
: base(GetEnvironmentVariables())
{
}
public ... |
e3d02b58-4bb6-488c-a50a-630a887c29c0 | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Linq;
using NUnit.Framework;
using osu.Framework.Graphics;
using osu.Framework.Testing;
using osu.Game.Beatmaps;
using osu.Game.Rulesets.Catch.Skinning... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using NUnit.Framework;
using osu.Game.Tests.Visual;
namespace osu.Game.Rulesets.Catch.Tests
{
[TestFixture]
public class TestSceneCatchPlayerLegacySkin : L... |
5e4771a2-52fb-4d24-a56e-c1cb99c51346 | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Game.Rulesets.UI;
using osuTK;
namespace osu.Game.Rulesets.Catch.UI
{
public c... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Game.Rulesets.UI;
using osuTK;
namespace osu.Game.Rulesets.Catch.UI
{
public c... |
02a541a2-d465-4f49-b62a-457c42d44847 | {
"language": "C#"
} | ```c#
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
namespace MonoGameUtils.Drawing
{
/// <summary>
/// Various useful utility methods that don't obviously go elsewhere.... | ```c#
using System;
using System.Collections.Generic;
using System.Diagnostics.Contracts;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
namespace MonoGameUtils.Drawing
{
/// <summary>
/// Various useful utility method... |
beda0a99-0e5a-45c7-b890-e01ed83ce610 | {
"language": "C#"
} | ```c#
using System.Collections.Generic;
using LinqToTTreeInterfacesLib;
namespace LINQToTTreeLib.Statements
{
/// <summary>
/// Sits inside a loop and records the integer that it is given on each call by pushing it onto a vector. It *does not*
/// check for uniqueness.
/// </summary>
clas... | ```c#
using System.Collections.Generic;
using LinqToTTreeInterfacesLib;
using LINQToTTreeLib.Variables;
namespace LINQToTTreeLib.Statements
{
/// <summary>
/// Sits inside a loop and records the integer that it is given on each call by pushing it onto a vector. It *does not*
/// check for uniquene... |
d3db0e4e-e203-4432-8a4f-34795e076be6 | {
"language": "C#"
} | ```c#
using Android.Widget;
using FFImageLoading.Work;
namespace FFImageLoading.Extensions
{
public static class ImageViewExtensions
{
/// <summary>
/// Retrieve the currently active work task (if any) associated with this imageView.
/// </summary>
/// <param name="imageView"></param>
/// <returns></return... | ```c#
using Android.Widget;
using FFImageLoading.Work;
using System;
namespace FFImageLoading.Extensions
{
public static class ImageViewExtensions
{
/// <summary>
/// Retrieve the currently active work task (if any) associated with this imageView.
/// </summary>
/// <param name="imageView"></param>
/// <re... |
b316d9e5-036d-439a-a15a-292ab015d084 | {
"language": "C#"
} | ```c#
using System.IO;
using System.Reflection;
using Cake.Core;
using Cake.Core.Annotations;
using Nerdbank.GitVersioning;
namespace Cake.GitVersioning
{
/// <summary>
/// Contains functionality for using Nerdbank.GitVersioning.
/// </summary>
[CakeAliasCategory("Git Versioning")]
public static c... | ```c#
using System.IO;
using System.Reflection;
using Cake.Core;
using Cake.Core.Annotations;
using Nerdbank.GitVersioning;
namespace Cake.GitVersioning
{
/// <summary>
/// Contains functionality for using Nerdbank.GitVersioning.
/// </summary>
[CakeAliasCategory("Git Versioning")]
public static c... |
da2a9d35-d288-435c-a6e8-f3770ae9066c | {
"language": "C#"
} | ```c#
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.Text;
using System.Threading.Tasks;
namespace Umbraco.Web.Models.ContentEditing
{
[DataContract(Name = "propertyGroup", Namespace = "")]
public class PropertyGroupDisplay
{
pub... | ```c#
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.Text;
using System.Threading.Tasks;
namespace Umbraco.Web.Models.ContentEditing
{
[DataContract(Name = "propertyGroup", Namespace = "")]
public class PropertyGroupDisplay
{
pub... |
903657a2-3f85-47f0-9305-8f03912626bf | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
#nullable disable
using osu.Framework.Bindables;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
namespace osu.Game.Graphics.Containers
{
... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
#nullable disable
using System.Collections.Specialized;
using osu.Framework.Allocation;
using osu.Framework.Audio;
using osu.Framework.Audio.Sample;
using osu.Fram... |
5065192e-51e4-4e76-89c0-397bd306d046 | {
"language": "C#"
} | ```c#
using Microsoft.Xunit.Performance;
using Xunit;
namespace DNXLibrary
{
// This project can output the Class library as a NuGet Package.
// To enable this option, right-click on the project and select the Properties menu item. In the Build tab select "Produce outputs on build".
public class DNXSample... | ```c#
using Microsoft.Xunit.Performance;
using Xunit;
namespace DNXLibrary
{
// This project can output the Class library as a NuGet Package.
// To enable this option, right-click on the project and select the Properties menu item. In the Build tab select "Produce outputs on build".
public class DNXSample... |
e8fccdec-c292-43d1-85df-f89d7a43e6bd | {
"language": "C#"
} | ```c#
@model JoinRpg.DataModel.MarkdownString
@{
var requiredMsg = new MvcHtmlString("");
var validation = false;
foreach (var attr in @Html.GetUnobtrusiveValidationAttributes(@ViewData.TemplateInfo.HtmlFieldPrefix, @ViewData.ModelMetadata))
{
if (attr.Key == "data-val-required")
{
requ... | ```c#
@model JoinRpg.DataModel.MarkdownString
@{
var requiredMsg = new MvcHtmlString("");
var validation = false;
foreach (var attr in @Html.GetUnobtrusiveValidationAttributes(@ViewData.TemplateInfo.HtmlFieldPrefix, @ViewData.ModelMetadata))
{
if (attr.Key == "data-val-required")
{
requ... |
9ac0f119-0e2f-418a-8bd2-037c03e1416b | {
"language": "C#"
} | ```c#
// WhistTest.cs
// <copyright file="WhistTest.cs"> This code is protected under the MIT License. </copyright>
using System;
using CardGames.Whist;
namespace ConsoleTesting
{
/// <summary>
/// The whist test class
/// </summary>
public class WhistTest : IGameTest
{
/// <su... | ```c#
// WhistTest.cs
// <copyright file="WhistTest.cs"> This code is protected under the MIT License. </copyright>
using System;
using CardGames.Whist;
namespace ConsoleTesting
{
/// <summary>
/// The whist test class
/// </summary>
public class WhistTest : IGameTest
{
/// <su... |
5c367440-f563-4e5e-bb11-22234871faf7 | {
"language": "C#"
} | ```c#
using System.Diagnostics;
using System.Windows.Input;
using DesktopWidgets.Classes;
using DesktopWidgets.Helpers;
using DesktopWidgets.ViewModelBase;
using GalaSoft.MvvmLight.Command;
namespace DesktopWidgets.Widgets.Search
{
public class ViewModel : WidgetViewModelBase
{
private string _searchT... | ```c#
using System.Diagnostics;
using System.Windows.Input;
using DesktopWidgets.Classes;
using DesktopWidgets.Helpers;
using DesktopWidgets.ViewModelBase;
using GalaSoft.MvvmLight.Command;
namespace DesktopWidgets.Widgets.Search
{
public class ViewModel : WidgetViewModelBase
{
private string _searchT... |
ebabb51d-a264-4822-80ba-af3865ffff50 | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using NUnit.Framework;
using osu.Framework.Allocation;
using osu.Framework.IO.Stores;
using osu.Game.Rulesets;
using osu.Game.Skinning;
namespace osu.Game.Tests.Vi... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using NUnit.Framework;
using osu.Framework.Allocation;
using osu.Framework.Extensions.IEnumerableExtensions;
using osu.Framework.IO.Stores;
using osu.Framework.Test... |
60b87ab9-38fc-4d7f-822e-8097498bcf80 | {
"language": "C#"
} | ```c#
namespace pinboard.net.Models
{
public class LastUpdate
{
}
}```
Implement last update model, had forgotten, hehe | ```c#
using Newtonsoft.Json;
using System;
namespace pinboard.net.Models
{
public class LastUpdate
{
[JsonProperty("update_time")]
public DateTimeOffset UpdateTime { get; set; }
}
}``` |
0c596866-695d-4690-a44a-5f9998a8201c | {
"language": "C#"
} | ```c#
using System.Resources;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly... | ```c#
using System.Resources;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly... |
61d8c98d-1228-48f5-b8fa-a8d421b79352 | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Bindables;
using osu.Framework.Graphics.UserInterface;
using osu.Game.Beatmaps;
using osu.Game.Rulesets;
using System.Linq;
using osu.Framework... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Bindables;
using osu.Framework.Graphics.UserInterface;
using osu.Game.Beatmaps;
using osu.Game.Rulesets;
using System.Linq;
namespace osu.Game... |
27b3e9a0-6982-49de-a3a4-5065717751f3 | {
"language": "C#"
} | ```c#
using System.Collections.Generic;
using System.IO;
using System.Linq;
namespace HelloSignNet.Core
{
public class HSSendSignatureRequestData
{
public string Title { get; set; }
public string Subject { get; set; }
public string Message { get; set; }
public string SigningRedi... | ```c#
using System.Collections.Generic;
using System.IO;
using System.Linq;
namespace HelloSignNet.Core
{
public class HSSendSignatureRequestData
{
public string Title { get; set; }
public string Subject { get; set; }
public string Message { get; set; }
public string SigningRedi... |
4bfb6369-bb94-419e-b546-ecb0b82c26f7 | {
"language": "C#"
} | ```c#
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace Downlitor
{
public partial class ItemInfoControl : UserControl
{
public ItemInfoControl(DlcItem dlc)
... | ```c#
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace Downlitor
{
public partial class ItemInfoControl : UserControl
{
public ItemInfoControl(DlcItem dlc)
... |
ad74edcd-9f23-49de-a06b-819ef929ba6c | {
"language": "C#"
} | ```c#
using RethinkDb.DatumConverters;
namespace RethinkDb.Newtonsoft.Configuration
{
public class NewtonSerializer : AggregateDatumConverterFactory
{
public NewtonSerializer() : base(
PrimitiveDatumConverterFactory.Instance,
TupleDatumConverterFactory.Instance,
Ano... | ```c#
using RethinkDb.DatumConverters;
namespace RethinkDb.Newtonsoft.Configuration
{
public class NewtonSerializer : AggregateDatumConverterFactory
{
public NewtonSerializer() : base(
PrimitiveDatumConverterFactory.Instance,
TupleDatumConverterFactory.Instance,
Ano... |
bb6843ad-41db-455b-a139-e7885e234290 | {
"language": "C#"
} | ```c#
using System;
using System.Configuration;
using System.Linq;
namespace NBi.NUnit.Runtime
{
public class NBiSection : ConfigurationSection
{
// Create a "remoteOnly" attribute.
[ConfigurationProperty("testSuite", IsRequired = true)]
public string TestSuiteFilename
... | ```c#
using System;
using System.Configuration;
using System.Linq;
namespace NBi.NUnit.Runtime
{
public class NBiSection : ConfigurationSection
{
// Create a "remoteOnly" attribute.
[ConfigurationProperty("testSuite", IsRequired = true)]
public string TestSuiteFilename
... |
d042ed58-0a3f-4203-be05-7ac5c57a3221 | {
"language": "C#"
} | ```c#
using Common;
using System;
namespace Crayon
{
internal class UsageDisplayWorker
{
private static readonly string USAGE = Util.JoinLines(
"Usage:",
" crayon BUILD-FILE -target BUILD-TARGET-NAME [OPTIONS...]",
"",
"Flags:",
... | ```c#
using Common;
using System;
namespace Crayon
{
internal class UsageDisplayWorker
{
private static readonly string USAGE = Util.JoinLines(
"Crayon version " + VersionInfo.VersionString,
"",
"To export:",
" crayon BUILD-FILE -target BUILD... |
1dae408f-d33f-4b42-8beb-7391c5761014 | {
"language": "C#"
} | ```c#
using System.IO;
using System.Text.Json;
namespace AsmResolver.DotNet.Config.Json
{
/// <summary>
/// Represents the root object of a runtime configuration, stored in a *.runtimeconfig.json file.
/// </summary>
public class RuntimeConfiguration
{
private static readonly JsonSerializer... | ```c#
using System.IO;
using System.Text.Json;
namespace AsmResolver.DotNet.Config.Json
{
/// <summary>
/// Represents the root object of a runtime configuration, stored in a *.runtimeconfig.json file.
/// </summary>
public class RuntimeConfiguration
{
private static readonly JsonSerializer... |
6e1418f8-eb27-4cc2-a9be-b1334dcf19f1 | {
"language": "C#"
} | ```c#
using System;
using System.Reflection;
using System.Runtime.InteropServices;
[assembly: AssemblyTitle("Autofac.Integration.SignalR")]
[assembly: AssemblyDescription("Autofac ASP.NET SignalR Integration")]
[assembly: ComVisible(false)]
[assembly: CLSCompliant(false)]```
Build script now writes the packag... | ```c#
using System;
using System.Reflection;
using System.Runtime.InteropServices;
[assembly: AssemblyTitle("Autofac.Integration.SignalR")]
[assembly: ComVisible(false)]
[assembly: CLSCompliant(false)]``` |
061f24ab-4a84-4def-8d2e-8bf779f28b48 | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Threading;
using NUnit.Framework;
using osu.Framework.Audio;
namespace osu.Framework.Tests.Audio
{
[TestFixture]
public class AudioCollection... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Threading;
using NUnit.Framework;
using osu.Framework.Audio;
namespace osu.Framework.Tests.Audio
{
[TestFixture]
public class AudioCollection... |
d9f13902-1845-41e7-a5fc-f2786b0013e6 | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
#nullable disable
using System.Linq;
using NUnit.Framework;
using osu.Game.Rulesets.Osu;
using osu.Game.Rulesets.Osu.Mods;
using osu.Game.Rulesets.UI;
namespace o... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Linq;
using NUnit.Framework;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Game.Rulesets.Osu;
using osu.Game.Ruleset... |
ed8cab9d-20ba-498f-844b-20428ac926a2 | {
"language": "C#"
} | ```c#
using System.IO;
using System.Text;
using Moq;
using Xunit;
namespace AppHarbor.Tests
{
public class ApplicationConfigurationTest
{
[Fact]
public void ShouldReturnApplicationIdIfConfigurationFileExists()
{
var fileSystem = new Mock<IFileSystem>();
var applicationName = "bar";
var configuration... | ```c#
using System.IO;
using System.Text;
using Moq;
using Xunit;
namespace AppHarbor.Tests
{
public class ApplicationConfigurationTest
{
public static string ConfigurationFile = Path.GetFullPath(".appharbor");
[Fact]
public void ShouldReturnApplicationIdIfConfigurationFileExists()
{
var fileSystem = ne... |
a18a7bae-ff92-48f4-a762-c6f1a9334e43 | {
"language": "C#"
} | ```c#
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Create.CSP.GitHub.Reporting.Entities
{
public class AuthorizationToken
{
/// <summary>
/// Captures when the token expires
/// </summary>
public D... | ```c#
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Create.CSP.GitHub.Reporting.Entities
{
public class AuthorizationToken
{
/// <summary>
/// Captures when the token expires
/// </summary>
public D... |
3650e9b9-6ccf-47a1-9e11-31c09c22ee30 | {
"language": "C#"
} | ```c#
using System.Threading.Tasks;
using Microsoft.AspNet.SignalR;
using System.Collections.Generic;
using WaveDev.ModelR.Models;
using System;
using System.Globalization;
namespace WaveDev.ModelR.Server
{
public class ModelRHub : Hub
{
#region Private Fields
private IList<SceneInfoModel> _s... | ```c#
using System.Threading.Tasks;
using Microsoft.AspNet.SignalR;
using System.Collections.Generic;
using System;
using System.Globalization;
using WaveDev.ModelR.Shared.Models;
namespace WaveDev.ModelR.Server
{
public class ModelRHub : Hub
{
#region Private Fields
private IList<SceneInfoMo... |
cdac47ca-d295-488a-b0eb-9a6f404cfaf1 | {
"language": "C#"
} | ```c#
using Alensia.Core.Locomotion;
using Alensia.Core.Sensor;
using UnityEngine;
using UnityEngine.Assertions;
using Zenject;
namespace Alensia.Core.Character
{
public class Humanoid : Character<IBinocularVision, ILeggedLocomotion>, IHumanoid
{
public override Transform Head { get; }
public... | ```c#
using Alensia.Core.Locomotion;
using Alensia.Core.Sensor;
using UnityEngine;
using UnityEngine.Assertions;
using Zenject;
namespace Alensia.Core.Character
{
public class Humanoid : Character<IBinocularVision, ILeggedLocomotion>, IHumanoid
{
public override Transform Head { get; }
public... |
53c10f4e-85fc-4eeb-a896-86a617a6a8f2 | {
"language": "C#"
} | ```c#
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.18033
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-ge... | ```c#
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.18033
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-ge... |
6c1c145b-d082-4b0e-bc2f-5d533a58317c | {
"language": "C#"
} | ```c#
using UniRx;
using UnityEngine;
using UnityEngine.UI;
public class TogglePlayPresenter : MonoBehaviour
{
[SerializeField]
Button togglePlayButton;
[SerializeField]
Sprite iconPlay;
[SerializeField]
Sprite iconPause;
NotesEditorModel model;
void Awake()
{
model = Not... | ```c#
using UniRx;
using UniRx.Triggers;
using UnityEngine;
using UnityEngine.UI;
public class TogglePlayPresenter : MonoBehaviour
{
[SerializeField]
Button togglePlayButton;
[SerializeField]
Sprite iconPlay;
[SerializeField]
Sprite iconPause;
NotesEditorModel model;
void Awake()
... |
89003a98-a2f9-49e7-b07d-0adce85b0149 | {
"language": "C#"
} | ```c#
namespace PusherClient
{
public enum ConnectionState
{
Initialized,
Connecting,
Connected,
Unavailable,
Disconnected,
WaitingToReconnect
}
}
```
Remove unused `Unavailable` connection state | ```c#
namespace PusherClient
{
public enum ConnectionState
{
Initialized,
Connecting,
Connected,
Disconnected,
WaitingToReconnect
}
}
``` |
997a0dec-5319-4044-bb4e-794651d0ca50 | {
"language": "C#"
} | ```c#
using System.Reflection;
using System.Resources;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Security;
using System.Security.Permissions;
using System.Web.UI;
using AjaxControlToolkit;
// Dependency Attribute for assemblies
[assembly: DependencyAttribute(... | ```c#
using System.Reflection;
using System.Resources;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Security;
using System.Security.Permissions;
using System.Web.UI;
using AjaxControlToolkit;
// Dependency Attribute for assemblies
[assembly: DependencyAttribute(... |
fa61e73d-2642-4ef4-8320-48b69900548d | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Linq;
using Microsoft.EntityFrameworkCore;
using osu.Framework.Platform;
using osu.Game.Database;
namespace osu.Game.Scoring
{
public class Score... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Linq;
using Microsoft.EntityFrameworkCore;
using osu.Framework.Platform;
using osu.Game.Database;
namespace osu.Game.Scoring
{
public class Score... |
d1969527-26f7-4f6f-ad67-3bf63d920087 | {
"language": "C#"
} | ```c#
using System;
using System.Threading;
using WebScriptHook.Framework;
using WebScriptHook.Framework.BuiltinPlugins;
using WebScriptHook.Terminal.Plugins;
namespace WebScriptHook.Terminal
{
class Program
{
static WebScriptHookComponent wshComponent;
static void Main(string[] args)
... | ```c#
using System;
using System.Threading;
using WebScriptHook.Framework;
using WebScriptHook.Framework.BuiltinPlugins;
using WebScriptHook.Terminal.Plugins;
namespace WebScriptHook.Terminal
{
class Program
{
static WebScriptHookComponent wshComponent;
static void Main(string[] args)
... |
762c4fcb-55a0-4db8-afdc-afe1d1b3a857 | {
"language": "C#"
} | ```c#
using Dapper;
using RapidCore.Migration;
using RapidCore.PostgreSql.Internal;
using System.Threading.Tasks;
namespace RapidCore.PostgreSql.Migration.Internal
{
public static class PostgreSqlSchemaCreator
{
public static async Task CreateSchemaIfNotExists(IMigrationContext context)
{
... | ```c#
using Dapper;
using RapidCore.Migration;
using RapidCore.PostgreSql.Internal;
using System.Threading.Tasks;
namespace RapidCore.PostgreSql.Migration.Internal
{
public static class PostgreSqlSchemaCreator
{
public static async Task CreateSchemaIfNotExists(IMigrationContext context)
{
... |
ea67d45e-39f8-49f9-960b-4bfb8bb2e310 | {
"language": "C#"
} | ```c#
using System.Windows;
using System.Windows.Controls;
namespace BindingTest.Control
{
public partial class CheckboxControl : UserControl
{
public bool Checked
{
get { return (bool)GetValue(CheckboxProperty); }
set
{
SetValue(... | ```c#
using System.Windows;
using System.Windows.Controls;
namespace BindingTest.Control
{
public partial class CheckboxControl : UserControl
{
public bool Checked
{
get { return (bool)GetValue(CheckboxProperty); }
set
{
SetValue(... |
d00ff63d-ab46-40ae-96d1-4c5b85bf0b95 | {
"language": "C#"
} | ```c#
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Text;
using System.Windows.Forms;
namespace TribalWars.Controls
{
/// <summary>
/// Adds addings time functionality to the TimeConverterControl
/// </summary>
public ... | ```c#
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Text;
using System.Windows.Forms;
namespace TribalWars.Controls
{
/// <summary>
/// Adds addings time functionality to the TimeConverterControl
/// </summary>
public ... |
bf6b4c97-8ff1-4910-98c5-a760ba3ea80f | {
"language": "C#"
} | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osuTK;
using osuTK.Graphics;
using osu.Framework.Graphics.Shapes;
namespace osu.Game.R... | ```c#
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osuTK;
using osuTK.Graphics;
using osu.Framework.Graphics.Shapes;
namespace osu.Game.R... |
2efec7c3-749a-43e2-a0f8-9752775df20e | {
"language": "C#"
} | ```c#
using System.IO;
using System.Linq;
using OmniSharp.Cake.Configuration;
namespace OmniSharp.Cake.Services
{
internal static class ScriptGenerationToolResolver
{
public static string GetExecutablePath(string rootPath, ICakeConfiguration configuration)
{
var toolPath = GetToolP... | ```c#
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Runtime.InteropServices;
using OmniSharp.Cake.Configuration;
namespace OmniSharp.Cake.Services
{
internal static class ScriptGenerationToolResolver
{
public static string GetExecutablePath(string roo... |
5d84d3ad-9a66-4dc3-8d00-d893a0a610f2 | {
"language": "C#"
} | ```c#
using System;
using PortableRazor;
namespace PortableCongress
{
public class PoliticianController
{
IHybridWebView webView;
IDataAccess dataAccess;
public PoliticianController (IHybridWebView webView, IDataAccess dataAccess)
{
this.webView = webView;
this.dataAccess = dataAccess;
}
publ... | ```c#
using System;
using PortableRazor;
namespace PortableCongress
{
public class PoliticianController
{
IHybridWebView webView;
IDataAccess dataAccess;
public PoliticianController (IHybridWebView webView, IDataAccess dataAccess)
{
this.webView = webView;
this.dataAccess = dataAccess;
}
publ... |
1568cc52-bae3-4c0c-b832-064da89f4c32 | {
"language": "C#"
} | ```c#
using System.Reflection;
#if XAMMAC2
[assembly: AssemblyTitle("Eto.Forms - Xamarin.Mac v2.0 Platform")]
[assembly: AssemblyDescription("OS X Platform for the Eto.Forms UI Framework using Xamarin.Mac v2.0")]
#elif XAMMAC
[assembly: AssemblyTitle("Eto.Forms - Xamarin.Mac Platform")]
[assembly: AssemblyDescription(... | ```c#
using System.Reflection;
#if XAMMAC2
[assembly: AssemblyTitle("Eto.Forms - Xamarin.Mac v2.0 Platform")]
[assembly: AssemblyDescription("OS X Platform for the Eto.Forms UI Framework using Xamarin.Mac v2.0")]
#elif XAMMAC
[assembly: AssemblyTitle("Eto.Forms - Xamarin.Mac Platform")]
[assembly: AssemblyDescription(... |
2dd0a96c-a87f-42ac-83bf-46f66dc7922b | {
"language": "C#"
} | ```c#
using System.Linq;
using System.Text.RegularExpressions;
namespace Inscribe.Text
{
public static class TweetTextCounter
{
public static int Count(string input)
{
// URL is MAX 20 Chars (if URL has HTTPS scheme, URL is MAX 21 Chars)
int prevIndex = 0;
i... | ```c#
using System.Linq;
using System.Text.RegularExpressions;
namespace Inscribe.Text
{
public static class TweetTextCounter
{
public static int Count(string input)
{
// Input maybe contains CRLF as a new line, but twitter converts CRLF to LF.
// It means CRLF should b... |
2861815e-e439-41e4-bb96-0d2610bcb483 | {
"language": "C#"
} | ```c#
using SFA.DAS.Authorization;
using System;
using System.Linq;
using System.Linq.Expressions;
using System.Web.Mvc;
namespace SFA.DAS.EmployerAccounts.Web.Extensions
{
public static class HtmlHelperExtensions
{
public static MvcHtmlString CommaSeperatedAddressToHtml(this HtmlHelper htmlHelper, st... | ```c#
using SFA.DAS.Authorization;
using System;
using System.Linq;
using System.Web.Mvc;
namespace SFA.DAS.EmployerAccounts.Web.Extensions
{
public static class HtmlHelperExtensions
{
public static MvcHtmlString CommaSeperatedAddressToHtml(this HtmlHelper htmlHelper, string commaSeperatedAddress)
... |
0a8a9fd2-17d0-42aa-9eb4-334a35c6096e | {
"language": "C#"
} | ```c#
/* Empiria Extensions Framework ******************************************************************************
* *
* Module : Empiria Web Api Component : Base controllers ... | ```c#
/* Empiria Extensions Framework ******************************************************************************
* *
* Module : Empiria Web Api Component : Base controllers ... |
7058b121-cf2e-411a-a711-573fee6c5cc6 | {
"language": "C#"
} | ```c#
using System.Drawing;
using MonoHaven.Graphics;
namespace MonoHaven.UI
{
public class Label : Widget
{
private string text;
private readonly TextBlock textBlock;
public Label(Widget parent)
: base(parent)
{
textBlock = new TextBlock(Fonts.Default);
}
public string Text
{
get { return ... | ```c#
using System.Drawing;
using MonoHaven.Graphics;
namespace MonoHaven.UI
{
public class Label : Widget
{
private string text;
private readonly TextBlock textBlock;
public Label(Widget parent, SpriteFont font) : base(parent)
{
textBlock = new TextBlock(font);
textBlock.TextColor = Color.White;
... |
9ab4566a-1e93-43dd-b885-cd2a375f9170 | {
"language": "C#"
} | ```c#
using System;
using Arkivverket.Arkade.Tests;
namespace Arkivverket.Arkade.Core.Addml.Processes
{
public class AnalyseFindMinMaxValues : IAddmlProcess
{
public const string Name = "Analyse_FindMinMaxValues";
private readonly TestRun _testRun;
private int? _minValue;
priva... | ```c#
using System;
using Arkivverket.Arkade.Tests;
namespace Arkivverket.Arkade.Core.Addml.Processes
{
public class AnalyseFindMinMaxValues : IAddmlProcess
{
public const string Name = "Analyse_FindMinMaxValues";
private readonly TestRun _testRun;
private int? _minValue;
priva... |
7eb3ddf7-c8bc-442f-a2fc-034d49d5dbcb | {
"language": "C#"
} | ```c#
@model Orc.CheckForUpdate.Web.Models.VersionsViewModel
@{
ViewBag.Title = "Index";
}
@section additionalstyles
{
@Styles.Render("~/Content/css/downloads")
}
<h2>Releases</h2>
<div>
@{
Html.RenderPartial("ReleasesList", Model);
}
</div>
```
Fix styling for users download page | ```c#
@model Orc.CheckForUpdate.Web.Models.VersionsViewModel
@{
ViewBag.Title = "Index";
}
@section additionalstyles
{
@Styles.Render("~/Content/css/releases")
}
<h2>Releases</h2>
<div>
@{
Html.RenderPartial("ReleasesList", Model);
}
</div>
``` |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.