Tuesday, March 10, 2015

Solving Builder Pattern Inheritance

...using a generics-based approach outlined here:

https://weblogs.java.net/node/642849

I have feeling this could also be applied to the problem of fluent interface issues having to do with forcing the caller to append properties in the order of super class to sub class -- that was addressed in this article. It also appears to solve in an elegant way the code smells associated with doing unchecked casts like return (T) this; or returning raw types. The trick to solve these issues appears to be the use of "self-referential" type parameters.

Wednesday, October 29, 2014

Logic-based Knowledge Different from Factual, Procedural

http://msdn.microsoft.com/en-us/library/aa480020.aspx

Facts (e.g. data in a database retrieved via CRUD) and procedures are good fit for computers and typical programming languages. But there's a "semantic gap" when it comes to knowledge which is better coded using rules engines.

So much for business logic being intrinsic to OOP domain objects?

Saturday, September 20, 2014

Wednesday, May 14, 2014

Programming Language Categorizations

In "Static vs. dynamic typing of programming languages" author compares languages in three spaces:

Statically typed vs Dynamically typed (e.g. Java vs Python)

Strongly types vs Weakly typed (e.g. Python vs Perl)

Manifestly typed vs Implicitely typed (Java vs Python?)

Sunday, November 3, 2013

Helper Class Anti-pattern

 Read http://blogs.msdn.com/b/nickmalik/archive/2005/09/06/461404.aspx

E.g. rather than create a helper class to be used for url-encoding, create, inject, and use a URL object:

"Encoding a URL is part of a URL object"