commit stringlengths 40 40 | subject stringlengths 4 1.73k | repos stringlengths 5 127k | old_file stringlengths 2 751 | new_file stringlengths 2 751 | new_contents stringlengths 1 8.98k | old_contents stringlengths 0 6.59k | license stringclasses 13
values | lang stringclasses 23
values |
|---|---|---|---|---|---|---|---|---|
68bfed9f3ae3a72990f21d047100731cadd4b10e | Update test app. | SonyaSa/CppSharp,ddobrev/CppSharp,txdv/CppSharp,nalkaro/CppSharp,zillemarco/CppSharp,zillemarco/CppSharp,ktopouzi/CppSharp,KonajuGames/CppSharp,mydogisbox/CppSharp,imazen/CppSharp,Samana/CppSharp,ddobrev/CppSharp,zillemarco/CppSharp,xistoso/CppSharp,ddobrev/CppSharp,inordertotest/CppSharp,txdv/CppSharp,u255436/CppSharp... | examples/Hello/Hello.cs | examples/Hello/Hello.cs | using System;
using CppCsBind;
public class HelloExample
{
public static void Main (String[] args) {
var h = new Hello();
h.PrintHello ("Hello world");
Console.WriteLine("True =" + h.test1(3, 3.0f).ToString());
Console.WriteLine("False =" + h.test1(2, 3.0f).ToString());
}
}
| using System;
using CppCsBind;
public class HelloExample
{
public static void Main (String[] args) {
var h = new Hello();
h.PrintHello ("Hello world");
}
}
| mit | C# |
ea31fc988ce7f87220c8619db8cde198b184d0bd | Add the Jefferson.Core/Directives/BlockDirective.cs#blockJefferson.Core/Directives/BlockDirective.cs directive which does nothing but create a block or in otherwords create a new scope. | mjvh80/jefferson | Jefferson.Core/Directives/BlockDirective.cs | Jefferson.Core/Directives/BlockDirective.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;
namespace Jefferson.Directives
{
/// <summary>
/// Does nothing but copy the current context as a new scope.
/// This is not as useless as it seems, e.g. consider... | apache-2.0 | C# | |
a752f6aabdf7e37829c849dadd31abf617e21694 | Create polygon out of selectet lines and arcs | sts-CAD-Software/PCB-Investigator-Scripts | Create_Polygon_of_Selection.cs | Create_Polygon_of_Selection.cs | //-----------------------------------------------------------------------------------
// PCB-Investigator Automation Script
// Created on 2014-04-24
// Autor support@easylogix.de
// www.pcb-investigator.com
// SDK online reference http://www.pcb-investigator.com/sites/default/files/documents/InterfaceDocumentation... | bsd-3-clause | C# | |
fa0afb2f1d5874914498fbe32d39ecfccdae683d | Create DrawRendererBounds.cs | UnityCommunity/UnityLibrary | Scripts/Helpers/DrawRendererBounds.cs | Scripts/Helpers/DrawRendererBounds.cs | using UnityEngine;
// draws mesh renderer bounding box using Debug.Drawline
public class DrawRendererBounds : MonoBehaviour
{
MeshRenderer meshRenderer;
void Awake()
{
meshRenderer = GetComponent<MeshRenderer>();
}
void Update()
{
var b = meshRenderer.bounds;
// bot... | mit | C# | |
87bedf2b098410e4863c5c77c7c2415b48ca2a11 | update AssemblyInformationalVersion => 1.0.0.0-alpha | larsw/azure-activedirectory-identitymodel-extensions-for-dotnet,AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet,tushargupta51/azure-activedirectory-identitymodel-extensions-for-dotnet,AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet,wvdd007/azure-activedirectory-identitymodel-extensio... | Microsoft.IdentityModel.Extensions/src/Properties/AssemblyInfo.cs | Microsoft.IdentityModel.Extensions/src/Properties/AssemblyInfo.cs | using System;
using System.Reflection;
using System.Resources;
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 ... | using System;
using System.Reflection;
using System.Resources;
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 ... | apache-2.0 | C# |
f1980f4f321f6fa501bc12d134bd48645bbf9bbc | Add new abstract class: Item | sheadovas/proj_platf_rpg | proj_platf_rpg/Assets/Scripts/Item.cs | proj_platf_rpg/Assets/Scripts/Item.cs | abstract public class Item
{
const int MAX_STACK_SIZE = 16;
public enum ItemProperty
{
NONE = 0,
EATABLE = (1 << 1),
EQUIPABLE = (1 << 2),
STACKABLE = (1 << 3),
ARMOUR = (1 << 4),
WEAPON = (1 << 5),
DISABLED = (1 << 6) // "broken"
};
public enum ItemQuality
... | bsd-3-clause | C# | |
ebc97c0f94d343e2c45af86d168e60a1ae1c597b | Update to Performance tests | JonPSmith/GenericServices | Tests/UnitTests/Group80Performance/Test05PostPerformance.cs | Tests/UnitTests/Group80Performance/Test05PostPerformance.cs | using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;
using NUnit.Framework;
using Tests.DataClasses;
using Tests.DataClasses.Concrete;
using Tests.DTOs.Concrete;
using Tests.Helpers;
namespace Tests... | mit | C# | |
61294fcaff1e2139822b5e48432cd2d117c07fdd | Add unit tests | wieslawsoltes/Perspex,AvaloniaUI/Avalonia,jkoritzinsky/Avalonia,jkoritzinsky/Avalonia,SuperJMN/Avalonia,AvaloniaUI/Avalonia,SuperJMN/Avalonia,SuperJMN/Avalonia,wieslawsoltes/Perspex,SuperJMN/Avalonia,jkoritzinsky/Avalonia,jkoritzinsky/Avalonia,AvaloniaUI/Avalonia,SuperJMN/Avalonia,grokys/Perspex,Perspex/Perspex,SuperJM... | tests/Avalonia.Controls.UnitTests/SplitViewTests.cs | tests/Avalonia.Controls.UnitTests/SplitViewTests.cs | using System;
using System.Collections.Generic;
using System.Text;
using Xunit;
namespace Avalonia.Controls.UnitTests
{
public class SplitViewTests
{
[Fact]
public void SplitView_PaneOpening_Should_Fire_Before_PaneOpened()
{
var splitView = new SplitView();
... | mit | C# | |
461d133c1f0a9a736bfa265e5c7dd060d6dd68b8 | Add test coverage of score importing | peppy/osu,ppy/osu,peppy/osu,ppy/osu,peppy/osu,ppy/osu | osu.Game.Tests/Visual/Gameplay/TestScenePlayerLocalScoreImport.cs | osu.Game.Tests/Visual/Gameplay/TestScenePlayerLocalScoreImport.cs | // 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.Screens;
using osu.Framework.Testing;
using osu.Game.Rulesets;
using osu.Game.Rulesets.Objects;
using osu.Ga... | mit | C# | |
0b09cd2918dee74d6cdeb6a42e8e6c4b04fdbe21 | Implement the DenyAllValidatorBuilder class | openchain/openchain | src/Openchain.Ledger/Validation/DenyAllValidatorBuilder.cs | src/Openchain.Ledger/Validation/DenyAllValidatorBuilder.cs | // Copyright 2015 Coinprism, Inc.
//
// 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 applicable law or agree... | apache-2.0 | C# | |
826d064582d39e1d7dd9e0d4272332d06628420f | Create JeffHicks.cs | planetpowershell/planetpowershell,planetpowershell/planetpowershell,planetpowershell/planetpowershell,planetpowershell/planetpowershell | src/Firehose.Web/Authors/JeffHicks.cs | src/Firehose.Web/Authors/JeffHicks.cs | 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 JeffHicks : IFilterMyBlogPosts, IAmAMicrosoftMVP
{
public string FirstName => "Jeff";
pub... | mit | C# | |
9c9c566bb559287c1d5ec641949ef3241c7394b2 | Create User Module Ninject Commit | hnidboubker/NeedDotNet,hnidboubker/NeedDotNet | Src/Web/www/NeedDotNet.Web/NinjectResolution/UserIdentityModule.cs | Src/Web/www/NeedDotNet.Web/NinjectResolution/UserIdentityModule.cs | using Microsoft.AspNet.Identity;
using Microsoft.AspNet.Identity.EntityFramework;
using NeedDotNet.Server.Domain.Entities;
using NeedDotNet.Web.Infrastructure;
using NeedDotNet.Web.Services;
using Ninject.Modules;
using Ninject.Web.Common;
namespace NeedDotNet.Web.NinjectResolution
{
internal class UserIdentityMod... | apache-2.0 | C# | |
36512d45f9c84492af8e60d5c493d6de1d76b188 | Create Carrefour.cs | HartmanDev/WimP | Carrefour.cs | Carrefour.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PathFinder
{
class Carrefour
{
#region Attributs
private TimeSpan timePath;
private DateTime dateCurrentTime;
private int iCrossX;
priv... | mit | C# | |
53cff7f1941b120a2e636ba97d21df0be9a26ea7 | add snippets for the 'Interval' type | malcolmr/nodatime,malcolmr/nodatime,BenJenkinson/nodatime,malcolmr/nodatime,nodatime/nodatime,nodatime/nodatime,malcolmr/nodatime,BenJenkinson/nodatime | src/NodaTime.Demo/IntervalDemo.cs | src/NodaTime.Demo/IntervalDemo.cs | // Copyright 2019 The Noda Time Authors. All rights reserved.
// Use of this source code is governed by the Apache License 2.0,
// as found in the LICENSE.txt file.
using NUnit.Framework;
namespace NodaTime.Demo
{
public class IntervalDemo
{
[Test]
public void Construction_WithNonNullablePara... | apache-2.0 | C# | |
34f6e16c9151f7818c9fdbd062831350f8108b9b | Create Synapse.cs | Quadrat1c/OpJinx | Epoch/Network/Synapse.cs | Epoch/Network/Synapse.cs | namespace Epoch.Network
{
public class Synapse
{
#region -- Properties --
public Neuron InputNeuron { get; set; }
public Neuron OutputNeuron { get; set; }
public double Weight { get; set; }
public double WeightDelta { get; set; }
#endregion
#region -- Con... | mit | C# | |
b23a5c7fdec6c716ee5ba722c837012be9034659 | Check emptyness of an XDocument | mattia72/GranitEditor,mattia72/GranitEditor | GranitXMLEditor/XDocumentExtension.cs | GranitXMLEditor/XDocumentExtension.cs | using System;
using System.Collections.Generic;
using System.Data;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Xml.Linq;
namespace GranitXMLEditor
{
public static class XDocumentExtension
{
public static bool IsEmpty(this XDocument element)
{
ret... | mit | C# | |
e2d70821a84c8d8f87e3cb381a69a57e888b1834 | Create Program.cs | dlidstrom/EventStoreLite | Program.cs | Program.cs | using System;
using System.Linq;
using Raven.Client.Document;
namespace RavenEventStore
{
public static class Program
{
public static void Main()
{
try
{
Run();
}
catch (Exception e)
{
Console.WriteLine(... | mit | C# | |
199a004792fb98c7442b378b3ca151b8e771d308 | Create ClassRenderer.cs | nir546/layout2class4Android | ClassRenderer.cs | ClassRenderer.cs | using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Layout2Class
{
public static class ClassRenderer
{
public static void CreateLayoutClasses(string package, DirectoryInfo layoutsfolder, DirectoryInfo outputFolde... | mit | C# | |
93c4ca8fb65a951c54f687d8fdacd143f61e1f87 | Create Users.cs | SongSync/windows | Classes/Users.cs | Classes/Users.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace SongSync
{
class Songs
{
public string name { get; set; }
public int playlist_ID { get; set; }
public DateTime created_at { get; set; }
public DateTime u... | apache-2.0 | C# | |
a029847d5263ef4df011e629c499f8bfb69ce541 | Create ProxyConnectorBase.cs | esskar/SignalR.Client.WebSocket4Net | src/SignalR.Client.WebSocket4Net.Core/ProxyConnectorBase.cs | src/SignalR.Client.WebSocket4Net.Core/ProxyConnectorBase.cs | using System;
using System.Text;
using System.Net;
using System.Net.Sockets;
using SuperSocket.ClientEngine;
namespace SuperSocket.ClientEngine.Proxy
{
public abstract class ProxyConnectorBase : IProxyConnector
{
public EndPoint ProxyEndPoint { get; private set; }
protected static Encoding ASC... | apache-2.0 | C# | |
c0afe2371ff0eae00ef015eb83849659c3e0332a | Allow scenario class to take properties | DavidAnson/nuproj,NN---/nuproj,ericstj/nuproj,PedroLamas/nuproj,zbrad/nuproj,DavidAnson/nuproj,kovalikp/nuproj,AArnott/nuproj,nuproj/nuproj,oliver-feng/nuproj,faustoscardovi/nuproj | src/NuProj.Tests/Infrastructure/Scenario.cs | src/NuProj.Tests/Infrastructure/Scenario.cs | using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
using NuGet;
namespace NuProj.Tests.Infrastructure
{
public static class Scenario
{
public static async Task<IPackage> RestoreAndBuildSinglePackage(string scenarioName, IDictionary<string... | using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
using NuGet;
namespace NuProj.Tests.Infrastructure
{
public static class Scenario
{
public static async Task<IPackage> RestoreAndBuildSinglePackage(string scenarioName)
{
... | mit | C# |
7775c8f36a27ab6c54b1506f05560739a48d243a | add perf bench | m5knt/BrownSugar | Test/Bench.cs | Test/Bench.cs | using System.Linq;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;
using System.Net;
using System.Runtime.InteropServices;
using ThunderEgg.BrownSugar;
namespace Test {
public static class Bench {
public static long Run(int limit, Action<long> action) {
var now = DateTime.No... | mit | C# | |
92c85bcbe21d2a5cce7840a791c8f1bda5f7b8c8 | Create settings.cs | IsaiahPatton/ned,IsaiahPatton/ned | stylesheets/settings.cs | stylesheets/settings.cs | nedface, nedsettings {
color: blue;
text-decoration: underline;
cursor: pointer;
}
nedsettings#inside {
color: black;
text-decoration: none;
cursor: none;
}
nedsettings#insideText {
display: none; <!--So it does not display when disabled-->
border-style: solid;
border-color: lightgra... | mit | C# | |
50f640ef18d70839af10846378616ce6f36d8712 | Test UnblidedSignatureJsonConverter | nopara73/HiddenWallet,nopara73/HiddenWallet,nopara73/HiddenWallet,nopara73/HiddenWallet | WalletWasabi.Tests/UnitTests/JsonConvertersTest/UnblindedSignatureTests.cs | WalletWasabi.Tests/UnitTests/JsonConvertersTest/UnblindedSignatureTests.cs | using NBitcoin;
using Newtonsoft.Json;
using System;
using System.IO;
using System.Linq;
using System.Text;
using WalletWasabi.Crypto;
using WalletWasabi.JsonConverters;
using Xunit;
namespace WalletWasabi.Tests.UnitTests.JsonConverters
{
public class UnblindedSignatureTests
{
private static Random Random = new Ra... | mit | C# | |
abde750e1d6a9c7660673bfea36b8e0582c4908e | Add test | plainerman/TicTacTube | TicTacTubeCoreTest/Processors/Filesystem/TestSourceCloner.cs | TicTacTubeCoreTest/Processors/Filesystem/TestSourceCloner.cs | using Microsoft.VisualStudio.TestTools.UnitTesting;
using System.IO;
using TicTacTubeCore.Processors.Filesystem;
using TicTacTubeCore.Sources.Files;
using TicTacTubeCoreTest.Sources.Files;
namespace TicTacTubeCoreTest.Processors.Filesystem
{
[TestClass]
public class TestSourceCloner
{
[TestMethod]
public void ... | mit | C# | |
35772c623ea622a428b97aba29115626faf7023c | Add a DataTypeValueConverter | MahApps/MahApps.Metro.IconPacks | src/MahApps.Metro.IconPacks.Core/Converter/DataTypeValueConverter.cs | src/MahApps.Metro.IconPacks.Core/Converter/DataTypeValueConverter.cs | using System;
#if (NETFX_CORE || WINDOWS_UWP)
using Windows.UI.Xaml;
using Windows.UI.Xaml.Data;
#else
using System.Globalization;
using System.Windows;
#endif
namespace MahApps.Metro.IconPacks.Converter
{
#if (NETFX_CORE || WINDOWS_UWP)
public class DataTypeValueConverter : MarkupConverter
{
private ... | mit | C# | |
397abb0946e0e81280d993929680a606bcd6ad54 | Add test code that uses login info to access CDS docs | gordonwatts/CERNSSO | CERNSSOWindowsDesktopTest/CERNSSOUserPass.cs | CERNSSOWindowsDesktopTest/CERNSSOUserPass.cs | using CERNSSO;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;
using System.IO;
using System.Threading.Tasks;
namespace CERNSSOWindowsDesktopTest
{
/// <summary>
/// Test access when we set a username and password.
/// </summary>
[TestClass]
public class CERNSSOUserPass
{
... | mit | C# | |
2d3ac3def9672ea1550e193af34308ab8b189bae | Add bitcoind checksums verification | nopara73/HiddenWallet,nopara73/HiddenWallet,nopara73/HiddenWallet,nopara73/HiddenWallet | WalletWasabi.Tests/UnitTests/BitcoinCore/BitcoindBinaryHashesTests.cs | WalletWasabi.Tests/UnitTests/BitcoinCore/BitcoindBinaryHashesTests.cs | using System;
using System.Collections.Generic;
using System.IO;
using System.Runtime.InteropServices;
using System.Security.Cryptography;
using System.Threading;
using WalletWasabi.Microservices;
using Xunit;
namespace WalletWasabi.Tests.UnitTests.BitcoinCore
{
public class BitcoindBinaryHashesTests
{
[Fact]
pu... | mit | C# | |
4b5ce0cf406b1c91ef7a7bfa0e04567a47173a8c | add failing unit test. | AvaloniaUI/Avalonia,SuperJMN/Avalonia,jkoritzinsky/Avalonia,jkoritzinsky/Avalonia,AvaloniaUI/Avalonia,wieslawsoltes/Perspex,grokys/Perspex,AvaloniaUI/Avalonia,jkoritzinsky/Avalonia,SuperJMN/Avalonia,jkoritzinsky/Avalonia,wieslawsoltes/Perspex,SuperJMN/Avalonia,AvaloniaUI/Avalonia,jkoritzinsky/Avalonia,jkoritzinsky/Pers... | tests/Avalonia.Controls.UnitTests/Presenters/TextPresenter_Tests.cs | tests/Avalonia.Controls.UnitTests/Presenters/TextPresenter_Tests.cs | using Avalonia.Controls.Presenters;
using Xunit;
namespace Avalonia.Controls.UnitTests.Presenters
{
public class TextPresenter_Tests
{
[Fact]
public void TextPresenter_can_contain_null_with_password_char_set()
{
var target = new TextPresenter
{
P... | mit | C# | |
7980d16b4c202bcb063c0569112ad76463e8a9c6 | Add failing test showing the issue of DHO lifetime | UselessToucan/osu,smoogipooo/osu,peppy/osu,UselessToucan/osu,smoogipoo/osu,UselessToucan/osu,smoogipoo/osu,NeoAdonis/osu,ppy/osu,peppy/osu-new,peppy/osu,NeoAdonis/osu,peppy/osu,smoogipoo/osu,ppy/osu,ppy/osu,NeoAdonis/osu | osu.Game.Tests/Gameplay/TestSceneDrawableHitObject.cs | osu.Game.Tests/Gameplay/TestSceneDrawableHitObject.cs | // 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.Testing;
using osu.Game.Rulesets.Objects;
using osu.Game.Rulesets.Objects.Drawables;
using osu.Game.Tests.Visual;
namespace os... | mit | C# | |
f569f75e2146f2b345850acb11e5be8f0797c4a8 | Add missing file | michael-reichenauer/GitMind | GitMind/Utils/Git/Private/GitCommit.cs | GitMind/Utils/Git/Private/GitCommit.cs | namespace GitMind.Utils.Git
{
internal class GitCommit : IGitCommit
{
}
} | mit | C# | |
c9720faec913cf0a55f29bbc94e933d32c7ce5a5 | Revert "Remove obsolete workaround" | JetBrains/resharper-unity,JetBrains/resharper-unity,JetBrains/resharper-unity | resharper/src/resharper-unity/Rider/TempAnnotationsLoader.cs | resharper/src/resharper-unity/Rider/TempAnnotationsLoader.cs | using System;
using System.Collections.Generic;
using JetBrains.Application;
using JetBrains.Metadata.Utils;
using JetBrains.ReSharper.Psi.ExtensionsAPI.ExternalAnnotations;
using JetBrains.Util;
namespace JetBrains.ReSharper.Plugins.Unity.Rider
{
// Temporary workaround for RIDER-13547
[ShellComponent]
p... | apache-2.0 | C# | |
10aaeca17213a56b7afa0e8e70ee48108010a3d9 | create custom attribute for checking if locked | Iwuh/Wycademy | WycademyV2/src/WycademyV2/Commands/Preconditions/RequireUnlockedAttribute.cs | WycademyV2/src/WycademyV2/Commands/Preconditions/RequireUnlockedAttribute.cs | using Discord.Commands;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using WycademyV2.Commands.Services;
namespace WycademyV2.Commands.Preconditions
{
public class RequireUnlockedAttribute : PreconditionAttribute
{
public override Task<PreconditionRe... | mit | C# | |
e43360782dca2b2020e3815aaddb4a3abffaf523 | add an implementation of IImage for Bitmap image | myxini/block-program | block-program/Detection/Image/BitmapImage.cs | block-program/Detection/Image/BitmapImage.cs | using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Myxini.Recognition.Image
{
class BitmapImage : IImage
{
private Bitmap bitmap;
public BitmapImage(Bitmap bitmap)
{
this.bitma... | mit | C# | |
cde28fccb8f9b4815031cc3aad7831328ebdbd9c | test the Catalog API | mightea/vernacular,mightea/vernacular,gabornemeth/vernacular,gabornemeth/vernacular,dsuess/vernacular,dsuess/vernacular,benoitjadinon/vernacular,StephaneDelcroix/vernacular,rdio/vernacular,benoitjadinon/vernacular,StephaneDelcroix/vernacular,rdio/vernacular | Vernacular.Test/CatalogTests.cs | Vernacular.Test/CatalogTests.cs | //
// CatalogTests.cs
//
// Author:
// Aaron Bockover <abock@rd.io>
//
// Copyright 2012 Rdio, Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including with... | mit | C# | |
0bb5c0d4973c0e7c8060e560082ffe710f9539e1 | Add files via upload | pw1316/LuaC,pw1316/LuaC,pw1316/LuaC,pw1316/LuaC | code/LuaScripts/DelayDrawing.cs | code/LuaScripts/DelayDrawing.cs | using System;
using System.Collections.Generic;
using UnityEditor;
using UnityEngine;
namespace Pangu.Tools
{
public class Drawing
{
private const int DEFAULT_WINDOW_WIDTH = 1500;
public Rect rect;
public Action Draw;
Drawing() { }
public static Drawing Crea... | mit | C# | |
f3f0286e807f6c0308637049b223d15a8df23f45 | Create AsyncHelpers.cs | cpoDesign/web.tools | AsyncHelpers.cs | AsyncHelpers.cs | public static class AsyncHelpers
{
/// <summary>
/// Execute's an async Task of T method which has a void return value synchronously
/// </summary>
/// <param name="task">Task of T method to execute</param>
public static void RunSync(Func<Task> task)
{
var... | mit | C# | |
7063e7b6324be7b1a7a7746f3697653722521495 | Add MagicStrings. | LightPaper/Infrastructure | MagicStrings.cs | MagicStrings.cs | namespace LightPaper.Infrastructure
{
public class MagicStrings
{
#region Nested type: LoggerTags
public static class LoggerTags
{
public static readonly string LP_VIEW_MODEL = "LightPaper ViewModel";
public static readonly string LP_UI = "LightPaper UI... | mit | C# | |
071ef0d8a643e427da954050a8878faec17a8996 | Create PauseMenu.cs | jon-lad/Battlefleet-Gothic | PauseMenu.cs | PauseMenu.cs | using UnityEngine;
using System.Collections;
public class PauseMenu : MonoBehaviour {
public bool paused = false;
void Start (){
Time.timeScale = 1;
}
void Update (){
if (Input.GetKeyUp (KeyCode.Escape)) {
paused = togglePause ();
}
}
bool togglePause(){
if(paused == true){
Ti... | mit | C# | |
70fbc5144f157fe2877857b8c3c27f37fdb99c30 | Add `ISCardReaderState` interface | Archie-Yang/PcscDotNet | src/PcscDotNet/ISCardReaderState.cs | src/PcscDotNet/ISCardReaderState.cs | namespace PcscDotNet
{
/// <summary>
/// This interface is used by functions for tracking smart cards within readers.
/// </summary>
public interface ISCardReaderState
{
/// <summary>
/// ATR of the inserted card.
/// </summary>
byte[] Atr { get; }
/// <summa... | mit | C# | |
e793de9e25be52442ecff9d67740d4806cbe5fa2 | Create SomeEntities.cs | thomas3d/BulkInsert | SomeEntities.cs | SomeEntities.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Data.SqlClient;
using System.ComponentModel.DataAnnotations.Schema;
using System.Data;
using System.Reflection;
using System.Data.Entity;
using System.Data.Entity.Infrastructure;
namespace B... | mit | C# | |
3b9c0439a214b59d59d1efa501d83892380276a4 | Create demo snippets for the Duration type (#1009) | malcolmr/nodatime,jskeet/nodatime,nodatime/nodatime,nodatime/nodatime,malcolmr/nodatime,BenJenkinson/nodatime,BenJenkinson/nodatime,jskeet/nodatime,malcolmr/nodatime,malcolmr/nodatime | src/NodaTime.Demo/DurationDemo.cs | src/NodaTime.Demo/DurationDemo.cs | // Copyright 2017 The Noda Time Authors. All rights reserved.
// Use of this source code is governed by the Apache License 2.0,
// as found in the LICENSE.txt file.
using NUnit.Framework;
using System;
namespace NodaTime.Demo
{
public class DurationDemo
{
[Test]
public void ConstructionFromDa... | apache-2.0 | C# | |
2e2519ee69ca250c873db68a3d8390768f81fdaa | add the OperatorExpression | toontown-archive/Krypton.LibProtocol | Krypton.LibProtocol/Src/Member/Expression/OperatorExpression.cs | Krypton.LibProtocol/Src/Member/Expression/OperatorExpression.cs | using System;
using Krypton.LibProtocol.Target;
namespace Krypton.LibProtocol.Member.Expression
{
public class OperatorExpression : IExpression, ITemplateType
{
/// <summary>
/// Operators, in their numerical form, that can be used within a group of <c>IExpression</c>s.
/// </summary>
... | mit | C# | |
85fa065a760958338439473783dbe23f843292e5 | Create Day_1.cs | leocabrallce/HackerRank,leocabrallce/HackerRank | Day_1.cs | Day_1.cs |
// Declare second integer, double, and String variables.
int j = i;
double e = d;
string t = s;
// Read and save an integer, double, and String to your variables.
int k = Int32.Parse(Console.ReadLine());
double f = Double.Parse(Console.ReadLine());
stri... | mit | C# | |
f1ccfd7e61a4eb9e834d607ce393a9ba1749b72f | Create x.cs | highnet/Java-101,highnet/Java-101 | TowerTW/x.cs | TowerTW/x.cs | mit | C# | ||
061e436e3f67db75d58ec44c83cafff00a998d40 | Add files via upload | gideonlouw/EasyClass | WebReader.cs | WebReader.cs | using Newtonsoft.Json.Linq;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Net;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading.Tasks;
namespace EasyClass
{
public class WebReader
{
public bool AddHeader { ... | mit | C# | |
3f26455f64822e750c68abb9817ec547cfa36f69 | Add SampleChannelVirtual | EVAST9919/osu-framework,peppy/osu-framework,smoogipooo/osu-framework,ppy/osu-framework,EVAST9919/osu-framework,ZLima12/osu-framework,peppy/osu-framework,EVAST9919/osu-framework,smoogipooo/osu-framework,ZLima12/osu-framework,peppy/osu-framework,EVAST9919/osu-framework,ppy/osu-framework,ppy/osu-framework | osu.Framework/Audio/Sample/SampleChannelVirtual.cs | osu.Framework/Audio/Sample/SampleChannelVirtual.cs | // 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.
namespace osu.Framework.Audio.Sample
{
/// <summary>
/// A <see cref="SampleChannel"/> which explicitly plays no audio.
/// Aimed for scenarios in which a non... | mit | C# | |
12b073f519f6c4353b851dc96eab8e538989a8ad | Test FunctionHandlerTypeResolver | manisero/DSLExecutor | dev/Manisero.DSLExecutor.Tests/Runtime/FunctionExecution/FunctionHandlerResolution/FunctionHandlerTypeResolvers/DictionarySourcedFunctionHandlerTypeResolverTests.cs | dev/Manisero.DSLExecutor.Tests/Runtime/FunctionExecution/FunctionHandlerResolution/FunctionHandlerTypeResolvers/DictionarySourcedFunctionHandlerTypeResolverTests.cs | using System;
using System.Collections.Generic;
using FluentAssertions;
using Manisero.DSLExecutor.Runtime.FunctionExecution.FunctionHandlerResolution.FunctionHandlerTypeResolvers;
using Manisero.DSLExecutor.Tests.TestsDomain;
using Xunit;
namespace Manisero.DSLExecutor.Tests.Runtime.FunctionExecution.Function... | mit | C# | |
cc0c2ff80a79d3fe72f9ee4333074442d1e5c1fe | Create 20180327.cs | twilightspike/cuddly-disco,twilightspike/cuddly-disco | main/20180327.cs | main/20180327.cs | using UnityEngine;
using UnityEngine.UI;
using System.Collections;
using System.Collections.Generic;
using System;
public class LuckyWheelManager: MonoBehaviour{}
| mit | C# | |
09c98476decf0d5779c14b0beef0e7b2aa6170f9 | Update AzureBackupContainer.cs | CamSoper/azure-powershell,seanbamsft/azure-powershell,stankovski/azure-powershell,zaevans/azure-powershell,DeepakRajendranMsft/azure-powershell,mayurid/azure-powershell,krkhan/azure-powershell,pomortaz/azure-powershell,AzureAutomationTeam/azure-powershell,mayurid/azure-powershell,pomortaz/azure-powershell,yantang-msft/... | src/ResourceManager/AzureBackup/Commands.AzureBackup/Models/AzureBackupContainer.cs | src/ResourceManager/AzureBackup/Commands.AzureBackup/Models/AzureBackupContainer.cs | // ----------------------------------------------------------------------------------
//
// Copyright Microsoft Corporation
// 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.apac... | // ----------------------------------------------------------------------------------
//
// Copyright Microsoft Corporation
// 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.apa... | apache-2.0 | C# |
17f6541113a60dbf7eade2e397358765d92d4f4b | Add registrations helper | StevenLiekens/Txt,StevenLiekens/TextFx | src/Txt.ABNF/Registrations.cs | src/Txt.ABNF/Registrations.cs | using System;
using System.Linq;
using System.Reflection;
namespace Txt.ABNF
{
public static class Registrations
{
public delegate void RegisterCallback(Type service, Type implementation, string lifestyle);
public static void GetRegistrations(RegisterCallback callback)
{
i... | mit | C# | |
97929a9e5abb03bc861d62ea2c58f8bb7c96d636 | Create 20170727.cs | twilightspike/cuddly-disco,twilightspike/cuddly-disco | main/20170727.cs | main/20170727.cs | using System;
using System.Drawing;
using System.Windows.Form;
namespace MouseEvent{
public event MouseHandler MouseMove;
}
| mit | C# | |
f74d0fb79b5f9249e09576aec878a10761503442 | Throw exception if command handlers not found | chenkaibin/SharpArchitecture-MultiTenant,yellowfeather/SharpArchitecture-MultiTenant,chenkaibin/SharpArchitecture-MultiTenant,yellowfeather/SharpArchitecture-MultiTenant | app/SharpArchitecture-MultiTenant.Framework/Commands/CommandHandlerNotFoundException.cs | app/SharpArchitecture-MultiTenant.Framework/Commands/CommandHandlerNotFoundException.cs | using System;
namespace SharpArchitecture.MultiTenant.Framework.Commands
{
public class CommandHandlerNotFoundException : Exception
{
public CommandHandlerNotFoundException () {}
}
} | bsd-3-clause | C# | |
e3db686933927ef22157ac13107208d2fb80fd2f | Add Q242 | txchen/localleet | csharp/Q242_ValidAnagram.cs | csharp/Q242_ValidAnagram.cs | using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Xunit;
// Given two strings s and t, write a function to determine if t is an anagram of s.
//
// For example,
// s = "anagram", t = "nagaram", return true.
// s = "rat", t = "car", return false.
//
//... | mit | C# | |
b063203111c3f70e17f60c4201fa55960532c346 | Create HomeController.cs | fatmagazaile/Projet | HomeController.cs | HomeController.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
namespace MvcMeublatexApp.Controllers
{
[HandleError]
public class HomeController : Controller
{
public ActionResult Index()
{
ViewData["Message"] = "Welcome to ASP.NET MVC... | apache-2.0 | C# | |
ee94693a263a22fd724f4e00ac15d0a27191c0cc | Create BuildError.cs | sobercoder/msbuild-api-hacks | BuildError.cs | BuildError.cs | using System;
public class BuildError
{
public string File { get; set; }
public DateTime Timestamp { get; set; }
public int LineNumber { get; set; }
public int ColumnNumber { get; set; }
public string Code { get; set; }
public string Message { get; set; }
public override string ToString()
{
return string.Fo... | unlicense | C# | |
c083af062d77ec6a30814aed1f27c49d6d7e3f91 | add Avalonia.Layout to https://github.com/avaloniaui | AvaloniaUI/Avalonia,wieslawsoltes/Perspex,grokys/Perspex,wieslawsoltes/Perspex,wieslawsoltes/Perspex,wieslawsoltes/Perspex,SuperJMN/Avalonia,SuperJMN/Avalonia,SuperJMN/Avalonia,wieslawsoltes/Perspex,AvaloniaUI/Avalonia,AvaloniaUI/Avalonia,jkoritzinsky/Avalonia,wieslawsoltes/Perspex,jkoritzinsky/Avalonia,AvaloniaUI/Aval... | src/Avalonia.Layout/Properties/AssemblyInfo.cs | src/Avalonia.Layout/Properties/AssemblyInfo.cs | // Copyright (c) The Avalonia Project. All rights reserved.
// Licensed under the MIT license. See licence.md file in the project root for full license information.
using Avalonia.Metadata;
[assembly: XmlnsDefinition("https://github.com/avaloniaui", "Avalonia.Layout")]
| mit | C# | |
7e954ab0fc7c165bb0ea2a766b012424133ab47b | Add F.Curry for functions of arity up to 10 | farity/farity | Farity/Curry.cs | Farity/Curry.cs | using System;
namespace Farity
{
public static partial class F
{
public static Func<TArg1, Func<TArg2, TResult>> Curry<TArg1, TArg2, TResult>(
Func<TArg1, TArg2, TResult> function)
{
return a => b => function(a, b);
}
public static Func<TArg1, Func<TArg... | mit | C# | |
5cf10d1f0dcf525fd74ed0a26901b67ec1b52149 | Create C#.cs | TobitSoftware/chayns-snippets,TobitSoftware/chayns-snippets,TobitSoftware/chayns-snippets,TobitSoftware/chayns-snippets | Backend/GetUserByQRCode/C#.cs | Backend/GetUserByQRCode/C#.cs | import RestSharp;
public string Server = "https://api.chayns.net/v2.0";
private const string Secret = "Your Tapp Secret";
[HttpPost]
[Route("GetUserFromQR")]
public IHttpActionResult GetUserFromQR(int locationId, int tappId, string qrData)
{
try
{
//Get the userdata
dynamic user = GetUserByQR(... | mit | C# | |
58cdf713b7568785aae0472052ad6ca28ec97ab5 | Define 'System.IO.FileAccess' | jonathanvdc/flame-llvm,jonathanvdc/flame-llvm,jonathanvdc/flame-llvm | stdlib/system-io/FileAccess.cs | stdlib/system-io/FileAccess.cs | namespace System.IO
{
/// <summary>
/// Specifies how a file can be accessed. This enumeration is
/// a bitwise combination of flags.
/// </summary>
public enum FileAccess
{
Read = 1,
Write = 2,
ReadWrite = 3
}
} | mit | C# | |
76234615931d0b625dd53136c194b2de0aae46fb | Add HttpUtility to WebSharpJs.DOM. | xamarin/WebSharp,xamarin/WebSharp,xamarin/WebSharp,xamarin/WebSharp,xamarin/WebSharp,xamarin/WebSharp | electron-dotnet/src/websharpjs/WebSharp.js/dotnet/WebSharpJs.DOM/HttpUtility.cs | electron-dotnet/src/websharpjs/WebSharp.js/dotnet/WebSharpJs.DOM/HttpUtility.cs | namespace WebSharpJs.DOM
{
using System.Net;
public static class HttpUtility
{
#region HtmlEncode and HtmlDecode methods
public static string HtmlEncode(string value)
{
return WebUtility.HtmlEncode(value);
}
public static string HtmlDecode(string value... | mit | C# | |
2a1cc35541f46c8bc36d8447fddce0d7c37589de | Add test scene | UselessToucan/osu,peppy/osu,UselessToucan/osu,peppy/osu,smoogipoo/osu,peppy/osu,peppy/osu-new,ppy/osu,ppy/osu,NeoAdonis/osu,ppy/osu,smoogipooo/osu,smoogipoo/osu,NeoAdonis/osu,NeoAdonis/osu,smoogipoo/osu,UselessToucan/osu | osu.Game.Rulesets.Taiko.Tests/Skinning/TestSceneDrawableBarLine.cs | osu.Game.Rulesets.Taiko.Tests/Skinning/TestSceneDrawableBarLine.cs | // 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;
using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Game.Bea... | mit | C# | |
d095bafecf666d2b774b6bc19e503a7e1a480109 | Create GetCartRequest.cs | daniela1991/hack4europecontest | GetCartRequest.cs | GetCartRequest.cs | using System;
using Newtonsoft.Json;
namespace Cdiscount.OpenApi.ProxyClient.Contract.GetCart
{
/// <summary>
/// GetCart request object
/// </summary>
public class GetCartRequest
{
/// <summary>
/// Cart identifier
/// </summary>
[JsonProperty(PropertyName = "CartGU... | mit | C# | |
1983224d184d966d5d58b39d0e6d344cd36f50e6 | Add unit tests. | jp7677/hellocoreclr,jp7677/hellocoreclr,jp7677/hellocoreclr,jp7677/hellocoreclr | test/app.tests/WebApi/Actions/GetLastTenGreetingsActionTest.cs | test/app.tests/WebApi/Actions/GetLastTenGreetingsActionTest.cs | using System.Threading.Tasks;
using Xunit;
using Moq;
using FluentAssertions;
using HelloWorldApp.Data;
using HelloWorldApp.WebApi.Actions;
using System.Collections.Generic;
using HelloWorldApp.Data.Entities;
using System;
namespace HelloWorldApp.Test.WebApi.Actions
{
public class GetLastTenGreetingsActionTest
... | mit | C# | |
43fd2b5442905e2120297311fb022a6c7674c8f4 | add a file IDocResult.cs | oceanho/DocViewer | src/DocViewer/Doc/IDocResult.cs | src/DocViewer/Doc/IDocResult.cs |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace DocViewer.Doc
{
using DocViewer.Impl;
public interface IDocResult : IResult
{
}
}
| apache-2.0 | C# | |
0e5ad9a95ca6059d71fd31dd3d6e50be6274d0e6 | Update PlaceOrderHandler.cs | eclaus/docs.particular.net,yuxuac/docs.particular.net,pashute/docs.particular.net,WojcikMike/docs.particular.net,pedroreys/docs.particular.net | samples/step-by-step/Version_5/Ordering.Server/PlaceOrderHandler.cs | samples/step-by-step/Version_5/Ordering.Server/PlaceOrderHandler.cs | #region PlaceOrderHandler
namespace Ordering.Server
{
using System;
using Messages;
using NServiceBus;
public class PlaceOrderHandler : IHandleMessages<PlaceOrder>
{
IBus bus;
public PlaceOrderHandler(IBus bus)
{
this.bus = bus;
}
public void H... | #region PlaceOrderHandler
namespace Ordering.Server
{
using System;
using Messages;
using NServiceBus;
public class PlaceOrderHandler : IHandleMessages<PlaceOrder>
{
IBus bus;
public PlaceOrderHandler(IBus bus)
{
this.bus = bus;
}
public void H... | apache-2.0 | C# |
ee66455057520c116bcef03aa549043c009c995a | Add unit tests for custom scoped notification publisher | umbraco/Umbraco-CMS,abryukhov/Umbraco-CMS,abjerner/Umbraco-CMS,abjerner/Umbraco-CMS,abryukhov/Umbraco-CMS,umbraco/Umbraco-CMS,KevinJump/Umbraco-CMS,dawoe/Umbraco-CMS,marcemarc/Umbraco-CMS,JimBobSquarePants/Umbraco-CMS,arknu/Umbraco-CMS,abjerner/Umbraco-CMS,marcemarc/Umbraco-CMS,dawoe/Umbraco-CMS,arknu/Umbraco-CMS,rober... | src/Umbraco.Tests.UnitTests/Umbraco.Core/Scoping/ScopedNotificationPublisherTests.cs | src/Umbraco.Tests.UnitTests/Umbraco.Core/Scoping/ScopedNotificationPublisherTests.cs | using System;
using Microsoft.Extensions.Logging;
using Microsoft.Extensions.Logging.Abstractions;
using Microsoft.Extensions.Options;
using Moq;
using NUnit.Framework;
using Umbraco.Cms.Core.Cache;
using Umbraco.Cms.Core.Configuration.Models;
using Umbraco.Cms.Core.Events;
using Umbraco.Cms.Core.Hosting;
using Umbraco... | mit | C# | |
6862492485b7716bc2fa15f058b36bbb821d074a | use header and body instead of rows in Examples (c#) | SabotageAndi/gherkin,thiblahute/gherkin3,thiblahute/gherkin3,thiblahute/gherkin3,thr0w/gherkin3,dirkrombauts/gherkin3,concertman/gherkin3,cucumber/gherkin3,SabotageAndi/gherkin,vincent-psarga/gherkin3,curzona/gherkin3,thetutlage/gherkin3,concertman/gherkin3,thiblahute/gherkin3,curzona/gherkin3,vincent-psarga/gherkin3,c... | dotnet/Gherkin/Ast/Examples.cs | dotnet/Gherkin/Ast/Examples.cs | using System;
using System.Collections.Generic;
using System.Linq;
namespace Gherkin.Ast
{
public class Examples : IHasLocation, IHasDescription, IHasRows, IHasTags
{
public IEnumerable<Tag> Tags { get; private set; }
public Location Location { get; private set; }
public stri... | using System;
using System.Collections.Generic;
using System.Linq;
namespace Gherkin.Ast
{
public class Examples : IHasLocation, IHasDescription, IHasRows, IHasTags
{
public IEnumerable<Tag> Tags { get; private set; }
public Location Location { get; private set; }
public stri... | mit | C# |
01296c25e9748606d9185fcbf4cf841dd1f324e2 | add SystemDateTime.cs | NDark/ndinfrastructure,NDark/ndinfrastructure | DotNet/SystemDateTime/SystemDateTime.cs | DotNet/SystemDateTime/SystemDateTime.cs | /**
@file SystemDateTime.cs
@author NDark
@date 201705118 file started.
*/
using UnityEngine;
public static class SystemDateTime
{
// \/Date(-62135596800000)\/
public static System.DateTime ConvertFromJSONDate( string _Str )
{
const string KEY_Date = "Date" ;
const string KEY_LeftBrace = "(" ;
const s... | mit | C# | |
45afe53525a3e488e5b91ab494028f4218302bb4 | Create Unity_Analytics_Singleton.cs | kinifi/framework-unity | Singletons/Unity_Analytics_Singleton.cs | Singletons/Unity_Analytics_Singleton.cs | //
// Unity_Analytics_Singleton.cs provides easy static methods for use during game for analytics
//
using UnityEngine;
using UnityEngine.SceneManagement;
using UnityEngine.UI;
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine.Analytics;
public class GameManager
{
//Class L... | mit | C# | |
1e20a36e5f14342163ab6b57650aac9bf870048a | Create IActiveRecord.cs | dingjimmy/Level | IActiveRecord.cs | IActiveRecord.cs | public interface IActiveRecord
{
RecordState State { get; set; }
bool Save();
}
| mit | C# | |
f322da2524e8f44ff2d7b59cb312b83231f9eb17 | Add Yield one extension | jaredthirsk/Core,lionfire/Core,lionfire/Core,lionfire/Core | src/LionFire.Runtime.Extensions/ExtensionMethods/System/Collections/Generic/IEnumerableExtensions.cs | src/LionFire.Runtime.Extensions/ExtensionMethods/System/Collections/Generic/IEnumerableExtensions.cs | using System.Collections.Generic;
namespace LionFire.ExtensionMethods
{
public static class IEnumerableExtensions
{
/// <summary>
/// Wraps this object instance into an IEnumerable<T>
/// consisting of a single item.
/// </summary>
/// <typeparam name="T"> Type of... | mit | C# | |
2527e0448063e9551b427a4cfa4d582dae0383a7 | add language repo interface | mzrimsek/resume-site-api | Core/Interfaces/ILanguageRepository.cs | Core/Interfaces/ILanguageRepository.cs | using System.Collections.Generic;
using Core.Models;
namespace Core.Interfaces
{
public interface ILanguageRepository
{
IEnumerable<LanguageDomainModel> GetAll();
LanguageDomainModel GetById(int id);
LanguageDomainModel Save(LanguageDomainModel job);
void Delete(int id);
}
} | mit | C# | |
7f8bbf06a25d8c5be7bfc6c1a04b59e754a0c676 | Remove Console.ReadKey | asd-and-Rizzo/ExpressionToCode,EamonNerbonne/ExpressionToCode | ExpressionToCode.Benchmarks/Program.cs | ExpressionToCode.Benchmarks/Program.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using BenchmarkDotNet.Attributes;
using BenchmarkDotNet.Running;
using ExpressionToCodeLib;
namespace ExpressionToCode.Benchmarks
{
public class Program
{
static void Main(string[] args)
{
... | using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using BenchmarkDotNet.Attributes;
using BenchmarkDotNet.Running;
using ExpressionToCodeLib;
namespace ExpressionToCode.Benchmarks
{
public class Program
{
static void Main(string[] args)
{
... | apache-2.0 | C# |
48bb144c1bcb91247880ada66dcd92964a31dced | Create Problem77.cs | fireheadmx/ProjectEuler,fireheadmx/ProjectEuler | Problems/Problem77.cs | Problems/Problem77.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ProjectEuler.Problems
{
class Problem77
{
private Sieve s;
private int upper = 5000;
public Problem77()
{
s = new Sieve(upper / 10);
}
private long count... | mit | C# | |
13590fb32834c974e8f1afc3754de057bd939c37 | Define a standard library 'Console' class | jonathanvdc/flame-llvm,jonathanvdc/flame-llvm,jonathanvdc/flame-llvm | standard-library/Console.cs | standard-library/Console.cs | using System.IO;
namespace System
{
public static class Console
{
/// <summary>
/// Writes a character to standard output.
/// </summary>
/// <param name="c">The character to write.</param>
public static void Write(char c)
{
// TODO: convert this char... | mit | C# | |
7689b4be6b509f17bfbb292c22d3d9c6f063ed46 | Create QParticle.cs | QetriX/CS | QetriX/libs/QParticle.cs | QetriX/libs/QParticle.cs | namespace com.qetrix.libs
{
/* Copyright (c) QetriX.com. Licensed under MIT License, see /LICENSE.txt file.
* 16.05.05 | Particle Class
*/
using System;
public class QParticle
{
public QParticle()
{
}
}
}
| mit | C# | |
59461d59f2b9a0e9fc54738e91a7c02140343095 | move back old test temporally | restdotnet/RestDotNet | test/RestDotNet.Tests/TempTests.cs | test/RestDotNet.Tests/TempTests.cs | using System;
using System.Net;
using System.Net.Http;
using System.Threading.Tasks;
using Xunit;
namespace RestDotNet.Tests
{
public class TempTests : BaseTest
{
private readonly Uri _uri;
private readonly string _path;
public TempTests()
{
_uri = new Uri("http://t... | mit | C# | |
bac14f5e8159a9a7451dd16c8922a362520d866f | add missing file | pgourlain/VsXmlDesigner | BaseEditors/DynamicIPC.cs | BaseEditors/DynamicIPC.cs | using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Diagnostics;
using System.Dynamic;
using System.Linq;
using System.Reflection;
using System.Text;
using System.Threading.Tasks;
namespace Genius.VisualStudio.BaseEditors
{
interface IProxyProperty
{
}
public c... | mit | C# | |
86b0a98f06fbb6600c6ae36f5ed1445509dd1770 | Verify preorder serialization | Gerula/interviews,Gerula/interviews,Gerula/interviews,Gerula/interviews,Gerula/interviews | LeetCode/remote/verify_preorder_serialization.cs | LeetCode/remote/verify_preorder_serialization.cs | // https://leetcode.com/problems/verify-preorder-serialization-of-a-binary-tree/
// One way to serialize a binary tree is to use pre-order traversal.
// When we encounter a non-null node, we record the node's value.
// If it is a null node, we record using a sentinel value such as #.
//
// Given a string of comma ... | mit | C# | |
5d90f32297c6d791e13c35b3f9d0bd669e8c293e | Add UsingBoolBoxes to ValidCode.csproj | DotNetAnalyzers/WpfAnalyzers | ValidCode/DependencyProperties/UsingBoolBoxes.cs | ValidCode/DependencyProperties/UsingBoolBoxes.cs | namespace ValidCode.DependencyProperties
{
using System.Windows;
using System.Windows.Controls;
public class UsingBoolBoxes : Control
{
/// <summary>Identifies the <see cref="IsTrue"/> dependency property.</summary>
public static readonly DependencyProperty IsTrueProperty = DependencyP... | mit | C# | |
27f5dc42c4a6f2006cb33574b00f2442e563938a | Create tests for grouped filters | sqlkata/querybuilder | QueryBuilder.Tests/WhereTests.cs | QueryBuilder.Tests/WhereTests.cs | using SqlKata.Compilers;
using SqlKata.Tests.Infrastructure;
using Xunit;
namespace SqlKata.Tests
{
public class WhereTests : TestSupport
{
[Fact]
public void GroupedWhereFilters()
{
var q = new Query("Table1")
.Where(q => q.Or().Where("Column1", 10).Or().Whe... | mit | C# | |
026b8e5a99a4b6638f365c0f66ceafff5fa76c0e | Set version to 3.2.0 | adamralph/FakeItEasy,adamralph/FakeItEasy,thomaslevesque/FakeItEasy,blairconrad/FakeItEasy,thomaslevesque/FakeItEasy,FakeItEasy/FakeItEasy,blairconrad/FakeItEasy,FakeItEasy/FakeItEasy | src/CommonAssemblyInfo.cs | src/CommonAssemblyInfo.cs | using System;
using System.Reflection;
using System.Resources;
using System.Runtime.InteropServices;
[assembly: AssemblyVersion("3.2.0")]
[assembly: AssemblyFileVersion("3.2.0")]
[assembly: AssemblyInformationalVersion("3.2.0")]
[assembly: AssemblyCompany("Patrik Hägne")]
[assembly: AssemblyCopyright("Copyr... | using System;
using System.Reflection;
using System.Resources;
using System.Runtime.InteropServices;
[assembly: AssemblyVersion("3.1.0")]
[assembly: AssemblyFileVersion("3.1.0")]
[assembly: AssemblyInformationalVersion("3.1.0")]
[assembly: AssemblyCompany("Patrik Hägne")]
[assembly: AssemblyCopyright("Copyr... | mit | C# |
cd603d7b4f1ab27233b1aafe1a4ea3801646c65f | Add management of policies | Seddryck/RsPackage | RsDeploy/Execution/PolicyService.cs | RsDeploy/Execution/PolicyService.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.IO;
using RsDeploy.ReportingService;
namespace RsDeploy.Execution
{
public class PolicyService : BaseService
{
public PolicyService(ReportingService2010 reportingService)
... | apache-2.0 | C# | |
7da87dc2e9dca0ea11cdfe0c3a34d3c80fce9bc4 | Create greenScreen.cs | Justinius/ImageHelpers,Justinius/ImageHelpers | greenScreen.cs | greenScreen.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Drawing;
namespace ImageTest
{
public static class greenScreen
{
private static int rgb2y(int r, int g, int b)
{
/*a utility function to convert colors in RGB into YCbCr*/
... | unlicense | C# | |
4d051818a152573834a0e859994f25c83bda1b7a | Add base class for all realtime multiplayer classes | UselessToucan/osu,ppy/osu,peppy/osu,ppy/osu,NeoAdonis/osu,UselessToucan/osu,NeoAdonis/osu,UselessToucan/osu,peppy/osu,smoogipoo/osu,peppy/osu-new,smoogipooo/osu,peppy/osu,NeoAdonis/osu,smoogipoo/osu,smoogipoo/osu,ppy/osu | osu.Game/Screens/Multi/RealtimeMultiplayer/RealtimeRoomComposite.cs | osu.Game/Screens/Multi/RealtimeMultiplayer/RealtimeRoomComposite.cs | // 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 JetBrains.Annotations;
using osu.Framework.Allocation;
using osu.Game.Online.RealtimeMultiplayer;
namespace osu.Game.Screens.Multi.RealtimeMultiplayer
{
public... | mit | C# | |
9147212c57f6d6d4a0561f94d0a7449cbc267e3a | add HeadOf class | icarus-consulting/Yaapii.Atoms | src/Yaapii.Atoms/IO/HeadOf.cs | src/Yaapii.Atoms/IO/HeadOf.cs | using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
namespace Yaapii.Atoms.IO
{
public sealed class HeadOf : IInput
{
private readonly IInput origin;
private readonly int length;
public HeadOf(IInput origin, int length)
{
this.origin... | mit | C# | |
5d4023649fc0e433ff0563aae3a94f2dcbfef2c0 | Create CampaignsController | skynode/eShopOnContainers,productinfo/eShopOnContainers,skynode/eShopOnContainers,dotnet-architecture/eShopOnContainers,dotnet-architecture/eShopOnContainers,dotnet-architecture/eShopOnContainers,skynode/eShopOnContainers,andrelmp/eShopOnContainers,albertodall/eShopOnContainers,TypeW/eShopOnContainers,andrelmp/eShopOnC... | src/Web/WebMVC/Controllers/CampaignsController.cs | src/Web/WebMVC/Controllers/CampaignsController.cs | namespace Microsoft.eShopOnContainers.WebMVC.Controllers
{
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Microsoft.eShopOnContainers.WebMVC.Services;
[Authorize]
public class CampaignsController : Controller
{
private ICampaignService _campaignService;
... | mit | C# | |
f35b66bb1f77e45ff7f979c7bdcc886d644d13f8 | add Maintenance | fs7744/etcdcsharp | etcd.v3/MaintenanceExtensions.cs | etcd.v3/MaintenanceExtensions.cs | using Etcdserverpb;
using Grpc.Core;
using static Etcdserverpb.AlarmRequest.Types;
namespace ETCD.V3
{
public static class MaintenanceExtensions
{
#region Alarm
public static AlarmRequest CreateAlarmRequest(this Client client, ulong memberID,
AlarmAction action = AlarmAction.Get, ... | mit | C# | |
276a83c6b86eb8d6bca2b4e66358c7fb31ee5fe4 | Add text broadcaster | adamabdelhamed/PowerArgs,adamabdelhamed/PowerArgs | PowerArgs/CLI/TextBroadcaster.cs | PowerArgs/CLI/TextBroadcaster.cs | using System;
using System.IO;
using System.Text;
namespace PowerArgs.Cli
{
internal class TextBroacaster : TextWriter
{
public override Encoding Encoding => Encoding.UTF8;
public Event<ConsoleString> TextReady { get; private set; } = new Event<ConsoleString>();
public override void Wr... | mit | C# | |
29a3d62573f14186c2ca3e48408ddc054e08a05d | comment out test for now according to @hovsepm's comment. | tonytang-microsoft-com/azure-powershell,nemanja88/azure-powershell,nickheppleston/azure-powershell,Matt-Westphal/azure-powershell,seanbamsft/azure-powershell,hallihan/azure-powershell,devigned/azure-powershell,shuagarw/azure-powershell,dominiqa/azure-powershell,yantang-msft/azure-powershell,AzureAutomationTeam/azure-po... | src/ResourceManager/Compute/Commands.Compute.Test/ScenarioTests/VirtualMachinePIRv2Tests.cs | src/ResourceManager/Compute/Commands.Compute.Test/ScenarioTests/VirtualMachinePIRv2Tests.cs | // ----------------------------------------------------------------------------------
//
// Copyright Microsoft Corporation
// 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.apa... | // ----------------------------------------------------------------------------------
//
// Copyright Microsoft Corporation
// 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.apa... | apache-2.0 | C# |
d2324b64c719f429e11b3946936341343d70d750 | Add missing file | RavenB/opensim,TomDataworks/opensim,RavenB/opensim,RavenB/opensim,EriHoss/OpenSim_0.8.2.0_Dev_LibLSLCC,TomDataworks/opensim,EriHoss/OpenSim_0.8.2.0_Dev_LibLSLCC,TomDataworks/opensim,TomDataworks/opensim,RavenB/opensim,EriHoss/OpenSim_0.8.2.0_Dev_LibLSLCC,RavenB/opensim,EriHoss/OpenSim_0.8.2.0_Dev_LibLSLCC,TomDataworks/... | OpenSim/Region/Framework/Scenes/Animation/MovementAnimationOverrides.cs | OpenSim/Region/Framework/Scenes/Animation/MovementAnimationOverrides.cs | /*
* Copyright (c) Contributors, http://opensimulator.org/
* See CONTRIBUTORS.TXT for a full list of copyright holders.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* * Redistributions of source code must r... | bsd-3-clause | C# | |
42b9ab145c19fbe9ce4937785b0425c8552b86a5 | Add NewLineParser | StevenLiekens/Txt,StevenLiekens/TextFx | src/Txt.ABNF/Core/CRLF/NewLineParser.cs | src/Txt.ABNF/Core/CRLF/NewLineParser.cs | using Txt.Core;
namespace Txt.ABNF.Core.CRLF
{
public class NewLineParser : Parser<NewLine, string>
{
protected override string ParseImpl(NewLine value)
{
return value.Text;
}
}
}
| mit | C# | |
45b0c6ab1c0b0ebb72ecf8e75080c6bcef64e3bf | Create Instantiate.cs | carcarc/unity3d | Instantiate.cs | Instantiate.cs | public GameObject object; // The enemy prefab to be spawned.
public Transform[] spawnPoints; // An array of the spawn points this enemy can spawn from.
Instantiate (object, spawnPoints[0].position, spawnPoints[0].rotation);
| mit | C# | |
2287957a96c785c88dbc0ec9459a4aa2ec41c12f | Create SuperReducedString.cs | shreeharshas/Algorithms,shreeharshas/hackerrank,shreeharshas/Algorithms,shreeharshas/hackerrank,shreeharshas/hackerrank,shreeharshas/Algorithms,shreeharshas/Algorithms,shreeharshas/hackerrank,shreeharshas/Algorithms | hackerrank/SuperReducedString.cs | hackerrank/SuperReducedString.cs | /*Interim version, to be updated*/
/*Based on hackerrank question at https://www.hackerrank.com/challenges/reduced-string */
using System;
using System.Collections.Generic;
using System.IO;
class Solution {
static void Main(String[] args) {
string s = Console.ReadLine();
Console.WriteLine(reduce(s)... | mit | C# | |
7a67156a30e86004f57220ffa423cef98120df6a | Add PokeBox class. To (randomly) get a pokemon from db. | NextLight/PokeBattle_Server | PokeBattle/PokeBattle/PokeBox.cs | PokeBattle/PokeBattle/PokeBox.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Data;
namespace PokeBattle
{
class PokeBox
{
Db db;
int versionGroupId = 16, languageId = 9;
Random rand = new Random();
public int NOfPokemon { get; private set; }
public PokeBox()
... | mit | C# | |
5f9bc1e9a51df2c83e100dc31fa56ab2101cfdc7 | Create PopupNotifications.cs | prrovoss/THUD | plugins/Prrovoss/PopupNotifications.cs | plugins/Prrovoss/PopupNotifications.cs | using System.Collections.Generic;
using System.Linq;
using Turbo.Plugins.Default;
namespace Turbo.Plugins.Prrovoss
{
public class PopupNotifications : BasePlugin
{
public List<Popup> Popups { get; set; }
public TopLabelWithTitleDecorator PopupDecorator { get; set; }
public float X, Y,... | mit | C# | |
94b4d4a6fcef1af00e2ea269f99ab891d5d05d72 | Add LuceneStatistics. | ZooPin/CK-Glouton,ZooPin/CK-Glouton,ZooPin/CK-Glouton,ZooPin/CK-Glouton | src/CK.Glouton.Lucene/LuceneStatistics.cs | src/CK.Glouton.Lucene/LuceneStatistics.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace CK.Glouton.Lucene
{
public class LuceneStatistics
{
LuceneSearcherManager _luceneSearcher;
LuceneSearcherConfiguration _allSearchLog;
LuceneSearcherConfiguratio... | mit | C# | |
abe10d1820f65f22d94279fa10b386353b5b9cff | Make CursorContainer extensible. | default0/osu-framework,Tom94/osu-framework,peppy/osu-framework,naoey/osu-framework,peppy/osu-framework,paparony03/osu-framework,DrabWeb/osu-framework,ppy/osu-framework,Nabile-Rahmani/osu-framework,DrabWeb/osu-framework,RedNesto/osu-framework,EVAST9919/osu-framework,paparony03/osu-framework,Tom94/osu-framework,NeoAdonis... | osu.Framework/Graphics/Cursor/CursorContainer.cs | osu.Framework/Graphics/Cursor/CursorContainer.cs | // Copyright (c) 2007-2016 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu-framework/master/LICENCE
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Drawables;
using osu.Framework.Input;
using OpenTK;
namespace osu.Framework.Gra... | // Copyright (c) 2007-2016 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu-framework/master/LICENCE
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Drawables;
using osu.Framework.Input;
using OpenTK;
namespace osu.Framework.Gra... | mit | C# |
a28a08977d70791553a9c6facebc790ebc822c10 | Add Q268 | txchen/csharp-leet,txchen/csharp-leet | solutions/Q268.cs | solutions/Q268.cs | public class Solution {
public int MissingNumber(int[] nums)
{
int xor = 0;
for (int i = 1; i <= nums.Length; i++)
{
xor = xor ^ i;
}
nums.ToList().ForEach(n => xor = xor ^ n);
return xor;
}
} | mit | C# |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.