Skip to content

Instantly share code, notes, and snippets.

/* tslint:disable */
/* eslint-disable */
//----------------------
// <auto-generated>
// Generated using the NSwag toolchain v13.1.6.0 (NJsonSchema v10.0.28.0 (Newtonsoft.Json v9.0.0.0)) (http://NSwag.org)
// </auto-generated>
//----------------------
// ReSharper disable InconsistentNaming
export class Client {
@jfreyre
jfreyre / HttpClientPartners.cs
Last active November 26, 2019 13:40
Result of the auto-generated http client with nswag
//----------------------
// <auto-generated>
// Generated using the NSwag toolchain v13.1.6.0 (NJsonSchema v10.0.28.0 (Newtonsoft.Json v9.0.0.0)) (http://NSwag.org)
// </auto-generated>
//----------------------
#pragma warning disable 108 // Disable "CS0108 '{derivedDto}.ToJson()' hides inherited member '{dtoBase}.ToJson()'. Use the new keyword if hiding was intended."
#pragma warning disable 114 // Disable "CS0114 '{derivedDto}.RaisePropertyChanged(String)' hides inherited member 'dtoBase.RaisePropertyChanged(String)'. To make the current member override that implementation, add the override keyword. Otherwise add the new keyword."
#pragma warning disable 472 // Disable "CS0472 The result of the expression is always 'false' since a value of type 'Int32' is never equal to 'null' of type 'Int32?'
#pragma warning disable 1573 // Disable "CS1573 Parameter '...' has no matching param tag in the XML comment for ...
@jfreyre
jfreyre / global.asax.cs
Last active August 29, 2015 14:25
How to list all availables routes from a webapi application
#region Usings
using System;
using System.Web;
using System.Web.Helpers;
using System.Web.Http;
using System.Web.Http.Description;
using System.Web.Mvc;
//
// ViewController.m
//
// Created by Jérome Freyre on 13.04.15.
// Copyright (c) 2015 @jfreyre. All rights reserved.
//
#import "ViewController.h"
#import <AddressBook/AddressBook.h>
@jfreyre
jfreyre / index.html
Created March 31, 2015 06:35
Angular | Same directive name but different implementation
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Example - example-example14-production</title>
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.4.0-beta.6/angular.min.js"></script>
<script src="script.js"></script>
<div class="article">
<div class="en-tete">
<h1>Lorem ipsum</h1>
</div>
<div class="contenu">
<p>Lorem ipsum dolor sit amet</p>
</div>
<div class="meta">...</div>
</div>
Storage.prototype.setObject = function(key, value) {
this.setItem(key, JSON.stringify(value));
}
Storage.prototype.getObject = function(key) {
var value = this.getItem(key);
return value && JSON.parse(value);
}
html {
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%
}
body {
margin: 0;
}
* {
-webkit-box-sizing: border-box;
@jfreyre
jfreyre / Assert Lave
Created October 27, 2014 12:37
Laravel Testing
assertArrayHasKey()
assertClassHasAttribute()
assertClassHasStaticAttribute()
assertContains()
assertContainsOnly()
assertContainsOnlyInstancesOf()
assertCount()
assertEmpty()