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 Foundation | |
public indirect enum Filter: ODataRepresentable { | |
public enum Operator: String { | |
case equalTo = "eq" | |
case notEqualTo = "ne" | |
case greaterThan = "gt" | |
case greaterThanOrEqualTo = "ge" |
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 Foundation | |
public func classDescription(_ obj: Any, | |
shouldIncludeType: Bool = false, | |
indentLevel: Int = 0) -> String { | |
return classDescription(obj, | |
shouldIncludeType: shouldIncludeType, | |
indentLevel: indentLevel, | |
optionalType: .non) |
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
var arr = [1, 1, 1, 2, 2, 3, 4, 5, 6, 6, 6, 6, 6, 7, 8] | |
var list = ["A","A","A","A","A","A","B","C","D","E","E","E","E"] | |
let set = Set(arr) // no duplicates but no order either | |
let orderedSet = NSOrderedSet(array: arr) // no duplicates and ordered, but not an array | |
let arrayFromOrderedSet = Array(NSOrderedSet(array: arr)) // is array, ordered, no duplicates, but loses type info | |
let sorted = Array(Set(arr)).sorted() // is array, ordered, no duplicates, keeps type info, but limited to ascending order | |
extension Array where Element: Equatable { |
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
INFO in lib_getUserMedia() - get(): constraints = {"video":{"facingMode":{"ideal":"user"},"width":{"min":480,"max":1280,"ideal":800},"height":{"min":480,"max":1280,"ideal":600}},"audio":false} | |
INFO in lib_getUserMedia - get_raw(): videoStream got | |
INFO in lib_getUserMedia - get_raw(): video.onloadedmetadata dispatched | |
INFO in lib_getUserMedia - get_raw(): playPromise accepted | |
WARNING in lib_getUserMedia - get_raw(): Image Capture API not found | |
INFO in lib_getUserMedia - get_raw(): callbackSuccess called with constraints= | |
{"facingMode":{"ideal":"user"},"width":{"min":480,"max":1280,"ideal":800},"height":{"min":480,"max":1280,"ideal":600}} | |
INFO in WebGLCoreLogger: VIDEO GOT! Start PlayerFF | |
============ INIT ContextFF ============ | |
INFO in ContextFF: webglOptions = {"antialias":true,"alpha":true,"preserveDrawingBuffer":true,"premultipliedAlpha":true,"stencil":false,"depth":true} |
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
// dependencies | |
const util = require('util'); | |
const sharp = require('sharp'); | |
const AWS = require('aws-sdk'); | |
// get reference to S3 client | |
const s3 = new AWS.S3(); | |
exports.handler = async (event, context, callback) => { |
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
const tree = { | |
"type": "", | |
"children": [ | |
{ | |
"type": "1", | |
"children": [ | |
{ | |
"type": "1.1", | |
"children": [ | |
{ "type": "1.1.1", "children": [] }, |