Instruction stringlengths 14 778 | input_code stringlengths 0 4.24k | output_code stringlengths 1 5.44k |
|---|---|---|
Remove random xml comment from file header | //-----------------------------------------------------------------------
// <copyright file="DataPortalMethodCache.cs" company="Marimer LLC">
// Copyright (c) Marimer LLC. All rights reserved.
// Website: https://cslanet.com
// </copyright>
// <summary>Gets a reference to the DataPortal_Create method for</sum... | //-----------------------------------------------------------------------
// <copyright file="DataPortalMethodCache.cs" company="Marimer LLC">
// Copyright (c) Marimer LLC. All rights reserved.
// Website: https://cslanet.com
// </copyright>
//-------------------------------------------------------------------... |
Change buried cards to screen bar in search page | /*
Copyright (C) 2016 Anki Universal Team <ankiuniversal@outlook.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 later version.
... | /*
Copyright (C) 2016 Anki Universal Team <ankiuniversal@outlook.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 later version.
... |
Improve readability of DbContextOptions code | using Microsoft.Data.Entity;
using Microsoft.Data.Entity.Infrastructure;
using Microsoft.Data.Entity.Metadata;
using System;
using System.Configuration;
using System.Linq;
namespace CycleSales.CycleSalesModel
{
public class CycleSalesContext : DbContext
{
public CycleSalesContext()
... | using Microsoft.Data.Entity;
using Microsoft.Data.Entity.Infrastructure;
using Microsoft.Data.Entity.Metadata;
using System;
using System.Configuration;
using System.Linq;
namespace CycleSales.CycleSalesModel
{
public class CycleSalesContext : DbContext
{
public CycleSalesContext()
... |
Use ConcurrentDictionary for collector registry | using System;
using System.Collections.Generic;
using System.Linq;
using Prometheus.Advanced.DataContracts;
namespace Prometheus.Advanced
{
public class DefaultCollectorRegistry : ICollectorRegistry
{
public readonly static DefaultCollectorRegistry Instance = new DefaultCollectorRegistry();
/... | using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using Prometheus.Advanced.DataContracts;
namespace Prometheus.Advanced
{
public class DefaultCollectorRegistry : ICollectorRegistry
{
public readonly static DefaultCollectorRegistry Instance = new DefaultCollectorRegi... |
Make debug log store work in release builds | using System;
using System.Threading.Tasks;
using Bit.Core.Contracts;
using Bit.Core.Models;
using System.Diagnostics;
namespace Bit.Owin.Implementations
{
public class DebugLogStore : ILogStore
{
private readonly IContentFormatter _formatter;
public DebugLogStore(IContentFormatter formatter)... | #define DEBUG
using System;
using System.Threading.Tasks;
using Bit.Core.Contracts;
using Bit.Core.Models;
using System.Diagnostics;
namespace Bit.Owin.Implementations
{
public class DebugLogStore : ILogStore
{
private readonly IContentFormatter _formatter;
public DebugLogStore(IContentFormat... |
Enable package search by default (in master). | // Copyright (c) Microsoft. All Rights Reserved. Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using Microsoft.CodeAnalysis.Options;
namespace Microsoft.CodeAnalysis.Shared.Options
{
/// <summary>
/// options to indicate whether a certain compo... | // Copyright (c) Microsoft. All Rights Reserved. Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using Microsoft.CodeAnalysis.Options;
namespace Microsoft.CodeAnalysis.Shared.Options
{
/// <summary>
/// options to indicate whether a certain compo... |
Fix U4-8532 - No built in Active Directory authentication in Umbraco 7.3+ | using System.Configuration;
using System.DirectoryServices.AccountManagement;
using System.Threading.Tasks;
using Umbraco.Core.Models.Identity;
namespace Umbraco.Core.Security
{
public class ActiveDirectoryBackOfficeUserPasswordChecker : IBackOfficeUserPasswordChecker
{
public Task<BackOfficeUserPassw... | using System.Configuration;
using System.DirectoryServices.AccountManagement;
using System.Threading.Tasks;
using Umbraco.Core.Models.Identity;
namespace Umbraco.Core.Security
{
public class ActiveDirectoryBackOfficeUserPasswordChecker : IBackOfficeUserPasswordChecker
{
public virtual string ActiveDir... |
Add tryremove/add to in memory store | using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Collections.Immutable;
using Abp.Data;
namespace Abp.RealTime
{
public class InMemoryOnlineClientStore : IOnlineClientStore
{
/// <summary>
/// Online clients.
/// </summary>
protected Concurren... | using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Collections.Immutable;
using Abp.Data;
namespace Abp.RealTime
{
public class InMemoryOnlineClientStore : IOnlineClientStore
{
/// <summary>
/// Online clients.
/// </summary>
protected Concurren... |
Add another keyframe to UT | using System.Linq;
using Avalonia.Data;
using Avalonia.Styling;
using Avalonia.UnitTests;
using Xunit;
namespace Avalonia.Markup.Xaml.UnitTests
{
public class SetterTests : XamlTestBase
{
[Fact]
public void Setter_Should_Work_Outside_Of_Style_With_SetterTargetType_Attribute()
{
... | using System.Linq;
using Avalonia.Data;
using Avalonia.Styling;
using Avalonia.UnitTests;
using Xunit;
namespace Avalonia.Markup.Xaml.UnitTests
{
public class SetterTests : XamlTestBase
{
[Fact]
public void Setter_Should_Work_Outside_Of_Style_With_SetterTargetType_Attribute()
{
... |
Revert "Change ProcessorInfo to CPU" | using IL2CPU.API;
using IL2CPU.API.Attribs;
using System;
using System.Diagnostics;
using Cosmos.Core;
namespace Cosmos.Core_Plugs.System.Diagnostics
{
[Plug(Target = typeof(global::System.Diagnostics.Stopwatch))]
public class StopwatchImpl
{
public static long GetTimestamp()
{
... | using IL2CPU.API;
using IL2CPU.API.Attribs;
using System;
using System.Diagnostics;
using Cosmos.Core;
namespace Cosmos.Core_Plugs.System.Diagnostics
{
[Plug(Target = typeof(global::System.Diagnostics.Stopwatch))]
public class StopwatchImpl
{
public static long GetTimestamp()
{
... |
Add hashrate data to MyRentalsRecord class | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MiningRigRentalsApi.Converters;
using Newtonsoft.Json;
namespace MiningRigRentalsApi.ObjectModel
{
public class MyRentals
{
public MyRentalsRecords[] records;
}
public class MyRentalsRecords
{
public int id;
public ... | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MiningRigRentalsApi.Converters;
using Newtonsoft.Json;
namespace MiningRigRentalsApi.ObjectModel
{
public class MyRentals
{
public MyRentalsRecords[] records;
}
public class MyRentalsRecords
{
public int id;
public ... |
Add method to return Department object by it's identifier | using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Diploms.Core;
namespace Diploms.WebUI.Controllers
{
[Route("api/[controller]")]
public class DepartmentsController : Controller
{
private readonly IRepository<Depar... | using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Diploms.Core;
namespace Diploms.WebUI.Controllers
{
[Route("api/[controller]")]
public class DepartmentsController : Controller
{
private readonly IRepository<Depar... |
Add background video for showcase scene (Tournament Client) | // 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;
namespace osu.Game.Tournament.Screens.Showcase
{
public class ShowcaseScreen : BeatmapInfoScreen
{
[BackgroundDependencyL... | // Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Game.Tournament.Components;
namespace osu.Game.Tournament.Screens.Showcase
{
public class Sho... |
Update to reuse existing window, if it exists | // Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
using Microsoft.MixedReality.Toolkit.Utilities.Editor;
using System;
using UnityEditor;
using UnityEngine;
namespace Microsoft.MixedReality.Toolkit.Editor
{
internal class MRTKVersionPopup : EditorWindow
{
private static MRTKV... | // Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
using Microsoft.MixedReality.Toolkit.Utilities.Editor;
using System;
using UnityEditor;
using UnityEngine;
namespace Microsoft.MixedReality.Toolkit.Editor
{
internal class MRTKVersionPopup : EditorWindow
{
private static MRTKV... |
Fix migration sql to be run in transaction block | using SimpleMigrations;
namespace Migrations
{
[Migration(5, "Add source track plays index")]
public class AddSourceTrackPlaysIndex : Migration
{
protected override void Up()
{
Execute(@"
CREATE INDEX IF NOT EXISTS idx_source_track_plays_id_btree ON source_track_... | using SimpleMigrations;
namespace Migrations
{
[Migration(5, "Add source track plays index")]
public class AddSourceTrackPlaysIndex : Migration
{
protected override void Up()
{
Execute(@"
CREATE INDEX IF NOT EXISTS idx_source_track_plays_id_btree ON source_track_... |
Create PermanentTestRunner rather than direct TestTree | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;... | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;... |
Add comments to a new class. | using Microsoft.AspNetCore.Mvc;
namespace LtiLibrary.AspNet.Outcomes.v1
{
public class ImsxXmlMediaTypeResult : ObjectResult
{
public ImsxXmlMediaTypeResult(object value) : base(value)
{
Formatters.Add(new ImsxXmlMediaTypeOutputFormatter());
}
}
}
| using Microsoft.AspNetCore.Mvc;
namespace LtiLibrary.AspNet.Outcomes.v1
{
/// <summary>
/// Use to attach a specific XML formatter to controller results. For example,
/// <code>public ImsxXmlMediaTypeResult Post([ModelBinder(BinderType = typeof(ImsxXmlMediaTypeModelBinder))] imsx_POXEnvelopeType request)<... |
Fix mono bug in the FontHelper class | using System;
using System.Drawing;
using System.Linq;
using NUnit.Framework;
using Palaso.UI.WindowsForms;
namespace PalasoUIWindowsForms.Tests.FontTests
{
[TestFixture]
public class FontHelperTests
{
[SetUp]
public void SetUp()
{
// setup code goes here
}
[TearDown]
public void TearDown()
{
... | using System;
using System.Drawing;
using NUnit.Framework;
using Palaso.UI.WindowsForms;
namespace PalasoUIWindowsForms.Tests.FontTests
{
[TestFixture]
public class FontHelperTests
{
[SetUp]
public void SetUp()
{
// setup code goes here
}
[TearDown]
public void TearDown()
{
// tear down code ... |
Fix exception that can occur when a PropertyEditor DLL no longer exists | using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Web;
using Census.Core;
using Census.Core.Interfaces;
using Census.UmbracoObject;
using umbraco.cms.businesslogic.datatype;
using umbraco.cms.businesslogic.web;
using umbraco.interfaces;
namespace Census.UmbracoObjectRel... | using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Web;
using Census.Core;
using Census.Core.Interfaces;
using Census.UmbracoObject;
using umbraco.cms.businesslogic.datatype;
using umbraco.cms.businesslogic.web;
using umbraco.interfaces;
namespace Census.UmbracoObjectRel... |
Fix OrderRecursivelyAsync bug with OrderByDescending | using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Threading.Tasks;
using ChessVariantsTraining.DbRepositories;
namespace ChessVariantsTraining.ViewModels
{
public class CommentSorter
{
ICommentVoteRepository voteRepo;
IUserRepository userRe... | using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Threading.Tasks;
using ChessVariantsTraining.DbRepositories;
namespace ChessVariantsTraining.ViewModels
{
public class CommentSorter
{
ICommentVoteRepository voteRepo;
IUserRepository userRe... |
Update property group type enum | namespace Umbraco.Core.Models
{
/// <summary>
/// Represents the type of a property group.
/// </summary>
public enum PropertyGroupType : short
{
/// <summary>
/// Display as a group (using a header).
/// </summary>
Group = 0,
/// <summary>
/// Displa... | namespace Umbraco.Core.Models
{
/// <summary>
/// Represents the type of a property group.
/// </summary>
public enum PropertyGroupType : short
{
/// <summary>
/// Display property types in a group.
/// </summary>
Group = 0,
/// <summary>
/// Display ... |
Check for collision with balls only. | using UnityEngine;
using UnityEngine.Events;
public class World : Planet {
private UnityEvent onPlanetHit = new UnityEvent();
private Lives lives;
private void Awake() {
lives = GetComponent<Lives>();
}
private void OnCollisionEnter( Collision other ) {
onPlanetHit.Invoke();
... | using UnityEngine;
using UnityEngine.Events;
public class World : Planet {
private UnityEvent onPlanetHit = new UnityEvent();
private Lives lives;
private void Awake() {
lives = GetComponent<Lives>();
}
private void OnCollisionEnter( Collision other ) {
if( other.transform.GetCo... |
Disable plot buttons until plot is available | using System;
using System.Diagnostics;
using Microsoft.Languages.Editor;
using Microsoft.Languages.Editor.Controller;
namespace Microsoft.VisualStudio.R.Package.Plots {
internal sealed class PlotWindowCommandController : ICommandTarget {
private PlotWindowPane _pane;
public PlotWindowCommandCont... | using System;
using System.Diagnostics;
using Microsoft.Languages.Editor;
using Microsoft.Languages.Editor.Controller;
namespace Microsoft.VisualStudio.R.Package.Plots {
internal sealed class PlotWindowCommandController : ICommandTarget {
private PlotWindowPane _pane;
public PlotWindowCommandCont... |
Remove LSP base from Xaml content type definition to avoid regressing rps | // 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.ComponentModel.Composition;
using Microsoft.VisualStudio.LanguageServer.Client;
using Microsoft.Visual... | // 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.ComponentModel.Composition;
using Microsoft.VisualStudio.LanguageServer.Client;
using Microsoft.Visual... |
Add documentation for string extensions. | namespace TraktApiSharp.Extensions
{
using System;
using System.Linq;
public static class StringExtensions
{
private static readonly char[] DelimiterChars = { ' ', ',', '.', ':', ';', '\n', '\t' };
public static string FirstToUpper(this string value)
{
if (string.I... | namespace TraktApiSharp.Extensions
{
using System;
using System.Linq;
/// <summary>Provides helper methods for strings.</summary>
public static class StringExtensions
{
private static readonly char[] DelimiterChars = { ' ', ',', '.', ':', ';', '\n', '\t' };
/// <summary>Converts t... |
Fix typo in NetCoreNUnit_SignIn_WithInvalidPassword test comment | using Atata;
using NUnit.Framework;
namespace AtataSamples.NetCore.NUnit
{
public class SignInTests : UITestFixture
{
[Test]
public void NetCoreNUnit_SignIn()
{
Go.To<SignInPage>().
Email.Set("admin@mail.com").
Password.Set("abc123").
... | using Atata;
using NUnit.Framework;
namespace AtataSamples.NetCore.NUnit
{
public class SignInTests : UITestFixture
{
[Test]
public void NetCoreNUnit_SignIn()
{
Go.To<SignInPage>().
Email.Set("admin@mail.com").
Password.Set("abc123").
... |
Add tests for PascalCaseToSpacedString extensions | using System;
using NUnit.Framework;
using Entelect.Extensions;
namespace Entelect.Tests.Strings
{
[TestFixture]
public class StringExtensionsTests
{
[Test]
public void ContainsIgnoringCase()
{
var doesContain = "asd".Contains("S",StringComparison.OrdinalIgnoreCase);
... | using System;
using NUnit.Framework;
using Entelect.Extensions;
namespace Entelect.Tests.Strings
{
[TestFixture]
public class StringExtensionsTests
{
[Test]
public void ContainsIgnoringCase()
{
var doesContain = "asd".Contains("S",StringComparison.OrdinalIgnoreCase);
... |
Return DisposableAction.Noop for the null profiler instead of creating new objects for every step. | using System;
using Kudu.Contracts;
using Kudu.Core.Infrastructure;
namespace Kudu.Core.Performance
{
public class NullProfiler : IProfiler
{
public static IProfiler Instance = new NullProfiler();
private NullProfiler()
{
}
public IDisposable Step(string value)
... | using System;
using Kudu.Contracts;
using Kudu.Core.Infrastructure;
namespace Kudu.Core.Performance
{
public class NullProfiler : IProfiler
{
public static IProfiler Instance = new NullProfiler();
private NullProfiler()
{
}
public IDisposable Step(string value)
... |
Split out extensions for Entity Framework, Azure Storage, and Mongo. These are now separate projects (and NuGet packages) that all reference the Tables project (which again references the core service project). New NuGet packages are creates and references added. | using Microsoft.WindowsAzure.Mobile.Service;
namespace ZUMOAPPNAMEService.DataObjects
{
public class TodoItem : TableData
{
public string Text { get; set; }
public bool Complete { get; set; }
}
} | using Microsoft.WindowsAzure.Mobile.Service;
namespace ZUMOAPPNAMEService.DataObjects
{
public class TodoItem : EntityData
{
public string Text { get; set; }
public bool Complete { get; set; }
}
} |
Move feature ideas to GitHub issue tracker | using System;
namespace ChatRelay
{
class Program
{
private static readonly Relay relay = new Relay();
static void Main()
{
AppDomain.CurrentDomain.UnhandledException += UnhandledExceptionTrapper;
Run();
}
public static void Run()
{
... | using System;
namespace ChatRelay
{
class Program
{
private static readonly Relay relay = new Relay();
static void Main()
{
AppDomain.CurrentDomain.UnhandledException += UnhandledExceptionTrapper;
Run();
}
public static void Run()
{
... |
Update Store.SqlServer connection string constructor | using System;
using System.Collections.Generic;
using System.Data.Common;
using System.Data.SqlClient;
using Store.Models;
using Store.Storage.Data;
namespace Store.Storage.SqlServer {
public class Client {
public Client(DBContext _dbContext) {
var fac = new Factory<SqlConnection>();
dbCo... | using System;
using System.Collections.Generic;
using System.Data.Common;
using System.Data.SqlClient;
using Store.Models;
using Store.Storage.Data;
namespace Store.Storage.SqlServer {
public class Client {
public Client(DBContext _dbContext) {
var fac = new Factory<SqlConnection>();
Func... |
Add exception (only difference from default template) | using System;
using AppKit;
using Foundation;
namespace UselessExceptions
{
public partial class ViewController : NSViewController
{
public ViewController (IntPtr handle) : base (handle)
{
}
public override void ViewDidLoad ()
{
base.ViewDidLoad ();
// Do any additional setup after loading the vi... | using System;
using AppKit;
using Foundation;
namespace UselessExceptions
{
public partial class ViewController : NSViewController
{
public ViewController (IntPtr handle) : base (handle)
{
}
public override void ViewDidLoad ()
{
base.ViewDidLoad ();
throw new Exception ("USELESS");
// Do any ... |
Fix conversion bug in out dir provider | /*
Copyright 2014 Daniel Cazzulino
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
*/
namespace OctoFlow
{
using CLAP;
using ... | /*
Copyright 2014 Daniel Cazzulino
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
*/
namespace OctoFlow
{
using CLAP;
using ... |
Fix for SOS2 calculator (for one element in array). | using System;
using System.Linq;
using MilpManager.Abstraction;
namespace MilpManager.Implementation.CompositeConstraints
{
public class SOS2Calculator : ICompositeConstraintCalculator
{
public IVariable Set(IMilpManager milpManager, CompositeConstraintType type, ICompositeConstraintParameters paramet... | using System;
using System.Linq;
using MilpManager.Abstraction;
namespace MilpManager.Implementation.CompositeConstraints
{
public class SOS2Calculator : ICompositeConstraintCalculator
{
public IVariable Set(IMilpManager milpManager, CompositeConstraintType type, ICompositeConstraintParameters paramet... |
Increase Cassandra delay after startup | using System;
namespace Evolve.Test.Utilities
{
public class CassandraDockerContainer
{
private DockerContainer _container;
public string Id => _container.Id;
public string ExposedPort => "9042";
public string HostPort => "9042";
public string ClusterName => "evolve";
... | using System;
namespace Evolve.Test.Utilities
{
public class CassandraDockerContainer
{
private DockerContainer _container;
public string Id => _container.Id;
public string ExposedPort => "9042";
public string HostPort => "9042";
public string ClusterName => "evolve";
... |
Remove help box from the folders settings list | /*
* 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 writing, software
* distrib... | /*
* 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 writing, software
* distrib... |
Add Trello provider (not yet working) | namespace Xamarin.Forms.OAuth.Providers
{
public sealed class TrelloOAuthProvider : OAuthProvider
{
private const string _redirectUrl = "https://trelloResponse.com";
public TrelloOAuthProvider(string clientId, string clientSecret, params string[] scopes)
: base(new OAuthProvid... | using System.Collections.Generic;
namespace Xamarin.Forms.OAuth.Providers
{
public sealed class TrelloOAuthProvider : OAuthProvider
{
private const string _redirectUrl = "https://trelloResponse.com";
public TrelloOAuthProvider(string clientId, string clientSecret, params string[] scopes... |
Add input event to dotnetcore2.0 example function | // Compile with:
// docker run --rm -v "$PWD":/var/task lambci/lambda:build-dotnetcore2.0 dotnet publish -c Release -o pub
// Run with:
// docker run --rm -v "$PWD"/pub:/var/task lambci/lambda:dotnetcore2.0 test::test.Function::FunctionHandler "some"
using System;
using System.Collections.Generic;
using System.Linq;
... | // Compile with:
// docker run --rm -v "$PWD":/var/task lambci/lambda:build-dotnetcore2.0 dotnet publish -c Release -o pub
// Run with:
// docker run --rm -v "$PWD"/pub:/var/task lambci/lambda:dotnetcore2.0 test::test.Function::FunctionHandler "some"
using Amazon.Lambda.Core;
[assembly: LambdaSerializer(typeof(Amazo... |
Update to MD5 hash PR. | using System;
using System.Text;
using System.Security.Cryptography;
namespace Gibe.DittoProcessors.Processors
{
public class StringToMd5HashAttribute : TestableDittoProcessorAttribute
{
public override object ProcessValue()
{
if (Value == null) throw new NullReferenceException();
var stringValue = Value... | using System;
using System.Text;
using System.Security.Cryptography;
namespace Gibe.DittoProcessors.Processors
{
public class StringToMd5HashAttribute : TestableDittoProcessorAttribute
{
public override object ProcessValue()
{
if (Value == null) throw new NullReferenceException();
var stringValue = Value... |
Update for .NET 6 rc2 | #pragma warning disable 1591
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//-------------... | #pragma warning disable 1591
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//-------------... |
Add container for sprite sheet prototypes | /*
** Project ShiftDrive
** (C) Mika Molenkamp, 2016.
*/
using System.Collections.Generic;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Audio;
namespace ShiftDrive {
/// <summary>
/// A simple static container, for holding game assets like textures and meshes.
/// </summary>
... | /*
** Project ShiftDrive
** (C) Mika Molenkamp, 2016.
*/
using System.Collections.Generic;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Audio;
namespace ShiftDrive {
/// <summary>
/// A simple static container, for holding game assets like textures and meshes.
/// </summary>
... |
Use Section instead of Paragraph for quote blocks. | // Copyright (c) 2016 Nicolas Musset. All rights reserved.
// This file is licensed under the MIT license.
// See the LICENSE.md file in the project root for more information.
using Markdig.Syntax;
namespace Markdig.Renderers.Xaml
{
/// <summary>
/// A XAML renderer for a <see cref="QuoteBlock"/>.
/// <... | // Copyright (c) 2016 Nicolas Musset. All rights reserved.
// This file is licensed under the MIT license.
// See the LICENSE.md file in the project root for more information.
using Markdig.Syntax;
namespace Markdig.Renderers.Xaml
{
/// <summary>
/// A XAML renderer for a <see cref="QuoteBlock"/>.
/// <... |
Introduce a Protocol class for better encapsulation | namespace OpcMockTests
{
internal class OpcMockProtocol
{
}
} | using System;
using System.Collections.Generic;
namespace OpcMock
{
public class OpcMockProtocol
{
private List<ProtocolLine> lines;
public OpcMockProtocol()
{
lines = new List<ProtocolLine>();
}
public List<ProtocolLine> Lines
{
get{ r... |
Fix Record Graph Type Query | using System;
using System.Collections.Generic;
using System.Text;
using GraphQL.Types;
using Snowflake.Model.Game.LibraryExtensions;
namespace Snowflake.Support.Remoting.GraphQL.Types.Model
{
public class GameFileExtensionGraphType : ObjectGraphType<IGameFileExtension>
{
public GameFileExtensionGraph... | using System;
using System.Collections.Generic;
using System.Text;
using GraphQL.Types;
using Snowflake.Model.Game.LibraryExtensions;
namespace Snowflake.Support.Remoting.GraphQL.Types.Model
{
public class GameFileExtensionGraphType : ObjectGraphType<IGameFileExtension>
{
public GameFileExtensionGraph... |
Change order of OWIN handlers so static file handler does not preempt NuGet client redirect handler. | using Autofac;
using Microsoft.Owin.FileSystems;
using Microsoft.Owin.StaticFiles;
using NuGet.Lucene.Web;
using NuGet.Lucene.Web.Formatters;
using Owin;
namespace Klondike.SelfHost
{
class SelfHostStartup : Klondike.Startup
{
private readonly SelfHostSettings selfHostSettings;
public SelfHos... | using Autofac;
using Microsoft.Owin.FileSystems;
using Microsoft.Owin.StaticFiles;
using NuGet.Lucene.Web;
using NuGet.Lucene.Web.Formatters;
using Owin;
namespace Klondike.SelfHost
{
class SelfHostStartup : Klondike.Startup
{
private readonly SelfHostSettings selfHostSettings;
public SelfHos... |
Add an option to enable handling of help on empty invocations | using System;
namespace Konsola.Parser
{
/// <summary>
/// Configures the options when parsing args and binding them to a context.
/// </summary>
[AttributeUsage(AttributeTargets.Class, Inherited = false, AllowMultiple = false)]
public class ContextOptionsAttribute : Attribute
{
/// <summary>
/// Gets or se... | using System;
namespace Konsola.Parser
{
/// <summary>
/// Configures the options when parsing args and binding them to a context.
/// </summary>
[AttributeUsage(AttributeTargets.Class, Inherited = false, AllowMultiple = false)]
public class ContextOptionsAttribute : Attribute
{
/// <summary>
/// Gets or se... |
Add a safety check for when Authors is null, which shouldn't happen in the first place. Work items: 1727, 1728 | using System;
using System.Collections.Generic;
using System.Windows.Data;
namespace NuGet.Dialog.PackageManagerUI
{
public class StringCollectionsToStringConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo cu... | using System;
using System.Collections.Generic;
using System.Windows.Data;
namespace NuGet.Dialog.PackageManagerUI
{
public class StringCollectionsToStringConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo cultur... |
Change ModelBuilder to use old EntityFrameworkCore RC1 naming conventions | using Microsoft.AspNetCore.Identity.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Metadata;
namespace Dangl.WebDocumentation.Models
{
public class ApplicationDbContext : IdentityDbContext<ApplicationUser>
{
public ApplicationDbContext(DbContextOptions op... | using Microsoft.AspNetCore.Identity.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Metadata.Internal;
namespace Dangl.WebDocumentation.Models
{
public class ApplicationDbContext : IdentityDbContext<ApplicationUser>
{
... |
Add test for generic name collision on frontend | using System.Web.Http;
using Newtonsoft.Json;
namespace WebApiTestApplication.Controllers
{
public class MegaClass : AnotherClass
{
public int Something { get; set; }
}
public class Chain1<T1, T2>
{
public T1 Value11 { get; set; }
public T2 Value12 { get; set; }
}
... | using System.Web.Http;
using Newtonsoft.Json;
namespace WebApiTestApplication.Controllers
{
public class MegaClass : AnotherClass
{
public int Something { get; set; }
}
public class Chain1<T>
{
public T Value { get; set; }
}
public class Chain1<T1, T2>
{
publi... |
Fix supported enum check in type extentions. | using System;
using System.Collections.Generic;
using System.Reflection;
namespace WindowsAzure.Table.Extensions
{
internal static class TypeExtentions
{
private static readonly HashSet<Type> _supportedEntityPropertyTypes = new HashSet<Type>
{
typeof(long),
typeof(int),... | using System;
using System.Collections.Generic;
using System.Reflection;
namespace WindowsAzure.Table.Extensions
{
internal static class TypeExtentions
{
private static readonly HashSet<Type> _supportedEntityPropertyTypes = new HashSet<Type>
{
typeof(long),
typeof(int),... |
Fix annotations loader for tests | using System;
using System.Collections.Generic;
using JetBrains.Application;
using JetBrains.Metadata.Utils;
using JetBrains.ReSharper.Psi.ExtensionsAPI.ExternalAnnotations;
using JetBrains.TestFramework.Utils;
using JetBrains.Util;
namespace JetBrains.ReSharper.Plugins.Unity.Tests
{
[ShellComponent]
public c... | using System;
using System.Collections.Generic;
using JetBrains.Application;
using JetBrains.Metadata.Utils;
using JetBrains.ReSharper.Psi.ExtensionsAPI.ExternalAnnotations;
using JetBrains.TestFramework.Utils;
using JetBrains.Util;
namespace JetBrains.ReSharper.Plugins.Unity.Tests
{
[ShellComponent]
public c... |
Add description for roles scope | using System.Collections.Generic;
using System.Linq;
using Thinktecture.IdentityServer.Core;
using Thinktecture.IdentityServer.Core.Models;
namespace Thinktecture.IdentityServer.Host.Config
{
public class Scopes
{
public static IEnumerable<Scope> Get()
{
return new[]
... | using System.Collections.Generic;
using System.Linq;
using Thinktecture.IdentityServer.Core;
using Thinktecture.IdentityServer.Core.Models;
namespace Thinktecture.IdentityServer.Host.Config
{
public class Scopes
{
public static IEnumerable<Scope> Get()
{
return new[]
... |
Revert "Use dot instead of dash to separate build metadata" | public class BuildVersion
{
public GitVersion GitVersion { get; private set; }
public string Version { get; private set; }
public string Milestone { get; private set; }
public string SemVersion { get; private set; }
public string GemVersion { get; private set; }
public string VsixVersion { get; ... | public class BuildVersion
{
public GitVersion GitVersion { get; private set; }
public string Version { get; private set; }
public string Milestone { get; private set; }
public string SemVersion { get; private set; }
public string GemVersion { get; private set; }
public string VsixVersion { get; ... |
Add test that aggregate exception is last | using System.Linq;
using System.Threading.Tasks;
using Bugsnag.Payload;
using Xunit;
namespace Bugsnag.Tests.Payload
{
public class ExceptionTests
{
[Fact]
public void CorrectNumberOfExceptions()
{
var exception = new System.Exception("oh noes!");
var exceptions = new Exceptions(exception,... | using System.Linq;
using System.Threading.Tasks;
using Bugsnag.Payload;
using Xunit;
namespace Bugsnag.Tests.Payload
{
public class ExceptionTests
{
[Fact]
public void CorrectNumberOfExceptions()
{
var exception = new System.Exception("oh noes!");
var exceptions = new Exceptions(exception,... |
Remove closing bracket from arguments | namespace AngleSharp.Css.ValueConverters
{
using System;
using System.Collections.Generic;
using System.Linq;
using AngleSharp.Dom.Css;
using AngleSharp.Parser.Css;
sealed class FunctionValueConverter<T> : IValueConverter<T>
{
readonly String _name;
readonly IValueConverter... | namespace AngleSharp.Css.ValueConverters
{
using System;
using System.Collections.Generic;
using System.Linq;
using AngleSharp.Dom.Css;
using AngleSharp.Parser.Css;
sealed class FunctionValueConverter<T> : IValueConverter<T>
{
readonly String _name;
readonly IValueConverter... |
Adjust version number to match DokanNet | using System;
using System.Reflection;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("DokanNet.Tests")]
[a... | using System;
using System.Reflection;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("DokanNet.Tests")]
[a... |
Update the length once during construction | // Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using System.Linq;
using osu.Framework.Audio.Track;
using osu.Game.Rulesets.Objects.Types;
namespace osu.Game.Beatmaps
{
public partial class WorkingBeatmap
{
... | // Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using System.Linq;
using osu.Framework.Audio.Track;
using osu.Game.Rulesets.Objects.Types;
namespace osu.Game.Beatmaps
{
public partial class WorkingBeatmap
{
... |
Revert CrytoConfiguration to using Credential implementation | using System.Collections.Generic;
namespace RockLib.Encryption.Symmetric
{
/// <summary>
/// Defines an xml-serializable object that contains the information needed to configure an
/// instance of <see cref="SymmetricCrypto"/>.
/// </summary>
public class CryptoConfiguration
{
/// <sum... | using System.Collections.Generic;
namespace RockLib.Encryption.Symmetric
{
/// <summary>
/// Defines an xml-serializable object that contains the information needed to configure an
/// instance of <see cref="SymmetricCrypto"/>.
/// </summary>
public class CryptoConfiguration
{
/// <sum... |
Add frame counter to give DrawVis a bit more activity. | //Copyright (c) 2007-2016 ppy Pty Ltd <contact@ppy.sh>.
//Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu-framework/master/LICENCE
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Cursor;
using osu.Framework.Graphics.Drawables;
usi... | //Copyright (c) 2007-2016 ppy Pty Ltd <contact@ppy.sh>.
//Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu-framework/master/LICENCE
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Cursor;
using osu.Framework.Graphics.Drawables;
usi... |
Add 10K mod to incompatibility list | // 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.Linq;
using osu.Game.Beatmaps;
using osu.Game.Rulesets.Mania.Beatmaps;
using osu.Game.Rulesets.Mods;
namespace osu.Game.Rulesets.Mania.Mods
{... | // 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.Linq;
using osu.Game.Beatmaps;
using osu.Game.Rulesets.Mania.Beatmaps;
using osu.Game.Rulesets.Mods;
namespace osu.Game.Rulesets.Mania.Mods
{... |
Revert "Fix issue with API header binding when running under a subdirectory" | using System;
using System.Web.Mvc;
namespace NuGetGallery
{
public class HttpHeaderValueProviderFactory : ValueProviderFactory
{
public override IValueProvider GetValueProvider(ControllerContext controllerContext)
{
var request = controllerContext.RequestContext.HttpContext.Reques... | using System;
using System.Web.Mvc;
namespace NuGetGallery
{
public class HttpHeaderValueProviderFactory : ValueProviderFactory
{
public override IValueProvider GetValueProvider(ControllerContext controllerContext)
{
var request = controllerContext.RequestContext.HttpContext.Reques... |
Check if eventargs is null | namespace Microsoft.ApplicationInsights.Extensibility.Implementation.Tracing
{
using System;
#if !NET40
using System.Diagnostics.Tracing;
#endif
using System.Linq;
#if NET40
using Microsoft.Diagnostics.Tracing;
#endif
internal class DiagnosticsEventListener : EventListener
{
private co... | namespace Microsoft.ApplicationInsights.Extensibility.Implementation.Tracing
{
using System;
#if !NET40
using System.Diagnostics.Tracing;
#endif
using System.Linq;
#if NET40
using Microsoft.Diagnostics.Tracing;
#endif
internal class DiagnosticsEventListener : EventListener
{
private co... |
Add method to get current power source. | // Copyright (C) 2017, 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) 2017, 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... |
Change datatype for OpeningBalance and OpeningRate | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace com.techphernalia.MyPersonalAccounts.Model.Inventory
{
public class StockItem
{
public int StockItemId { get; set; }
public string StockItemName { get; set; }
public int StockGroupId { get; ... | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace com.techphernalia.MyPersonalAccounts.Model.Inventory
{
public class StockItem
{
public int StockItemId { get; set; }
public string StockItemName { get; set; }
public int StockGroupId { get; ... |
Add token issuspended to view model | using Foundatio.Repositories.Models;
namespace Exceptionless.Web.Models;
public class ViewToken : IIdentity, IHaveDates {
public string Id { get; set; }
public string OrganizationId { get; set; }
public string ProjectId { get; set; }
public string UserId { get; set; }
public string DefaultProject... | using Foundatio.Repositories.Models;
namespace Exceptionless.Web.Models;
public class ViewToken : IIdentity, IHaveDates {
public string Id { get; set; }
public string OrganizationId { get; set; }
public string ProjectId { get; set; }
public string UserId { get; set; }
public string DefaultProject... |
Fix failing test on Linux | using System;
using Newtonsoft.Json;
using Oocx.ACME.Jose;
using Oocx.ACME.Protocol;
using Xunit;
namespace Oocx.ACME.Tests
{
public class RegistrationTests
{
[Fact]
public void Can_serialize()
{
var request = new NewRegistrationRequest
{
Contact... | using System;
using Newtonsoft.Json;
using Oocx.ACME.Jose;
using Oocx.ACME.Protocol;
using Xunit;
namespace Oocx.ACME.Tests
{
public class RegistrationTests
{
[Fact]
public void Can_serialize()
{
var request = new NewRegistrationRequest
{
Contact... |
Add Method to Get Device | using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Windows.Devices.I2c;
namespace AM2320Demo
{
public struct AM2320Data
{
public double Temperature;
public double Humidity;
}
public class ... | using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Windows.Devices.I2c;
namespace AM2320Demo
{
public struct AM2320Data
{
public double Temperature;
public double Humidity;
}
public class ... |
Fix for the wrong updateBuildNumber behavior | using System;
using System.Collections.Generic;
using GitVersion.Logging;
using GitVersion.OutputVariables;
namespace GitVersion
{
public abstract class BuildAgentBase : ICurrentBuildAgent
{
protected readonly ILog Log;
protected IEnvironment Environment { get; }
protected BuildAgentBa... | using System;
using System.Collections.Generic;
using GitVersion.Logging;
using GitVersion.OutputVariables;
namespace GitVersion
{
public abstract class BuildAgentBase : ICurrentBuildAgent
{
protected readonly ILog Log;
protected IEnvironment Environment { get; }
protected BuildAgentBa... |
Allow word boundary delimiter to be set by user | using System;
namespace FluentConsole.Library
{
/// <summary>
/// Optionial configuration for FluentConsole
/// </summary>
public class FluentConsoleSettings
{
/// <summary>
/// Gets or sets a value indicating how long lines of text should be displayed in the console window.
... | using System;
namespace FluentConsole.Library
{
/// <summary>
/// Optionial configuration for FluentConsole
/// </summary>
public class FluentConsoleSettings
{
/// <summary>
/// Gets or sets a value indicating how long lines of text should be displayed in the console window.
... |
Add comments to public methods | using System;
using System.Diagnostics;
using System.Threading.Tasks;
namespace ConsoleWritePrettyOneDay
{
public static class Spinner
{
private static char[] _chars = new[] { '|', '/', '-', '\\', '|', '/', '-', '\\' };
public static void Wait(Action action, string message = null)
... | using System;
using System.Diagnostics;
using System.Threading.Tasks;
namespace ConsoleWritePrettyOneDay
{
public static class Spinner
{
private static char[] _chars = new[] { '|', '/', '-', '\\', '|', '/', '-', '\\' };
/// <summary>
/// Displays a spinner while the provide... |
Fix dllimport inconsistency and possibly being broken on windows. | //
// Copyright (c) 2017-2019 the rbfx project.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, mer... | //
// Copyright (c) 2017-2019 the rbfx project.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, mer... |
Add ResolveByName attribute to TargetControl property | using Avalonia.Controls;
using Avalonia.Input;
using Avalonia.Interactivity;
using Avalonia.Xaml.Interactivity;
namespace Avalonia.Xaml.Interactions.Custom;
/// <summary>
/// A behavior that allows to show control on double tapped event.
/// </summary>
public class ShowOnDoubleTappedBehavior : Behavior<Control>
{
... | using Avalonia.Controls;
using Avalonia.Input;
using Avalonia.Interactivity;
using Avalonia.Xaml.Interactivity;
namespace Avalonia.Xaml.Interactions.Custom;
/// <summary>
/// A behavior that allows to show control on double tapped event.
/// </summary>
public class ShowOnDoubleTappedBehavior : Behavior<Control>
{
... |
Fix ring glow lookup being incorrect | // Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Sprites;
using osu.Framework.Graphics... | // Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Sprites;
using osu.Framework.Graphics... |
Change number of cells. ( 9 => 7 ) | using System;
namespace XamarinLifeGameXAML.Logic
{
public class CellUtils
{
public static int GetIndex(Tuple<int, int> point)
{
return GetIndex(point.Item1, point.Item2);
}
public static int GetIndex(int x, int y)
{
return (y + x * CellSize);
... | using System;
namespace XamarinLifeGameXAML.Logic
{
public class CellUtils
{
public static int GetIndex(Tuple<int, int> point)
{
return GetIndex(point.Item1, point.Item2);
}
public static int GetIndex(int x, int y)
{
return (y + x * CellSize);
... |
Return added disposable from `DisposeWith` | using System;
using System.Collections.Generic;
using System.Reactive.Disposables;
using System.Text;
namespace SolidworksAddinFramework
{
public static class DisposableExtensions
{
public static IDisposable ToCompositeDisposable(this IEnumerable<IDisposable> d)
{
return new Compos... | using System;
using System.Collections.Generic;
using System.Reactive.Disposables;
using System.Text;
namespace SolidworksAddinFramework
{
public static class DisposableExtensions
{
public static IDisposable ToCompositeDisposable(this IEnumerable<IDisposable> d)
{
return new Compos... |
Introduce variables to avoid multiple type casting | using System.Collections.Generic;
namespace Ploeh.AutoFixture.Xunit
{
internal class CustomizeAttributeComparer : Comparer<CustomizeAttribute>
{
public override int Compare(CustomizeAttribute x, CustomizeAttribute y)
{
if (x is FrozenAttribute && !(y is FrozenAttribute))
... | using System.Collections.Generic;
namespace Ploeh.AutoFixture.Xunit
{
internal class CustomizeAttributeComparer : Comparer<CustomizeAttribute>
{
public override int Compare(CustomizeAttribute x, CustomizeAttribute y)
{
var xfrozen = x is FrozenAttribute;
var yfrozen = y... |
Fix project name in assembly info | using System.Reflection;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("TOTD.Mailer.Html")]
[assembly: AssemblyDe... | using System.Reflection;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("TOTD.Mailer.Templates")]
[assembly: Assem... |
Add test skipping for 0.5.2 | using System;
using Microsoft.VisualStudio.TestTools.UnitTesting;
namespace Consul.Test
{
[TestClass]
public class CoordinateTest
{
[TestMethod]
public void TestCoordinate_Datacenters()
{
var client = new Client();
var datacenters = client.Coordinate.Datace... | using System;
using Microsoft.VisualStudio.TestTools.UnitTesting;
namespace Consul.Test
{
[TestClass]
public class CoordinateTest
{
[TestMethod]
public void TestCoordinate_Datacenters()
{
var client = new Client();
var info = client.Agent.Self();
... |
Implement the read/write xml data | // XMLDataSaver.cs
// <copyright file="XMLDataSaver.cs"> This code is protected under the MIT License. </copyright>
using System.Collections.Generic;
using System.IO;
using System.Xml.Serialization;
namespace Todo_List
{
/// <summary>
/// A static class for reading and writing to XML files.
/// </summary>... | // XMLDataSaver.cs
// <copyright file="XMLDataSaver.cs"> This code is protected under the MIT License. </copyright>
using System.Collections.Generic;
using System.IO;
using System.Xml.Serialization;
namespace Todo_List
{
/// <summary>
/// A static class for reading and writing to XML files.
/// </summary>... |
Add bing map keys with fake default | namespace TestAppUWP.Samples.Map
{
public class MapServiceSettings
{
public static string Token="Pippo";
}
} | namespace TestAppUWP.Samples.Map
{
public class MapServiceSettings
{
public static string Token = string.Empty;
}
} |
Remove obsolete Linux build architectures on 2019.2+ | using UnityEditor;
namespace SuperSystems.UnityBuild
{
[System.Serializable]
public class BuildLinux : BuildPlatform
{
#region Constants
private const string _name = "Linux";
private const string _dataDirNameFormat = "{0}_Data";
private const BuildTargetGroup _targetGroup = BuildTargetGroup.Standalo... | using UnityEditor;
namespace SuperSystems.UnityBuild
{
[System.Serializable]
public class BuildLinux : BuildPlatform
{
#region Constants
private const string _name = "Linux";
private const string _dataDirNameFormat = "{0}_Data";
private const BuildTargetGroup _targetGroup = BuildTargetGroup.Standalo... |
Use CombineLatest instead of Zip | #region Usings
using System.Collections.Generic;
using System.Linq;
using System.Reactive.Linq;
using System.Threading;
using System.Threading.Tasks;
using ReactiveUI;
#endregion
namespace UI.WPF.Modules.Installation.ViewModels.Installation
{
public class InstallationItemParent : InstallationItem
{
... | #region Usings
using System.Collections.Generic;
using System.Linq;
using System.Reactive.Linq;
using System.Threading;
using System.Threading.Tasks;
using ReactiveUI;
#endregion
namespace UI.WPF.Modules.Installation.ViewModels.Installation
{
public class InstallationItemParent : InstallationItem
{
... |
Adjust tests to MySqlConnector 1.4.0-beta.4. | using Microsoft.EntityFrameworkCore;
using Pomelo.EntityFrameworkCore.MySql.FunctionalTests.TestUtilities;
using Pomelo.EntityFrameworkCore.MySql.Tests;
using Xunit;
namespace Pomelo.EntityFrameworkCore.MySql.FunctionalTests
{
public class TwoDatabasesMySqlTest : TwoDatabasesTestBase, IClassFixture<MySqlFixture>
... | using Microsoft.EntityFrameworkCore;
using Pomelo.EntityFrameworkCore.MySql.FunctionalTests.TestUtilities;
using Pomelo.EntityFrameworkCore.MySql.Tests;
using Xunit;
namespace Pomelo.EntityFrameworkCore.MySql.FunctionalTests
{
public class TwoDatabasesMySqlTest : TwoDatabasesTestBase, IClassFixture<MySqlFixture>
... |
Fix cross plattform issue with drive info method | using System;
using System.IO;
using Arkivverket.Arkade.Core.Base;
namespace Arkivverket.Arkade.Core.Util
{
public static class SystemInfo
{
public static long GetAvailableDiskSpaceInBytes()
{
return GetAvailableDiskSpaceInBytes(ArkadeProcessingArea.RootDirectory.FullName);
... | using System;
using System.IO;
using System.Linq;
using Arkivverket.Arkade.Core.Base;
namespace Arkivverket.Arkade.Core.Util
{
public static class SystemInfo
{
public static long GetAvailableDiskSpaceInBytes()
{
return GetAvailableDiskSpaceInBytes(ArkadeProcessingArea.RootDirectory.... |
Allow all characters for password fields | namespace SFA.DAS.EmployerUsers.Web.Models
{
public class RegisterViewModel :ViewModelBase
{
public string FirstName { get; set; }
public string LastName { get; set; }
public string Email { get; set; }
public string Password { get; set; }
public string ConfirmPassword { ... | using System.Web.Mvc;
namespace SFA.DAS.EmployerUsers.Web.Models
{
public class RegisterViewModel :ViewModelBase
{
public string FirstName { get; set; }
public string LastName { get; set; }
public string Email { get; set; }
[AllowHtml]
public string Password { get; s... |
Load levels with SceneManager instead of Application for Unity 5.3+ | using UnityEngine;
using UnityEngine.UI;
using System.Collections;
public class LoadTest : MonoBehaviour
{
public void SignInButtonClicked()
{
GameJolt.UI.Manager.Instance.ShowSignIn((bool success) => {
if (success)
{
Debug.Log("Logged In");
}
else
{
Debug.Log("Dismissed");
}
});
}
... | using UnityEngine;
using UnityEngine.UI;
using System.Collections;
public class LoadTest : MonoBehaviour
{
public void SignInButtonClicked()
{
GameJolt.UI.Manager.Instance.ShowSignIn((bool success) => {
if (success)
{
Debug.Log("Logged In");
}
else
{
Debug.Log("Dismissed");
}
});
}
... |
Fix namespace so that external access wrapper type can be accessed from UT. | // 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.Serialization;
using Microsoft.CodeAnalysis.Remote;
namespace Microsoft.CodeAnalysis.External... | // 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.Serialization;
using Microsoft.CodeAnalysis.Remote;
namespace Microsoft.CodeAnalysis.External... |
Add email validity check to change email command | using System.Threading.Tasks;
using SFA.DAS.EmployerUsers.Application.Validation;
namespace SFA.DAS.EmployerUsers.Application.Commands.RequestChangeEmail
{
public class RequestChangeEmailCommandValidator : IValidator<RequestChangeEmailCommand>
{
public Task<ValidationResult> ValidateAsync(Reque... | using System.Threading.Tasks;
using SFA.DAS.EmployerUsers.Application.Validation;
namespace SFA.DAS.EmployerUsers.Application.Commands.RequestChangeEmail
{
public class RequestChangeEmailCommandValidator : BaseValidator, IValidator<RequestChangeEmailCommand>
{
public Task<ValidationResult> Vali... |
Use acknowledgement callback to indicate whether createTopic event was successful | using System.Diagnostics;
using System.Threading;
using System.Threading.Tasks;
using Quobject.SocketIoClientDotNet.Client;
namespace KafkaHttp.Net
{
public interface IKafkaProducer
{
Task CreateTopic(string name);
void Publish(params Message<string>[] payload);
}
public class KafkaPr... | using System.Diagnostics;
using System.Threading;
using System.Threading.Tasks;
using Quobject.SocketIoClientDotNet.Client;
namespace KafkaHttp.Net
{
public interface IKafkaProducer
{
Task CreateTopic(string name);
void Publish(params Message<string>[] payload);
}
public class KafkaPr... |
Fix typo in VersionNavigation class name | // 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 Newtonsoft.Json;
using System;
using System.Collections.Generic;
namespace osu.Game.Online.API.Requests.Responses
{
public class APIChangelogBuild : IEquatabl... | // 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 Newtonsoft.Json;
using System;
using System.Collections.Generic;
namespace osu.Game.Online.API.Requests.Responses
{
public class APIChangelogBuild : IEquatabl... |
Allow using `ToLocalisableString` without a format string | // 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;
#nullable enable
namespace osu.Framework.Localisation
{
public static class LocalisableStringExtensions
{
/// <summary>
/// Return... | // 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;
#nullable enable
namespace osu.Framework.Localisation
{
public static class LocalisableStringExtensions
{
/// <summary>
/// Return... |
Add EF extensions for identity columns and index column order | using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Data.Entity.Infrastructure.Annotations;
using System.Data.Entity.ModelConfiguration.Configuration;
using System.Linq;
namespace TOTD.EntityFramework
{
public static class ConfigurationExtensions
{
... | using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Data.Entity.Infrastructure.Annotations;
using System.Data.Entity.ModelConfiguration.Configuration;
using System.Linq;
namespace TOTD.EntityFramework
{
public static class ConfigurationExtensions
{
... |
Fix changelog header staying dimmed after build show | // 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.Game.Online.API.Requests.Responses;
namespace osu.Game.Overlays.Changelog
{
public class ChangelogUpdateStreamControl : OverlayStreamControl<APIUpdateStre... | // 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.Game.Online.API.Requests.Responses;
namespace osu.Game.Overlays.Changelog
{
public class ChangelogUpdateStreamControl : OverlayStreamControl<APIUpdateStre... |
Extend the extension methods test case again | using System;
using System.Collections.Generic;
using System.Linq;
public class Herp
{
public Herp(int X)
{
this.X = X;
}
public int X { get; private set; }
}
public static class HerpExtensions
{
public static void PrintX(this Herp Value)
{
Console.WriteLine(Value.X);
}
}
... | using System;
using System.Collections.Generic;
using System.Linq;
public class Herp
{
public Herp(int X)
{
this.X = X;
}
public int X { get; private set; }
}
public static class HerpExtensions
{
public static void PrintX(this Herp Value)
{
Console.WriteLine(Value.X);
}
}
... |
Move BindValueChanged subscriptions to LoadComplete | // 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.Game.Online.Multiplayer;
using osu.Game.Screens.OnlinePlay.Match.Components;
namespace osu.Game.... | // 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.Game.Online.Multiplayer;
using osu.Game.Screens.OnlinePlay.Match.Components;
namespace osu.Game.... |
Change Price type to double | using Newtonsoft.Json;
namespace BitFlyer.Apis
{
public class SendChildOrderParameter
{
[JsonProperty("product_code")]
public ProductCode ProductCode { get; set; }
[JsonProperty("child_order_type")]
public ChildOrderType ChildOrderType { get; set; }
[JsonProperty("sid... | using Newtonsoft.Json;
namespace BitFlyer.Apis
{
public class SendChildOrderParameter
{
[JsonProperty("product_code")]
public ProductCode ProductCode { get; set; }
[JsonProperty("child_order_type")]
public ChildOrderType ChildOrderType { get; set; }
[JsonProperty("sid... |
Disable login redirect to dbbrowser.aspx forbidding redirects altogether | using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Text;
using System.Threading.Tasks;
namespace Sitecore.Linqpad.Server
{
public class CookieAwareWebClient : WebClient
{
public CookieAwareWebClient(CookieContainer cookies = null)
{
th... | using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Text;
using System.Threading.Tasks;
namespace Sitecore.Linqpad.Server
{
public class CookieAwareWebClient : WebClient
{
public CookieAwareWebClient(CookieContainer cookies = null)
{
th... |
Revert "clean code a bit" | using System.Collections.Generic;
namespace Humanizer.Localisation.NumberToWords
{
internal class FrenchNumberToWordsConverter : FrenchNumberToWordsConverterBase
{
protected override void CollectPartsUnderAHundred(ICollection<string> parts, ref int number, GrammaticalGender gender, bool pluralize)
... | using System.Collections.Generic;
namespace Humanizer.Localisation.NumberToWords
{
internal class FrenchNumberToWordsConverter : FrenchNumberToWordsConverterBase
{
protected override void CollectPartsUnderAHundred(ICollection<string> parts, ref int number, GrammaticalGender gender, bool pluralize)
... |
Allow redefining already defined symbols | using System.Collections.Generic;
using Squirrel.Nodes;
namespace Squirrel
{
public class Environment
{
private readonly Environment _parent;
private readonly Dictionary<string, INode> _definitions = new Dictionary<string, INode>();
public Environment(Environment parent)
{
... | using System.Collections.Generic;
using Squirrel.Nodes;
namespace Squirrel
{
public class Environment
{
private readonly Environment _parent;
private readonly Dictionary<string, INode> _definitions = new Dictionary<string, INode>();
public Environment(Environment parent)
{
... |
Remove lazy loading of configuration | using System.IO;
using Newtonsoft.Json;
namespace TfsHipChat.Configuration
{
public class ConfigurationProvider : IConfigurationProvider
{
private TfsHipChatConfig _tfsHipChatConfig;
public TfsHipChatConfig Config
{
get
{
if (_tfsHi... | using System.IO;
using Newtonsoft.Json;
using TfsHipChat.Properties;
namespace TfsHipChat.Configuration
{
public class ConfigurationProvider : IConfigurationProvider
{
public ConfigurationProvider()
{
using (var reader = new JsonTextReader(new StreamReader(Settings.Defaul... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.