This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import QuartzCore | |
extension CGContext { | |
private static let colorSpace = CGColorSpaceCreateDeviceRGB() | |
private static let bitmapInfo = | |
CGBitmapInfo.byteOrder32Big.rawValue | | |
CGImageAlphaInfo.premultipliedLast.rawValue & CGBitmapInfo.alphaInfoMask.rawValue | |
static func from(pixels: [UInt32], width: Int) -> CGContext? { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import UIKit | |
@UIApplicationMain | |
class AppDelegate: UIResponder, UIApplicationDelegate { | |
var window: UIWindow? | |
func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool { | |
let viewController = SplitVc() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class TestOutputHelperTextWriterAdapter : TextWriter | |
{ | |
private readonly ITestOutputHelper output; | |
private string currentLine = ""; | |
public TestOutputHelperTextWriterAdapter(ITestOutputHelper output) | |
{ | |
this.output = output; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace RomTile; | |
using SixLabors.ImageSharp; | |
using SixLabors.ImageSharp.PixelFormats; | |
internal static class Program | |
{ | |
private const int TileWidth = 8; | |
private const int TileHeight = 8; | |
private const int NumberOfPixelsInATile = TileWidth * TileHeight; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
protocol Cipher { | |
func encrypt(message: String, secret: Int) -> String | |
func decrypt(message: String, secret: Int) -> String | |
} | |
struct XOR: Cipher { | |
private func impl(message: String, secret: Int) -> String? { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace MonoGameCross_PlatformDesktopApplication1 | |
{ | |
using Microsoft.Xna.Framework; | |
using Microsoft.Xna.Framework.Graphics; | |
using Microsoft.Xna.Framework.Input; | |
public static class Program | |
{ | |
[STAThread] | |
private static void Main() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Text; | |
public static class AutoGarbage | |
{ | |
private const string Chars = "qwertyuiopasdfghjklzxcvbnm1234567890"; | |
public static T Next<T>(this Random random) => (T)Next(random, typeof(T)); | |
private static object Next(this Random random, Type type) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.IO; | |
using Lucene.Net.Analysis; | |
using Lucene.Net.Analysis.Standard; | |
using Lucene.Net.Documents; | |
using Lucene.Net.Index; | |
using Lucene.Net.QueryParsers; | |
using Lucene.Net.Search; | |
using Lucene.Net.Store; | |
using NUnit.Framework; |
NewerOlder