Skip to content

Instantly share code, notes, and snippets.

View MarkNijhof's full-sized avatar

Mark Nijhof MarkNijhof

View GitHub Profile
@MarkNijhof
MarkNijhof / Sammy.js
Created November 7, 2010 01:17
Sammy_setup
<script type="text/javascript">
$(document).ready(function() {
var app = $.sammy(function() {
this.get('#/', function() {
clear_book_information_panel_when_needed();
});
this.get('#/:book_name/Details', function() {
<?xml version="1.0"?>
<output>
<blogpost>
<url>http://cre8ivethought.com/blog/2010/08/22/importing-comments-into-disqus/</url>
<title>Title of the post</title>
<guid>{the guid that Disqus has for the post, often it is just the url}</guid>
<comments>
<comment>
<isAnon>1</isAnon>
<score>1</score>
function positive_int() { return $(test "$@" -eq "$@" > /dev/null 2>&1 && test "$@" -ge 0 > /dev/null 2>&1); }
function sizetw() {
if [[ $# -eq 2 ]] && $(positive_int "$1") && $(positive_int "$2"); then
printf "\e[8;${1};${2};t"
return 0
fi
return 1
}
namespace Fohjin.DDD.Events.Account
{
[Serializable]
public class CashWithdrawnEvent : DomainEvent
{
public decimal Balance { get; private set; }
public decimal Amount { get; private set; }
public CashWithdrawnEvent(decimal balance, decimal amount)
{
namespace Test.Fohjin.DDD
{
[Specification]
public abstract class BaseTestFixture
{
protected Exception CaughtException;
protected virtual void Given() { }
protected abstract void When();
protected virtual void Finally() { }
namespace Fohjin.DDD.BankApplication.Views
{
public partial class ClientSearchForm : Form, IClientSearchFormView
{
public ClientSearchForm()
{
InitializeComponent();
RegisterClientEvents();
}
namespace Fohjin.DDD.Domain.Client
{
public class Client : BaseAggregateRoot<IDomainEvent>, IOrginator
{
private Address _address;
public Client()
{
registerEvents();
}
void IEventProvider.LoadFromHistory(IEnumerable<IDomainEvent> domainEvents)
{
if (domainEvents.Count() == 0)
return;
foreach (var domainEvent in domainEvents)
{
apply(domainEvent.GetType(), domainEvent);
}
namespace Fohjin.DDD.EventStore.Storage.Memento
{
public interface IOrginator
{
IMemento CreateMemento();
void SetMemento(IMemento memento);
}
}
namespace Fohjin.Refactoring
{
public class ClassToBeRefactored
{
public void DoSomething()
{
DependencyA dependencyA = new DependencyA();
DependencyB dependencyB = new DependencyB();
}
}