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 |
|---|---|---|---|---|---|---|---|---|
5e781a63e4a16583441286569f18fcbc52742339 | add MathTypeConverter | yufeih/Common | MathTypeConverter.cs | MathTypeConverter.cs | namespace System
{
using Globalization;
using System.Linq;
static class MathTypeConverter
{
public static T[] FromText<T>(string text, int count, Func<string, T> parse)
{
if (string.IsNullOrEmpty(text)) return null;
var i = 0;
var result ... | mit | C# | |
35bc451136be7e748c09810b1adc509d5d3d8c6a | Create UnityEventOnKeyUp.cs | felladrin/unity-scripts,felladrin/unity3d-scripts | UnityEventOnKeyUp.cs | UnityEventOnKeyUp.cs | using UnityEngine;
using UnityEngine.Events;
public class UnityEventOnKeyUp : MonoBehaviour
{
public KeyCode Key;
public KeyCode ComboKey;
public UnityEvent OnKeyDown;
void Update()
{
if (ComboKey == KeyCode.None)
{
if (Input.GetKeyUp(Key)) OnKeyDown.Invoke();
}... | mit | C# | |
31d6c0504bf805793004d92861abfce93f5687e1 | Create FindDigits.cs | costincaraivan/hackerrank,costincaraivan/hackerrank | algorithms/implementation/C#/FindDigits.cs | algorithms/implementation/C#/FindDigits.cs | using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
class Solution {
static void Main(String[] args) {
int t = Convert.ToInt32(Console.ReadLine());
for(int a0 = 0; a0 < t; a0++){
int n = Convert.ToInt32(Console.ReadLine());
var co... | mit | C# | |
7faeef18900e356eb0bb92df9c1289a376e6adb0 | Create task_1_3_8_2_age.cs | AndrewTurlanov/ANdrew | task_1_3_8_2_age.cs | task_1_3_8_2_age.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp1
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Введите свой возраст");
int UserAge = Convert.ToInt32(Console... | apache-2.0 | C# | |
66e655e33a764b6676550ece9fe9e54618f95b8e | Create OpenApiClient.cs | daniela1991/hack4europecontest | OpenApiClient.cs | OpenApiClient.cs | using System;
using System.Net.Http;
using System.Net.Http.Headers;
using System.Text;
using System.Threading.Tasks;
using Cdiscount.OpenApi.ProxyClient.Config;
using Cdiscount.OpenApi.ProxyClient.Contract.Common;
using Cdiscount.OpenApi.ProxyClient.Contract.GetCart;
using Cdiscount.OpenApi.ProxyClient.Contract.GetProd... | mit | C# | |
664cd3002aa286b815a41576905a7331b3288ae0 | Create ZeroGMovement.cs | scmcom/unitycode | ZeroGMovement.cs | ZeroGMovement.cs | //===================================================
// defines 3D zero gravity physics per KEYBOARD input
// KEYBOARD INPUTS - CHANGE POSITION VECTOR
//
// up, down, left-sidestep, right-sidestep, up, back
// W A S D keys
// OR
// < > ^ down (arrow keys)
//===================================================
... | mit | C# | |
7ac0da49140c3c723fe17c072f9eca8f02630af5 | Add date time passing practices. | AxeDotNet/AxePractice.CSharpViaTest | src/CSharpViaTest.OtherBCLs/HandleDates/PassingDateTimeBetweenDifferentCultures.cs | src/CSharpViaTest.OtherBCLs/HandleDates/PassingDateTimeBetweenDifferentCultures.cs | using System;
using System.Collections.Generic;
using System.Globalization;
using Xunit;
namespace CSharpViaTest.OtherBCLs.HandleDates
{
/*
* Description
* ===========
*
* This test will try passing date time between the boundary (e.g. via HTTP).
* And the culture information at each si... | mit | C# | |
622599fda7bf8ffbbabc656d744bbf5312bae990 | Create RandomExtensions.cs | keith-hall/Extensions,keith-hall/Extensions | src/RandomExtensions.cs | src/RandomExtensions.cs | using System;
namespace HallLibrary.Extensions
{
public static class RandomExtensionMethods
{
/// <summary>
/// Returns a random long from min (inclusive) to max (exclusive).
/// </summary>
/// <param name="random">The given random instance.</param>
/// <param name="min">The inclusive minimum bound.</param... | apache-2.0 | C# | |
2dcf6e2d8318d9b71ebc9514fcd489acce6bd8b9 | Create IMongoClientSessionProvider.cs | tiksn/TIKSN-Framework | TIKSN.Core/Data/Mongo/IMongoClientSessionProvider.cs | TIKSN.Core/Data/Mongo/IMongoClientSessionProvider.cs | using LanguageExt;
using MongoDB.Driver;
namespace TIKSN.Data.Mongo
{
public interface IMongoClientSessionProvider
{
Option<IClientSessionHandle> GetClientSessionHandle();
}
} | mit | C# | |
3328d5d7e51e23f90afd7b5d110b77500c14d63b | bump version | modulexcite/Anotar,mstyura/Anotar,distantcam/Anotar,Fody/Anotar | CommonAssemblyInfo.cs | CommonAssemblyInfo.cs | using System.Reflection;
[assembly: AssemblyTitle("Anotar")]
[assembly: AssemblyProduct("Anotar")]
[assembly: AssemblyVersion("2.11.1")]
[assembly: AssemblyFileVersion("2.11.1")]
| using System.Reflection;
[assembly: AssemblyTitle("Anotar")]
[assembly: AssemblyProduct("Anotar")]
[assembly: AssemblyVersion("2.11.0")]
[assembly: AssemblyFileVersion("2.11.0")]
| mit | C# |
15ce7bacf1fcc319916f9365643f5ef1e73f26d6 | Add test coverage for confine functionality | smoogipoo/osu,smoogipoo/osu,ppy/osu,NeoAdonis/osu,NeoAdonis/osu,UselessToucan/osu,peppy/osu,smoogipooo/osu,NeoAdonis/osu,peppy/osu-new,ppy/osu,peppy/osu,smoogipoo/osu,peppy/osu,ppy/osu,UselessToucan/osu,UselessToucan/osu | osu.Game.Tests/Input/ConfineMouseTrackerTest.cs | osu.Game.Tests/Input/ConfineMouseTrackerTest.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.Allocation;
using osu.Framework.Configuration;
using osu.Framework.Input;
using osu.Framework.Testing;
using osu.Game.Configura... | mit | C# | |
6a00f499d292644365f874b31cec4f6a63d8094c | add PagedRequest | WeihanLi/WeihanLi.Common,WeihanLi/WeihanLi.Common,WeihanLi/WeihanLi.Common | src/WeihanLi.Common/Models/PagedRequest.cs | src/WeihanLi.Common/Models/PagedRequest.cs | namespace WeihanLi.Common.Models
{
public class PagedRequest
{
private int _pageNum = 1;
private int _pageSize = 10;
public int PageNum
{
get => _pageNum;
set => _pageNum = value > 0 ? value : 1;
}
public int PageSize
{
... | mit | C# | |
03a816f19d5e31b99a718646a18852d2785c1f32 | Add Peek tests | StevenLiekens/Txt,StevenLiekens/TextFx | test/Txt.Core.Tests/TextSourceTests.Peek.cs | test/Txt.Core.Tests/TextSourceTests.Peek.cs | using Xunit;
namespace Txt.Core
{
public partial class TextSourceTests
{
public class Peek
{
[Fact]
public void EmptyData()
{
var sut = new StringTextSource("");
Assert.Equal(-1, sut.Peek());
Assert.Equal(0, su... | mit | C# | |
764e23fa32e348e281938b6d9301a28cfe26eb77 | add impl for ICapTransaction | dotnetcore/CAP,ouraspnet/cap,dotnetcore/CAP,dotnetcore/CAP | src/DotNetCore.CAP/ICapTransaction.Base.cs | src/DotNetCore.CAP/ICapTransaction.Base.cs | using System.Collections.Generic;
using DotNetCore.CAP.Models;
namespace DotNetCore.CAP
{
public abstract class CapTransactionBase : ICapTransaction
{
private readonly IDispatcher _dispatcher;
private readonly IList<CapPublishedMessage> _bufferList;
protected CapTransactionBase(IDisp... | mit | C# | |
076e498a6378b07dcae67e4b06bfde1d0f6f565c | create abstract class OverlaySidebar | peppy/osu,NeoAdonis/osu,ppy/osu,peppy/osu,smoogipoo/osu,smoogipooo/osu,NeoAdonis/osu,ppy/osu,NeoAdonis/osu,UselessToucan/osu,smoogipoo/osu,peppy/osu,UselessToucan/osu,ppy/osu,peppy/osu-new,UselessToucan/osu,smoogipoo/osu | osu.Game/Overlays/OverlaySidebar.cs | osu.Game/Overlays/OverlaySidebar.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.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Shapes;
u... | mit | C# | |
0247e55bf604f761310606e9fc42ad8ffd314612 | Insert sort | sylviot/algoritmos,sylviot/algoritmos,sylviot/algoritmos | sorting/Insert.cs | sorting/Insert.cs | using System;
public class InsertSort
{
public static void Main()
{
// Array de exemplo.
int[] array = new int[] { 2, 3, 1, 5, 4 };
// Resultado da ordenação do array de exemplo.
int[] arraySorted = Insert(array);
foreach(var item in arraySorted){
Console.WriteLine(item);
}
}
public static i... | mit | C# | |
119de2e1e5a908bcdc396c7c93e64604359881d7 | add credit card balance | borismod/FinBotApp,idoban/FinBotApp,idoban/FinBotApp,borismod/FinBotApp | FinBot/Engine/CreditBalanceAdapter.cs | FinBot/Engine/CreditBalanceAdapter.cs | using Syn.Bot.Siml;
namespace FinBot.Engine
{
public class CreditBalanceAdapter : BaseAdapter
{
private readonly IFinancialServices _financialServices;
public CreditBalanceAdapter(IFinancialServices financialServices)
{
_financialServices = financialServices;
}
... | mit | C# | |
7df10c7f024330d9d51251ff85b255db6b3f8704 | Add test properties | brandonio21/update.net | update.net_test/Properties/AssemblyInfo.cs | update.net_test/Properties/AssemblyInfo.cs | 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.
[assembly: AssemblyTi... | mit | C# | |
fb78e2b5fdb4ed78c1930cc1b729cde43615145d | Add script for serializing level data | jguarShark/Unity2D-Components,cmilr/Unity2D-Components | Level/LevelData.cs | Level/LevelData.cs | using System.IO;
using System.Runtime.Serialization.Formatters.Binary;
using System;
using UnityEngine;
public class LevelData : BaseBehaviour
{
public int HP { get; set; }
public int AC { get; set; }
public int Damage { get; set; }
public void Save()
{
var bf = new BinaryFormatter();
FileStream file... | mit | C# | |
3e1371252905d8b9b297fad8fca15305525c84b0 | add currentUser remove NCMBMenu for #57 | NIFTYCloud-mbaas/ncmb_unity,NIFTYCloud-mbaas/ncmb_unity,NIFTYCloud-mbaas/ncmb_unity | ncmb_unity/Assets/NCMB/NCMBMenu.cs | ncmb_unity/Assets/NCMB/NCMBMenu.cs | using System.IO;
using UnityEditor;
using UnityEngine;
namespace NCMB
{
internal class NCMBMenu
{
[MenuItem ("NCMB/DeleteCurrentUserCache")]
private static void DeleteCurrentUserCache ()
{
File.Delete (Application.persistentDataPath + "/" + "currentUser");
Debug.Log ("CurrentUser cache is deleted");
}... | apache-2.0 | C# | |
478cfc0b87ac3a6062e5948fe8df496df0fac991 | Split model class for mod state | NeoAdonis/osu,ppy/osu,peppy/osu,ppy/osu,ppy/osu,NeoAdonis/osu,peppy/osu,peppy/osu,NeoAdonis/osu | osu.Game/Overlays/Mods/ModState.cs | osu.Game/Overlays/Mods/ModState.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 osu.Framework.Bindables;
using osu.Game.Rulesets.Mods;
namespace osu.Game.Overlays.Mods
{
/// <summary>
/// Wrapper class used to store the current state o... | mit | C# | |
9c6dd28e7d3cc2a24a7a5154d1f4604fd0920c7d | Add IProvideExpenditure class to support data provision | xyon1/Expenditure-App | GeneralUseClasses/Services/IProvideExpenditureData.cs | GeneralUseClasses/Services/IProvideExpenditureData.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using GeneralUseClasses.Contracts;
namespace GeneralUseClasses.Services
{
public interface IProvideExpenditureData
{
IEnumerable<string> GetDominantTags();
IEnumerable<string> ... | apache-2.0 | C# | |
4c7ba3d93c8e30b9fe81e3d092cf87d2040e993f | Add tagging capability to Dinamico news page | nimore/n2cms,EzyWebwerkstaden/n2cms,nimore/n2cms,SntsDev/n2cms,EzyWebwerkstaden/n2cms,VoidPointerAB/n2cms,SntsDev/n2cms,n2cms/n2cms,nicklv/n2cms,bussemac/n2cms,nicklv/n2cms,nimore/n2cms,nicklv/n2cms,nicklv/n2cms,n2cms/n2cms,bussemac/n2cms,SntsDev/n2cms,VoidPointerAB/n2cms,EzyWebwerkstaden/n2cms,EzyWebwerkstaden/n2cms,D... | src/Mvc/Dinamico/Dinamico/Themes/Default/Views/ContentPages/News.cshtml | src/Mvc/Dinamico/Dinamico/Themes/Default/Views/ContentPages/News.cshtml | @model Dinamico.Models.ContentPage
@{
Content.Define(re =>
{
re.Title = "News page";
re.IconUrl = "{IconsUrl}/newspaper.png";
re.DefaultValue("Visible", false);
re.RestrictParents("Container");
re.Sort(N2.Definitions.SortBy.PublishedDescending);
re.Tags("Tags");
});
}
@Html.Partial("Lay... | @model Dinamico.Models.ContentPage
@{
Content.Define(re =>
{
re.Title = "News page";
re.IconUrl = "{IconsUrl}/newspaper.png";
re.DefaultValue("Visible", false);
re.RestrictParents("Container");
re.Sort(N2.Definitions.SortBy.PublishedDescending);
});
}
@Html.Partial("LayoutPartials/BlogCont... | lgpl-2.1 | C# |
0bdd1131bb4173b2df859fa88cad653b76dd4b6f | Add missing file | abjerner/Umbraco-CMS,arknu/Umbraco-CMS,marcemarc/Umbraco-CMS,NikRimington/Umbraco-CMS,tcmorris/Umbraco-CMS,robertjf/Umbraco-CMS,arknu/Umbraco-CMS,leekelleher/Umbraco-CMS,bjarnef/Umbraco-CMS,KevinJump/Umbraco-CMS,bjarnef/Umbraco-CMS,madsoulswe/Umbraco-CMS,robertjf/Umbraco-CMS,mattbrailsford/Umbraco-CMS,leekelleher/Umbra... | src/Umbraco.Core/Migrations/Upgrade/V_8_0_0/AddUserLoginDtoDateIndex.cs | src/Umbraco.Core/Migrations/Upgrade/V_8_0_0/AddUserLoginDtoDateIndex.cs | using Umbraco.Core.Persistence.Dtos;
namespace Umbraco.Core.Migrations.Upgrade.V_8_0_0
{
public class AddUserLoginDtoDateIndex : MigrationBase
{
public AddUserLoginDtoDateIndex(IMigrationContext context)
: base(context)
{ }
public override void Migrate()
{
... | mit | C# | |
d49694623cc3ccf4377d1e09b2a6d78c5fcae1b5 | Create IntellisenseHelper.cs | Excel-DNA/IntelliSense | IntellisenseHelper.cs | IntellisenseHelper.cs | using System;
using System.Collections.Generic;
using ExcelDna.Integration;
namespace ExcelDna.IntelliSense
{
public class IntellisenseHelper : IDisposable
{
private readonly IntelliSenseDisplay _id;
public IntellisenseHelper()
{
_id = CrossAppDomainSingleton.GetOrCreate();... | mit | C# | |
69ea7c7ea4d82c6edc624534cd748bcbf547f841 | Create SerializerException.cs | tiksn/TIKSN-Framework | TIKSN.Core/Serialization/SerializerException.cs | TIKSN.Core/Serialization/SerializerException.cs | using System;
namespace TIKSN.Serialization
{
[Serializable]
public class SerializerException : Exception
{
public SerializerException()
{
}
public SerializerException(string message) : base(message)
{
}
public SerializerException(string message, E... | mit | C# | |
657ced56271a3c2f486d7ce1b1c8d4870ab2b8dd | Create ObjectRotateClamp.cs | zabaglione/ObjectRotateClamp | ObjectRotateClamp.cs | ObjectRotateClamp.cs | using UnityEngine;
using System.Collections;
//
// 元ネタ:http://detail.chiebukuro.yahoo.co.jp/qa/question_detail/q11128560141 .
//
public class ObjectRotateClamp : MonoBehaviour {
public float maxAngleH = 60; // 最大回転角度.
public float minAngleH = -60; // 最小回転角度.
public float maxAngleV = 60; // 最大回転角度.
public floa... | mit | C# | |
0cbc716b84dc545522d636f169e19e102b592ea6 | Add Id field to Label model (#1946) | shiftkey/octokit.net,alfhenrik/octokit.net,adamralph/octokit.net,octokit/octokit.net,octokit/octokit.net,shiftkey/octokit.net,alfhenrik/octokit.net | Octokit/Models/Response/Label.cs | Octokit/Models/Response/Label.cs | using System.Diagnostics;
using System.Globalization;
namespace Octokit
{
[DebuggerDisplay("{DebuggerDisplay,nq}")]
public class Label
{
public Label() { }
public Label(long id, string url, string name, string nodeId, string color, string description, bool @default)
{
... | using System.Diagnostics;
using System.Globalization;
namespace Octokit
{
[DebuggerDisplay("{DebuggerDisplay,nq}")]
public class Label
{
public Label() { }
public Label(string url, string name, string nodeId, string color, string description, bool @default)
{
Url = url... | mit | C# |
29677f8895436a0eef540c335b51517a0ec71c78 | bump up version to 1.0.0.5 | Azure/durabletask,yonglehou/durabletask,affandar/durabletask,jasoneilts/durabletask,ddobric/durabletask | Framework/Properties/AssemblyInfo.cs | Framework/Properties/AssemblyInfo.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.... | // ----------------------------------------------------------------------------------
// 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.... | apache-2.0 | C# |
a593f588db95a8ac6b8bb2594c1a94909ade9c5f | Add a test for the realtime room manager | NeoAdonis/osu,UselessToucan/osu,peppy/osu,UselessToucan/osu,ppy/osu,smoogipooo/osu,NeoAdonis/osu,ppy/osu,smoogipoo/osu,peppy/osu,peppy/osu,peppy/osu-new,UselessToucan/osu,NeoAdonis/osu,ppy/osu,smoogipoo/osu,smoogipoo/osu | osu.Game.Tests/Visual/RealtimeMultiplayer/TestSceneRealtimeRoomManager.cs | osu.Game.Tests/Visual/RealtimeMultiplayer/TestSceneRealtimeRoomManager.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.Graphics;
using osu.Game.Online.Multiplayer;
namespace osu.Game.Tests.Visual.RealtimeMultiplayer
{
public class TestSceneR... | mit | C# | |
c105453b7c0f8f742c0db0aa1fbd1b625ccf59ac | Add text builder benchmark | ppy/osu-framework,ppy/osu-framework,ppy/osu-framework,smoogipooo/osu-framework,peppy/osu-framework,peppy/osu-framework,ZLima12/osu-framework,ZLima12/osu-framework,smoogipooo/osu-framework,peppy/osu-framework | osu.Framework.Benchmarks/BenchmarkTextBuilder.cs | osu.Framework.Benchmarks/BenchmarkTextBuilder.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.Threading.Tasks;
using BenchmarkDotNet.Attributes;
using osu.Framework.Graphics.Sprites;
using osu.Framework.Graphics.Textures;
using osu.Framework.Text;
na... | mit | C# | |
afc942b001cb3835f048a57c36f689d8d72669de | Bring TimedExpiryGlyphStore back from the dead | peppy/osu-framework,EVAST9919/osu-framework,smoogipooo/osu-framework,EVAST9919/osu-framework,ZLima12/osu-framework,EVAST9919/osu-framework,ppy/osu-framework,peppy/osu-framework,ppy/osu-framework,peppy/osu-framework,ZLima12/osu-framework,smoogipooo/osu-framework,EVAST9919/osu-framework,ppy/osu-framework | osu.Framework/IO/Stores/TimedExpiryGlyphStore.cs | osu.Framework/IO/Stores/TimedExpiryGlyphStore.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.
// 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.... | mit | C# | |
5ba524bab11adb60580e0d25b5f75f3ef98b2386 | increment version | AzureAD/microsoft-authentication-library-for-dotnet,AzureAD/microsoft-authentication-library-for-dotnet,bjartebore/azure-activedirectory-library-for-dotnet,yamamoWorks/azure-activedirectory-library-for-dotnet,AzureAD/microsoft-authentication-library-for-dotnet,AzureAD/azure-activedirectory-library-for-dotnet,AzureAD/mi... | src/ADAL.Common/CommonAssemblyInfo.cs | src/ADAL.Common/CommonAssemblyInfo.cs | //----------------------------------------------------------------------
// Copyright (c) Microsoft Open Technologies, Inc.
// All Rights Reserved
// Apache License 2.0
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may ob... | //----------------------------------------------------------------------
// Copyright (c) Microsoft Open Technologies, Inc.
// All Rights Reserved
// Apache License 2.0
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may ob... | mit | C# |
cc60ac253a2ac3158c2a93f6d5b5b685605a3bce | upgrade version to 2.0.8 | Aaron-Liu/equeue,tangxuehua/equeue,tangxuehua/equeue,geffzhang/equeue,Aaron-Liu/equeue,geffzhang/equeue,tangxuehua/equeue | src/EQueue/Properties/AssemblyInfo.cs | src/EQueue/Properties/AssemblyInfo.cs | using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// 有关程序集的常规信息通过以下
// 特性集控制。更改这些特性值可修改
// 与程序集关联的信息。
[assembly: AssemblyTitle("EQueue")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyPro... | using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// 有关程序集的常规信息通过以下
// 特性集控制。更改这些特性值可修改
// 与程序集关联的信息。
[assembly: AssemblyTitle("EQueue")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyPro... | mit | C# |
123dc6474cf96f2ab90a02df615f0598c810c22e | Hide logout when not using forms auth | nimore/n2cms,VoidPointerAB/n2cms,SntsDev/n2cms,bussemac/n2cms,n2cms/n2cms,nimore/n2cms,n2cms/n2cms,SntsDev/n2cms,EzyWebwerkstaden/n2cms,EzyWebwerkstaden/n2cms,nicklv/n2cms,VoidPointerAB/n2cms,DejanMilicic/n2cms,nicklv/n2cms,nimore/n2cms,nicklv/n2cms,nimore/n2cms,bussemac/n2cms,EzyWebwerkstaden/n2cms,SntsDev/n2cms,busse... | src/Mvc/MvcTemplates/N2/Top.master.cs | src/Mvc/MvcTemplates/N2/Top.master.cs | using System.Configuration;
using System.Web.Configuration;
namespace N2.Management
{
public partial class Top : System.Web.UI.MasterPage
{
protected override void OnLoad(System.EventArgs e)
{
base.OnLoad(e);
try
{
var section = (AuthenticationSection)ConfigurationManager.GetSection("... |
namespace N2.Management
{
public partial class Top : System.Web.UI.MasterPage
{
}
}
| lgpl-2.1 | C# |
ecd7580bc9a2dc32105b87485a56d1d879f04378 | Create PCGSphereTester.cs | scmcom/unitycode | PCGSphereTester.cs | PCGSphereTester.cs | using UnityEngine;
[RequireComponent(typeof(MeshFilter))]
public class PCGSphereTester : MonoBehaviour {
public int subdivisions = 0;
public float radius = 1f;
private void Awake(){
GetComponent<MeshFilter>().mesh = PCGSphereCreator.Create(subdivisions, radius);
}
}
| mit | C# | |
e400781bd553ce384e4f958af9cf864b99e10c22 | Create GLOBAL.cs | Tech-Curriculums/101-GameDesign-2D-GameDesign-With-Unity | AngryHipsters/GLOBAL.cs | AngryHipsters/GLOBAL.cs | using UnityEngine;
using System.Collections;
public class GLOBAL : MonoBehaviour {
private int glasses = 0;
public int getNumberOfGlasses() {
return glasses;
}
public int Hipped(int hits) {
if (glasses >= 1) {
glasses--;
}
return glasses;
}
public void PlusOne() {
glasses++;
}
}
| mit | C# | |
38eb44fcc5ddbd8151b13d33ffe52815d29c6ae2 | Create Gemstones.cs | SurgicalSteel/Competitive-Programming,SurgicalSteel/Competitive-Programming,SurgicalSteel/Competitive-Programming,SurgicalSteel/Competitive-Programming,SurgicalSteel/Competitive-Programming | Hackerrank/Gemstones.cs | Hackerrank/Gemstones.cs | using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
class Solution {
static void Main(String[] args) {
/* Enter your code here. Read input from STDIN. Print output to STDOUT. Your class should be named Solution */
string temp;
int tc;
temp=Console.Read... | mit | C# | |
5069bdfca2c70bf16bb41aab822dc97c86127e78 | add fix that ensures routing | leotsarev/joinrpg-net,joinrpg/joinrpg-net,leotsarev/joinrpg-net,joinrpg/joinrpg-net,leotsarev/joinrpg-net,leotsarev/joinrpg-net,joinrpg/joinrpg-net,joinrpg/joinrpg-net | JoinRpg.Portal.Test/RoutingTests.cs | JoinRpg.Portal.Test/RoutingTests.cs | using System.Reflection;
using JoinRpg.Portal.Controllers;
using JoinRpg.Portal.Controllers.Common;
using JoinRpg.TestHelpers;
using Microsoft.AspNetCore.Mvc;
using Shouldly;
using Xunit;
namespace JoinRpg.Portal.Test
{
public class RoutingTests
{
[Theory]
[ClassData(typeof(ControllerDataSource... | mit | C# | |
15d5d4c9ef6fbd78a3d44f44987eb6b5353e9d61 | Create LanguagesController.cs | letsbelopez/asp.net-snippets,letsbelopez/asp.net-snippets | LanguagesController.cs | LanguagesController.cs | using Sabio.Web.Models;
using Sabio.Web.Models.ViewModels;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
namespace Sabio.Web.Controllers
{
[Authorize(Roles = "Admin")]
[RoutePrefix("languages")]
public class LanguagesController : BaseController
... | mit | C# | |
262be727fd8f9adaa4ef18ddc5e8832b72fa08ff | Add enums folder and one enum | fredatgithub/UsefulFunctions | FonctionsUtiles.Fred.Csharp/Enums/Result.cs | FonctionsUtiles.Fred.Csharp/Enums/Result.cs | namespace FonctionsUtiles.Fred.Csharp.Enums
{
public enum Result
{
Unknown = 0,
Failure,
Success
}
}
| mit | C# | |
c181c592ce2f42c72902c106115b2767768538be | Create Task.cs | KirillOsenkov/MSBuildTools | test/Task.cs | test/Task.cs | using Microsoft.Build.Framework;
using Microsoft.Build.Utilities;
using System;
using System.Collections.Generic;
namespace HelloTask
{
public class Hello : Task
{
public string YourName { get; set; }
public override bool Execute()
{
Log.LogMessage(MessageImportance.High, "... | mit | C# | |
caecae78cca7e535c16ff498693c1d81cf2e182d | Add cake build script | Cheesebaron/ALRadialMenu | build.cake | build.cake | #tool nuget:?package=GitVersion.CommandLine
#tool nuget:?package=vswhere
#addin nuget:?package=Cake.Incubator
///////////////////////////////////////////////////////////////////////////////
// ARGUMENTS
///////////////////////////////////////////////////////////////////////////////
var target = Argument("target", "De... | mit | C# | |
0ad8d961ddfe781619e3585277bf11a84d88d5dd | Create StaffController.cs | Longfld/ASPNETCoreAngular2,Longfld/ASPNETCoreAngular2,Longfld/ASPNETCoreAngular2,Longfld/ASPNETCoreAngular2 | webapp/src/webapp/Controllers/StaffController.cs | webapp/src/webapp/Controllers/StaffController.cs |
using System.Collections.Generic;
using Microsoft.AspNetCore.Mvc;
namespace webapp
{
[Route("api/[controller]")]
public class StaffController : Controller
{
[HttpGet("GetStaff")]
public IActionResult GetStaff()
{
List<string> model = new List<string>();
... | mit | C# | |
ac09dbba9c5d213fd02ed19534a17d098cbd6a18 | Add min/max examples #762 | mbdavid/LiteDB,89sos98/LiteDB,falahati/LiteDB,falahati/LiteDB,89sos98/LiteDB | LiteDB.Tests/Database/MinMax_Tests.cs | LiteDB.Tests/Database/MinMax_Tests.cs | using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;
using System.IO;
using System.Linq;
namespace LiteDB.Tests.Database
{
#region Model
public class EntityMinMax
{
public int Id { get; set; }
public byte ByteValue { get; set; }
public int IntValue { get; set; }
... | mit | C# | |
8c6f78568a25f204ec100bfbdb8e06c1bbd1be6a | Attach Identity.cs source | jeremyrsellars/no-new-legacy,jeremyrsellars/no-new-legacy,jeremyrsellars/no-new-legacy | posts/Identity.cs | posts/Identity.cs | public class Identity<TSelf, TData> : IEquatable<TSelf>
where TSelf : Identity<TSelf, TData>
where TData : IEquatable<TData>
{
private readonly TData _value;
public Identity(TData value)
{
if (ReferenceEquals(value, null))
throw new ArgumentNu... | isc | C# | |
9dd1600ff367cb1c0b9617a535dac3b69c49d191 | Introduce OrderAttribute and Utils | peppy/osu-framework,peppy/osu-framework,ppy/osu-framework,peppy/osu-framework,smoogipooo/osu-framework,ZLima12/osu-framework,smoogipooo/osu-framework,ppy/osu-framework,ppy/osu-framework,ZLima12/osu-framework | osu.Framework/Utils/OrderAttribute.cs | osu.Framework/Utils/OrderAttribute.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;
namespace osu.Framework.Utils
{
public static class OrderAttributeUtils
{
/// <summary... | mit | C# | |
6abdcc6ccb3769848659f7863cca963d028814f3 | Add LayoutFile class | whampson/cascara,whampson/bft-spec | Cascara/Src/LayoutFile.cs | Cascara/Src/LayoutFile.cs | #region License
/* Copyright (c) 2017 Wes Hampson
*
* 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 without limitation the rights
* to use, copy, modify, ... | mit | C# | |
143d7ab640b588569e5dc31bd0d87f79b8a78401 | Add test scene for spinner rotation | ppy/osu,peppy/osu,peppy/osu-new,ZLima12/osu,UselessToucan/osu,UselessToucan/osu,UselessToucan/osu,johnneijzen/osu,peppy/osu,ppy/osu,ppy/osu,2yangk23/osu,smoogipoo/osu,ZLima12/osu,smoogipooo/osu,NeoAdonis/osu,johnneijzen/osu,smoogipoo/osu,NeoAdonis/osu,smoogipoo/osu,2yangk23/osu,peppy/osu,NeoAdonis/osu,EVAST9919/osu,EVA... | osu.Game.Rulesets.Osu.Tests/TestSceneSpinnerRotation.cs | osu.Game.Rulesets.Osu.Tests/TestSceneSpinnerRotation.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.Allocation;
using osu.Framework.Audio;
using osu.Framework.Logging;
using osu.Framework.MathUtils;
using osu.Framework.Testing... | mit | C# | |
c8ff5acec2a511a3e2d60673d419f9798b275e2e | Add RID unit tests. | lecaillon/Evolve | test/Evolve.Core.Test/Utilities/RIDTest.cs | test/Evolve.Core.Test/Utilities/RIDTest.cs | using Evolve.Utilities;
using Xunit;
namespace Evolve.Core.Test.Utilities
{
public class RIDTest
{
[Theory(DisplayName = "RID_ToString_must_extract_metadata")]
[InlineData((string)null, "RID: [] OS: [], Version: [], Architecture: []")]
[InlineData("", "RID: [] OS: [], Version: [], Arch... | mit | C# | |
2de560d6644a7f73aa6e5b35cd5e0254d02c05db | Add a factory for Property path element | Domysee/Pather.CSharp | src/Pather.CSharp/PathElements/PropertyFactory.cs | src/Pather.CSharp/PathElements/PropertyFactory.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
namespace Pather.CSharp.PathElements
{
public class PropertyFactory : IPathElementFactory
{
public IPathElement Create(string pathElement)
{
return... | mit | C# | |
c0bb234f30026b7d9438a2ed815e25ecc688549d | Create SmsController.cs | TwilioDevEd/api-snippets,TwilioDevEd/api-snippets,TwilioDevEd/api-snippets,TwilioDevEd/api-snippets,TwilioDevEd/api-snippets,TwilioDevEd/api-snippets,TwilioDevEd/api-snippets,TwilioDevEd/api-snippets,TwilioDevEd/api-snippets,TwilioDevEd/api-snippets,TwilioDevEd/api-snippets,TwilioDevEd/api-snippets | quickstart/csharp/sms/receive-sms-core/SmsController.cs | quickstart/csharp/sms/receive-sms-core/SmsController.cs | // Code sample for ASP.NET Core on .NET Core
// From command prompt, run:
// dotnet add package Twilio.AspNet.Core
using Twilio.AspNet.Common;
using Twilio.AspNet.Core;
using Twilio.TwiML;
namespace YourNewWebProject.Controllers
{
public class SmsController : TwilioController
{
public TwiMLResult Inde... | mit | C# | |
5c86c502ad610d755791d8370e93e5c0b80c743b | Create HttpJsonTarget.cs | jupe/NLog.HttpJsonTarget | HttpJsonTarget.cs | HttpJsonTarget.cs | using System;
using System.IO;
using System.Net;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using NLog.Common;
using NLog.Config;
using NLog.Layouts;
using NLog.Targets;
namespace NLog.Targets
{
[Target("HttpJsonTarget")]
public sealed class HttpJsonTarget : Target
{
[RequiredParameter]
... | mit | C# | |
076fe91611858d47cc351b512b9d3d58663b1248 | Add tests for RNG | ektrah/nsec | tests/Core/RandomTests.cs | tests/Core/RandomTests.cs | using System;
using NSec.Cryptography;
using Xunit;
namespace NSec.Tests.Core
{
public static class RandomTests
{
#region GenerateBytes #1
[Fact]
public static void GenerateBytesWithNegativeCount()
{
Assert.Throws<ArgumentOutOfRangeException>("count", () => SecureRa... | mit | C# | |
95367b8eecc8cce8b58a55cfdfc6a3764f1b27e3 | Create program.cs | justynak2/indywidualne | program.cs | program.cs | int a =2;
| mit | C# | |
22438a4bf6a4c92067c8db9bb6baf45514d9e6b0 | Create Transmitter.cs | Pharap/SpengyUtils | Examples/SimpleCommandSystem/Transmitter.cs | Examples/SimpleCommandSystem/Transmitter.cs | // Instructions:
// 1. Place script in programmable block
// 2. Assign programmable block to antenna named "Antenna"
public void Broadcast(string name, string message)
{
var antenna = GridTerminalSystem.GetBlockWithName(name) as IMyRadioAntenna;
antenna.TransmitMessage(message);
}
public void Main(string arg... | apache-2.0 | C# | |
9cbf925947d9b7ff6000bd866bae19be8badc39a | introduce TsProjectFile | isukces/isukces.code | isukces.code/Typescript/_project/TsProjectFile.cs | isukces.code/Typescript/_project/TsProjectFile.cs | using System;
using System.IO;
namespace isukces.code.Typescript
{
/// <summary>
/// Helps to manage relations between ts files
/// </summary>
public class TsProjectFile
{
public TsProjectFile(TsFile file, DirectoryInfo webProjectRoot, DirectoryInfo resultFileDir)
{
File... | mit | C# | |
cc64c7e4b08c6878aefa16336ee41a654b87734c | Bump version number | mjanthony/Huxley,Newsworthy/Huxley,jpsingleton/Huxley,mjanthony/Huxley,jpsingleton/Huxley,Newsworthy/Huxley | src/Huxley/Properties/AssemblyInfo.cs | src/Huxley/Properties/AssemblyInfo.cs | using System.Reflection;
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.
[assembly: AssemblyTitle("Huxley")]
[assembly: AssemblyDes... | using System.Reflection;
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.
[assembly: AssemblyTitle("Huxley")]
[assembly: AssemblyDes... | agpl-3.0 | C# |
6f661f15a1fc3c010d6c2a9da077085ceb84c2b2 | Add spline easing class | wieslawsoltes/Perspex,AvaloniaUI/Avalonia,AvaloniaUI/Avalonia,AvaloniaUI/Avalonia,wieslawsoltes/Perspex,SuperJMN/Avalonia,SuperJMN/Avalonia,jkoritzinsky/Avalonia,jkoritzinsky/Avalonia,SuperJMN/Avalonia,wieslawsoltes/Perspex,wieslawsoltes/Perspex,SuperJMN/Avalonia,jkoritzinsky/Avalonia,Perspex/Perspex,AvaloniaUI/Avaloni... | src/Avalonia.Animation/Easing/SplineEasing.cs | src/Avalonia.Animation/Easing/SplineEasing.cs | namespace Avalonia.Animation.Easings
{
/// <summary>
/// Eases a <see cref="double"/> value
/// using a user-defined cubic bezier curve.
/// Good for custom easing functions that doesn't quite
/// fit with the built-in ones.
/// </summary>
public class SplineEasing : Easing
{
//... | mit | C# | |
0552a676747b4721b72133e4ec71f9b1c409bb7b | Add test | bgTeamDev/bgTeam.Core,bgTeamDev/bgTeam.Core | tests/Test.bgTeam.Core/Tests/Test_Helpers.cs | tests/Test.bgTeam.Core/Tests/Test_Helpers.cs | using bgTeam.Core.Helpers;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Text;
using System.Threading.Tasks;
using Xunit;
namespace Test.bgTeam.Core.Tests
{
public class Test_Helpers
{
[Fact]
public void ConfigHelper_I... | mit | C# | |
eeaf463f917a991121abb7bb1201c9a4ee845b78 | Test detouring empty methods | AngelDE98/MonoMod,0x0ade/MonoMod | MonoMod.UnitTest/RuntimeDetour/DetourEmptyTest.cs | MonoMod.UnitTest/RuntimeDetour/DetourEmptyTest.cs | #pragma warning disable CS1720 // Expression will always cause a System.NullReferenceException because the type's default value is null
#pragma warning disable xUnit1013 // Public method should be marked as test
using Xunit;
using MonoMod.RuntimeDetour;
using System;
using System.Reflection;
using System.Runtime.Comp... | mit | C# | |
97ca5a4df499834a843cca4e64042a77fce9c5dd | Create DEB.cs | etormadiv/njRAT_0.7d_Stub_ReverseEngineering | j_csharp/OK/DEB.cs | j_csharp/OK/DEB.cs | //Reversed by Etor Madiv
public static string DEB(ref string s)
{
byte[] data = System.Convert.FromBase64String(s);
return BS(ref data);
}
| unlicense | C# | |
79c3dda0346d66766bf852da495f1595354f01a0 | sort questions | jackzhenguo/leetcode-csharp | Sort/WiggleSortSln.cs | Sort/WiggleSortSln.cs | /* ==============================================================================
* 功能描述:WiggleSort
* 创 建 者:gz
* 创建日期:2017/5/31 14:02:01
* ==============================================================================*/
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namesp... | mit | C# | |
c3245f8d89bdb988ad86a2f1991a24002574045a | Add HttpModule | whongxiao/Refactor-Bruce-Blog,whongxiao/Refactor-Bruce-Blog,whongxiao/Refactor-Bruce-Blog,whongxiao/Refactor-Bruce-Blog,whongxiao/Refactor-Bruce-Blog | blog/App_Code/NHibernateBindCurrentSession.cs | blog/App_Code/NHibernateBindCurrentSession.cs | using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using NHibernate;
using NHibernate.Context;
using NHibernateUtility;
//... | apache-2.0 | C# | |
f1d8f9514ed90283d74fa5594fc0da0748fb8280 | Rename task_1_3_8_4.cs to task_1_3_8_5.cs | AndrewTurlanov/ANdrew | task_1_3_8_5.cs | task_1_3_8_5.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp1
{
class Program
{
static void Main(string[] args)
{
/*
Сделать метод DrawPyramid который принимает 1 параметр типа int size.
... | apache-2.0 | C# | |
c522ef1a0f12237b8c65822835f125c0a3696640 | Create GravityCenter.cs | scmcom/unitycode | GravityCenter.cs | GravityCenter.cs | using UnityEngine;
using System.Collections;
[RequireComponent(typeof(Rigidbody))]
public class GravityCenter : MonoBehaviour {
// Rigidbody rigidbody;
public Rigidbody rb;
public Rigidbody rb2;
// public Transform pi;
// public Transform twopi;
// public float orbitTime = 1.0f;
// private float startTime;
void S... | mit | C# | |
e75263bf6ca89563550cf7f32548905bd2203bd4 | Add Rect <-> Vector2i collisions | neon2d/neonGL,neon2d/neon2d,DontBelieveMe/neon2d | neon2d/neon2d/Physics.cs | neon2d/neon2d/Physics.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using neon2d.Math;
namespace neon2d.Physics
{
public class Rect
{
public float x, y;
public float width, height;
public Rect(int x, int y, int width, int height)
... | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using neon2d.Math;
namespace neon2d.Physics
{
public class Rect
{
public float x, y;
public float width, height;
public Rect(int x, int y, int width, int height)
... | mit | C# |
ce48dc84ad3bf22563226862e7071bb7fd830f7c | Create MsBuildLogger.cs | sobercoder/msbuild-api-hacks | MsBuildLogger.cs | MsBuildLogger.cs | using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.Build.Framework;
using Microsoft.Build.Utilities;
public class MsBuildLogger : Logger
{
private StringBuilder errorLog = new StringBuilder();
/// <summary>
/// This will gather error info about the projects being built
/// </summar... | unlicense | C# | |
3d7d1d39ab148732bc374a474750c86c0aaa44c4 | Add test for PeerList | BYVoid/distribox | src/Distribox.Network/PeerListTest.cs | src/Distribox.Network/PeerListTest.cs | namespace Distribox.Network
{
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using NUnit.Framework;
[TestFixture]
class PeerListTest
{
[Test]
public void TestOperation()
{
string fileName = ... | mit | C# | |
6a5d3138e683fd4ee143b3b61c3f9a9b3487df71 | Add support for LoadRules and ExtractRules commands | agardiner/hfmcmd,agardiner/hfmcmd,agardiner/hfmcmd | src/hfm/RulesLoad.cs | src/hfm/RulesLoad.cs | using System;
using System.IO;
using log4net;
using HSVSESSIONLib;
using HSVRULESLOADACVLib;
using HFMCONSTANTSLib;
using Command;
using HFMCmd;
namespace HFM
{
public class RulesLoad
{
/// <summary>
/// Defines the possible rule file formats.
/// </summary>
public enum ERu... | bsd-2-clause | C# | |
a82e52b6255e11785820b2828c5ce62899fc7c17 | fix bookshelf | MediaBrowser/Emby.Plugins,SvenVandenbrande/Emby.Plugins,SvenVandenbrande/Emby.Plugins,MediaBrowser/Emby.Plugins,SvenVandenbrande/Emby.Plugins,heksesang/Emby.Plugins,heksesang/Emby.Plugins,heksesang/Emby.Plugins | Bookshelf/Plugin.cs | Bookshelf/Plugin.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using MBBookshelf.Configuration;
using MediaBrowser.Common.Configuration;
using MediaBrowser.Common.Plugins;
using MediaBrowser.Model.Plugins;
using MediaBrowser.Model.Serializati... | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using MBBookshelf.Configuration;
using MediaBrowser.Common.Configuration;
using MediaBrowser.Common.Plugins;
using MediaBrowser.Model.Plugins;
using MediaBrowser.Model.Serializati... | mit | C# |
c53ec61945df55c803e45e5506b71e06c18387c5 | Add PostHelper | Aux/NTwitch,Aux/NTwitch | src/NTwitch.Rest/Entities/Feeds/PostHelper.cs | src/NTwitch.Rest/Entities/Feeds/PostHelper.cs | using System;
using System.Collections.Generic;
using System.Threading.Tasks;
namespace NTwitch.Rest
{
internal class PostHelper
{
public static Task CreateReactionAsync(RestPostComment post, ulong emoteid)
{
throw new NotImplementedException();
}
public static Tas... | mit | C# | |
dd38e718fc82b1b3c60f1f807594e8e71176bf40 | Add redirect. | Giftednewt/roslyn,swaroop-sridhar/roslyn,genlu/roslyn,AnthonyDGreen/roslyn,tannergooding/roslyn,bbarry/roslyn,Giftednewt/roslyn,jhendrixMSFT/roslyn,DustinCampbell/roslyn,cston/roslyn,tvand7093/roslyn,bkoelman/roslyn,TyOverby/roslyn,dpoeschl/roslyn,srivatsn/roslyn,agocke/roslyn,Shiney/roslyn,shyamnamboodiripad/roslyn,ag... | src/VisualStudio/Setup.Next/AssemblyRedirects.cs | src/VisualStudio/Setup.Next/AssemblyRedirects.cs | // Copyright (c) Microsoft. All Rights Reserved. Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using Microsoft.VisualStudio;
using Microsoft.VisualStudio.Shell;
using Roslyn.VisualStudio.Setup;
[assembly: ProvideRoslynBindingRedirection("Microsoft.Code... | // Copyright (c) Microsoft. All Rights Reserved. Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using Microsoft.VisualStudio;
using Microsoft.VisualStudio.Shell;
using Roslyn.VisualStudio.Setup;
[assembly: ProvideRoslynBindingRedirection("Microsoft.Code... | mit | C# |
1bb62020c9e1749e27083c2c2c8fe2d9a7765ab1 | add category extensions | arrowflex/FreeAgent | src/FreeAgent/ModelExtensions/CategoryExtensions.cs | src/FreeAgent/ModelExtensions/CategoryExtensions.cs | using FreeAgent.Model;
using System;
using System.Threading.Tasks;
using FreeAgent.Helpers;
namespace FreeAgent
{
public static class CategoryExtensions
{
public static async Task<Categories> GetCategoriesAsync(this FreeAgentClient client)
{
var result = await client.Execute(c => c... | apache-2.0 | C# | |
893adb15869b72062ed411388ce7a66127107413 | Add UptimeController | OlsonDev/PersonalWebApp,OlsonDev/PersonalWebApp | Controllers/UptimeController.cs | Controllers/UptimeController.cs | using System;
using System.Globalization;
using Microsoft.AspNet.Mvc;
namespace PersonalWebApp.Controllers {
public class UptimeController : Controller {
public IActionResult Ping() {
return Content(DateTime.Now.ToString("o"));
}
}
} | mit | C# | |
219990b0785df14f5f7fc96cdb79f0d0cbd379c0 | Add test vector from draft-arciszewski-xchacha-00 | ektrah/nsec | tests/Rfc/XChaCha20Poly1305Tests.cs | tests/Rfc/XChaCha20Poly1305Tests.cs | using System;
using NSec.Cryptography;
using NSec.Experimental.Sodium;
using Xunit;
namespace NSec.Tests.Rfc
{
public static class XChaCha20Poly1305Tests
{
public static readonly TheoryData<string[]> TestVectors = new TheoryData<string[]>
{
// https://tools.ietf.org/html/draft-arcis... | mit | C# | |
b06785c4964e0d86fe2e2e0050b9aaae81c164ab | Add IPartitioner interface | mayuanyang/MapReduce.Net | src/MapReduce.Net/IPartitioner.cs | src/MapReduce.Net/IPartitioner.cs | namespace MapReduce.Net
{
public interface IPartitioner
{
//Don't know what to do with this one yet
}
}
| apache-2.0 | C# | |
76648cb01faada63d3a68b49066d615967e9111d | Add video object tests | RehanSaeed/Schema.NET | Tests/Schema.NET.Test/VideoObjectTest.cs | Tests/Schema.NET.Test/VideoObjectTest.cs | namespace Schema.NET.Test
{
using System;
using System.Collections.Generic;
using System.Text;
using Xunit;
public class VideoObjectTest
{
// https://developers.google.com/search/docs/data-types/articles
[Fact]
public void ToString_VideoGoogleStructuredData_ReturnsExpec... | mit | C# | |
c1ae775c7ce1cbe5ec86da87be8a8c7b92c3a051 | Add extension method to provide drawable adjustments | ZLima12/osu-framework,EVAST9919/osu-framework,EVAST9919/osu-framework,ZLima12/osu-framework,EVAST9919/osu-framework,peppy/osu-framework,EVAST9919/osu-framework,ppy/osu-framework,smoogipooo/osu-framework,peppy/osu-framework,ppy/osu-framework,peppy/osu-framework,smoogipooo/osu-framework,ppy/osu-framework | osu.Framework/Graphics/DrawableExtensions.cs | osu.Framework/Graphics/DrawableExtensions.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;
namespace osu.Framework.Graphics
{
/// <summary>
/// Holds extension methods for <see cref="Drawable"/>.
/// </summary>
public static class... | mit | C# | |
49d3a3af15e8d6d57a8fe55c51402ff3e14f3849 | Adjust FinishedLaunching() structure | andypaul/monotouch-samples,kingyond/monotouch-samples,YOTOV-LIMITED/monotouch-samples,haithemaraissia/monotouch-samples,peteryule/monotouch-samples,hongnguyenpro/monotouch-samples,a9upam/monotouch-samples,iFreedive/monotouch-samples,W3SS/monotouch-samples,davidrynn/monotouch-samples,sakthivelnagarajan/monotouch-samples... | OpenGLESSample-GameView/Main.cs | OpenGLESSample-GameView/Main.cs | using UIKit;
namespace OpenGLESSampleGameView
{
public class Application
{
static void Main (string[] args)
{
UIApplication.Main (args);
}
}
}
| mit | C# | |
8f3cca975e247432c825e3afcdc2961c9b45e4f0 | remove debug code | DecaTec/windows-universal,scherke85/windows-universal,scherke/windows-universal,SunboX/windows-universal,scherke/windows-universal,altima/windows-universal,altima/windows-universal,SunboX/windows-universal,TheScientist/windows-universal,altima/windows-universal,scherke85/windows-universal,TheScientist/windows-universal... | NextcloudApp/AppShell.xaml.cs | NextcloudApp/AppShell.xaml.cs | using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
using NextcloudApp.Services;
namespace NextcloudApp
{
public sealed partial class AppShell
{
public AppShell()
{
InitializeComponent();
ShowUpdateMessage();
}
private void ShowUpdateMessage()
... | using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
using NextcloudApp.Services;
namespace NextcloudApp
{
public sealed partial class AppShell
{
public AppShell()
{
InitializeComponent();
ShowUpdateMessage();
}
private void ShowUpdateMessage()
... | mpl-2.0 | C# |
c6b15fd523a83dc0336ec9add90f6e0188dbe52b | Create InvocationHelper.cs | smusenok/misc | InvocationHelper.cs | InvocationHelper.cs | using System;
using System.Linq;
using System.Linq.Expressions;
using System.Reflection;
namespace Temp
{
class Program
{
static void Main()
{
var method = GetInvoker(typeof(My).GetMethod("Get"));
var param = new object[] { 500, 0, 1 };
try { method(new My(),... | mit | C# | |
94bd1270ac849b5f29cddc24edb132815e7d23f8 | Remove unused using. | lorcanmooney/roslyn,sharwell/roslyn,AnthonyDGreen/roslyn,jasonmalinowski/roslyn,vslsnap/roslyn,brettfo/roslyn,zooba/roslyn,MichalStrehovsky/roslyn,akrisiun/roslyn,tmat/roslyn,AlekseyTs/roslyn,nguerrera/roslyn,jmarolf/roslyn,bkoelman/roslyn,vslsnap/roslyn,eriawan/roslyn,mavasani/roslyn,diryboy/roslyn,CyrusNajmabadi/rosl... | src/Features/CSharp/Portable/InlineDeclaration/CSharpInlineDeclarationCodeFixProvider.InlineDeclarationFixAllProvider.cs | src/Features/CSharp/Portable/InlineDeclaration/CSharpInlineDeclarationCodeFixProvider.InlineDeclarationFixAllProvider.cs | // Copyright (c) Microsoft. All Rights Reserved. Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using System.Collections.Immutable;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.CodeFixes;
using Microsoft.CodeAnalysi... | // Copyright (c) Microsoft. All Rights Reserved. Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using System.Collections.Immutable;
using System.Composition;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.CodeFixes;
u... | mit | C# |
5c98554e0594eac5f67a7893ebeb0340588500a3 | Add license | waltersoto/PortableMD5 | PortableMD5/PortableMD5/MD5Extensions.cs | PortableMD5/PortableMD5/MD5Extensions.cs | /*
The MIT License (MIT)
Copyright (c) 2015 Walter M. Soto Reyes
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 without limitation the rights
to use, copy, modify... | using System;
using System.Text;
namespace PortableMD5
{
public static class Md5Extensions
{
public static uint RotateLeft(this uint val, int count)
{
return (val << count) | (val >> (32 - count));
}
public static uint RotateRight(this uint val, int count)
... | mit | C# |
03c5282f4c28f4179d10b2db7b7e636da06bac14 | Remove unused deconstructor | physhi/roslyn,bartdesmet/roslyn,tannergooding/roslyn,sharwell/roslyn,mavasani/roslyn,diryboy/roslyn,wvdd007/roslyn,mgoertz-msft/roslyn,jasonmalinowski/roslyn,jasonmalinowski/roslyn,AlekseyTs/roslyn,AlekseyTs/roslyn,AlekseyTs/roslyn,sharwell/roslyn,CyrusNajmabadi/roslyn,weltkante/roslyn,tmat/roslyn,CyrusNajmabadi/roslyn... | src/Features/Core/Portable/InlineHints/TypeHint.cs | src/Features/Core/Portable/InlineHints/TypeHint.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Diagnostics;
using Microsoft.CodeAnalysis.Text;
namespace Microso... | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Diagnostics;
using Microsoft.CodeAnalysis.Text;
namespace Microso... | mit | C# |
f8632d8c3072de9cc1b13700c0c2d828bfefea3b | Add new exception type | aNutForAJarOfTuna/kafka-net,PKRoma/kafka-net,CenturyLinkCloud/kafka-net,nightkid1027/kafka-net,geffzhang/kafka-net,gigya/KafkaNetClient,BDeus/KafkaNetClient,bridgewell/kafka-net,martijnhoekstra/kafka-net,EranOfer/KafkaNetClient,Jroland/kafka-net | kafka-net/Protocol.cs | kafka-net/Protocol.cs | using System;
namespace KafkaNet
{
public enum ApiKeyRequestType
{
Produce = 0,
Fetch = 1,
Offset = 2,
MetaData = 3,
LeaderAndIsr = 4,
StopReplica = 5,
OffsetCommit = 6,
OffsetFetch = 7
}
public enum ErrorResponseCode
{
NoErr... | using System;
namespace KafkaNet
{
public enum ApiKeyRequestType
{
Produce = 0,
Fetch = 1,
Offset = 2,
MetaData = 3,
LeaderAndIsr = 4,
StopReplica = 5,
OffsetCommit = 6,
OffsetFetch = 7
}
public enum ErrorResponseCode
{
NoErr... | apache-2.0 | C# |
428a09be874e01d80c007a631491797ad7c8cff5 | Create GetBCPHighScoreNotification.cs | missionpinball/unity-bcp-server | Assets/BCP/Scripts/PlayMaker/GetBCPHighScoreNotification.cs | Assets/BCP/Scripts/PlayMaker/GetBCPHighScoreNotification.cs | using UnityEngine;
using System;
using HutongGames.PlayMaker;
using TooltipAttribute = HutongGames.PlayMaker.TooltipAttribute;
/// <summary>
/// Custom PlayMaker action for MPF that sends an Event when a high_score_enter_initials BCP Trigger
/// command is received.
/// </summary>
[ActionCategory("BCP")]
[Tooltip("S... | mit | C# | |
011ca99ee6ee449b90b5f041b18639edfc9ce760 | Add Nuget Reference | monoman/NugetCracker,monoman/NugetCracker | NugetCracker/Components/NugetReference.cs | NugetCracker/Components/NugetReference.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NugetCracker.Interfaces;
using System.Text.RegularExpressions;
namespace NugetCracker.Components
{
public class NugetReference : IComponent
{
public NugetReference(string name, string versions)
{
Name = n... | apache-2.0 | C# | |
90b5101b8ccd284cd340e99b44a95f04c3c0d4bc | Create HUD.cs | ryskulova/UnityGame | HUD.cs | HUD.cs | using UnityEngine;
using System.Collections;
public class HUD : MonoBehaviour {
public GameObject Player1;
public GameObject Player2;
public BoxCollider2D topWall;
public BoxCollider2D bottomWall;
public BoxCollider2D leftWall;
public BoxCollider2D rightWall;
}
| mit | C# | |
cbeaa458968a6e6c528b273228bbbb9713679295 | Add test (#1879) | oxwanawxo/Newtonsoft.Json,jkorell/Newtonsoft.Json,JamesNK/Newtonsoft.Json,bfriesen/Newtonsoft.Json,PKRoma/Newtonsoft.Json,ze-pequeno/Newtonsoft.Json,brjohnstmsft/Newtonsoft.Json,TylerBrinkley/Newtonsoft.Json | Src/Newtonsoft.Json.Tests/Issues/Issue1877.cs | Src/Newtonsoft.Json.Tests/Issues/Issue1877.cs | #region License
// Copyright (c) 2007 James Newton-King
//
// 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 without limitation the rights to use,
// copy,... | mit | C# | |
0e5df3783eeae7ba25ee926601a94fa21317d113 | Create SceneSwitcherWindow.cs | UnityCommunity/UnityLibrary | Assets/Scripts/Editor/Tools/SceneSwitcherWindow.cs | Assets/Scripts/Editor/Tools/SceneSwitcherWindow.cs |
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
using System.Collections;
using System.Collections.Generic;
using UnityEn... | mit | C# | |
adb69df4efc0ddc92e46c058b4ee129050aa1b57 | fix warning CS0162: Unreachable code detected in Log.cs | wenyanw/FakeItEasy,wenyanw/FakeItEasy,adamralph/FakeItEasy,FakeItEasy/FakeItEasy,blairconrad/FakeItEasy,FakeItEasy/FakeItEasy,khellang/FakeItEasy,adamralph/FakeItEasy,robvanschelven/FakeItEasy,jamiehumphries/FakeItEasy,thomaslevesque/FakeItEasy,CedarLogic/FakeItEasy,robvanschelven/FakeItEasy,CedarLogic/FakeItEasy,jamie... | Source/FakeItEasy/Log.cs | Source/FakeItEasy/Log.cs | namespace FakeItEasy
{
using System;
using System.Diagnostics.CodeAnalysis;
internal static class Log
{
static Log()
{
UseLogging = false;
}
private static bool UseLogging { get; set; }
public static Logger GetLogger<T>()
{
... | namespace FakeItEasy
{
using System;
using System.Diagnostics.CodeAnalysis;
internal static class Log
{
#if DEBUG
private const bool UseLogging = false;
#else
private const bool UseLogging = false;
#endif
public static Logger GetLogger<T>()
{
... | mit | C# |
363a237d2d1053a6a17fb4e04877e128d61e3222 | Create IProtocol.cs | poostwoud/discovery | src/Protocol/IProtocol.cs | src/Protocol/IProtocol.cs | public interface IProtocol
{
void Append();
void Partial();
string Read(Uri uri, string userName = "", string password = "");
void Remove();
void Replace();
}
| mit | C# | |
231f08f6669073a341bc3e9fdf4c86bdcae340a0 | Add ImageValueConverter. | cube-soft/Cube.Core,cube-soft/Cube.Core | Converters/ImageValueConverter.cs | Converters/ImageValueConverter.cs | /* ------------------------------------------------------------------------- */
//
// Copyright (c) 2010 CubeSoft, 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-2.0 | C# | |
e5260f5758c53df202e44d3aaca5ec4724c838d6 | Fix warnings in unit tests flagged by MSBuild Log | github/VisualStudio,github/VisualStudio,github/VisualStudio | test/GitHub.Exports.UnitTests/GlobalSuppressions.cs | test/GitHub.Exports.UnitTests/GlobalSuppressions.cs |
// This file is used by Code Analysis to maintain SuppressMessage
// attributes that are applied to this project.
// Project-level suppressions either have no target or are given
// a specific target and scoped to a namespace, type, member, etc.
[assembly: System.Diagnostics.CodeAnalysis.SuppressMessage("Naming", ... | mit | C# | |
cc7d4598664b8119a820406722962f9f03f5332b | Add a button press example | DuFF14/OSVR-Unity,grobm/OSVR-Unity,grobm/OSVR-Unity,JeroMiya/OSVR-Unity,OSVR/OSVR-Unity | OSVR-Unity/Assets/scripts/HandleButtonPress.cs | OSVR-Unity/Assets/scripts/HandleButtonPress.cs | using UnityEngine;
using System.Collections;
public class HandleButtonPress : MonoBehaviour {
public OSVR.Unity.OSVRClientKit clientKit;
public OSVR.Unity.InterfaceCallbacks cb;
public void Start() {
GetComponent<OSVR.Unity.InterfaceCallbacks> ().RegisterCallback (handleButton);
}
public void handleButton(... | apache-2.0 | C# | |
c662e718aef36d5e50194c39e291a2bce1bc0c87 | Test fix | MikhailArkhipov/RTVS,AlexanderSher/RTVS,karthiknadig/RTVS,AlexanderSher/RTVS,MikhailArkhipov/RTVS,AlexanderSher/RTVS,MikhailArkhipov/RTVS,AlexanderSher/RTVS,karthiknadig/RTVS,karthiknadig/RTVS,MikhailArkhipov/RTVS,MikhailArkhipov/RTVS,karthiknadig/RTVS,MikhailArkhipov/RTVS,karthiknadig/RTVS,AlexanderSher/RTVS,Alexander... | src/R/Components/Test/Script/InstallPackagesTest.cs | src/R/Components/Test/Script/InstallPackagesTest.cs | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.
using System;
using System.Diagnostics.CodeAnalysis;
using FluentAssertions;
using Microsoft.Common.Core.Install;
using Microsoft.Common.Core.Test.Install;
using Mic... | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.
using System;
using System.Diagnostics.CodeAnalysis;
using FluentAssertions;
using Microsoft.Common.Core.Install;
using Microsoft.Common.Core.Test.Install;
using Mic... | mit | C# |
405069dd9830c115bc4fe043a180b67e8370c066 | Add SGD | kawatan/Milk | Megalopolis/Optimizers/SGD.cs | Megalopolis/Optimizers/SGD.cs | using System;
namespace Megalopolis.Optimizers
{
public class SGD
{
public double lr = 0.001; // Learning rate
public SGD() { }
public SGD(double lr)
{
this.lr = lr;
}
public double Optimize(int index, double weight, double gradient)
{
... | apache-2.0 | C# | |
6dff62e0d09feae2e3d9bb9d29319f1aa4db5390 | Create C#.cs | TobitSoftware/chayns-snippets,TobitSoftware/chayns-snippets,TobitSoftware/chayns-snippets,TobitSoftware/chayns-snippets | Backend/EmailToGroup/C#.cs | Backend/EmailToGroup/C#.cs | import RestSharp;
public class MailDto
{
public string Headline { get; set; }
public string Text { get; set; }
public string Greeting { get; set; }
public string Subject { get; set; }
public List<int> UacIds { get; set; }
public List<int> UserIds { get; set; }
}
public string Server = "https:/... | mit | C# | |
c575a259142ffb4424433658c35ee2d041c40594 | Create simple-targets.csx | adamralph/simple-targets-csx | simple-targets.csx | simple-targets.csx | using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
public class Target
{
private string[] inputs = new string[0];
private string[] outputs = new string[0];
private string[] dependOn = new string[0];
public string[] Inputs
{
get { return this.inputs; }
... | mit | C# |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.