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 |
|---|---|---|---|---|---|---|---|---|
251f0f1b204f5a9c5951fd7e0da687f183a48edd | Create ColorPresets.cs | judah4/HSV-Color-Picker-Unity | ColorPresets.cs | ColorPresets.cs | using UnityEngine;
using UnityEngine.UI;
public class ColorPresets : MonoBehaviour
{
public ColorPicker picker;
public GameObject[] presets;
public Image createPresetImage;
void Awake()
{
// picker.onHSVChanged.AddListener(HSVChanged);
picker.onValueChanged.AddListener(ColorChanged);
}
public void CreatePr... | mit | C# | |
40434efd41726bfdb224893438f13aa06df349e8 | Add ProxyLexer | StevenLiekens/TextFx,StevenLiekens/Txt | src/Txt/ProxyLexer.cs | src/Txt/ProxyLexer.cs | using System;
namespace Txt
{
public sealed class ProxyLexer<TElement> : Lexer<TElement>
where TElement : Element
{
private ILexer<TElement> innerLexer;
public void Initialize(ILexer<TElement> lexer)
{
if (lexer == null)
{
throw new Argu... | mit | C# | |
c226fdca12ff1f5b20ba675f5d1a7a33dbb727ec | Introduce `Ref` type | rexm/Handlebars.Net,rexm/Handlebars.Net | source/Handlebars/Runtime/Ref.cs | source/Handlebars/Runtime/Ref.cs | using System.Runtime.CompilerServices;
namespace HandlebarsDotNet.Runtime
{
public class Ref<T> where T: class
{
private readonly Ref<T> _parent;
private T _value;
public T Value
{
[MethodImpl(MethodImplOptions.AggressiveInlining)]
get => _value ?? _pare... | mit | C# | |
b0679f3c2af35d567a7419e62c3ab7785934be4a | Add query | xin9le/DeclarativeSql | src/DeclarativeSql/Sql/Query.cs | src/DeclarativeSql/Sql/Query.cs | namespace DeclarativeSql.Sql
{
/// <summary>
/// Represents a query statement and parameter pair.
/// </summary>
public sealed class Query
{
#region Properties
/// <summary>
/// Gets SQL statement.
/// </summary>
public string Statement { get; }
///... | mit | C# | |
eef975c43542149fc489ffe603359ca259fdab08 | Add unit test for CreateExtractJobOptions | jskeet/google-cloud-dotnet,benwulfe/google-cloud-dotnet,evildour/google-cloud-dotnet,chrisdunelm/gcloud-dotnet,googleapis/google-cloud-dotnet,iantalarico/google-cloud-dotnet,evildour/google-cloud-dotnet,jskeet/google-cloud-dotnet,iantalarico/google-cloud-dotnet,googleapis/google-cloud-dotnet,iantalarico/google-cloud-do... | apis/Google.Cloud.BigQuery.V2/Google.Cloud.BigQuery.V2.Tests/CreateExtractJobOptionsTest.cs | apis/Google.Cloud.BigQuery.V2/Google.Cloud.BigQuery.V2.Tests/CreateExtractJobOptionsTest.cs | // Copyright 2017 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applic... | apache-2.0 | C# | |
dab893482d27cf737ad0dc06398ece4043dc524c | Create Program.cs | nkesic/multivalue-lab,codedecay/multivalue-lab,nkesic/multivalue-lab,nkesic/multivalue-lab,RocketSoftware/multivalue-lab,codedecay/multivalue-lab,codedecay/multivalue-lab,RocketSoftware/multivalue-lab,nkesic/multivalue-lab,RocketSoftware/multivalue-lab,nkesic/multivalue-lab,codedecay/multivalue-lab,RocketSoftware/multi... | U2-Toolkit/DataAdapter/Program.cs | U2-Toolkit/DataAdapter/Program.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows.Forms;
namespace DataAdapter
{
static class Program
{
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main()
{
A... | mit | C# | |
ae33f79a2eea7f2de014bc355ed9502744cd9ccc | Add new NSErrorException type to be used by the async code to signal failure. | mono/maccore | src/Foundation/NSErrorException.cs | src/Foundation/NSErrorException.cs | //
// Authors:
// Rodrigo Kumpera
//
// Copyright 2011 Xamarin 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
// without limitation the rights to ... | apache-2.0 | C# | |
bd073b4a6dd93275cb2c15d2c01c4a33519ea09b | Move ExeptionMessages to StaticData folder | stoyanov7/SoftwareUniversity,stoyanov7/SoftwareUniversity,stoyanov7/SoftwareUniversity,stoyanov7/SoftwareUniversity | C#Development/BashSoft/BashSoft/StaticData/ExceptionMessages.cs | C#Development/BashSoft/BashSoft/StaticData/ExceptionMessages.cs | namespace BashSoft.Exceptions
{
public static class ExceptionMessages
{
public const string DataAlreadyInitialisedException = "Data is already initialized!";
public const string DataNotInitializedExceptionMessage = "The data structure must be initialised first in order to make any operat... | mit | C# | |
a9ab12a3b05b4e50c1279d833362a3a977e981c2 | Add missing file | michael-reichenauer/GitMind | GitMind/Git/BranchName.cs | GitMind/Git/BranchName.cs | using System;
using GitMind.Utils;
namespace GitMind.Git
{
/// <summary>
/// Branch name type, which handles branch names as case insensitive strings.
/// </summary>
public class BranchName : Equatable<BranchName>, IComparable
{
public static BranchName Master = new BranchName("master");
public static Branc... | mit | C# | |
b9fb29493d0b856447c10753709e75e11a5d0627 | Add base class for all human actors | 0culus/ElectronicCash | ElectronicCash/BaseActor.cs | ElectronicCash/BaseActor.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ElectronicCash
{
public abstract class BaseActor
{
public string Name { get; set; }
public Guid ActorGuid { get; set; }
}
}
| mit | C# | |
c4acb0c44b64ca47dd916bf4c3701f91d7a3c45b | allow access to Settings from different threads. | morkt/GARbro,dsp2003/GARbro,dsp2003/GARbro,dsp2003/GARbro,morkt/GARbro | ArcFormats/Settings.cs | ArcFormats/Settings.cs | using System;
using System.Windows;
using System.Windows.Threading;
namespace GameRes.Formats.Properties {
// This class allows you to handle specific events on the settings class:
// The SettingChanging event is raised before a setting's value is changed.
// The PropertyChanged event... | namespace GameRes.Formats.Properties {
// This class allows you to handle specific events on the settings class:
// The SettingChanging event is raised before a setting's value is changed.
// The PropertyChanged event is raised after a setting's value is changed.
// The SettingsLoade... | mit | C# |
4371de1750c8869869b58ccde5ee2e39dce36897 | Fix some details of build script | Desolath/ConfuserEx3,engdata/ConfuserEx,HalidCisse/ConfuserEx,MetSystem/ConfuserEx,mirbegtlax/ConfuserEx,farmaair/ConfuserEx,apexrichard/ConfuserEx,timnboys/ConfuserEx,AgileJoshua/ConfuserEx,yuligang1234/ConfuserEx,KKKas/ConfuserEx,Immortal-/ConfuserEx,yeaicc/ConfuserEx,modulexcite/ConfuserEx,mirbegtlax/ConfuserEx,JPVe... | Build/UpdateVersion.cs | Build/UpdateVersion.cs | using System;
using System.Diagnostics;
using System.IO;
public static class Program {
public static int Main(string[] args) {
if (args.Length != 1) {
Console.WriteLine("invalid argument length.");
return -1;
}
string dir = args[0];
string ver = File.ReadAllText(Path.Combine(dir, "VERSION"));
string ... | using System;
using System.Diagnostics;
using System.IO;
public static class Program {
public static int Main(string[] args) {
if (args.Length != 1) {
Console.WriteLine("invalid argument length.");
return -1;
}
string dir = args[0];
string ver = File.ReadAllText(Path.Combine(dir, "VERSION"));
string ... | mit | C# |
5cb4eb7c59f3aa1cf1cfc7344d91632fd6db9da0 | Add simple weaklist test | ppy/osu-framework,peppy/osu-framework,ppy/osu-framework,smoogipooo/osu-framework,EVAST9919/osu-framework,peppy/osu-framework,EVAST9919/osu-framework,EVAST9919/osu-framework,ZLima12/osu-framework,peppy/osu-framework,ZLima12/osu-framework,EVAST9919/osu-framework,ppy/osu-framework,smoogipooo/osu-framework | osu.Framework.Tests/Lists/TestWeakList.cs | osu.Framework.Tests/Lists/TestWeakList.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.Lists;
namespace osu.Framework.Tests.Lists
{
[TestFixtu... | mit | C# | |
1c7519fd87f16cd30fd95b954a737c208f99a53a | Add ConcurrentCaches Test | rducom/StackCache | StackCache.Test/ConcurrentCaches.cs | StackCache.Test/ConcurrentCaches.cs | namespace StackCache.Test
{
using System;
using System.Threading.Tasks;
using Core;
using Core.Configuration;
using Xunit;
public class ConcurrentCaches
{
private const string _keySerialized = "42Concurent";
private static readonly Serialized _dataSerialized = new Serialized... | mit | C# | |
494b7476f37b87660edce7e63eba21badae2bf2c | Add near-empty cell file | 12joan/hangman | cell.cs | cell.cs | using System;
namespace Hangman {
public class Cell {
public Cell() {
}
}
}
| unlicense | C# | |
48400bfb2fbf5ec5f1bc6c2d8c5263a4bad5ee1b | Convert DrawLineTouch to C# | rinkenuyten/ExpoDraw | ExpoDraw/Assets/Scripts/DrawLines/DrawLinesTouch.cs | ExpoDraw/Assets/Scripts/DrawLines/DrawLinesTouch.cs | using UnityEngine;
using System.Collections;
using System.Collections.Generic;
using Vectrosity;
public class DrawLinesTouch : MonoBehaviour {
// For touchscreen devices -- draw a line with your finger
public Texture lineTex;
public float maxPoints = 5000;
public float lineWidth = 4.0f;
public int minPixelMove = ... | apache-2.0 | C# | |
e3019a42d63356b539dbb2882ae6876dee0bde4c | Create BlacklistedHostManager.cs | siuccwd/IOER,siuccwd/IOER,siuccwd/IOER | Services/Isle.BizServices/BlacklistedHostManager.cs | Services/Isle.BizServices/BlacklistedHostManager.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using LRWarehouse.Business;
using LRWarehouse.DAL;
namespace Isle.BizServices
{
public class BlackListedHostServices : Isle.BusinessServices.BaseService
{
private BlacklistedHostManager blackListedHostManager;
... | apache-2.0 | C# | |
9f8498c35d85aa42b1805d846ab3fffc79e96cb3 | Add Q239 | txchen/localleet | csharp/Q239_SlidingWindowMaximum.cs | csharp/Q239_SlidingWindowMaximum.cs | using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Xunit;
// Given an array nums, there is a sliding window of size k which is moving from the very left of the array to the very right. You can only see the k numbers in the window. Each time the sliding... | mit | C# | |
3efe651a76076c3d25b4af57fb6cd98c36fb3410 | Create NameMosa.cs | krbysh/FFXIV-ACT-OverlayPlugin-Plugins | NameMosa.cs | NameMosa.cs | using Advanced_Combat_Tracker;
using System;
using System.Reflection;
using System.Text;
using System.Windows.Forms;
// Advanced Combat Tracker - mini parse window用Plugin
// NameMosa:キャラクターをモザイク処理
[assembly: AssemblyTitle("Mini Parse Mosaic Name")]
[assembly: AssemblyVersion("1.0.0.0")]
namespace ACTv3Plugins
{
publi... | mit | C# | |
b10f1d5e626430f868735fb17014e82485fec2b1 | Reduce Oculus headtracking latency by updating every frame | bmolyneaux/41X,bmolyneaux/41X,bmolyneaux/VrPlayer,bmolyneaux/VrPlayer | VrPlayer.Trackers/VrPlayer.Trackers.OculusRiftTracker/OculusRiftTracker.cs | VrPlayer.Trackers/VrPlayer.Trackers.OculusRiftTracker/OculusRiftTracker.cs | using System;
using System.Runtime.InteropServices;
using System.Runtime.Serialization;
using System.Windows.Threading;
using System.Windows.Media.Media3D;
using VrPlayer.Contracts.Trackers;
using VrPlayer.Helpers;
using OpenTK;
using System.Windows.Media;
namespace VrPlayer.Trackers.OculusRiftTracker
{
... | using System;
using System.Runtime.InteropServices;
using System.Runtime.Serialization;
using System.Windows.Threading;
using System.Windows.Media.Media3D;
using VrPlayer.Contracts.Trackers;
using VrPlayer.Helpers;
using OpenTK;
namespace VrPlayer.Trackers.OculusRiftTracker
{
[DataContract]
unsafe... | lgpl-2.1 | C# |
c2569537210197ea39546a10a1212ca81451accd | Create Guess.cs | zelbo/Number-Guessing | Guess.cs | Guess.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Diagnostics;
namespace NumberGuessing
{
partial class Program
{
// adjust ratings (way off, not quite, close, very close, correct)
//public enum Rating { Correct = 0, Close = 2, Off = 4, WayOff = ... | mit | C# | |
e05aa8942d464c0db45fea9044ef79bc3ab36968 | Add Upsert to LiteCollection #94 | mbdavid/LiteDB,89sos98/LiteDB,masterdidoo/LiteDB,falahati/LiteDB,masterdidoo/LiteDB,falahati/LiteDB,RytisLT/LiteDB,89sos98/LiteDB,RytisLT/LiteDB | LiteDB/Database/Collections/Upsert.cs | LiteDB/Database/Collections/Upsert.cs | using System;
using System.Collections.Generic;
using System.Linq;
namespace LiteDB
{
public partial class LiteCollection<T>
{
/// <summary>
/// Insert or Update a document in this collection. Returns false if not found document in collection
/// </summary>
public bool Upsert(T... | mit | C# | |
e6f15eadbe367888a75013a7dcee0677a310c13d | Create AddIn.cs | Excel-DNA/IntelliSense | CustomAddin/AddIn.cs | CustomAddin/AddIn.cs | using System.Collections.Generic;
using System.ComponentModel;
using System.Diagnostics;
using System.Linq;
using System.Runtime.InteropServices;
using ExcelDna.Integration;
using ExcelDna.Integration.CustomUI;
using ExcelDna.IntelliSense;
namespace TestAddIn
{
public static class TestFunctions
{
[Exce... | mit | C# | |
c1e2b0f22a6a7bc826a2c84a592315ca680ae35a | Create FlatFileExtensions.cs | strvmarv/Extensions | FlatFileExtensions.cs | FlatFileExtensions.cs | using System;
using System.Collections.Generic;
using System.Data;
using System.IO;
using System.Linq;
using System.Text;
namespace Extensions
{
public class FlatFileExtensions
{
public static EnumerableRowCollection<DataRow> ConvertFlatFileToDataRowList(string filename, char delimiter)
{
... | mit | C# | |
872b4505d76c24a4131791dc66f7a16e37e1fd8b | Create PartSelection.cs | Kerbas-ad-astra/WernherChecker,linuxgurugamer/WernherChecker,Magion/WernherChecker | Source/PartSelection.cs | Source/PartSelection.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using UnityEngine;
namespace WernherChecker
{
class PartSelection
{
public Vector2 startClick = -Vector2.one;
public Rect selection;
public List<Part> selectedParts = new List<Part>();
Vector2 ... | mit | C# | |
d814584092672219d34d54b623bd8030a99da25f | Add missing Buyer class. | bitpay/csharp-bitpay-client | BitPay/Buyer.cs | BitPay/Buyer.cs | using Newtonsoft.Json;
using System;
namespace BitPayAPI
{
/// <summary>
/// Provides an interface to a buyer.
/// </summary>
public class Buyer
{
public Buyer() { }
[JsonProperty(PropertyName = "name")]
public string Name { get; set; }
[JsonProperty(PropertyName ... | mit | C# | |
4e92323a9ba1add50e282439b635b4780788660f | Create WhoDisabledOrEnabled.cs | UnityCommunity/UnityLibrary | Assets/Scripts/Helpers/Debug/WhoDisabledOrEnabled.cs | Assets/Scripts/Helpers/Debug/WhoDisabledOrEnabled.cs | // shows who disabled/enabled this gameobject from another script
// usage: attach to gameobject that you want to track (see console stack trace)
using UnityEngine;
namespace UnityLibrary
{
public class WhoDisabledOrEnabled : MonoBehaviour
{
private void OnDisable()
{
Debug.LogErr... | mit | C# | |
f3ab235577a0c0acfccae7b1faf3587f82fe4b4b | Add new unit Tests for BasicBlocks | ilovepi/Compiler,ilovepi/Compiler | compiler/NUnit.Tests/Middle-End/BasicBlockTests.cs | compiler/NUnit.Tests/Middle-End/BasicBlockTests.cs | using NUnit.Framework;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace NUnit.Tests.Middle_End
{
[TestFixture]
public class BasicBlockTests
{
[Test]
public void TestMethod()
{
// TODO: Add your... | mit | C# | |
e7eb433d411a63bf2554c90f9d3701399cc859ab | Create Popup.cs | jon-lad/Battlefleet-Gothic | Popup.cs | Popup.cs | using UnityEngine;
public class Popup
{
private static bool forceToUnShow = false;
private static int useControlID = -1;
private bool isClickedComboButton = false;
private int selectedItemIndex = 0;
private Rect rect;
private GUIContent buttonContent;
private GUIContent[] listContent;
private string buttonS... | mit | C# | |
1aac51f073fcabf52b4cd9898bdfd941292ee4ee | Add a ITypeSig field to Local | yck1509/dnlib,jorik041/dnlib,kiootic/dnlib,Arthur2e5/dnlib,modulexcite/dnlib,picrap/dnlib,ZixiangBoy/dnlib,ilkerhalil/dnlib,0xd4d/dnlib | src/DotNet/Emit/Local.cs | src/DotNet/Emit/Local.cs | namespace dot10.DotNet.Emit {
/// <summary>
/// A method local
/// </summary>
public sealed class Local {
ITypeSig typeSig;
/// <summary>
/// Gets/sets the type of the local
/// </summary>
public ITypeSig Type {
get { return typeSig; }
set { typeSig = value; }
}
/// <summary>
/// Constructo... | namespace dot10.DotNet.Emit {
/// <summary>
/// A method local
/// </summary>
public class Local {
}
}
| mit | C# |
940289d204e368e4a43b12e5e5958b429d8a5cdb | Add first pass of function (mostly already done via linqpad script) | ChrisWoody/artidea-api | run.csx | run.csx | using System.Net;
public static async Task<HttpResponseMessage> Run(HttpRequestMessage req)
{
try
{
//log.Info("Going to find an art idea...");
var idea = FindRandomArtIdea();
//log.Info($"Found the idea \"{idea}\"");
return req.CreateResponse(HttpStatusCode.O... | mit | C# | |
84f8edd951a2dff31e7706be796e86dafae532b3 | Add missing unit test file. | symbooglix/symbooglix,symbooglix/symbooglix,symbooglix/symbooglix | src/SymbooglixLibTests/ConstantFolding/FoldBVor.cs | src/SymbooglixLibTests/ConstantFolding/FoldBVor.cs | using NUnit.Framework;
using System;
using Symbooglix;
using Microsoft.Boogie;
using Microsoft.Basetypes;
namespace ConstantFoldingTests
{
[TestFixture()]
public class FoldBVor : TestBase
{
[Test()]
public void AllOnes()
{
helper(5, 10, 15);
}
[Test()]
... | bsd-2-clause | C# | |
63983d896b93353dd59b31582101eec468e7acaa | Create DependencyPropertyExtensions.cs | jamesqo/typed-xaml | src/Typed.Xaml.Wpf/DependencyPropertyExtensions.cs | src/Typed.Xaml.Wpf/DependencyPropertyExtensions.cs | using System;
using System.Collections.Generic;
using System.Windows;
namespace Typed.Xaml
{
public static class DependencyPropertyExtensions
{
public static DependencyProperty AddOwner<T>(this DependencyProperty property)
where T : DependencyObject
{
return property.Add... | mit | C# | |
681e52a625cd9bb518a261e2b2a9f85cb117f8be | Add LockedWeakList | DrabWeb/osu-framework,peppy/osu-framework,ZLima12/osu-framework,EVAST9919/osu-framework,Tom94/osu-framework,ppy/osu-framework,EVAST9919/osu-framework,DrabWeb/osu-framework,smoogipooo/osu-framework,EVAST9919/osu-framework,Tom94/osu-framework,EVAST9919/osu-framework,ppy/osu-framework,ppy/osu-framework,peppy/osu-framework... | osu.Framework/Lists/LockedWeakList.cs | osu.Framework/Lists/LockedWeakList.cs | // Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu-framework/master/LICENCE
using System;
namespace osu.Framework.Lists
{
/// <summary>
/// A <see cref="IWeakList{T}"/> which locks all operations.
/// </summary>
public... | mit | C# | |
e113b5a175f429a4e469de007ecae64c4dafae75 | Add AssemblyInfo.cs with [assembly: ComVisible(false)] to Atata.WebDriverExtras project | atata-framework/atata-webdriverextras,atata-framework/atata-webdriverextras | src/Atata.WebDriverExtras/Properties/AssemblyInfo.cs | src/Atata.WebDriverExtras/Properties/AssemblyInfo.cs | using System.Runtime.InteropServices;
[assembly: ComVisible(false)]
| apache-2.0 | C# | |
d67cecd3066d5d17ecf7c1366b1fab276dd8c2d0 | Add RemoveNugetFromSamples script | florin-chelaru/urho,florin-chelaru/urho,florin-chelaru/urho,florin-chelaru/urho,florin-chelaru/urho,florin-chelaru/urho | bindings/RemoveNugetFromSamples.cs | bindings/RemoveNugetFromSamples.cs | using System.Xml;
using System.Xml.Linq;
using System.Xml.XPath;
/*
Changes nuget references to ProjectReferences in FeatureSamples.
Nuget doesn't support ItemGroups with conditions (it will overwrite them on the next package update) so that's why this script exists
By default, this utility removes urho.targets imp... | mit | C# | |
f02ac23e8e66459285d89555769471cf86245530 | Update server side API for single multiple answer question | Promact/trappist,Promact/trappist,Promact/trappist,Promact/trappist,Promact/trappist | Trappist/src/Promact.Trappist.Core/Controllers/QuestionsController.cs | Trappist/src/Promact.Trappist.Core/Controllers/QuestionsController.cs | using Microsoft.AspNetCore.Mvc;
using Promact.Trappist.DomainModel.Models.Question;
using Promact.Trappist.Repository.Questions;
using System;
namespace Promact.Trappist.Core.Controllers
{
[Route("api/question")]
public class QuestionsController : Controller
{
private readonly IQuestionRepository ... | mit | C# | |
a583cbc39b8b032936c16b214dfb8f4ec49cbc9f | Add ClosestNumbers.cs | regeldso/hrank | Algorithms/Sorting/ClosestNumbers.cs | Algorithms/Sorting/ClosestNumbers.cs | using System;
using System.Collections.Generic;
using System.IO;
class Solution {
public static int partition(int[] array, int start, int end)
{
int marker = start;
for (int i = start; i <= end; i++)
{
if (array[i] <= array[end])
{
int temp = array... | mit | C# | |
3e47a46d2b5de1045d2993ab54c9fc11fe833c09 | Add CreateCustomer example (#36) | googleads/google-ads-dotnet,googleads/google-ads-dotnet,googleads/google-ads-dotnet,googleads/google-ads-dotnet | examples/Services/AccountManagement/CreateCustomer.cs | examples/Services/AccountManagement/CreateCustomer.cs | // Copyright 2018 Google LLC
//
// 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 agreed to in ... | apache-2.0 | C# | |
72462005fce55844215e7b74205436c29d98aab3 | Create Achievement.cs | Rewtek/GameLibrary | Code/Rewtek.GameLibrary/Achievements/Achievement.cs | Code/Rewtek.GameLibrary/Achievements/Achievement.cs | namespace Rewtek.GameLibrary.Achivements
{
#region Using directives
using global::System;
using global::System.Linq;
using global::System.Collections.Generic;
#endregion
/// <summary>
/// Provides an achivement.
/// </summary>
public class Achievement
{
// Variables
... | mit | C# | |
a01003e41d0460db45f0e78e82477247845513db | Store tempdata as cookie collection key value pairs. fixes #92 | KuduApps/NugetGallery16Fx45-DeleteMe,ScottShingler/NuGetGallery,kudustress/NuGetGalleryOptmized,KuduApps/NuGetGallery,JetBrains/ReSharperGallery,KuduApps/NugetGallery16Fx45-DeleteMe,grenade/NuGetGallery_download-count-patch,KuduApps/NugetGallery21Fx45-DeleteMe,KuduApps/NuGetGallery,grenade/NuGetGallery_download-count-p... | Facts/Infrastructure/CookieTempDataProviderFacts.cs | Facts/Infrastructure/CookieTempDataProviderFacts.cs | using System.Collections.Generic;
using System.Web;
using System.Web.Mvc;
using Moq;
using Xunit;
namespace NuGetGallery.Infrastructure {
public class CookieTempDataProviderFacts {
public class TheSaveTempDataMethod {
[Fact]
public void StoresValuesInCookie() {
var ... | apache-2.0 | C# | |
dc59563ee9eb8a25bfde248fc010eea189e40b08 | Create EditorShortCutKeys.cs | UnityCommunity/UnityLibrary | Scripts/Editor/EditorShortCutKeys.cs | Scripts/Editor/EditorShortCutKeys.cs | using UnityEngine;
using UnityEditor;
using UnityEditor.SceneManagement;
using UnityEngine.SceneManagement;
// original source by "Mavina" http://answers.unity3d.com/answers/1204307/view.html
// usage: Place this script into Editor/ folder, then you can press F5 to enter/exit Play Mode
public class EditorShortCutKeys... | mit | C# | |
fb10a39a09aa2cd2557a519bd43d6bd717aef735 | add JWT authentication helper class | tsolarin/Csharp-jwt-authentication-sample | Api/Auth/JWTAuth.cs | Api/Auth/JWTAuth.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Api.Models;
using JWT;
using Newtonsoft.Json.Linq;
namespace Api.Auth
{
public class JWTAuth
{
// I know I know this shouldn't be visible
// it's a sample cut me some slack :)
privat... | mit | C# | |
27b9215d551ac48b26db3b4674084e8f79e8e34d | Add custom xaml namespace | ButchersBoy/Dragablz,coderUT/Dragablz | Dragablz/Properties/AssemblyInfo.cs | Dragablz/Properties/AssemblyInfo.cs | using System.Reflection;
using System.Resources;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Windows;
using System.Windows.Markup;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify t... | using System.Reflection;
using System.Resources;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Windows;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated ... | mit | C# |
018406a5e5e470ad491eb2c8b6b7e5824b5bfa6a | Create ThreadPoolTest.cs | UnityCommunity/UnityLibrary | Scripts/Threading/ThreadPoolTest.cs | Scripts/Threading/ThreadPoolTest.cs | using UnityEngine;
using System.Collections;
using System.Threading;
// Reference: http://www.dotnetperls.com/threadpool
// Usage: Attach this script to gameobject in scene, press play, hit 1 key to queue new threads, see console for progress
// we pass thread parameters as object
class ThreadInfo
{
public int th... | mit | C# | |
f2b6003bc44077771700e984eca124169d5e3e78 | Read initialize properties of config file | muhammedikinci/FuzzyCore | FuzzyCore/Initialize/ConfigReader.cs | FuzzyCore/Initialize/ConfigReader.cs | using System;
using System.Collections.Generic;
using System.IO;
using Newtonsoft.Json;
using FuzzyCore.Server;
namespace FuzzyCore.Initialize
{
public class ConfigReader
{
public string ConfigFile_Path = "./config.json";
public string ConfigFile_Content = "";
bool ConfigFile_Control()... | mit | C# | |
6674d76d6d03d547ac541b88548c265fcf114bee | Add missing file | btcpayserver/btcpayserver,btcpayserver/btcpayserver,btcpayserver/btcpayserver,btcpayserver/btcpayserver | BTCPayServer/WebsocketExtensions.cs | BTCPayServer/WebsocketExtensions.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Net.WebSockets;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
namespace BTCPayServer
{
public static class WebsocketExtensions
{
/// <summary>
/// NGINX closes websocket connections after ... | mit | C# | |
609527aa50f4da260f52bfbc9c13d2e92c61f090 | Compress array in intervals of consecutive elements | Gerula/interviews,Gerula/interviews,Gerula/interviews,Gerula/interviews,Gerula/interviews | CareerCup/Google/compress_array.cs | CareerCup/Google/compress_array.cs | // http://careercup.com/question?id=5693954190213120
//
// Given an ordered array, find segments
//
using System;
using System.Collections.Generic;
using System.Linq;
static class Program
{
static IEnumerable<int[]> Segment(this int[] array)
{
int n = array.Length;
int start = array[0];
... | mit | C# | |
bd2f82b93255266dfd1dce70d683e9cfa8d8efb1 | Add - Inizio implementazione evento trasferimento chiamata | vvfosprojects/sovvf,vvfosprojects/sovvf,vvfosprojects/sovvf,vvfosprojects/sovvf,vvfosprojects/sovvf | src/backend/SO115App.Models/Classi/Soccorso/Eventi/TrasferimentoChiamata.cs | src/backend/SO115App.Models/Classi/Soccorso/Eventi/TrasferimentoChiamata.cs | using SO115App.API.Models.Classi.Soccorso;
using SO115App.API.Models.Classi.Soccorso.Eventi;
using System;
namespace SO115App.Models.Classi.Soccorso.Eventi
{
public class TrasferimentoChiamata : Evento
{
public TrasferimentoChiamata(RichiestaAssistenza richiesta, DateTime istante, string codiceFonte, ... | agpl-3.0 | C# | |
9c78119373a5b350e749e9e9655c0320aad92039 | add update school tests | mzrimsek/resume-site-api | Test.Integration/ControllerTests/SchoolControllerTests/UpdateSchoolShould.cs | Test.Integration/ControllerTests/SchoolControllerTests/UpdateSchoolShould.cs | using Microsoft.AspNetCore.TestHost;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System.Net;
using System.Net.Http;
using Test.Integration.TestHelpers;
using Web.Models.SchoolModels;
namespace Test.Integration.ControllerTests.SchoolControllerTests
{
[TestClass]
public class UpdateSchoolShould
... | mit | C# | |
6eff354d94c00402b6aa9c9785327d80253edb80 | Add Model class with very simple model configuration | maul-esel/ssharp,isse-augsburg/ssharp,isse-augsburg/ssharp,isse-augsburg/ssharp,isse-augsburg/ssharp,maul-esel/ssharp,isse-augsburg/ssharp,maul-esel/ssharp,maul-esel/ssharp | models/SelfOrganizingPillProduction/Model.cs | models/SelfOrganizingPillProduction/Model.cs | using SafetySharp.Analysis;
using SafetySharp.Modeling;
using ModelRole = SafetySharp.Analysis.Role;
namespace SelfOrganizingPillProduction
{
public class Model : ModelBase
{
public Model(Station[] stations)
{
Stations = stations;
}
[Root(ModelRole.System)]
... | mit | C# | |
05f8db95b6c0632667fb6e854471f83b5c3a509d | Fix whitespace | jogibear9988/websocket-sharp,jogibear9988/websocket-sharp,TabbedOut/websocket-sharp,hybrid1969/websocket-sharp,Liryna/websocket-sharp,juoni/websocket-sharp,zq513705971/WebSocketApp,microdee/websocket-sharp,microdee/websocket-sharp,TabbedOut/websocket-sharp,pjc0247/websocket-sharp-unity,sinha-abhishek/websocket-sharp,2T... | websocket-sharp/ErrorEventArgs.cs | websocket-sharp/ErrorEventArgs.cs | #region License
/*
* ErrorEventArgs.cs
*
* The MIT License
*
* Copyright (c) 2012-2014 sta.blockhead
*
* 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 ... | #region License
/*
* ErrorEventArgs.cs
*
* The MIT License
*
* Copyright (c) 2012-2014 sta.blockhead
*
* 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 ... | mit | C# |
8f0f4713427fce73400dd136bd5e922ea8baffe7 | fix bug. | geffzhang/equeue,tangxuehua/equeue,tangxuehua/equeue,geffzhang/equeue,tangxuehua/equeue,Aaron-Liu/equeue,Aaron-Liu/equeue | src/EQueue/Broker/LongPolling/PullRequest.cs | src/EQueue/Broker/LongPolling/PullRequest.cs | using System;
using ECommon.Remoting;
using ECommon.Utilities;
using EQueue.Protocols;
namespace EQueue.Broker.LongPolling
{
public class PullRequest
{
public string Id { get; private set; }
public RemotingRequest RemotingRequest { get; private set; }
public PullMessageRequest PullMess... | using System;
using ECommon.Remoting;
using ECommon.Utilities;
using EQueue.Protocols;
namespace EQueue.Broker.LongPolling
{
public class PullRequest
{
public string Id { get; private set; }
public RemotingRequest RemotingRequest { get; private set; }
public PullMessageRequest PullMess... | mit | C# |
09c7c32e1912f205a117a49e2f9459e91413ca5f | Add the missing file. | jkoritzinsky/Avalonia,SuperJMN/Avalonia,jkoritzinsky/Avalonia,wieslawsoltes/Perspex,Perspex/Perspex,grokys/Perspex,AvaloniaUI/Avalonia,grokys/Perspex,AvaloniaUI/Avalonia,wieslawsoltes/Perspex,jkoritzinsky/Perspex,MrDaedra/Avalonia,SuperJMN/Avalonia,SuperJMN/Avalonia,AvaloniaUI/Avalonia,wieslawsoltes/Perspex,SuperJMN/Av... | src/Markup/Avalonia.Markup.Xaml/XamlLoadException.cs | src/Markup/Avalonia.Markup.Xaml/XamlLoadException.cs | using System;
using System.Runtime.Serialization;
namespace Avalonia.Markup.Xaml
{
public class XamlLoadException: Exception
{
public XamlLoadException()
{
}
protected XamlLoadException(SerializationInfo info, StreamingContext context): base(info, context)
{
}
... | mit | C# | |
9dc8ae282e6120440d834ef1f4c64590d1894163 | add error handler | shortgiraffe4/MomWorld,shortgiraffe4/MomWorld,shortgiraffe4/MomWorld | Articles.Entities/Error.cs | Articles.Entities/Error.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace MomWorld.Entities
{
public class Error
{
public int HttpStatusCode { get; set; }
public Exception Exception { get; set; }
}
}
| mit | C# | |
afaab23f873cbc55f0acf5fcc756d24fced61017 | Add net to selected objects | sts-CAD-Software/PCB-Investigator-Scripts | Editing/AddNetToSelection.cs | Editing/AddNetToSelection.cs | //-----------------------------------------------------------------------------------
// PCB-Investigator Automation Script (Synchronous)
// Created on 06.12.2017
// Author Fabio.Gruber
// SDK online reference http://www.pcb-investigator.com/sites/default/files/documents/InterfaceDocumentation/Index.html
// SDK h... | bsd-3-clause | C# | |
8dc218c2e53015d106c63620219b4841cc85efe7 | Create EditorMenu.cs | Ibuprogames/Unity-Standard-Hierarchy | Scripts/Editor/Menus/EditorMenu.cs | Scripts/Editor/Menus/EditorMenu.cs | ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Unity Standard Hierarchy.
//
// The MIT License (MIT)
//
// Copyright (c) 2014 Ibuprogames
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this... | mit | C# | |
5a0882a408c9804d395d7d39c773e7187e61f8e5 | Add files via upload | Liluye/Capstone | Player.cs | Player.cs | using UnityEngine;
using System.Collections;
public class Player : MonoBehaviour
{
float speed = 2.5f;
float test = 2;
// Use this for initialization
void Start()
{
}
// Update is called once per frame
void Update()
{
Move();
}
//Player movemen... | mit | C# | |
bce7b8f8db45df98116a10aa7f578e0dc654945c | Add missing model | joelverhagen/RemindMeWhen,joelverhagen/RemindMeWhen | RemindMeWhen.Core/Models/MovieReleasedEventContent.cs | RemindMeWhen.Core/Models/MovieReleasedEventContent.cs | using System;
using System.Collections.Generic;
namespace Knapcode.RemindMeWhen.Core.Models
{
public class MovieReleasedEventContent
{
public string Title { get; set; }
public int? ReleasedYear { get; set; }
public Uri ImdbUrl { get; set; }
public Uri RottenTomatoesUrl { get; s... | mit | C# | |
b1b1bb3e0c5dd846a8dd2587f78a73612d090242 | Add file | PlayScriptRedux/monomac,dlech/monomac,kangaroo/monomac | src/AppKit/NSColor.cs | src/AppKit/NSColor.cs | using System;
using MonoMac.Foundation;
using MonoMac.ObjCRuntime;
using System.Runtime.InteropServices;
namespace MonoMac.AppKit {
public partial class NSColor {
public static NSColor FromColorSpace (NSColorSpace space, float[] components)
{
if (components == null)
throw new ArgumentNullException ("compo... | apache-2.0 | C# | |
5db1f6f58e5787a7bf8883a8e0b65dee469622de | use location.href rather than window.location.hash because firefox auto decodes the later | projectkudu/SimpleWAWS,projectkudu/SimpleWAWS,projectkudu/TryAppService,fashaikh/SimpleWAWS,davidebbo/SimpleWAWS,davidebbo/SimpleWAWS,fashaikh/SimpleWAWS,fashaikh/SimpleWAWS,davidebbo/SimpleWAWS,projectkudu/TryAppService,projectkudu/TryAppService,projectkudu/TryAppService,fashaikh/SimpleWAWS,projectkudu/SimpleWAWS,davi... | SimpleWAWS/Login.cshtml | SimpleWAWS/Login.cshtml | <!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width" />
<script>
//Firefox auto decodes window.location.hash which breaks the login flow.
var queryString = location.href.split("#")[1];
window.location.replace('https://' + window.location.host + '/?' + queryS... | <!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width" />
<script>
var queryString = window.location.hash.substring(1);
window.location.replace('https://' + window.location.host + '/?' + queryString);
</script>
</head>
<body>
</body>
</html>
| apache-2.0 | C# |
5e0eba46443890549353bf590642df1f3770fcee | Create empty folder | lizaamini/CSharpExercises | Sheet-8/Exercise8A.cs | Sheet-8/Exercise8A.cs | mit | C# | ||
7a6805bb7306bfb1fa429921184f8b0e509f35eb | Add SceneEditorCameraMovement.cs | felladrin/unity-scripts,felladrin/unity3d-scripts | SceneEditorCameraMovement.cs | SceneEditorCameraMovement.cs | using UnityEngine;
public class SceneEditorCameraMovement : MonoBehaviour {
public float TranslateSpeed;
public float RotateSpeed;
Vector3 lastMousePosition = Vector3.zero;
void Update () {
if (Input.GetKey (KeyCode.W)) {
transform.Translate (Vector3.forward * Time.deltaTime * TranslateSpeed);
}
if (... | mit | C# | |
a82791a967aad031fd764f07cc0c564a8ac6c3ca | Create cs-1.0.0.cs | IamSilviu/Utility-Belt,IamSilviu/Utility-Belt,IamSilviu/Utility-Belt | UB/CSharp/cs-1.0.0.cs | UB/CSharp/cs-1.0.0.cs | namespace UtilityBelt
{
using System;
public class UB
{
}
}
| mit | C# | |
3562ae206c9262f7a6c8a118ed8d091e15d3c2e0 | Add container struct for search index values. | CodeConnect/SourceBrowser,AmadeusW/SourceBrowser,AmadeusW/SourceBrowser,CodeConnect/SourceBrowser,AmadeusW/SourceBrowser | src/SourceBrowser.Search/ViewModels/TokenViewModel.cs | src/SourceBrowser.Search/ViewModels/TokenViewModel.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace SourceBrowser.Search.ViewModels
{
public struct TokenViewModel
{
public string DocumentId { get; }
public string FullName { get; }
public int LineNumber { get; ... | mit | C# | |
941264d8ea598df7dba35d94c6d9b6c8fe4979cd | Create 20180129.cs | twilightspike/cuddly-disco,twilightspike/cuddly-disco | main/20180129.cs | main/20180129.cs | using UnityEngine.SceneManagement;
using UnityEngine;
public class Abcde : BaseBehaviour {
void Start(){
}
}
| mit | C# | |
172ddd4902a2684df7e7394829069ec10f9f0152 | add JsonConvertTest | WeihanLi/WeihanLi.Common,WeihanLi/WeihanLi.Common,WeihanLi/WeihanLi.Common | test/WeihanLi.Common.Test/JsonTest/JsonConvertTest.cs | test/WeihanLi.Common.Test/JsonTest/JsonConvertTest.cs | using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using System.Net;
using WeihanLi.Common.Json;
using WeihanLi.Extensions;
using Xunit;
namespace WeihanLi.Common.Test.JsonTest
{
public class JsonConvertTest
{
[Fact]
public void JsonTest()
{
var obj = new
{
... | mit | C# | |
4937e63a2a4bdfc659f543abea442233a42db427 | Add while command | Baggykiin/Netstack | Netstack/Language/Framework/Control/While.cs | Netstack/Language/Framework/Control/While.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Netstack.Language.Framework.Control
{
class While : Function
{
public override void Execute(NetStack stack)
{
var condition = stack.Pop<Statement>();
... | mit | C# | |
43fe95eaf1cc9fcbe5833ceb2ff1b184dc088be4 | Add a boring wrapper around Engine since it's sealed | rzhw/Squirrel.Windows,rzhw/Squirrel.Windows | src/Shimmer.WiXUi/EngineWrapper.cs | src/Shimmer.WiXUi/EngineWrapper.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Tools.WindowsInstallerXml.Bootstrapper;
namespace Shimmer.WiXUi
{
public interface IEngine
{
Engine.Variables<long> NumericVariables { get; }
int PackageCount { get; }
Engine.Variables... | mit | C# | |
53d4e05a6d0442d249a22ac42e7277bed1aae062 | Fix for using two kinds of RssMonitor objects. | cube-soft/Cube.Core,cube-soft/Cube.Core | BindableOperator.cs | BindableOperator.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# | |
4dc930ea7b1aa429eb30f2ee0b460d5edf5a244f | Move Interop.GetTimestamp.cs to shared CoreLib partition. (#35031) | poizan42/coreclr,cshung/coreclr,krk/coreclr,krk/coreclr,krk/coreclr,mmitche/coreclr,wtgodbe/coreclr,poizan42/coreclr,wtgodbe/coreclr,krk/coreclr,wtgodbe/coreclr,mmitche/coreclr,poizan42/coreclr,wtgodbe/coreclr,mmitche/coreclr,mmitche/coreclr,wtgodbe/coreclr,cshung/coreclr,mmitche/coreclr,mmitche/coreclr,krk/coreclr,poi... | src/System.Private.CoreLib/shared/Interop/Unix/System.Native/Interop.GetTimestamp.cs | src/System.Private.CoreLib/shared/Interop/Unix/System.Native/Interop.GetTimestamp.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.Runtime.InteropServices;
internal static partial class Interop
{
internal static partial class Sys... | mit | C# | |
43cb80a436e8a7a1b7471b64af4f4bcf668197e3 | Create TickableDemoClasses.cs | DGoodayle/TickableObjects | TickableDemoClasses.cs | TickableDemoClasses.cs | /*
Tickable Classes by Just a Pixel - Danny Goodayle (@DGoodayle) - http://www.justapixel.co.uk
The MIT License (MIT)
Copyright (c) 2015 DGoodayle
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... | mit | C# | |
f0b246c8a0bdae8cd980965191d684c7828aa0fa | add GroupQueue<T> class. | yisoft-dotnet/framework | src/Yisoft.Framework/Collections/Generic/GroupQueue.cs | src/Yisoft.Framework/Collections/Generic/GroupQueue.cs | // ===============================================================================
// Website: https://yi.team/
// Copyright © Yi.TEAM. All rights reserved.
// ===============================================================================
using System.Collections.Generic;
namespace Yisoft.Framework.Collections.Gener... | apache-2.0 | C# | |
424c9c9746c773a8c5fa4ca3ed398bf94cabebe6 | Rename Image class to OwnImage | lucianodelucchi/convertidor | Convertidor/Models/OwnImage.cs | Convertidor/Models/OwnImage.cs | using System;
namespace Convertidor.Models
{
/// <summary>
/// Description of Image.
/// </summary>
public class Image
{
#region Creation
public static Image CreateNewImage()
{
return new Image();
}
public static Image CreateImage(string filename, string path... | mit | C# | |
1b49a8d760123d551aff422e75f4fa65ece9b5cc | Make dashboard container name match new conventions (fixes #164). | shrishrirang/azure-webjobs-sdk,oaastest/azure-webjobs-sdk,brendankowitz/azure-webjobs-sdk,oaastest/azure-webjobs-sdk,vasanthangel4/azure-webjobs-sdk,brendankowitz/azure-webjobs-sdk,shrishrirang/azure-webjobs-sdk,oliver-feng/azure-webjobs-sdk,shrishrirang/azure-webjobs-sdk,Azure/azure-webjobs-sdk,gibwar/azure-webjobs-sd... | src/Dashboard/Data/DashboardContainerNames.cs | src/Dashboard/Data/DashboardContainerNames.cs | // Copyright (c) Microsoft Open Technologies, Inc. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
namespace Dashboard.Data
{
// Names of containers used only by the dashboard (not part of the protocol with hosts).
internal s... | // Copyright (c) Microsoft Open Technologies, Inc. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
namespace Dashboard.Data
{
// Names of containers used only by the dashboard (not part of the protocol with hosts).
internal s... | mit | C# |
b2dc1d35c6e526f9f297504de42ee8ace346e37e | Add unit tests for #34. | StephenCleary/Comparers | test/UnitTests/RegressionTests.cs | test/UnitTests/RegressionTests.cs | using System;
using System.Collections.Generic;
using System.Text;
using Nito.Comparers;
using Xunit;
namespace UnitTests
{
public class RegressionTests
{
[Fact]
public void ComparableBaseDefaultComparer_WithoutTypeInstantiation_IsNotNull()
{
Assert.NotNull(DoNotInstantiate... | mit | C# | |
564f5a45ba2242cdbda9d27f784ec342ad4d6302 | Fix about | aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore | src/AuthSamples/samples/DynamicSchemes/Pages/About.cshtml | src/AuthSamples/samples/DynamicSchemes/Pages/About.cshtml | @page
@model AboutModel
@{
ViewData["Title"] = "About";
}
<h2>@ViewData["Title"]</h2>
<h3>@Model.Message</h3>
<p>Use this area to provide additional information.</p>
| apache-2.0 | C# | |
9927fb25f1abb81816b48965f7c64aedc82cf03d | add StateIndexBase.cs | NDark/ndinfrastructure,NDark/ndinfrastructure | Unity/StateMachine/StateIndexBase.cs | Unity/StateMachine/StateIndexBase.cs | using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class StateIndexBase<T>
{
public StateIndexBase()
{
}
public StateIndexBase( T _InitState )
{
m_NextValue = m_CurrentValue = m_PreviousValue = _InitState ;
}
public virtual void CallInit( Dictionary<T,TransitionSet> _Tr... | mit | C# | |
d351c4be2696204d3911dd175abbc9e150bc7cac | Create DrawLine.cs | UnityCommunity/UnityLibrary | Assets/Scripts/Drawing/DrawLine.cs | Assets/Scripts/Drawing/DrawLine.cs | using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class DrawLine : MonoBehaviour
{
[SerializeField]
protected LineRenderer m_LineRenderer;
protected List<Vector3> m_Points;
public virtual LineRenderer lineRenderer
{
get
{
return m_LineRenderer;
}
}
public virtual ... | mit | C# | |
3401c376ef69e26cc5d501f45a4bac6770869a0b | Create Auto-Censor.cs | DeanCabral/Code-Snippets | Console/Auto-Censor.cs | Console/Auto-Censor.cs | class AutoCensor
{
static void Main(string[] args)
{
GetUserInput();
}
static void GetUserInput()
{
string input = "";
string censor = "";
Console.Write("Word to censor: ");
censor = Console.ReadLine();
... | mit | C# | |
c0c7b9428c4831bb2a8b77ef2102ff881ab226d5 | Create Problem108.cs | fireheadmx/ProjectEuler,fireheadmx/ProjectEuler | Problems/Problem108.cs | Problems/Problem108.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ProjectEuler.Problems
{
class Problem108
{
public void Run()
{
//int max_solutions = 850;
//int max_n = 120120;
//int n = 120120;
int max_solutions = ... | mit | C# | |
c923859fae364515baf8221dc98042538c4f42c5 | Add interface IInitializable to make Init() available in select places | PiranhaCMS/piranha.core,PiranhaCMS/piranha.core,PiranhaCMS/piranha.core,PiranhaCMS/piranha.core | core/Piranha/IInitializable.cs | core/Piranha/IInitializable.cs | using System.Threading.Tasks;
namespace Piranha
{
public interface IInitializable
{
public void Init();
}
} | mit | C# | |
0c46d9d806dfd863c9a41598e05bea20f925aa83 | Add Q169 | txchen/localleet | csharp/Q169_MajorityElement.cs | csharp/Q169_MajorityElement.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Xunit;
// Given a positive integer, return its corresponding column title as appear in an Excel sheet.
//
// For example:
//
// 1 -> A
// 2 -> B
// 3 -> C
// ...
// 26 -> Z
// 27 -> AA
// 28 -> AB
/... | mit | C# | |
98e0371049d03aeaf746101121fdfff6d8cadeb7 | support NetworkJsonConverter serialization for other network | dangershony/NStratis,MetacoSA/NBitcoin,stratisproject/NStratis,NicolasDorier/NBitcoin,lontivero/NBitcoin,thepunctuatedhorizon/BrickCoinAlpha.0.0.1,MetacoSA/NBitcoin | NBitcoin/JsonConverters/NetworkJsonConverter.cs | NBitcoin/JsonConverters/NetworkJsonConverter.cs | #if !NOJSONNET
using NBitcoin;
using Newtonsoft.Json;
using System;
using System.Reflection;
namespace NBitcoin.JsonConverters
{
#if !NOJSONNET
public
#else
internal
#endif
class NetworkJsonConverter : JsonConverter
{
public override bool CanConvert(Type objectType)
{
return typeof(... | #if !NOJSONNET
using NBitcoin;
using Newtonsoft.Json;
using System;
using System.Reflection;
namespace NBitcoin.JsonConverters
{
#if !NOJSONNET
public
#else
internal
#endif
class NetworkJsonConverter : JsonConverter
{
public override bool CanConvert(Type objectType)
{
return typeof(... | mit | C# |
39c6f536235f6e56e80867f76855a77c0bd9ed2d | Create layer | marios-tsiliakos/Adobe-Illustrator-export-GH | src/create_layer.cs | src/create_layer.cs | /// <summary>check if the specified layer exists and if not create it.</summary>
private void create_layer(string l)
{
int layerslist = doc.Layers.Find(l, true);
if(layerslist < 0){
Rhino.DocObjects.Layer l0 = new Rhino.DocObjects.Layer();
System.Drawing.Color m_color = RandomColour();
... | mit | C# | |
8590bb860e03ba25677dc57219c7cc994b309d2b | Add test to show a handler is instantiated twice, when using a pipeline | jbogard/MediatR.Extensions.Microsoft.DependencyInjection | test/MediatR.Extensions.Microsoft.DependencyInjection.Tests/PipeLineMultiCallToConstructorTest.cs | test/MediatR.Extensions.Microsoft.DependencyInjection.Tests/PipeLineMultiCallToConstructorTest.cs | using Microsoft.Extensions.DependencyInjection;
namespace MediatR.Extensions.Microsoft.DependencyInjection.Tests
{
using System.Reflection;
using System.Threading.Tasks;
using Shouldly;
using Xunit;
public class PipelineMultiCallToConstructorTests
{
public class ConstructorTestBehavio... | mit | C# | |
34a34aba20cfec04d2d7c8132b2fd6578243af08 | 更新 Ivony.Html.Web.Mvc 项目版本号为 3.0 | yonglehou/Jumony,zpzgone/Jumony,wukaixian/Jumony,zpzgone/Jumony,yonglehou/Jumony,wukaixian/Jumony | Ivony.Html.Web.Mvc/Properties/AssemblyInfo.cs | Ivony.Html.Web.Mvc/Properties/AssemblyInfo.cs | using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// 有关程序集的常规信息通过以下
// 特性集控制。更改这些特性值可修改
// 与程序集关联的信息。
[assembly: AssemblyTitle( "Ivony.Html.Web.Mvc" )]
[assembly: AssemblyDescription( "" )]
[assembly: AssemblyConfiguration( "" )]
[assembly: AssemblyCompany... | using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// 有关程序集的常规信息通过以下
// 特性集控制。更改这些特性值可修改
// 与程序集关联的信息。
[assembly: AssemblyTitle( "Ivony.Html.Web.Mvc" )]
[assembly: AssemblyDescription( "" )]
[assembly: AssemblyConfiguration( "" )]
[assembly: AssemblyCompany... | apache-2.0 | C# |
9a1f4537c7da79544b9af297729ae850759fed1d | Add temporary extension for bridging osuTK | ppy/osu-framework,ZLima12/osu-framework,smoogipooo/osu-framework,ppy/osu-framework,ZLima12/osu-framework,EVAST9919/osu-framework,EVAST9919/osu-framework,peppy/osu-framework,peppy/osu-framework,EVAST9919/osu-framework,ppy/osu-framework,peppy/osu-framework,EVAST9919/osu-framework,smoogipooo/osu-framework | osu.Framework/Extensions/BridgingExtensions.cs | osu.Framework/Extensions/BridgingExtensions.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 TKVector2 = osuTK.Vector2;
using SNVector2 = System.Numerics.Vector2;
namespace osu.Framework.Extensions
{
/// <summary>
/// Temporary extension functions ... | mit | C# | |
44688ac2d40c013e0ab6a7119c1a706d50e8a8ab | Test default batch values | SkillsFundingAgency/das-commitments,SkillsFundingAgency/das-commitments,SkillsFundingAgency/das-commitments | src/SFA.DAS.Commitments.Database.IntegrationTests/StoredProcedures/GetLearnersBatch/WhenNoBatchSupplied.cs | src/SFA.DAS.Commitments.Database.IntegrationTests/StoredProcedures/GetLearnersBatch/WhenNoBatchSupplied.cs | using NUnit.Framework;
using FluentAssertions;
using Dapper;
using System.Data;
using System;
namespace SFA.DAS.Commitments.Database.IntegrationTests.StoredProcedures.GetLearnersBatch
{
[TestFixture]
public class WhenNoBatchSupplied : GetLearnersBatchIntegrationTestBase
{
[Test]
public voi... | mit | C# | |
0df15b4d7a4361368d1504ec18695902b9969d82 | Add test coverage | peppy/osu-new,NeoAdonis/osu,UselessToucan/osu,UselessToucan/osu,peppy/osu,smoogipoo/osu,smoogipoo/osu,UselessToucan/osu,NeoAdonis/osu,NeoAdonis/osu,smoogipoo/osu,peppy/osu,ppy/osu,smoogipooo/osu,ppy/osu,ppy/osu,peppy/osu | osu.Game.Rulesets.Osu.Tests/Mods/TestSceneOsuModAutoplay.cs | osu.Game.Rulesets.Osu.Tests/Mods/TestSceneOsuModAutoplay.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.Testing;
using osu.Framework.Utils;
using osu.Game.Beatmaps;
using osu.Game.Rulesets.Mods;
using osu.Game.Ru... | mit | C# | |
d009a0be51defe7890002ca501d666c40e29fbd9 | Move class to final location | peppy/osu-new,ppy/osu,smoogipoo/osu,NeoAdonis/osu,smoogipooo/osu,UselessToucan/osu,NeoAdonis/osu,smoogipoo/osu,peppy/osu,ppy/osu,UselessToucan/osu,UselessToucan/osu,peppy/osu,ppy/osu,smoogipoo/osu,NeoAdonis/osu,peppy/osu | osu.Game/Screens/Play/HUD/MultiplayerGameplayLeaderboard.cs | osu.Game/Screens/Play/HUD/MultiplayerGameplayLeaderboard.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.Collections.Generic;
using System.Linq;
using JetBrains.Annotations;
using osu.Framework.Allocation;
using osu.Framework.Bindables;
using osu.Game.Configurat... | mit | C# | |
4833f136e36a802b1c22dd735806a37d4d3a7645 | Create AssemblyInfo.cs | PanAndZoom/PanAndZoom,wieslawsoltes/PanAndZoom,PanAndZoom/PanAndZoom,wieslawsoltes/PanAndZoom | src/Avalonia.Controls.PanAndZoom/Properties/AssemblyInfo.cs | src/Avalonia.Controls.PanAndZoom/Properties/AssemblyInfo.cs | using Avalonia.Metadata;
[assembly: XmlnsDefinition("https://github.com/avaloniaui", "Avalonia.Controls.PanAndZoom")]
| mit | C# | |
32f3b28494f1f2553cffaea15a88643a5a12f007 | Add the bio view. | bigfont/sweet-water-revolver | mvcWebApp/Views/Home/_Bio.cshtml | mvcWebApp/Views/Home/_Bio.cshtml | <div class="container">
<p>In 2003 Ashton found 21 year old Rama performing solo at an eclectic independent coffee house in Tampa Florida and invited Rama to come to see her next show. The rest is history. Sweet Water Revolver was formed in 2005 by band members Ashton and Rama Cheromaya. Later graced by the robus... | mit | C# | |
a6080874c7092d307b0f9c46df28ffd1161c5522 | Create HelloWorld.cs | KrzysFR/frqsspslt | HelloWorld.cs | HelloWorld.cs | using System;
namespace Hello
{
public static class World()
{
public static bool IsWorldTakenOver { get; private set; }
public static void TakeOverTheWorld()
{
throw new NotImplementedException();
}
public bool TryTakeOverTheWorld()
{
try
{
Console.WriteLine("Taking over the world...... | bsd-3-clause | C# | |
889c209bcff56bb9640d2adfb96aac444e53d65a | Create Excel2Json.cs | eatYOU/MyTool | Excel2Json.cs | Excel2Json.cs | using System;
using System.IO;
using System.Data;
using System.Text;
using System.Collections.Generic;
using Excel;
/// <summary>
/// Excel转换为Json, Sql, Csharp定义字段
/// </summary>
sealed public class Excel2Json {
private static string configPath = @"Config.ini";
private static string excelPath = "";
private stat... | apache-2.0 | C# | |
8f46e6b0d1fc9cc1ac26a0e5ff90cb69503fb704 | Test program for using new RDF wrapper classes | Dynalon/banshee-osx,stsundermann/banshee,arfbtwn/banshee,allquixotic/banshee-gst-sharp-work,babycaseny/banshee,mono-soc-2011/banshee,eeejay/banshee,stsundermann/banshee,Carbenium/banshee,GNOME/banshee,GNOME/banshee,GNOME/banshee,dufoli/banshee,Carbenium/banshee,arfbtwn/banshee,lamalex/Banshee,Dynalon/banshee-osx,lamale... | src/MusicBrainz/SimpleLookupTest.cs | src/MusicBrainz/SimpleLookupTest.cs | /* -*- Mode: csharp; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: t -*- */
/***************************************************************************
* SimpleLookupTest.cs
*
* Copyright (C) 2005 Novell
* Written by Aaron Bockover (aaron@aaronbock.net)
****************************************************... | mit | C# | |
e3d52d8d7171076a28ddb67feaf130cf62a7ea3a | Add NewsOverlay class | NeoAdonis/osu,smoogipoo/osu,UselessToucan/osu,2yangk23/osu,johnneijzen/osu,2yangk23/osu,peppy/osu,peppy/osu,ppy/osu,UselessToucan/osu,EVAST9919/osu,smoogipooo/osu,johnneijzen/osu,ppy/osu,UselessToucan/osu,EVAST9919/osu,NeoAdonis/osu,peppy/osu,smoogipoo/osu,smoogipoo/osu,ppy/osu,peppy/osu-new,NeoAdonis/osu | osu.Game/Overlays/NewsOverlay.cs | osu.Game/Overlays/NewsOverlay.cs | using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Shapes;
using osu.Game.Graphics;
namespace osu.Game.Overlays
{
public class NewsOverlay : FullscreenOverlay
{
[BackgroundDependencyLoader]
private void load(OsuColour colours)
{
Child... | mit | C# | |
7900edeec32c9b0e614fc7cc629e6ee8e8ab9061 | Add GameState class | FireCube-/HarvesterBot | TexasHoldEm/GameState.cs | TexasHoldEm/GameState.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace TexasHoldEm
{
class GameState
{
}
}
| mit | C# | |
ddbbe5d2d652b32b5957753cc348bcb4a94d154f | Create LINQ | neyogiry/Examples_Csharp | UnderstandingLINQ.cs | UnderstandingLINQ.cs | using System;
using System.Collections.Gemeric;
using System.Linq;
namespace UnderstandingLINQ
{
class Program
{
static void Main(string[] args)
{
List<Car> myCars = new List<Car>(){
new Car() { Make = "BMW", Model = "550i", Color = CarColor.Blue, StickerPrice = 55000, Year = 2009},
new Car() { Make =... | mpl-2.0 | C# | |
2277275790339b36444b47cc5947d92fe28eb6d6 | add endian util | tfwio/ds2wav_cs | cs/source/WriterExt.cs | cs/source/WriterExt.cs | /* tfwxo * 1/18/2016 * 9:57 PM */
using System;
using System.IO;
using on.iff;
using on.dsformat;
namespace System.IO
{
static class WriterExt
{
static public byte[] flip(this byte[] input)
{
Array.Reverse(input);
return input;
}
static public void WriteE(this BinaryWriter w, int input)
{
... | mit | C# |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.