Skip to content

Instantly share code, notes, and snippets.

Avatar

Jimit Ndiaye jimitndiaye

View GitHub Profile
@jimitndiaye
jimitndiaye / EventMessage.cs
Created Jul 15, 2011
Generic EventMessage
View EventMessage.cs
/// <summary>
/// Wraps an <see cref = "IEvent">event</see>
/// to be transportable by NServiceBus.
/// </summary>
[Serializable]
[DataContract(Namespace = MessageNamespace)]
public class EventMessage<TEvent> : EventMessage, IEventMessage<TEvent> where TEvent : class
{
public EventMessage(IPublishedEvent<TEvent> @event) : base(@event)
{
@jimitndiaye
jimitndiaye / ConcurrentLinkedList.cs
Last active Oct 25, 2017
ConcurrentLinkedList<T>
View ConcurrentLinkedList.cs
#pragma warning disable 420
namespace System.Collections.Concurrent
{
using Azure.Framework;
using Diagnostics;
using Diagnostics.Contracts;
using Generic;
using Runtime.InteropServices;
using Runtime.Serialization;
@jimitndiaye
jimitndiaye / explorer.model.ts
Last active Aug 16, 2018
RXJS, @ngrx/store - Memoizing a tree search
View explorer.model.ts
import { Map, Record, List } from 'immutable';
export interface FolderTree {
id: string;
name: string;
subFolders: FolderTree[];
dialogs: DialogSummary[];
}
export interface DialogSummary {
id: string;
@jimitndiaye
jimitndiaye / context.ts
Created Dec 14, 2016
Angular2 directives supporting nested drag and drop
View context.ts
import { Injectable } from '@angular/core';
@Injectable()
export class DndContext {
dropEffect = 'none';
isDragging = false;
itemType = undefined;
dragData: any = undefined;
// stopDragOver= new Map<string, () => void>();
stopDragOver: () => void = undefined;
You can’t perform that action at this time.