RSSAmplifier

Andraž Bajt's blog · Jan 27, 2013

Generic singletons through dependent method types

0
Sign in to vote or save

This page cannot be shown here. You can still read it on the original site — the toolbar below keeps your place in the directory.

Ever tried to write a generic singleton? It’s an oxymoron of a sort. But sometimes my brain dreams up funny concepts to solve the problem at hand. Sadly I cannot remember what I wanted to use them for. Anyway I think I just made all the methods generic and solved it this way. But this doesn’t really express the notion of one entity that’s agnostic to type of the parameters. With…

Ever tried to write a generic singleton? It’s an oxymoron of a sort. But sometimes my brain dreams up funny concepts to solve the problem at hand. Sadly I cannot remember what I wanted to use them for. Anyway I think I just made all the methods generic and solved it this way. But this doesn’t really express the notion of one entity that’s agnostic to type of the parameters. With generic methods you get a bunch of disconnected units - at least that’s the picture in my head.

Read on /posts/2013-01-27-generic-singletons/

Comments

Nothing yet. Say the first thing.

    Sign in to join the conversation.