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 |
|---|---|---|---|---|---|---|---|---|
a7fb0697662b74df499da21f2f290f53189101d1 | Add "AddOrUpdate" dictionary extension | Dexiom/Dexiom.EPPlusExporter | Dexiom.EPPlusExporter/Extensions/IDictionaryExtensions.cs | Dexiom.EPPlusExporter/Extensions/IDictionaryExtensions.cs | using System.Collections.Generic;
using System.Reflection;
namespace Dexiom.EPPlusExporter.Extensions
{
internal static class IDictionaryExtensions
{
public static void AddOrUpdate<TKey, TValue>(this IDictionary<TKey, TValue> dictionary, TKey key, TValue value)
{
if (dictionary.Con... | mit | C# | |
e04103dd3b29d5f712c8337002cb61a0f30663f5 | Add AccStructure | mehrandvd/Tralus,mehrandvd/Tralus | Selonia/Selonia.Accounting/Selonia.Accounting.BusinessModel/Entities/AccStructure.cs | Selonia/Selonia.Accounting/Selonia.Accounting.BusinessModel/Entities/AccStructure.cs | using System;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using DevExpress.ExpressApp.Utils;
using DevExpress.Persistent.Base.General;
using Tralus.Framework.BusinessModel.Entities;
n... | apache-2.0 | C# | |
be90dfcea329508508f61c6196c3f842bd9ff9fe | Add the SqlServerLedger class | openchain/openchain | src/Openchain.SqlServer/SqlServerLedger.cs | src/Openchain.SqlServer/SqlServerLedger.cs | // Copyright 2015 Coinprism, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agree... | apache-2.0 | C# | |
3669d595b8669c142843409e79f284ad760e94d1 | Create ParsingException.cs | tuttomax/IniSharp | Exceptions/ParsingException.cs | Exceptions/ParsingException.cs | namespace IniSharp.Exceptions
{
internal class ParsingException : Exception
{
public ParsingException()
{
}
public ParsingException(string message)
: base(message)
{
}
}
}
| mit | C# | |
9671f4803b2d60d780f17f577992c98360f19db5 | Create ADObjectTypecs.cs | sghaida/ADWS | ADWS/Models/ADObjectTypecs.cs | ADWS/Models/ADObjectTypecs.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.Web;
namespace ADWS.Models
{
[DataContract( Name = "ObjectType" )]
public enum ObjectType
{
[EnumMember( Value = "USER" )]
USER = 1 ,
[EnumMember( Value = "GROUP" )]
... | apache-2.0 | C# | |
0fc157a5063ab98c69701d01ca99f83d565c5341 | Patch array - memory exceeded. I wanted only to see the array | Gerula/interviews,Gerula/interviews,Gerula/interviews,Gerula/interviews,Gerula/interviews | LeetCode/remote/patch_array.cs | LeetCode/remote/patch_array.cs | // https://leetcode.com/problems/patching-array/
//
// Given a sorted positive integer array nums and an integer n, add/patch elements to the array such that any number in range [1, n] inclusive can be formed by the sum of some elements in the array. Return the minimum number of patches required.
//
// Example 1:
//... | mit | C# | |
b3f31476d967162c093103790e7bd5f5ec75f215 | Add tests for DialogBehavior. | cube-soft/Cube.Core,cube-soft/Cube.Core | Tests/Sources/Behaviors/DialogBehaviorTest.cs | Tests/Sources/Behaviors/DialogBehaviorTest.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# | |
5cad49ba9e9e808fb3bac236181fb0c1b93925b2 | Implement Authentication manager | stoyanov7/SoftwareUniversity,stoyanov7/SoftwareUniversity,stoyanov7/SoftwareUniversity,stoyanov7/SoftwareUniversity | C#Development/Database/DatabasesAdvanced/Workshop/TeamBuilder.Utilities/AuthenticationManager.cs | C#Development/Database/DatabasesAdvanced/Workshop/TeamBuilder.Utilities/AuthenticationManager.cs | namespace TeamBuilder.Utilities
{
using System;
using Models;
public static class AuthenticationManager
{
private static User currentUser;
public static void Authorize()
{
if (currentUser == null)
{
throw new InvalidOperatio... | mit | C# | |
1f3527d116f4286ae9b126f69237ed39d08b8226 | Create IQueryableExtensions.cs | strvmarv/Extensions | IQueryableExtensions.cs | IQueryableExtensions.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
namespace Extensions
{
public static class IQueryableExtensions
{
public static bool Exists<TSource>(this IQueryable<TSource> source, Expression<Func<TSource, bool>> predicate)
{... | mit | C# | |
b27a31e8ccd3b5e464445f0982c206b64fc0ae71 | add default OriginalServiceProvider imp | AspectCore/Lite,AspectCore/AspectCore-Framework,AspectCore/Abstractions,AspectCore/AspectCore-Framework | src/AspectCore.Lite/Internal/OriginalServiceProvider.cs | src/AspectCore.Lite/Internal/OriginalServiceProvider.cs | using System;
using AspectCore.Lite.Abstractions;
namespace AspectCore.Lite.Internal
{
internal sealed class OriginalServiceProvider : IOriginalServiceProvider
{
private readonly IServiceProvider serviceProvider;
public OriginalServiceProvider(IServiceProvider serviceProvider)
{
... | mit | C# | |
ef26840fca7e18461bee06c1349313fd05d5c2ed | Create SubsetSum.cs | DuckBoss/Programming-Challenges,DuckBoss/Programming-Challenges,DuckBoss/Programming-Challenges,DuckBoss/Programming-Challenges | Subset_Sum/SubsetSum.cs | Subset_Sum/SubsetSum.cs | using System;
namespace SubsetSum
{
class MainClass
{
public static void Main(string[] args)
{
if (args.Length == 0)
{
Console.WriteLine("This program requires atleast 1 integer input!\n");
Environment.Exit(0);
}
int[] inputtedData = new int[args.Length];
Console.Write("Given: {");
... | unlicense | C# | |
5e15418e3187c7ca8a1636a8dc1fd2822ecaefa4 | Add failing test | ppy/osu-framework,ZLima12/osu-framework,peppy/osu-framework,peppy/osu-framework,smoogipooo/osu-framework,EVAST9919/osu-framework,EVAST9919/osu-framework,peppy/osu-framework,ZLima12/osu-framework,ppy/osu-framework,smoogipooo/osu-framework,EVAST9919/osu-framework,EVAST9919/osu-framework,ppy/osu-framework | osu.Framework.Tests/Platform/ComponentAsyncDisposalTest.cs | osu.Framework.Tests/Platform/ComponentAsyncDisposalTest.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;
using System.Threading.Tasks;
using NUnit.Framework;
using osu.Framework.Allocation;
using osu.Framework.Graphics.Containers;
using osu.Framework.... | mit | C# | |
174a5b471570dac2109deab3c9eda0b9c24c65e2 | Fix the issues with the persistentId and vessels dissapearing, etc | gavazquez/LunaMultiPlayer,gavazquez/LunaMultiPlayer,DaggerES/LunaMultiPlayer,gavazquez/LunaMultiPlayer | LmpClient/Harmony/ShipConstruct_LoadShip.cs | LmpClient/Harmony/ShipConstruct_LoadShip.cs | using Harmony;
using LmpCommon.Enums;
// ReSharper disable All
namespace LmpClient.Harmony
{
/// <summary>
/// This harmony patch is intended to always assign a persistentID and NEVER use the persistent id of the .craft file
/// </summary>
[HarmonyPatch(typeof(ShipConstruct))]
[HarmonyPatch("LoadS... | mit | C# | |
b164ffb2082c13e747d88b09a815b54fa4e9d4e9 | Add ClipLabelPosition sample code | SharpMap/SharpMap,SharpMap/SharpMap | Examples/ExampleCodeSnippets/ClipLabelPosition.cs | Examples/ExampleCodeSnippets/ClipLabelPosition.cs | namespace ExampleCodeSnippets
{
/// <summary>
/// A clipping utility that ensures every geometry is labeled within the current map viewport
/// </summary>
public class ClipLabelPosition
{
private GeoAPI.Geometries.IGeometry _clip;
private GeoAPI.Geometries.Prepared.IPreparedGeometry... | lgpl-2.1 | C# | |
838511acef47ca0305d72b1732ca9ece729c75b3 | Make movement better, still not the best | sheix/GameEngine,sheix/GameEngine,sheix/GameEngine | Engine/Vector.cs | Engine/Vector.cs | namespace Engine
{
public class Vector
{
public readonly int _x;
public readonly int _y;
public Vector(int x, int y)
{
_x = x;
_y = y;
}
}
}
| mit | C# | |
29771b3debd9124bd0ef64370e4be845fd53bb8e | Create Problem47.cs | fireheadmx/ProjectEuler,fireheadmx/ProjectEuler | Problems/Problem47.cs | Problems/Problem47.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ProjectEuler.Problems
{
class Problem47
{
Sieve s;
private int upper = 1000000;
public Problem47()
{
s = new Sieve(upper/2);
}
private int CountFactors(in... | mit | C# | |
fb0cafea07ffd34af4e12c0fa2e7a9b10add5197 | Solve Area of a Circle in c# | deniscostadsc/playground,deniscostadsc/playground,deniscostadsc/playground,deniscostadsc/playground,deniscostadsc/playground,deniscostadsc/playground,deniscostadsc/playground,deniscostadsc/playground,deniscostadsc/playground,deniscostadsc/playground,deniscostadsc/playground,deniscostadsc/playground,deniscostadsc/playgr... | solutions/uri/1002/1002.cs | solutions/uri/1002/1002.cs | using System;
using System.Collections.Generic;
class Solution {
static void Main() {
double n;
string val;
val = Console.ReadLine();
n = Convert.ToDouble(val);
Console.Write("A={0:F4}{1}", n * n * 3.14159, Environment.NewLine);
}
}
| mit | C# | |
2c1a65d90acfa70f206cf46a00b26da5d93111c8 | Add simple test | smoogipoo/osu,ppy/osu,2yangk23/osu,peppy/osu,NeoAdonis/osu,2yangk23/osu,smoogipoo/osu,smoogipoo/osu,UselessToucan/osu,smoogipooo/osu,peppy/osu,ppy/osu,EVAST9919/osu,johnneijzen/osu,UselessToucan/osu,NeoAdonis/osu,peppy/osu,EVAST9919/osu,johnneijzen/osu,ppy/osu,peppy/osu-new,NeoAdonis/osu,UselessToucan/osu | osu.Game.Tests/Editor/TestSceneBlueprintContainer.cs | osu.Game.Tests/Editor/TestSceneBlueprintContainer.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.Game.Screens.Edit.Compose.Components;
using osu.Game.Tests.Visual;
namespace osu.Game.Tests.Editor
{
public class TestSceneBlueprint... | mit | C# | |
08e13fdca486952e9c2b650a38dce0779636a471 | Create ConstantRotation.cs | xxmon/unity | ConstantRotation.cs | ConstantRotation.cs | using UnityEngine;
using System.Collections;
public class ConstantRotation : MonoBehaviour
{
public bool local = true;
public Vector3 speed;
// Use this for initialization
void Start ()
{
}
// Update is called once per frame
void Update ()
{
if (local) {
transform.Rotate (speed * Time.deltaTime);
... | mit | C# | |
61bff7b21976baefc9f1d7c9999fbd7a555df9d0 | Reduce 0xdeadbeef to signed int value 0xabadbabe | pardeike/Harmony | Harmony/Internal/NativeThisPointerCheck.cs | Harmony/Internal/NativeThisPointerCheck.cs | using System;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
namespace Harmony
{
// A test for https://github.com/dotnet/coreclr/blob/master/Documentation/botr/clr-abi.md
//
internal class NativeThisPointer
{
internal static bool NeedsNativeThisPointerFix(Me... | using System;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
namespace Harmony
{
// A test for https://github.com/dotnet/coreclr/blob/master/Documentation/botr/clr-abi.md
//
internal class NativeThisPointer
{
internal static bool NeedsNativeThisPointerFix(Me... | mit | C# |
185331967cfd07d84117524882fad7297ab9a5e9 | Create Problem23.cs | fireheadmx/ProjectEuler,fireheadmx/ProjectEuler | Problems/Problem23.cs | Problems/Problem23.cs | using System;
namespace ProjectEuler
{
class Problem23
{
private int upper = 28124;
private bool[] abundant;
public Problem23()
{
abundant = new bool[upper];
for (int i = 1; i < upper; i++)
{
// Mark abundant numbers to avoid ... | mit | C# | |
4265d779ae7654406d5854497b32a018795b4a53 | Create Problem62.cs | fireheadmx/ProjectEuler,fireheadmx/ProjectEuler | Problems/Problem62.cs | Problems/Problem62.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Numerics;
namespace ProjectEuler.Problems
{
class Problem62
{
private string getDigits(BigInteger number)
{
List<char> charNumber = number.ToString().ToCharArray().ToList();
... | mit | C# | |
d00e90ee0e3a1bed553444a0524e8d9fa56abfd7 | Fix for URL Referrer bug. | YAFNET/YAFNET,mexxanit/YAFNET,moorehojer/YAFNET,YAFNET/YAFNET,Pathfinder-Fr/YAFNET,Pathfinder-Fr/YAFNET,YAFNET/YAFNET,Pathfinder-Fr/YAFNET,mexxanit/YAFNET,YAFNET/YAFNET,moorehojer/YAFNET,mexxanit/YAFNET,moorehojer/YAFNET | yafsrc/YAF.Classes/YAF.Classes.Utils/Security.cs | yafsrc/YAF.Classes/YAF.Classes.Utils/Security.cs | /* Yet Another Forum.net
* Copyright (C) 2003-2005 Bjørnar Henden
* Copyright (C) 2006-2007 Jaben Cargman
* http://www.yetanotherforum.net/
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundat... | /* Yet Another Forum.net
* Copyright (C) 2003-2005 Bjørnar Henden
* Copyright (C) 2006-2007 Jaben Cargman
* http://www.yetanotherforum.net/
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundat... | apache-2.0 | C# |
881ae733026190a0e0f5f7984ac15b11ff02c7bc | Create SimpleTypeModelDescription.cs | MingLu8/Nancy.WebApi.HelpPages | src/Nancy.WebApi.HelpPages.Demo/HelpPage/ModelDescriptions/SimpleTypeModelDescription.cs | src/Nancy.WebApi.HelpPages.Demo/HelpPage/ModelDescriptions/SimpleTypeModelDescription.cs | namespace WebApplication1.Areas.HelpPage.ModelDescriptions
{
public class SimpleTypeModelDescription : ModelDescription
{
}
}
| mit | C# | |
bebfa0071d07886840ab0767cbfc63427065117a | Create InputReader class | stoyanov7/SoftwareUniversity,stoyanov7/SoftwareUniversity,stoyanov7/SoftwareUniversity,stoyanov7/SoftwareUniversity | C#Development/BashSoft/BashSoft/IO/InputReader.cs | C#Development/BashSoft/BashSoft/IO/InputReader.cs | namespace BashSoft.IO
{
using BashSoft.StaticData;
using System;
public static class InputReader
{
private const string quitCommand = "quit";
private const string exitCommand = "exit";
public static void StartReadingCommands()
{
OutputWriter.Wri... | mit | C# | |
0db51fce7296b74e193df8f3295dadd6fa4db537 | Add DescribeTableResultTests | carbon/Amazon | src/Amazon.DynamoDb.Tests/Results/DescribeTableResultTests.cs | src/Amazon.DynamoDb.Tests/Results/DescribeTableResultTests.cs | using System;
using System.Text.Json;
using Amazon.DynamoDb.Models;
using Xunit;
namespace Amazon.DynamoDb.Tests
{
public class DescribeTableResultTests
{
[Fact]
public void Parse()
{
string text = @"
{
""Table"": {
""TableArn"": ""arn:aws:dyn... | mit | C# | |
469d7ad7ffcbf2c8ab39891f745701f64f550fc7 | add DefaultMessageHandlerAsyncEvent | jiehanlin/WeiXinMPSDK,lishewen/WeiXinMPSDK,mc7246/WeiXinMPSDK,jiehanlin/WeiXinMPSDK,JeffreySu/WeiXinMPSDK,JeffreySu/WeiXinMPSDK,JeffreySu/WeiXinMPSDK,jiehanlin/WeiXinMPSDK,mc7246/WeiXinMPSDK,mc7246/WeiXinMPSDK,lishewen/WeiXinMPSDK,lishewen/WeiXinMPSDK | src/Senparc.Weixin/Senparc.Weixin/MessageHandlers/Async/DefaultMessageHandlerAsyncEvent.cs | src/Senparc.Weixin/Senparc.Weixin/MessageHandlers/Async/DefaultMessageHandlerAsyncEvent.cs | #region Apache License Version 2.0
/*----------------------------------------------------------------
Copyright 2018 Jeffrey Su & Suzhou Senparc Network Technology Co.,Ltd.
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 ... | apache-2.0 | C# | |
4348bf9a1d258bc541a754c26bee07e864281062 | Add tests for ITraktHttpRequest interface. | henrikfroehling/TraktApiSharp | Source/Tests/TraktApiSharp.Tests/Experimental/Requests/Interfaces/ITraktHttpRequestTests.cs | Source/Tests/TraktApiSharp.Tests/Experimental/Requests/Interfaces/ITraktHttpRequestTests.cs | namespace TraktApiSharp.Tests.Experimental.Requests.Interfaces
{
using FluentAssertions;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System.Linq;
using System.Net.Http;
using TraktApiSharp.Experimental.Requests.Interfaces;
[TestClass]
public class ITraktHttpRequestTests
{... | mit | C# | |
2dbc183a969cb82c22b60eaed90f6f7e9e059d0c | Add ITokenService interface | denismaster/dcs,denismaster/dcs,denismaster/dcs,denismaster/dcs | src/Diploms.WebUI/Authentication/ITokenService.cs | src/Diploms.WebUI/Authentication/ITokenService.cs | using Diploms.Dto.Login;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json;
using System.Threading.Tasks;
namespace Diploms.WebUI.Authentication
{
public interface ITokenService
{
Task<ObjectResult> IssueToken(LoginDto user, JwtIssuerOptions _jwtOptions, JsonSerializerSettings _serializerSettings);... | mit | C# | |
2f26728cdb6a28235a9e15c9e1acd0296938fb05 | Add test coverage of editor sample playback | UselessToucan/osu,smoogipoo/osu,peppy/osu,peppy/osu,NeoAdonis/osu,ppy/osu,smoogipoo/osu,smoogipooo/osu,peppy/osu-new,ppy/osu,UselessToucan/osu,ppy/osu,smoogipoo/osu,UselessToucan/osu,NeoAdonis/osu,peppy/osu,NeoAdonis/osu | osu.Game.Tests/Visual/Editing/TestSceneEditorSamplePlayback.cs | osu.Game.Tests/Visual/Editing/TestSceneEditorSamplePlayback.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.Graphics.Audio;
using osu.Framework.Testing;
using osu.Game.Rulesets;
using osu.Game.Rulesets.Osu;
using osu... | mit | C# | |
0544eea17ec66e11d6112bb50754d8c7c8223f9a | add Upgrade_20221012_UpdateNugets2 | signumsoftware/framework,signumsoftware/framework | Signum.Upgrade/Upgrades/Upgrade_20221012_UpdateNugets2.cs | Signum.Upgrade/Upgrades/Upgrade_20221012_UpdateNugets2.cs | using Signum.Utilities;
using System.Collections.Generic;
namespace Signum.Upgrade.Upgrades;
class Upgrade_20221012_UpdateNugets2 : CodeUpgradeBase
{
public override string Description => "Updates Nuget again";
public override void Execute(UpgradeContext uctx)
{
uctx.ForeachCodeFile(@"... | mit | C# | |
4be581a2f379b74dc495ccdf9b77180bd159bc7d | Make oAuth setting files | CloudBreadProject/CloudBread-Unity-SDK | Assets/CloudBread/Editor/CBAuthEditor.cs | Assets/CloudBread/Editor/CBAuthEditor.cs | using UnityEngine;
using UnityEditor;
using System.Collections;
namespace CloudBread
{
public class CBAuthEditor : EditorWindow
{
static CBAuthEditor _instance = null;
[MenuItem("CloudBread/CB-Authentication")]
public static void InitWindow()
{
if (null == _instance)
{
_instance = GetWindow<CBAu... | mit | C# | |
f74d44bfcbacc3b3c7ec3c6ec25c79c9838d053e | Add missing TasksModel.cs file | SauliusSun/DayTasksPrioritizer | DayTasksPrioritizer/Models/TasksModel.cs | DayTasksPrioritizer/Models/TasksModel.cs | using System.Collections.Generic;
namespace DayTasksPrioritizer.Models
{
public class TasksModel
{
public List<TaskModel> TasksList { get; set; }
public TasksModel()
{
TasksList = new List<TaskModel>();
}
}
} | mit | C# | |
e8019fe187dc9e314c3e10e92ea2380abe0336ed | use editable in schema tags (#2528) | superyyrrzz/docfx,superyyrrzz/docfx,superyyrrzz/docfx,dotnet/docfx,dotnet/docfx,dotnet/docfx | src/Microsoft.DocAsCode.Build.SchemaDriven/SchemaExtensions.cs | src/Microsoft.DocAsCode.Build.SchemaDriven/SchemaExtensions.cs | // Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
namespace Microsoft.DocAsCode.Build.SchemaDriven
{
public static class SchemaExtensions
{
private const string IsRequiredInFragmentsTag = "editable";
... | mit | C# | |
b742e3f23914e3480e8a2813e3135192b9f7ca3d | Copy of other project to get started. | jandockx/ppwcode-recovered-from-google-code,jandockx/ppwcode-recovered-from-google-code,jandockx/ppwcode-recovered-from-google-code,jandppw/ppwcode-recovered-from-google-code,jandppw/ppwcode-recovered-from-google-code,jandppw/ppwcode-recovered-from-google-code,jandppw/ppwcode-recovered-from-google-code,jandockx/ppwcode... | dotnet/Util/SharePoint/trunk/I/Properties/AssemblyInfo.cs | dotnet/Util/SharePoint/trunk/I/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... | apache-2.0 | C# | |
1cd8443e9fe7fdf34ee88140771aa8d7a63783c1 | Fix OsBrandStringTests.WindowsIsPrettified | Ky7m/BenchmarkDotNet,ig-sinicyn/BenchmarkDotNet,PerfDotNet/BenchmarkDotNet,Teknikaali/BenchmarkDotNet,ig-sinicyn/BenchmarkDotNet,PerfDotNet/BenchmarkDotNet,alinasmirnova/BenchmarkDotNet,alinasmirnova/BenchmarkDotNet,Teknikaali/BenchmarkDotNet,adamsitnik/BenchmarkDotNet,adamsitnik/BenchmarkDotNet,alinasmirnova/Benchmark... | tests/BenchmarkDotNet.Tests/Environments/OsBrandStringTests.cs | tests/BenchmarkDotNet.Tests/Environments/OsBrandStringTests.cs | using BenchmarkDotNet.Environments;
using Xunit;
namespace BenchmarkDotNet.Tests.Environments
{
public class OsBrandStringTests
{
[Theory]
[InlineData("6.3.9600", "Windows 8.1 (6.3.9600)")]
[InlineData("10.0.14393", "Windows 10 Redstone 1 [1607, Anniversary Update] (10.0.14393)")]
... | using BenchmarkDotNet.Environments;
using Xunit;
namespace BenchmarkDotNet.Tests.Environments
{
public class OsBrandStringTests
{
[Theory]
[InlineData("6.3.9600", "Windows 8.1 (6.3.9600)")]
[InlineData("10.0.14393", "Windows 10 Redstone 1 (10.0.14393)")]
public void WindowsIsPre... | mit | C# |
2650674b4ea70ad1873406cbd09640e78a34ff1a | Add ValidationUtilities.GetMethods | riganti/dotvvm-samples-academy,riganti/dotvvm-samples-academy,riganti/dotvvm-samples-academy | DotvvmAcademy/DotvvmAcademy.Validation/ValidationUtilities.cs | DotvvmAcademy/DotvvmAcademy.Validation/ValidationUtilities.cs | using DotvvmAcademy.Validation.Abstractions;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Reflection;
namespace DotvvmAcademy.Validation
{
public static class ValidationUtilities
{
public static IDictionary<string, MethodInfo> GetValidationMethods<TD... | apache-2.0 | C# | |
57cdc41439817f2f0da71e10ed1c2fda63417f15 | modify CustomOAuthAttribute | mc7246/WeiXinMPSDK,mc7246/WeiXinMPSDK,lishewen/WeiXinMPSDK,jiehanlin/WeiXinMPSDK,lishewen/WeiXinMPSDK,mc7246/WeiXinMPSDK,JeffreySu/WeiXinMPSDK,jiehanlin/WeiXinMPSDK,lishewen/WeiXinMPSDK,jiehanlin/WeiXinMPSDK,JeffreySu/WeiXinMPSDK,JeffreySu/WeiXinMPSDK | Samples/Senparc.Weixin.MP.Sample.vs2017/Senparc.Weixin.MP.CoreSample/Filters/CustomOAuthAttribute.cs | Samples/Senparc.Weixin.MP.Sample.vs2017/Senparc.Weixin.MP.CoreSample/Filters/CustomOAuthAttribute.cs | using System.Web;
using Microsoft.AspNetCore.Http;
using Senparc.Weixin.MP.MvcExtension;
namespace Senparc.Weixin.MP.CoreSample.Filters
{
/// <summary>
/// OAuth自动验证,可以加在Action或整个Controller上
/// </summary>
public class CustomOAuthAttribute : SenparcOAuthAttribute
{
public CustomOAuthAttrib... | apache-2.0 | C# | |
dffb4bc885c30191b4b300af5f5943d0b130b4cd | Create Pot.cs | SurgicalSteel/Competitive-Programming,SurgicalSteel/Competitive-Programming,SurgicalSteel/Competitive-Programming,SurgicalSteel/Competitive-Programming,SurgicalSteel/Competitive-Programming | Kattis-Solutions/Pot.cs | Kattis-Solutions/Pot.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Pot
{
class Program
{
static int pangkat(int nb, int np)
{
if (np == 0) { return 1; }
else { return nb * pangkat(nb, np - 1); }
}
... | mit | C# | |
b81e9b596e100bdadf3fdbae2d2dbbab363fa893 | Save Form 2&1 | Orcunegeacar/Dream-Browser | Information.cs | Information.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Dream_Browser
{
public class Information
{
private string data1;
private string data2;
private string data3;
public string Data1
{
get { r... | mpl-2.0 | C# | |
f4e745ab23658b01422d537d0561f1d60aaf16c0 | Add SingaporeProvider | tinohager/Nager.Date,tinohager/Nager.Date,tinohager/Nager.Date | Src/Nager.Date/PublicHolidays/SingaporeProvider.cs | Src/Nager.Date/PublicHolidays/SingaporeProvider.cs | using Nager.Date.Contract;
using Nager.Date.Model;
using System.Collections.Generic;
using System.Linq;
namespace Nager.Date.PublicHolidays
{
/// <summary>
/// Singapore
/// </summary>
public class SingaporeProvider : IPublicHolidayProvider
{
/// <summary>
/// SingaporeProvider
... | mit | C# | |
bba34b73abe6ba63119defa7822a674f07bf392f | Add use of tag-helpers instead of razor elements. Remove useless displayfor. | TypeW/eShopOnContainers,BillWagner/eShopOnContainers,skynode/eShopOnContainers,productinfo/eShopOnContainers,dotnet-architecture/eShopOnContainers,dotnet-architecture/eShopOnContainers,skynode/eShopOnContainers,TypeW/eShopOnContainers,TypeW/eShopOnContainers,TypeW/eShopOnContainers,andrelmp/eShopOnContainers,andrelmp/e... | src/Web/WebMonolithic/eShopWeb/Views/Catalog/_pagination.cshtml | src/Web/WebMonolithic/eShopWeb/Views/Catalog/_pagination.cshtml | @model eShopWeb.ViewModels.PaginationInfo
<div class="esh-pager">
<div class="container">
<article class="esh-pager-wrapper row">
<nav>
<a class="esh-pager-item esh-pager-item--navigable @Model.Previous"
id="Previous"
... | @model eShopWeb.ViewModels.PaginationInfo
<div class="esh-pager">
<div class="container">
<article class="esh-pager-wrapper row">
<nav>
<a class="esh-pager-item esh-pager-item--navigable @Model.Previous"
id="Previous"
href="@Url.Actio... | mit | C# |
4db656b8c410a10160f5be790133669bf16b3cb6 | Add HistogramSeriesExamples | oxyplot/documentation-examples | ExampleGenerator/Series/HistogramSeriesExamples.cs | ExampleGenerator/Series/HistogramSeriesExamples.cs | namespace ExampleGenerator
{
using System;
using System.Collections.Generic;
using OxyPlot;
using OxyPlot.Axes;
using OxyPlot.Series;
public class HistogramSeriesExamples
{
[Export("Series/HistogramSeries")]
public static PlotModel HistogramSeries()
{
//... | mit | C# | |
65d1ef8449cd19c062b029d9732d7a8e086dedea | Add Preset2 class for mapping BI Preset2 files | BeowulfStratOps/BSU.Sync | FileTypes/BI/Preset2.cs | FileTypes/BI/Preset2.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Xml;
using System.Xml.Serialization;
namespace BSU.Sync.FileTypes.BI
{
[XmlRoot(ElementName = "addons-presets")]
public class Preset2
{
[XmlElement(ElementName = "last-u... | mit | C# | |
ba9a4d85b01daaefc2c221dd4ba9b33cc236b649 | add missing Server\TConsole.cs | DeathCradle/Terraria-s-Dedicated-Server-Mod,DeathCradle/Terraria-s-Dedicated-Server-Mod,DeathCradle/Terraria-s-Dedicated-Server-Mod,DeathCradle/Terraria-s-Dedicated-Server-Mod | Terraria_Server/Server/TConsole.cs | Terraria_Server/Server/TConsole.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
namespace Terraria_Server
{
public class TConsole
{
StreamWriter streamWriter = null;
public TConsole(string serverLog)
{
streamWriter = new StreamWriter(serverLog);
... | mit | C# | |
14f75e80f186e063c8134c1cbe9b9ce4a953fecf | Add Unit Test for Report Training Provider Command Handler | SkillsFundingAgency/das-employerapprenticeshipsservice,SkillsFundingAgency/das-employerapprenticeshipsservice,SkillsFundingAgency/das-employerapprenticeshipsservice | src/SFA.DAS.EmployerAccounts.UnitTests/Commands/ReportTrainingProvider/WhenReportingATrainingProvider.cs | src/SFA.DAS.EmployerAccounts.UnitTests/Commands/ReportTrainingProvider/WhenReportingATrainingProvider.cs | using MediatR;
using Moq;
using NServiceBus;
using NUnit.Framework;
using SFA.DAS.EmployerAccounts.Commands.ReportTrainingProvider;
using SFA.DAS.EmployerAccounts.Configuration;
using SFA.DAS.NLog.Logger;
using SFA.DAS.Notifications.Messages.Commands;
using System;
using System.Collections.Generic;
using System.Linq;
... | mit | C# | |
2387b24465240fc8894a63a0f0863b3d00e196db | add support for new ASP.NET packaging (missing file from previous commit) | apache/npanday,apache/npanday,apache/npanday,apache/npanday | dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/ASPNetPomConverter.cs | dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/ASPNetPomConverter.cs | #region Apache License, Version 2.0
//
// Licensed to the Apache Software Foundation (ASF) under one
// or more contributor license agreements. See the NOTICE file
// distributed with this work for additional information
// regarding copyright ownership. The ASF licenses this file
// to you under the Apache License, ... | apache-2.0 | C# | |
aff79a551f09082ef797c8e9d480f49bf8b4c83d | Set up manager and admin users. bugid: 912 | MarimerLLC/csla,JasonBock/csla,rockfordlhotka/csla,jonnybee/csla,ronnymgm/csla-light,rockfordlhotka/csla,JasonBock/csla,BrettJaner/csla,JasonBock/csla,BrettJaner/csla,rockfordlhotka/csla,jonnybee/csla,BrettJaner/csla,ronnymgm/csla-light,jonnybee/csla,MarimerLLC/csla,ronnymgm/csla-light,MarimerLLC/csla | Samples/NET/cs/ProjectTracker/ProjectTracker.DalMock/MockDb.cs | Samples/NET/cs/ProjectTracker/ProjectTracker.DalMock/MockDb.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using ProjectTracker.DalMock.MockDbTypes;
namespace ProjectTracker.DalMock
{
public static class MockDb
{
public static List<ProjectData> Projects { get; private set; }
public static List<ResourceData> Resourc... | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using ProjectTracker.DalMock.MockDbTypes;
namespace ProjectTracker.DalMock
{
public static class MockDb
{
public static List<ProjectData> Projects { get; private set; }
public static List<ResourceData> Resourc... | mit | C# |
aa3b186a36de49e930459898549afa225af7962c | Add TestConstants class | mperdeck/jsnlog | src/JSNLog.Tests/TestConstants.cs | src/JSNLog.Tests/TestConstants.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
namespace JSNLog.Tests
{
public class TestConstants
{
public const string _jsnlogDirectory = @"C:\Dev\JSNLog\";
// All tests here write a partial with the complete demo html.
// The partia... | mit | C# | |
112096768b2107645ec0cafcad8bd9a8893c18ac | Add test checking incompatibility of multi mods | ppy/osu,peppy/osu,peppy/osu,peppy/osu,ppy/osu,NeoAdonis/osu,NeoAdonis/osu,ppy/osu,NeoAdonis/osu | osu.Game.Tests/Mods/MultiModIncompatibilityTest.cs | osu.Game.Tests/Mods/MultiModIncompatibilityTest.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.Game.Rulesets;
using osu.Game.Rulesets.Catch;
using osu.Game.Rulesets.... | mit | C# | |
e76a9a3e007770073a6ae635777c275306ae5df1 | Create FontStyleSlant.cs | wieslawsoltes/Draw2D,wieslawsoltes/Draw2D,wieslawsoltes/Draw2D | src/Draw2D.ViewModels/Style/Core/FontStyleSlant.cs | src/Draw2D.ViewModels/Style/Core/FontStyleSlant.cs | // Copyright (c) Wiesław Šoltés. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
namespace Draw2D.ViewModels.Style
{
public enum FontStyleSlant
{
Upright = 0,
Italic = 1,
Oblique = 2
}
}
| mit | C# | |
5011bdc44461108b8b0ae708052d4e39240c8d3a | Simplify null check. | karthiknadig/RTVS,AlexanderSher/RTVS,karthiknadig/RTVS,AlexanderSher/RTVS,AlexanderSher/RTVS,AlexanderSher/RTVS,karthiknadig/RTVS,MikhailArkhipov/RTVS,karthiknadig/RTVS,AlexanderSher/RTVS,karthiknadig/RTVS,MikhailArkhipov/RTVS,MikhailArkhipov/RTVS,MikhailArkhipov/RTVS,MikhailArkhipov/RTVS,MikhailArkhipov/RTVS,karthikna... | src/Package/Impl/DataInspect/Viewers/GridViewer.cs | src/Package/Impl/DataInspect/Viewers/GridViewer.cs | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.
using System.ComponentModel.Composition;
using Microsoft.R.DataInspection;
namespace Microsoft.VisualStudio.R.Package.DataInspect.Viewers {
[Export(typeof(IObje... | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.
using System.ComponentModel.Composition;
using Microsoft.R.DataInspection;
namespace Microsoft.VisualStudio.R.Package.DataInspect.Viewers {
[Export(typeof(IObje... | mit | C# |
ae948ed25525df9f86e5c8dc04ec0285dfd163b6 | Add SendGrid Sender | anthonyvscode/FluentEmail,anthonyvscode/FluentEmail,lukencode/FluentEmail,lukencode/FluentEmail | src/Senders/FluentEmail.SendGrid/SendGridSender.cs | src/Senders/FluentEmail.SendGrid/SendGridSender.cs | using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using FluentEmail.Core;
using FluentEmail.Core.Interfaces;
using FluentEmail.Core.Models;
using SendGrid;
using SendGrid.Hel... | mit | C# | |
09fe28adf373242112e73f7d1af54d9fb63ceff0 | Create NANDGate.cs | irtezasyed007/CSC523-Game-Project | Gates/NANDGate.cs | Gates/NANDGate.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace CSC_523_Game.Gates
{
class NANDGate : ANDGate
{
public NANDGate(Variable [] vars) : base(vars)
{
}
public override bool getResult()
{
return !base.gateOperation... | mit | C# | |
9910dd9705c976a0badb6545887147c436c31046 | Create 20170707.cs | twilightspike/cuddly-disco,twilightspike/cuddly-disco | main/20170707.cs | main/20170707.cs | float timer = 80f;
| mit | C# | |
625b919a25f22da921ccd45b849ec62a7ebd33ab | Create SQLExtensions.cs | keith-hall/Extensions,keith-hall/Extensions | src/SQLExtensions.cs | src/SQLExtensions.cs | // code taken from: https://jonnybekkum.wordpress.com/2013/03/02/linqpad-dumpasinsert-extension/
public static class SQLExtensions {
public static IEnumerable<T> DumpAsInsert<T>(this IEnumerable<T> data) where T:class
{
return DumpAsInsert(data, null);
}
public static IEnumerable<T> DumpAsInsert<T>(this IEnumer... | apache-2.0 | C# | |
543986ae77977579bcd05fcbd119b4c6f2c694e5 | Add NSMutableSet | mono/maccore,cwensley/maccore,jorik041/maccore | src/Foundation/NSMutableSet.cs | src/Foundation/NSMutableSet.cs | //
// This file describes the API that the generator will produce
//
// Authors:
// Miguel de Icaza
//
// Copyright 2012, 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 ... | apache-2.0 | C# | |
b08785068117b8e7b6ab27ca9825b2657758fe17 | add pictureviewmodel due to issues with DB if there is only picture model | SoftwareFans/AstroPhotoGallery,SoftwareFans/AstroPhotoGallery,SoftwareFans/AstroPhotoGallery | AstroPhotoGallery/AstroPhotoGallery/Models/PictureViewModel.cs | AstroPhotoGallery/AstroPhotoGallery/Models/PictureViewModel.cs | using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;
namespace AstroPhotoGallery.Models
{
public class PictureViewModel
{
public int Id { get; set; }
[Required]
[StringLength(50)]... | mit | C# | |
cb1da2b6cc6edd1b9e0b30b4c8cc40ca5573b4d4 | Add example for storing a private key in a file | ektrah/nsec | tests/Examples/ExportImport.cs | tests/Examples/ExportImport.cs | using System;
using NSec.Cryptography;
using System.Collections.Generic;
using Xunit;
namespace NSec.Tests.Examples
{
public static class ExportImport
{
[Fact]
public static void ExportImportNSecPrivateKey()
{
// fake System.IO.File
var File = new Dictionary<stri... | mit | C# | |
44d906e2eefa4d7d3cf89669cd6eaa315e7294d3 | Add IAcceptor interface. | cbojar/acceptor-csharp | IAcceptor.cs | IAcceptor.cs | using System;
namespace CBojar.Acceptors
{
public interface IAcceptor<T>
{
IAcceptor<T> Accept(Action<T> visitor);
IAcceptor<T> Accept<U>(Action<U> visitor) where U : T;
IAcceptor<T> Accept<U, V>(Action<V> visitor) where U : T, V;
}
} | mit | C# | |
44dd9a57a8718da214ea801b35b9aca941518cc1 | Add abstract hit object application test scene | peppy/osu-new,peppy/osu,smoogipoo/osu,UselessToucan/osu,ppy/osu,NeoAdonis/osu,ppy/osu,UselessToucan/osu,NeoAdonis/osu,smoogipooo/osu,NeoAdonis/osu,peppy/osu,smoogipoo/osu,UselessToucan/osu,smoogipoo/osu,peppy/osu,ppy/osu | osu.Game.Rulesets.Taiko.Tests/HitObjectApplicationTestScene.cs | osu.Game.Rulesets.Taiko.Tests/HitObjectApplicationTestScene.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 osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Testing;
using osu.Framework.Timing;
using osu.Game.Beatmaps;
using osu.Ga... | mit | C# | |
21cd46c441eed0ddfc0c61d4349877a94bba17c5 | Add DepartmentService | denismaster/dcs,denismaster/dcs,denismaster/dcs,denismaster/dcs | src/Diploms.Services/Departments/DepartmentsService.cs | src/Diploms.Services/Departments/DepartmentsService.cs | using System;
using System.Threading.Tasks;
using AutoMapper;
using Diploms.Core;
using Diploms.Dto;
using Diploms.Dto.Departments;
namespace Diploms.Services.Departments
{
public class DepartmentsService
{
private readonly IRepository<Department> _repository;
private readonly IMapper _mapper;... | mit | C# | |
b16556a95d45d652d75cd747a122e168a40d6497 | Create NodesListBoxDropHandler.cs | wieslawsoltes/AvaloniaBehaviors,wieslawsoltes/AvaloniaBehaviors | samples/DragAndDropSample/Behaviors/NodesListBoxDropHandler.cs | samples/DragAndDropSample/Behaviors/NodesListBoxDropHandler.cs | using Avalonia.Controls;
using Avalonia.Input;
using Avalonia.VisualTree;
using Avalonia.Xaml.Interactions.DragAndDrop;
using DragAndDropSample.ViewModels;
namespace DragAndDropSample.Behaviors
{
public class NodesListBoxDropHandler : DropHandlerBase
{
private bool Validate<T>(ListBox listBox, DragEven... | mit | C# | |
46669b18cba836ae3e0c500f9539895c2ce36ae2 | Add C# API test class | zelloptt/zello-for-work-server-api-libs,zelloptt/zello-for-work-server-api-libs,zelloptt/zello-for-work-server-api-libs,zelloptt/zello-for-work-server-api-libs,zelloptt/zello-for-work-server-api-libs,zelloptt/zello-for-work-server-api-libs | csharp/APITest.cs | csharp/APITest.cs | //
// Copyright © 2016 Zello. All rights reserved.
//
using System;
using System.Collections.Generic;
using System.Collections;
using System.Security.Cryptography;
using System.Text;
namespace Zello.API
{
public class APITest
{
readonly ZelloAPI api;
public APITest(string host, string apiKey, string username... | mit | C# | |
9f647a83b5f83eed925a146be6dfeb861fa4a394 | Add missing file. | mcartoixa/Common.FileTransfer,mcartoixa/Common.FileTransfer | FileTransfer/FileSystem/FileSystemTransferClient.cs | FileTransfer/FileSystem/FileSystemTransferClient.cs | using System;
using System.IO;
using System.Threading.Tasks;
namespace Common.FileTransfer.FileSystem
{
public class FileSystemTransferClient:
FileTransferClient
{
public FileSystemTransferClient(Uri baseAddress):
base(baseAddress)
{
}
protected override T... | mit | C# | |
4cbeea8ce06085187de6d74042c5ff12aa780d10 | Add unit test. | richardszalay/mockhttp | RichardSzalay.MockHttp.Tests/Issues/Issue86Tests.cs | RichardSzalay.MockHttp.Tests/Issues/Issue86Tests.cs | using System;
using System.Net;
using System.Threading.Tasks;
using Xunit;
namespace RichardSzalay.MockHttp.Tests.Issues
{
public class Issue86Tests
{
[Fact]
public async Task Forgetting_to_configure_response_throws()
{
// Given
var mockHttp = new MockHttp();
... | mit | C# | |
6d2e614bb0edc518c95055c222046c643b319c2f | Add C# AI | AI-comp/Terraforming,AI-comp/Terraforming,AI-comp/Terraforming,AI-comp/Terraforming,AI-comp/Terraforming,AI-comp/Terraforming,AI-comp/Terraforming,AI-comp/Terraforming | SampleAI/CSharp/Program.cs | SampleAI/CSharp/Program.cs | using System;
public class AI {
public static void Main(string[] args) {
Console.WriteLine("SampleCSharp");
while (true) {
var line = Console.ReadLine();
if (line == null) break;
if (line != "EOS") continue;
Console.WriteLine("finish");
}
}
}
| apache-2.0 | C# | |
25af4c958b144cfe41a5ec9c78bd191fca9fae97 | Add custom code for the AddWatch method | GStreamer/gstreamer-sharp,GStreamer/gstreamer-sharp,freedesktop-unofficial-mirror/gstreamer__gstreamer-sharp,gstreamer-sharp/gstreamer-sharp,freedesktop-unofficial-mirror/gstreamer__gstreamer-sharp,GStreamer/gstreamer-sharp,gstreamer-sharp/gstreamer-sharp,gstreamer-sharp/gstreamer-sharp,freedesktop-unofficial-mirror/gs... | sources/custom/Bus.cs | sources/custom/Bus.cs | // Copyright (C) 2013 Bertrand Lorentz <bertrand.lorentz@gmail.com>
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any lat... | lgpl-2.1 | C# | |
0a3cab1442131ab568559e877c7e29ba487746ef | add pattern for DataIntegrator | iakov/qreal,iakov/qreal,iakov/qreal,iakov/qreal,iakov/qreal,iakov/qreal,iakov/qreal,iakov/qreal,iakov/qreal | plugins/sbt/sbtGenerator/template/DataIntegrator.cs | plugins/sbt/sbtGenerator/template/DataIntegrator.cs | using System;
public class @@DataIntegrator@@
{
public @@DataIntegrator@@()
{
}
private string query = "@@queryString@@";
public @@ReturnDataObject@@ executeQuery(@@ParameterDataObject@@ dataObject)
{
return new @@ReturnDataObject@@();
}
}
| apache-2.0 | C# | |
7cf1f4e2f9cd9b0e5f9f89b0a3160fa41f90ef28 | Create renameExportDWG.cs | Gytaco/RevitAPI,Gytaco/RevitAPI | Macros/CS/ImportExport/renameExportDWG.cs | Macros/CS/ImportExport/renameExportDWG.cs | /*
This is a simple routine that allows a user to customise the naming of their DWG exports. It will save people alot
of time. Please make sure you rename the ExportDWGSettings to "Adam" or a custom export setting name
as well as change the folder location before using this feature.
*/
public void renameExport... | mit | C# | |
03a8c10865718463f26366596a4dc7679cba4e00 | Implement trie | Gerula/interviews,Gerula/interviews,Gerula/interviews,Gerula/interviews,Gerula/interviews | LeetCode/remote/implement_trie.cs | LeetCode/remote/implement_trie.cs | // https://leetcode.com/submissions/detail/36702616/
class TrieNode {
// Initialize your data structure here.
public Dictionary<char, TrieNode> next = new Dictionary<char, TrieNode>();
public bool isWord;
public TrieNode() {
}
}
public class Trie {
private TrieNode root;
public... | mit | C# | |
33f8343b538e5be38332ed9b73c70fdb2075f806 | Fix default timeout for non-value-returning overload of GetResultOnUIThread. | karthiknadig/RTVS,MikhailArkhipov/RTVS,karthiknadig/RTVS,karthiknadig/RTVS,karthiknadig/RTVS,AlexanderSher/RTVS,AlexanderSher/RTVS,MikhailArkhipov/RTVS,MikhailArkhipov/RTVS,AlexanderSher/RTVS,karthiknadig/RTVS,MikhailArkhipov/RTVS,AlexanderSher/RTVS,MikhailArkhipov/RTVS,AlexanderSher/RTVS,karthiknadig/RTVS,karthiknadig... | src/Debugger/Engine/Impl/TaskExtensions.cs | src/Debugger/Engine/Impl/TaskExtensions.cs | using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.Common.Core;
using Microsoft.VisualStudio.Shell;
using Microsoft.VisualStudio.Shell.Interop;
using ... | using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.Common.Core;
using Microsoft.VisualStudio.Shell;
using Microsoft.VisualStudio.Shell.Interop;
using ... | mit | C# |
1d2302bfe9684d6f6de21cccca3a8b803c4c1ae7 | Create JSCookbook.Master.cs | lerwine/JSCookbook,lerwine/JSCookbook,lerwine/JSCookbook | JSCookbook/JSCookbook.Master.cs | JSCookbook/JSCookbook.Master.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
namespace JSCookbook
{
public partial class JSCookbook_Master : System.Web.UI.MasterPage
{
protected void Page_Load(object sender, EventArgs e)
{
}
... | apache-2.0 | C# | |
0ade34b93694f748455b6d1edc2186210d177bdd | add Upgrade_20220211_FixBrakpoint | signumsoftware/framework,signumsoftware/framework | Signum.Upgrade/Upgrades/Upgrade_20220211_FixBrakpoint.cs | Signum.Upgrade/Upgrades/Upgrade_20220211_FixBrakpoint.cs | using Signum.Utilities;
namespace Signum.Upgrade.Upgrades;
class Upgrade_20220211_FixBrakpoint : CodeUpgradeBase
{
public override string Description => "Change Breakpoint to sm because breakpoints round down";
public override void Execute(UpgradeContext uctx)
{
uctx.ChangeCodeFile(@"Southwind.Re... | mit | C# | |
21d3def3101f282576a1cbea61014ec7d59de93b | Add SongComparer to repo | GeorgeHahn/SOVND | SOVND.Lib/Utils/SongComparer.cs | SOVND.Lib/Utils/SongComparer.cs | using System;
using System.Collections;
using SOVND.Lib.Models;
namespace SOVND.Lib.Utils
{
public class SongComparer : IComparer
{
public int Compare(object x, object y)
{
var xs = x as Song;
var ys = y as Song;
if (xs == null)
throw new Argu... | epl-1.0 | C# | |
9e34baec8f8e36200ed20d3946dba2f3dcc29b06 | Add AsEnumerable | nuke-build/nuke,nuke-build/nuke,nuke-build/nuke,nuke-build/nuke | source/Nuke.Common/Utilities/Collections/Enumerable.AsEnumerable.cs | source/Nuke.Common/Utilities/Collections/Enumerable.AsEnumerable.cs | // Copyright 2020 Maintainers of NUKE.
// Distributed under the MIT License.
// https://github.com/nuke-build/nuke/blob/master/LICENSE
using System.Collections;
using System.Collections.Generic;
using System.Linq;
namespace Nuke.Common.Utilities.Collections
{
public static partial class EnumerableExtensions
... | mit | C# | |
ca66e89899f5d09cd28fa2e071dc2f7d12f356fe | Add a basic attribute routing test | aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore | test/Microsoft.AspNetCore.Routing.Performance/RoutingBenchmark.cs | test/Microsoft.AspNetCore.Routing.Performance/RoutingBenchmark.cs | // Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using System;
using System.Linq;
using System.Text.Encodings.Web;
using System.Threading.Tasks;
using BenchmarkDotNet.Attributes;
using Microsoft.AspNet... | apache-2.0 | C# | |
38d9750c2b799a9c88eb924858c98728a0f74b0f | Change color of components to highlight them. | sts-CAD-Software/PCB-Investigator-Scripts | HighligtSelectionCMPs.cs | HighligtSelectionCMPs.cs | //ASynchronous template
//-----------------------------------------------------------------------------------
// PCB-Investigator Automation Script
// Created on 01.03.2016
// Autor support@easylogix.de
// www.pcb-investigator.com
// SDK online reference http://www.pcb-investigator.com/sites/default/files/documen... | bsd-3-clause | C# | |
a9094f59f93f7824f03e14abfa5e5c03015b2b4a | Add NStoolbarItem.cs which now supports an Activated event | PlayScriptRedux/monomac,dlech/monomac | src/AppKit/NSToolbarItem.cs | src/AppKit/NSToolbarItem.cs | //
// NSToolbarItem.cs: Support for the NSToolbarItem class
//
// Author:
// Johan Hammar
//
using System;
using MonoMac.ObjCRuntime;
using MonoMac.Foundation;
namespace MonoMac.AppKit {
public partial class NSToolbarItem {
public event EventHandler Activated {
add {
Target = ActionDispatcher.SetupActi... | apache-2.0 | C# | |
69b87b16e64a4f2a571422da07f2d92dc295ce05 | Create Item.cs | QetriX/quly | Assets/Scripts/Item.cs | Assets/Scripts/Item.cs | namespace Quly
{
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
[Serializable]
public class Item
{
protected string _name;
protected float _weight = 1;
// List<Item> _rewards;
protected int _materialCapacity = 100; // How much material can the item contain ... | mit | C# | |
e6b89481a47740a83801adb6e6c09bdae7c85b0f | Fix missing files for release 3.7.4.2704 | Patagames/Pdf.WinForms | Print/PrintSizeMode.cs | Print/PrintSizeMode.cs | namespace Patagames.Pdf.Net.Controls.WinForms
{
/// <summary>
/// Represents the scaling options of the page for printing
/// </summary>
public enum PrintSizeMode
{
/// <summary>
/// Fit page
/// </summary>
Fit,
/// <summary>
/// Actual size
... | mit | C# | |
d99a1b7bd1b52138be796806fecc25e676abf0bb | Create HelloWorld.cs | ram381/hello-word | HelloWorld.cs | HelloWorld.cs | Console.ReadLine("Hello, World !");
| mpl-2.0 | C# | |
dd4d4b756b7928ac762e84cbe72cc55ad3836237 | Create CameraPan.cs | xxmon/unity | CameraPan.cs | CameraPan.cs | using UnityEngine;
using System.Collections;
public class CameraPan : MonoBehaviour {
public Vector3 lastPosition;
public Vector3 startPosition;
// Use this for initialization
void Start () {
}
// Update is called once per frame
Vector3 CursorWorldPosition()
{
Vector3 position = new Vector3();
Ray ra... | mit | C# | |
08ac538983bbb7e57b5613a1cbb9336e99ecd43e | Fix expected Google Cloud Storage URL in unit test. | duplicati/duplicati,mnaiman/duplicati,duplicati/duplicati,mnaiman/duplicati,sitofabi/duplicati,sitofabi/duplicati,duplicati/duplicati,sitofabi/duplicati,sitofabi/duplicati,mnaiman/duplicati,sitofabi/duplicati,mnaiman/duplicati,duplicati/duplicati,duplicati/duplicati,mnaiman/duplicati | Duplicati/UnitTest/WebApiTests.cs | Duplicati/UnitTest/WebApiTests.cs | // Copyright (C) 2018, The Duplicati Team
// http://www.duplicati.com, info@duplicati.com
//
// This library is free software; you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as
// published by the Free Software Foundation; either version 2.1 of the
// L... | // Copyright (C) 2018, The Duplicati Team
// http://www.duplicati.com, info@duplicati.com
//
// This library is free software; you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as
// published by the Free Software Foundation; either version 2.1 of the
// L... | lgpl-2.1 | C# |
d95799c6f23fde329342953e26c693d7cb2a10f6 | Add test coverage | ppy/osu-framework,peppy/osu-framework,smoogipooo/osu-framework,ppy/osu-framework,peppy/osu-framework,ZLima12/osu-framework,ppy/osu-framework,ZLima12/osu-framework,peppy/osu-framework,smoogipooo/osu-framework | osu.Framework.Tests/Visual/Platform/TestScreenActiveState.cs | osu.Framework.Tests/Visual/Platform/TestScreenActiveState.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.Allocation;
using osu.Framework.Bindables;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Shapes;
using osu.Framework.Platform;
using osuT... | mit | C# | |
95d90def166d5d227435f7188a2d15acd1fd6e50 | Fix log usage | SonarSource/sonar-msbuild-runner,duncanpMS/sonar-msbuild-runner,duncanpMS/sonar-msbuild-runner,SonarSource-VisualStudio/sonar-scanner-msbuild,SonarSource-VisualStudio/sonar-scanner-msbuild,SonarSource-VisualStudio/sonar-msbuild-runner,duncanpMS/sonar-msbuild-runner,SonarSource-VisualStudio/sonar-msbuild-runner,SonarSou... | SonarQube.Bootstrapper/Program.cs | SonarQube.Bootstrapper/Program.cs | /*
* SonarQube Scanner for MSBuild
* Copyright (C) 2015-2017 SonarSource SA and Microsoft Corporation
* mailto: contact AT sonarsource DOT com
*
* Licensed under the MIT License.
* See LICENSE file in the project root for full license information.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY K... | /*
* SonarQube Scanner for MSBuild
* Copyright (C) 2015-2017 SonarSource SA and Microsoft Corporation
* mailto: contact AT sonarsource DOT com
*
* Licensed under the MIT License.
* See LICENSE file in the project root for full license information.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY K... | mit | C# |
7f1a67e066a7c9931c47fef99db1337bf9a656c9 | Add array test | DotNetCross/Memory.Unsafe | src/DotNetCross.Memory.Unsafe.Tests/Unsafe.ByteOffset.Test.cs | src/DotNetCross.Memory.Unsafe.Tests/Unsafe.ByteOffset.Test.cs | using System;
using Xunit;
namespace DotNetCross.Memory.Tests
{
public class Unsafe_ByteOffset_Test
{
[Fact]
public static unsafe void ByteOffset_BoxedInt()
{
var obj = (object)42;
ref var valueRef = ref Unsafe.Unbox<int>(obj);
var valueB... | mit | C# | |
d21d53741556e07f1e918e3504aa33878d983fb2 | Test fixup | jeff-pang/Nancy,charleypeng/Nancy,AcklenAvenue/Nancy,NancyFx/Nancy,vladlopes/Nancy,rudygt/Nancy,VQComms/Nancy,horsdal/Nancy,felipeleusin/Nancy,VQComms/Nancy,xt0rted/Nancy,jonathanfoster/Nancy,tareq-s/Nancy,sloncho/Nancy,jongleur1983/Nancy,tareq-s/Nancy,jeff-pang/Nancy,fly19890211/Nancy,lijunle/Nancy,sroylance/Nancy,Sav... | src/Nancy.ViewEngines.Razor.Tests/RazorViewCompilerFixture.cs | src/Nancy.ViewEngines.Razor.Tests/RazorViewCompilerFixture.cs | namespace Nancy.ViewEngines.Razor.Tests
{
using System;
using System.IO;
using FakeItEasy;
using Nancy.Tests;
using Xunit;
public class RazorViewCompilerFixture
{
private readonly RazorViewEngine engine;
private readonly IRenderContext renderContext;
pri... | namespace Nancy.ViewEngines.Razor.Tests
{
using System;
using System.IO;
using FakeItEasy;
using Nancy.Tests;
using Xunit;
public class RazorViewCompilerFixture
{
private readonly RazorViewEngine engine;
private readonly IRenderContext renderContext;
pri... | mit | C# |
00a0a88909acb216ed884b3982aef036ebb7b607 | Add tests for F.ForEach | farity/farity | Farity.Tests/ForEachTests.cs | Farity.Tests/ForEachTests.cs | using System;
using System.Collections.Generic;
using Xunit;
namespace Farity.Tests
{
public class ForEachTests
{
[Fact]
public void ForEachExecutesFunctionsForAllElementsInTheList()
{
var expected = "12345";
var collected = "";
var source = new List... | mit | C# | |
d42b22d5e81a6476432fa3b0430e2997d0ce2f2c | Add GCNotifier class. | AvaloniaUI/Avalonia,jkoritzinsky/Avalonia,wieslawsoltes/Perspex,wieslawsoltes/Perspex,AvaloniaUI/Avalonia,jkoritzinsky/Avalonia,Perspex/Perspex,AvaloniaUI/Avalonia,akrisiun/Perspex,AvaloniaUI/Avalonia,SuperJMN/Avalonia,jkoritzinsky/Avalonia,SuperJMN/Avalonia,SuperJMN/Avalonia,grokys/Perspex,AvaloniaUI/Avalonia,wieslaws... | src/Avalonia.Base/Utilities/GCNotifier.cs | src/Avalonia.Base/Utilities/GCNotifier.cs | // Copyright (c) The Avalonia Project. All rights reserved.
// Licensed under the MIT license. See licence.md file in the project root for full license information.
using System;
namespace Avalonia.Utilities
{
public class GCNotifier
{
public static event EventHandler GarbageCollected;
stati... | mit | C# | |
0d752df7a69fc2d7386332de33111e18bc63a5b7 | Create empty folder | lizaamini/CSharpExercises | Sheet-7/Exercise7A.cs | Sheet-7/Exercise7A.cs | mit | C# | ||
23a9c5338d049f838504275d5400f08be0184fe2 | add NHibernate batch sample (#77) | googleapis/dotnet-spanner-nhibernate,googleapis/dotnet-spanner-nhibernate | Google.Cloud.Spanner.NHibernate.Samples/Snippets/BatchSample.cs | Google.Cloud.Spanner.NHibernate.Samples/Snippets/BatchSample.cs | // Copyright 2022 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# | |
600ec8f84aee5662a986387ebfadac4c33bb9675 | Add base implementation for agent bus | pranavkm/Glimpse.Prototype,pranavkm/Glimpse.Prototype,zanetdev/Glimpse.Prototype,peterblazejewicz/Glimpse.Prototype,mike-kaufman/Glimpse.Prototype,pranavkm/Glimpse.Prototype,peterblazejewicz/Glimpse.Prototype,zanetdev/Glimpse.Prototype,pranavkm/Glimpse.Prototype,mike-kaufman/Glimpse.Prototype,mike-kaufman/Glimpse.Proto... | src/Glimpse.Agent.Common/Framework/DefaultMessageAgentBus.cs | src/Glimpse.Agent.Common/Framework/DefaultMessageAgentBus.cs | using System;
using System.Collections.Generic;
using System.Reactive.Linq;
using System.Reactive.Subjects;
using System.Reflection;
namespace Glimpse.Agent
{
public class DefaultMessageAgentBus : IMessageAgentBus
{
private readonly ISubject<IMessage> _subject;
// TODO: Review if we care abo... | mit | C# | |
0a7cb007696bd4f2ce546d0fa5f2d4461f28530e | Create Dauntless.cs | jon-lad/Battlefleet-Gothic | Ships/Imperial/Cruiser/Dauntless.cs | Ships/Imperial/Cruiser/Dauntless.cs | using UnityEngine;
using System.Collections;
public class Dauntless : Ship {
// Use this for initialization
public override void Start () {
base.Start ();
stand = (GameObject)Instantiate(GameData.instance.SmallStandPrefab, transform.position, Quaternion.Euler(new Vector3()));
hits = 8;
speed = 25;
minMo... | mit | C# | |
b5e43144a9be23ee4f2435981ab7f25ea8fcdef0 | Add a Player test scene that uses a legacy skin | smoogipooo/osu,UselessToucan/osu,smoogipoo/osu,UselessToucan/osu,smoogipoo/osu,ppy/osu,NeoAdonis/osu,peppy/osu,peppy/osu-new,UselessToucan/osu,NeoAdonis/osu,NeoAdonis/osu,smoogipoo/osu,ppy/osu,ppy/osu,peppy/osu,peppy/osu | osu.Game.Rulesets.Catch.Tests/TestSceneCatchPlayerLegacySkin.cs | osu.Game.Rulesets.Catch.Tests/TestSceneCatchPlayerLegacySkin.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.IO.Stores;
using osu.Game.Skinning;
using osu.Game.Tests.Visual;
na... | mit | C# | |
4c795f94983c9a31977a6b2389f9c4fb1502700d | Add context class | Lc5/CurrencyRates,Lc5/CurrencyRates,Lc5/CurrencyRates | src/DbContext.cs | src/DbContext.cs | using System.Data.Entity;
namespace CurrencyRates
{
class Context : DbContext
{
public Context() : base() {}
public DbSet<Currency> Currencies { get; set; }
public DbSet<File> Files { get; set; }
public DbSet<Rate> Rates { get; set; }
}
}
| mit | C# | |
0d2a24cdabd6ba2cb95cb842001eafa79964ed51 | Add snippets for Offset type | jskeet/nodatime,malcolmr/nodatime,nodatime/nodatime,BenJenkinson/nodatime,BenJenkinson/nodatime,malcolmr/nodatime,malcolmr/nodatime,malcolmr/nodatime,jskeet/nodatime,nodatime/nodatime | src/NodaTime.Demo/OffsetDemo.cs | src/NodaTime.Demo/OffsetDemo.cs | // Copyright 2018 The Noda Time Authors. All rights reserved.
// Use of this source code is governed by the Apache License 2.0,
// as found in the LICENSE.txt file.
using NUnit.Framework;
using System;
namespace NodaTime.Demo
{
public class OffsetDemo
{
[Test]
public void ConstructionFromHour... | apache-2.0 | C# | |
c068ce60b0953a20998328d4f8efb8426a5ed0ed | add EditorCardboardCamera script | UnityCommunity/UnityLibrary | Assets/Scripts/Camera/EditorCardboardCamera.cs | Assets/Scripts/Camera/EditorCardboardCamera.cs | using System.Collections;
using System.Collections.Generic;
using UnityEngine;
// editor only Google Carboard VR cam simulation with left alt + mouse
public class EditorCardboardCamera : MonoBehaviour
{
#if UNITY_EDITOR
Vector2 rotation = Vector2.zero;
public float speed = 3;
void Update()
... | mit | C# | |
89a3ca993ad241c5b52096bb45f6a659a684adad | add integration test for b2_authorize_account API | NebulousConcept/b2-csharp-client | b2-csharp-client-test/B2.Client/Apis/AuthorizeAccountV1/TestAuthorizeAccountV1.cs | b2-csharp-client-test/B2.Client/Apis/AuthorizeAccountV1/TestAuthorizeAccountV1.cs | using System;
using System.Threading.Tasks;
using NUnit.Framework;
using B2.Client.Rest;
using B2.Client.Test;
namespace B2.Client.Apis.AuthorizeAccountV1.Test
{
[TestFixture]
public class TestAuthorizeAccountV1
{
[Test]
public async Task TestAuthorizeAccountSuccess()
{
... | mit | C# | |
7ec5dc1e979bd55dded8f7295e0710345c69c92a | Add Maverick Sevmont as author | planetpowershell/planetpowershell,planetpowershell/planetpowershell,planetpowershell/planetpowershell,planetpowershell/planetpowershell | src/Firehose.Web/Authors/MaverickSevmont.cs | src/Firehose.Web/Authors/MaverickSevmont.cs | using System;
using System.Collections.Generic;
using System.Linq;
using System.ServiceModel.Syndication;
using System.Web;
using Firehose.Web.Infrastructure;
namespace Firehose.Web.Authors {
public class MaverickSevmont : IAmACommunityMember
{
public string FirstName => "Maverick";
... | mit | C# |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.