Version following TSQL files
00 Backup Data.sql
- automated01 Drop Model.sql
- automated02 Create Model.sql
03 Functions.sql
04 Procedures.sql
05 Static Data.sql
06 Test Data.sql
07 Restore Data.sql
- automated
namespace RangeTester | |
{ | |
/// <summary> | |
/// Defines range related members to implementing classes. | |
/// </summary> | |
/// <typeparam name="TPoint">The type of the range point.</typeparam> | |
public interface IRangeChecker<TPoint> | |
{ | |
/// <summary> | |
/// Gets the range starting point. |
public class Program | |
{ | |
private static Random rnd = new Random(); | |
private const int RangeLength = 365; | |
private const int RangeCount = 1; | |
private const int MaxRangeLength = 100; | |
private const int IterationCount = 1000000; | |
private const int RepeatCount = 5; | |
private static readonly DateTime RangeStart = new DateTime(2012, 1, 1); |
// Global reusable mixins | |
/* | |
* Version: 2.0 (2 Feb 2012) | |
* | |
* Copyright (c) 2011 Robert Koritnik | |
* Licensed under the terms of the MIT license | |
* http://www.opensource.org/licenses/mit-license.php | |
*/ |
/* AngularJS string.Format filter | |
* | |
* This filter provides string variable replacement similar to C# string.Format("{0}", "something"); | |
* | |
* Usage: {{ "From model: {0}; and a constant: {1};" | format:model.property:"constant":...:... }} | |
*/ | |
(function (angular) { | |
angular |
Version following TSQL files
00 Backup Data.sql
- automated01 Drop Model.sql
- automated02 Create Model.sql
03 Functions.sql
04 Procedures.sql
05 Static Data.sql
06 Test Data.sql
07 Restore Data.sql
- automatedStoredProcedures.tt file automatically generates a C# code file with calsses and methods corresponding to your database stored procedure definitions. This is then used to simply call stored procedures within NPoco/PetaPoco and avoid magic strings and parameter type guessing. It also supports output parameters.
In order to have your stored procedure calls well structured there are particular yet simple naming conventions you should follow when creating your stored procedures:
ClassName_Method
Don't write the same code over and over again and rather save these two code snippets to simplify your coding. YOu will still have the same code in your methods, but will gain two main things:
So until we get Visual Studio 2014 with new C# ?.
operator this is the simplest way without additional code in the form of either extension methods or other things.
There are two snippets
$(function() { | |
alert("Initializing additional Slack keyboard shortcuts.\n\nCTRL+B = bold\nCTRL+I = italic\nCTRL+S = strike through\nCTRL+P = preformatted\nCTRL+< = code"); | |
var keys = { | |
b: "*", | |
i: "_", | |
"<": "`", | |
p: "\n```\n", | |
s : "~" |
type Prefix<TModel extends {}, P extends string> = { | |
[Key in string & keyof TModel as `${P}${Capitalize<Key>}`]: TModel[Key]; | |
} | |
type Suffix<TModel extends {}, S extends string> = { | |
[Key in string & keyof TModel as `${Key}${Capitalize<S>}`]: TMOdel[Key]; | |
} | |
// EnsureProps<{}> = never | |
// EnsureProps<Person> = Person |
const usePrevious = (value, initialValue) => { | |
const ref = useRef(initialValue); | |
useEffect(() => { | |
ref.current = value; | |
}); | |
return ref.current; | |
}; | |
export const useEffectDebugger = (effectHook, dependencies, dependencyNames = []) => { | |
const previousDeps = usePrevious(dependencies, []); |