Looking at the List (4 of 6 or 7)

Another set of annotations for the list:


31.  Declarative – LINQ


LINQ allows a specific way to access collections. This access is via a query which is executed when needed. The common syntax can be interpreted via a provider. The actual behavior moves from the code into the provider, and designing objects for meaningful use in LINQ becomes imperative.

 

32.  DependencyProperties


Dependency properties are a property bag – in short form a dictionary where items are placed in, accessed via, and tracked via the surrounding dependency object. This makes dependency objects far more powerful and flexible, particularly in the area of designers. Object design with libraries that use dependency properties (currently WPF and WF) must select which properties are dependency properties.

 

33.  Dynamic languages

(I’m weak on dynamic languages and am actually going to postpone this to let someone else jump in here. I anticipate many child implications of this. But, as we do not have dynamic languages on our desks today in mainstream .NET languages, this does not have an immediate impact) 

34.  Security


The appearance of an object, the available properties, is determined partly by structure, and partly by the authorization roles of the current user. This must be considered in designing objects – both properties and available methods.

 

35.  Unstructured data


As programmers we remain enamored with the structured data – relational data stored in the database, and other pre-structured data. But much of the important information in the world resides in unstructured data – text documents, html pages, email, IM histories, wikis, etc. This data is not tractable from an object point of view, but we must deal with it. 

 

36.  Generative programming


Generative programming is a general term for programming with an extra level of abstraction. It generally means programming via metadata. Historically, if the work was done at runtime, it was called an OR/M (Object Relational Modeling) tool and at design time a code generator – although that terminology is not consistently used.

 

37.  Social networking


Applications don’t just involve data and bits, the success of an application may depend on how humans interact with each other through the software. This is fairly obvious in programs like IM and Linked In. It is also present in all voting applications and programs like the NetFlix ratings that depend on socially collected data. 


38.  AJAX


Ajax splits code across client and server – some literally runs at each location. Designing objects to work well in this environment also complicates testing and maintenance, especially in an enterprise environment where proxy servers may be involved.


39.  Reporting (filtering, authorization)


If objects are involved in reporting, additional demands for user-driven/configurable reporting become involved. A set of objects may exist solely for the purpose of testing. If they are not involved, then calculations are pushed back on to the data server, which may not be desirable.


40.BDD/TDD/Agile


In general agile results in a code as you go strategy to design as opposed to a lot of up front design. Supporting “You ain’t going to need it” (YAGNI) means developers are focused on the immediate problem, generally forgoing a broader perspective. Also, BDD, by its name and usage is a behavior focused, rather than data focused view of objects. Finally, certain agile methodologies are tied to certain design patters, specifically “model-view-controller” (MVC).



 

Looking at the List (3 of 6 or 7)

Here’s the next set of annotation for the list of reasons your development is crazy.


Each item is also the reason devleopment is possible, and wonderful. I am not whining about this – just trying to get a meaningful perspective and taxonomy to rein in crazy development. While I’m working on my taxonomy passes, feel free to do your own. Just categorize the items in any way that feels useful to you. That’s all a taxonomy is – a useful organization.


 21.  Generics


Generics provide a pattern from which many classes derive. These are extremely powerful in refactoring hierarchies and often result in an extra hierarchy layer so there is a polymorphic non-generic base class, and a generic base class.

 

22.  Reflection


Reflection allows you to break scoping rules at will. Sometimes this is highly desirable, such as creating factories and overcoming limitations in the generic New constraint.

 

23.  Intellisense


In addition to designing classes for their runtime behavior, we need to design them to minimize Intellisense polluting. This primarily involves a design pass of adding attributes to items inappropriate for Intellisense.

 

24.  Partial classes


Partial classes remove the anticipated relationship between files and classes. It also allows fragments of a file to be placed anywhere in your source code – potentially a vulnerability if you have marginally trusted people in your source code. There is currently no way to track partial classes.

 

25.  Partial methods


Partial methods result in new design patterns for the sake of allowing code replacements. This approach is unique in that code is actually not compiled, rather than being compiled and treated in a special manner at runtime. In addition to being philosophically unique, it allows for hazardous side effects.

 

26.  Extension methods


From a logical and Intellisense perspective, you can add methods to any class and anyone can add methods to your class. They do not need to be have your source code and from the perspective of the class or programmers maintaining the class, these methods do not exist.

 

27.  Lambda expressions and delegates


Delegates and lambda expressions allow fragments of code to be passed around the application. This technique became much more powerful with the introduction of generic delegates where common features can be implemented without casts. As a result, classes can be designed so that important portions of their functionality plug in and behavior might differ markedly depending on runtime assignments.

 

28.  Anonymous types


You don’t even have to write the class anymore. Simple objects with data (not behavior) can be created on the fly at runtime and not even known at compile time.

 

29.  Declarative – XAML


XAML offers a new syntax for creating objects and properties. By itself that has little impact on class design. However, XAML also offers markup extensions which allow a specialized string only syntax for constructors. Also, since XAML doesn’t run code, code must be contained in an adjacent “code beside” file that is not even written in the same language. At runtime, XAML becomes .NET code, so there is an extra level of redirection in debugging. Effectively using XAML and markup requires consideration during design.

 

30.WPF – styles


WPF redefines what it means to be a UI item. It allows separation of UI into layout, appearance and behavior. This relies on styles which are a collection of property settings, relying on other property settings. Thus UI behavior is comprised of code in many places, and because of implicit properties these are not all available through the property name, but its type.