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
class Order { | |
var _id; | |
var _reference; | |
var date; | |
var code; | |
List<String> bookings; | |
Order(this._id, this._reference, {this.date}); | |
Order.withDiscount(this._id, this._reference, [this.code]) { | |
date = DateTime.now(); |
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
void main() { | |
MockClient client = null; | |
test('calling initiate(client) returns a list of storylinks', () async { | |
// Arrange | |
client = MockClient((req) => Future(() => Response(''' | |
<body> | |
<table><tbody><tr> | |
<td class="title"> | |
<a class="storylink" href="https://dartlang.org">Get started with Dart</a> |
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 'dart:async'; | |
import 'package:http/http.dart' as http; | |
import 'package:html/parser.dart' as parser; | |
import 'package:html/dom.dart'; | |
main() async { | |
http.Response response = await http.get('https://news.ycombinator.com/'); | |
Document document = parser.parse(response.body); | |
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
class _DiamondBorder extends ShapeBorder { | |
const _DiamondBorder(); | |
@override | |
EdgeInsetsGeometry get dimensions { | |
return const EdgeInsets.only(); | |
} | |
@override | |
Path getInnerPath(Rect rect, { TextDirection textDirection }) { |
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
class ScreenOne extends StatefulWidget { | |
@override | |
_ScreenOneState createState() => _ScreenOneState(); | |
} | |
class _ScreenOneState extends State<ScreenOne> { | |
@override | |
Widget build(BuildContext context) { | |
return Scaffold( | |
appBar: AppBar( |
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
using System; | |
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
public class MeshDestroy : MonoBehaviour | |
{ | |
private bool edgeSet = false; | |
private Vector3 edgeVertex = Vector3.zero; | |
private Vector2 edgeUV = Vector2.zero; |
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
Shader "Custom/HlslFog" | |
{ | |
Properties | |
{ | |
_MainTex ("Base (RGB)", 2D) = "white" { } | |
_FogColor ("Fog Color (RGB)", Color) = (0.5, 0.5, 0.5, 1.0) | |
_FogStart ("Fog Start", Float) = 0.0 | |
_FogEnd ("Fog End", Float) = 10.0 | |
} | |
SubShader |
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
Shader "Custom/AlphaMask_Additive" | |
{ | |
Properties | |
{ | |
_TintColor ("Tint Color", Color) = (0.5, 0.5, 0.5, 0.5) | |
_MainTex ("Base (RGB)", 2D) = "white" { } | |
_AlphaMask ("Alpha Mask", 2D) = "white" { } | |
_AlphaAmount ("Alpha Amount", Range(-1, 1)) = 1 | |
} | |
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
Shader "Custom/AlphaMask_Unlit" | |
{ | |
Properties | |
{ | |
_TintColor ("Tint Color", Color) = (0.5, 0.5, 0.5, 0.5) | |
_MainTex ("Base (RGB)", 2D) = "white" { } | |
_AlphaMask ("Alpha Mask", 2D) = "white" { } | |
_AlphaAmount ("Alpha Amount", Range(-1, 1)) = 1 | |
} | |
SubShader |
NewerOlder