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
#title="[HTML] 選択したTSVから表を作成" | |
function getLines() { | |
var text = Document.Selection.Text.trim(); | |
if (text.length > 0) { | |
var delimiter = /\n/.test(text) ? /\r?\n/ : /\r/; | |
return text.split(delimiter); | |
} |
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
<!DOCTYPE html> | |
<html lang="ja" xmlns="http://www.w3.org/2000/svg"> | |
<head> | |
<meta charset="UTF-8" /> | |
<title>BlackBox v0.0</title> | |
<script src="https://cdn.jsdelivr.net/gh/exis9/squery@latest/squery.min.js"></script> | |
<style> | |
body { |
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
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.10.5/font/bootstrap-icons.css"> | |
<style> | |
body { | |
margin: 0; | |
border: 4px solid; | |
border-color: #aaa #666 #666 #aaa; | |
padding: 8px; | |
height: 100vh; | |
background: linear-gradient(to bottom right, #ccc, #888); |
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 java.util.function.Supplier; | |
public enum CircularReference { | |
P1(() -> Child.C1), | |
P2(() -> Child.C2); | |
public enum Child { | |
C1(P1), | |
C2(P2); |
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 java9.sample; | |
import java.time.LocalTime; | |
import java.util.concurrent.Flow; | |
import java.util.concurrent.SubmissionPublisher; | |
import java.util.stream.Collectors; | |
import java.util.stream.IntStream; | |
import java.util.stream.Stream; | |
public class FlowTest { |
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 final class MapLists<K, V> { | |
public final class Maps { | |
private final HashMap<K, V> map = new HashMap<K, V>(); | |
private Maps() { | |
} | |
public Maps put(K key, V value) { | |
map.put(key, value); |
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 satomaru.quiz; | |
import java.util.Arrays; | |
import java.util.Comparator; | |
import java.util.List; | |
import java.util.Optional; | |
import java.util.stream.IntStream; | |
import java.util.stream.Stream; | |
/** |
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 satomaru.sandbox.stream; | |
import java.util.Optional; | |
import java.util.function.BiFunction; | |
import java.util.stream.Stream; | |
/** | |
* Java Stream API にこういう機能があったらいいなあ的な妄想を書きなぐりました。 | |
* | |
* <p> |
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 final class EnumSetMapBuilder { | |
/** コレクター特性。 */ | |
public static final Set<Collector.Characteristics> ENUM_SET_MAP_COLLECTOR_CHARS = | |
Collections.singleton(Collector.Characteristics.UNORDERED); | |
/** |
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 tools.util; | |
import java.util.Comparator; | |
import java.util.function.Function; | |
/** | |
* 単純なコンパレーターです。 | |
* | |
* @param <T> ソート対象 | |
* @param <C> ソートに用いる値の型 |
NewerOlder