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
<?php | |
<<<CONFIG | |
packages: | |
- "symfony/dom-crawler: ~2.3" | |
- "symfony/css-selector: ~2.3" | |
CONFIG; | |
use Symfony\Component\DomCrawler\Crawler; | |
$html = <<<HTML |
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
<?php | |
class MyThing | |
{ | |
private $myArray = null; | |
public function __construct($myArray) | |
{ | |
$this->myArray = $myArray; | |
} |
Examples for the "Object-oriented event sourcing" article:
All gists:
-
Object-oriented event sourcing
These are code examples for the “Functional event sourcing example in Kotlin” article:
All gists:
-
Functional event sourcing example in Kotlin
These are code examples for the “Deriving state from events” article:
All gists:
-
Deriving state from events
Install Raspberry Pi OS Lite 64bit with the Raspberry Pi Imager.
Enable ssh with key authentication, change the host name, set the user password, the WiFi password. etc.
- Boot the Pi.
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
<?php | |
namespace Acme\Builder; | |
class TestDataBuilder | |
{ | |
/** | |
* @var array | |
*/ | |
protected $defauts = []; |
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
#!/usr/bin/env bash | |
COMMAND=${1:-"help"} | |
PROJECT_DIR=$(dirname $(readlink -f $0))"/.." | |
BIN_DIR=$PROJECT_DIR"/bin" | |
LOG_PATH=$PROJECT_DIR"/app/logs/ngrok.log" | |
NGROK_PATH=$BIN_DIR"/ngrok" | |
PARAMETERS_PATH=$PROJECT_DIR"/app/config/parameters.yml" |
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
package com.kaffeinelabs.function; | |
import java.util.function.Supplier; | |
public class Singleton<T> implements Supplier<T> { | |
private final Supplier<? extends T> factory; | |
private T instance = null; | |
private Singleton(final Supplier<? extends T> factory) { | |
this.factory = factory; |
NewerOlder