| Constant | Description |
|---|---|
| none | There is no content type. The text is not editable. |
This file contains hidden or 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
| // somewhere early in App.xaml.cs | |
| AppDomain.CurrentDomain.UnhandledException += (s, e) => | |
| LogUnhandledException((Exception) e.ExceptionObject, "AppDomain.CurrentDomain.UnhandledException"); | |
| DispatcherUnhandledException += (s, e) => | |
| LogUnhandledException(e.Exception, "Application.Current.DispatcherUnhandledException"); | |
| TaskScheduler.UnobservedTaskException += (s, e) => | |
| LogUnhandledException(e.Exception, "TaskScheduler.UnobservedTaskException"); |
Many different applications claim to support regular expressions. But what does that even mean?
Well there are lots of different regular expression engines, and they all have different feature sets and different time-space efficiencies.
The information here is just copied from: http://regular-expressions.mobi/refflavors.html
This file contains hidden or 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 ruby | |
| require 'yaml' | |
| TYPE_TO_KSY = { | |
| 'uint8_t' => 'u1', | |
| 'uint16_t' => 'u2', | |
| 'uint32_t' => 'u4', | |
| 'uint64_t' => 'u8', |
This file contains hidden or 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.io.ByteArrayOutputStream | |
| import java.io.File | |
| import java.nio.charset.StandardCharsets.UTF_8 | |
| import java.util.zip.GZIPInputStream | |
| import java.util.zip.GZIPOutputStream | |
| fun gzip(content: String): ByteArray { | |
| val bos = ByteArrayOutputStream() | |
| GZIPOutputStream(bos).bufferedWriter(UTF_8).use { it.write(content) } | |
| return bos.toByteArray() |
This file contains hidden or 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 io.realm.* | |
| import io.realm.kotlin.where | |
| import kotlinx.coroutines.GlobalScope | |
| import kotlinx.coroutines.launch | |
| import kotlinx.coroutines.suspendCancellableCoroutine | |
| import kotlin.coroutines.resume | |
| import kotlin.coroutines.resumeWithException | |
| private suspend fun <T: RealmObject, S: RealmQuery<T>> findAllAwait(query: S): RealmResults<T> = suspendCancellableCoroutine { continuation -> | |
| val listener = RealmChangeListener<RealmResults<T>> { t -> continuation.resume(t) } |
This file contains hidden or 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 'package:flutter/material.dart'; | |
| void main() => runApp(MyApp()); | |
| class MyApp extends StatelessWidget { | |
| @override | |
| Widget build(BuildContext context) { | |
| return MaterialApp( | |
| home: Scaffold( | |
| body: Center( |
Node Version Manager (https://github.com/nvm-sh/nvm) works perfectly across native node installations as well as emulated Rosetta installations. The trick I am using here is to install one LTS version of node under Rosetta and another stable version as native binary.
- find a way how to run the same node version on both platforms
This document now exists on the official ASP.NET core docs page.
- Application
- Request Handling
OlderNewer