background preloader

Programming

Facebook Twitter

A summary of 2011 and a look at what is about to come. Happy 2012 folks!

A summary of 2011 and a look at what is about to come

I hope you all had a wonderful new years eve! The year 2011 has been very interesting, we’ve had the opportunity to see some very exciting things that is about to reach the market. I’d like to summarize what I’ve been writing about in 2011 and breifly tell you guys what’s about to expect from me in 2012. How to Get Elevated Process Path in .Net - About My Code. .net - Hidden Features of C# Spec# Spec# is a formal language for API contracts (influenced by JML, AsmL, and Eiffel), which extends C# with constructs for non-null types, preconditions, postconditions, and object invariants.

Spec#

Spec# comes with a sound programming methodology that permits specification and reasoning about object invariants even in the presence of callbacks and multi-threading. Spec# is a research vehicle that has been used to explore specifications and the dynamic/static tools that make use of them. Contracts. Code Contracts provide a language-agnostic way to express coding assumptions in .NET programs.

Contracts

The contracts take the form of preconditions, postconditions, and object invariants. Contracts act as checked documentation of your external and internal APIs. The contracts are used to improve testing via runtime checking, enable static contract verification, and documentation generation. Sorting Algorithm Animations. Algorithms in Java, Parts 1-4, 3rd edition by Robert Sedgewick. Addison Wesley, 2003. Quicksort is Optimal by Robert Sedgewick and Jon Bentley, Knuthfest, Stanford University, January, 2002.

Dual Pivot Quicksort: Code by Discussion. Bubble-sort with Hungarian (“Csángó”) folk dance YouTube video, created at Sapientia University, Tirgu Mures (Marosvásárhely), Romania. Select-sort with Gypsy folk dance YouTube video, created at Sapientia University, Tirgu Mures (Marosvásárhely), Romania. Sorting Out Sorting, Ronald M.

Using the C# Interactive Window that comes with Roslyn – Part 2. In the previous post we looked over an introduction to the C# Interactive Window that comes with Roslyn, now let’s have a look at some things in the c# interactive window that will increase your productivity!

Using the C# Interactive Window that comes with Roslyn – Part 2

I want to thank Kevin Pilch-Bisson ( @Pilchie ) for pointing some of these things out. Hosted Execution of smaller code snippets with Roslyn. Lately a lot of my time has been spent on playing around with Roslyn, if you have no idea what Roslyn is I suggest that you go and read my previous posts on it.

Hosted Execution of smaller code snippets with Roslyn

One of the things that I challenged myself into doing was creating some soft of service that could execute a code snippet like the interactive window and give me the result back to me. First off I just want to say that I completely Love the C# Interactive Window, I’ve got two posts dedicated to it already! With that said, let’s step on the gas a bit, a while back there was a blog post about how to replicate the c# interactive window outside visual studio, hence creating a REPL that didn’t require you to run visual studio.

This is pretty awesome if you ask me. However the code that you write into the REPL is assumed to be trusted, it doesn’t run in a completely different security context which makes it dangerous if you want to expose it to others. So what I wanted to achieve was the following: Sounds confusing? If (! Topten Software. A tiny ORM-ish thing for your POCOs PetaPoco is a tiny, fast, single-file micro-ORM for .NET and Mono.

Topten Software

Like Massive it's a single file that you easily add to any projectUnlike Massive it works with strongly typed POCO'sLike Massive, it now also supports dynamic Expandos too - read moreLike ActiveRecord, it supports a close relationship between object and database tableLike SubSonic, it supports generation of poco classes with T4 templatesLike Dapper, it's fast because it uses dynamic method generation (MSIL) to assign column values to properties Background PetaPoco was original inspired by Rob Conery's Massive project but for use with non-dynamic POCO objects. It came about because I was finding many of my projects that used SubSonic/Linq were slow or becoming mixed bags of Linq and CodingHorror. I needed a data acess layer that was tiny, fast, easy to use and could run on .NET 3.5 and/or Mono 2.6 (ie: no support for dynamic expandos). So, what's with the name? Component-based Scalable Logical Architecture.

CSLA .NET logo Although CSLA itself is free to download, the only documentation the creator provides are his books and videos, which are not free.

Component-based Scalable Logical Architecture

CSLA .NET was expounded in Expert C# Business Objects [2] and Expert One-on-One Visual Basic .NET Business Objects ISBN 1-59059-145-3, both written by Lhotka. Although CSLA and CSLA .NET were originally targeted toward Microsoft programming languages, most of the framework can be applied to most object oriented languages. Current information about CSLA .NET is available through Lhotka's self-published Using CSLA 4 ebook series.[3] Features of CSLA[edit] Smart data[edit] A business object encapsulates all the data and behavior (business logic and rules) associated with the object it represents.

Rules engine[edit] The CSLA .NET framework provides a rules engine that supports validation rules, business rules, and authorization rules. Object persistence[edit] Metastate maintenance[edit] CSLA .NET manages the metastate about each business object.