http://www.people4business.com/e/617D28C6-4E92-47C4-BCED-558A6218E18A
If you go through the above link to register then I’ll get a finders fee if you get a contract through the site - which I’ll split 50/50 with you
About people4business:
“To create a sophisticated online business-to-business marketplace for the Buyers and Sellers of contracting and consultancy services across all industries and job types�
Our lean 10% margin on our Sellers’ hourly rates is far lower than most specialist contractor sites. We believe in absolute transparency of cost – so Buyers and Sellers know exactly what rates are being charged in their market.
I was asked this very question (What do you think of Polymorphism?) in an interview and unfortunately wasn’t able to communicate my thoughts on this area of OO theory very well. TBH I just hadn’t had to vocalise or rationalise my thoughts on this to anyone before .. so was a little lost in an interview situation.
Basically my view is that Polymorphism is a great thing to have BUT you do have to a be a little carefull how you go about achieving it.
Inheritance versus composition: Which one should you choose? - A comparative look at two fundamental ways to relate classes.
Author’s Summary (not mine)
“Make sure inheritance models the is-a relationship My main guiding philosophy is that inheritance should be used only when a subclass is-a superclass. In the example above, an Apple likely is-a Fruit, so I would be inclined to use inheritance.
An important question to ask yourself when you think you have an is-a relationship is whether that is-a relationship will be constant throughout the lifetime of the application and, with luck, the lifecycle of the code. For example, you might think that an Employee is-a Person, when really Employee represents a role that a Person plays part of the time. What if the person becomes unemployed? What if the person is both an Employee and a Supervisor? Such impermanent is-a relationships should usually be modelled with composition.
Don’t use inheritance just to get code reuse If all you really want is to reuse code and there is no is-a relationship in sight, use composition.
Don’t use inheritance just to get at polymorphism If all you really want is polymorphism, but there is no natural is-a relationship, use composition with interfaces. ” - Bill Venners
I seem to have moved up a level when it comes to climbing indoors. By this I mean that I find that I’m climbing a grade harder than I have ever done before. This is good .. it’s great! .. but it’s raised some issues.
Those issues mainly boil down to; how do I climb even harder routes
What I’ll do is list the current situation in terms of what’s holding me back:
With vertical routes it’s usually simply reading the route .. once I’ve discovered the move I’ll do it. Unfortunately, at the moment, it’s taking a couple of goes or some beta before I figure it out. I’m not too worried about this .. reckon I’ll just get better at this over time, naturally and with no special effort on my part.
On slightly overhanging routes it’s usually that I just don’t have the finger strength. At this grade and with a slight incline it appears that most routes require finger holds that are just too small for me to hang at the moment. I’m worried by this as my fingers appear to be getting hammered anyway, just doing the routes I’m attempting without hanging onto even smaller holds. I believe that in the New Year I’ll start using my finger board and this will prove to be the single training aid that’ll get me over this hurdle. That and losing weight (1/2 stone I reckon will make a difference).
On overhanging routes - strength/power are what I require. Technique appears to be OK (bouldering has seen to that) but usually it’s a power move that I have to mess around with using better technique to get around. Just a little more strength/power would make this a whole lot easier. Not too worried .. just doing these routes will improve my strength/power and when I lose a little weight that’ll all help too.
I thought I’d gotten a handle on unit testing my code .. I knew that some of my tests where not unit tests at all but that was always because the legacy code I was having to update just made it difficult to truly unit test.
But now with my File Watcher project underway and I’m writing virgin code without any limitations on time or methodology, where there’s no place to hide in terms of excuses, then I’m having to face the stark reality that I need to raise my game somewhat and start writing better test code.
I’m not saying that I can’t write tests or that I’m not using TDD but I firmly believe that I should try harder to write better test code. Probably the easiest way to explain this is to state a simple aim that I’m now aiming to hit:
- if one line of code has a bug then one, and only one, unit test should fail.
To follow on from this, the next obvious xUnit tool I should be using is some sort of automated coverage utility becuase if I seriously restrict my unit tests to very small areas of code then it’ll be easy fo rme to miss areas.
BTW Learning this would have been so much easier with some kind of mentor and pair programming.
It’s weird .. you get to a certain level of competency within a particle field .. you think you’ve got it sussed, you know your limitations but on the whole your happy with your abilities and get stuff done.
Then you decide consciously (and usually it is a conscious decision) to make the move up to the next level of skill and bang! Your understanding and ability feel like they’ve gone back to square one. You feel clumsy and unsure of your self at this new level.
This same thing has happened to me in the last couple of weeks in two completely different aspects of my life: unit testing my code and rock climbing.
Now that I’ve gotten a simple WCF infrastructure up and running, with the original File Monitor process passing events onto a Publish Subscribe service it was incredably easy to add a whole bunch of observers applications;
- Console App
- Winforms App
- WPF Application (Thick client)
These all re-used a proxy object to the subscribe management service and with a simple list box (or Console.Writeline() call) where all “seeing” the file changes within a few minutes
I then moved onto another style of observer app:
- WPF Browser Application (Thin client)
.. and straight away I was getting cryptic error messages re: unable to create the web page due to a problem with the XAML format. This error message is misleading becuase I tracked the problem down to the code where I was attempting to actually subscribe via the proxy to an event. It just didn’t like it.
I haven’t found a solution yet .. I’ve just downloaded the VS 2008 Web Development Express version to see if a “normal” website has similar problems.
Other items I’ve noticed re: all of this so far include:
- Out of the box WCF appears to use no message queing of any sort .. to have this functionality (TBH It’s the main feature I’m interested in) then it needs to be setup. I’ll do this once I’ve figured out the WPF website issues.
- WCF does not like end point services to just disappear .. not surprising in itself but it does appear to then get its knickers in a bit of a mess for some time afterwards. It appears to throw channel faults for sometime afterwards even when all services are have been re-instated and there is therefore no obvious reason for a fault to occur. This is a bit of a worry .. will have to wait and see.
I climbed Parle (3 pitch sea cliff route in the Toix area of Costa Blanca) a couple of weeks ago and put up a blog about what is my favourite climb I’ve ever been on.
Well .. some friends from the same climbing club went to do the route the day after I did .. they’ve written up their mini adventure here.
I don’t want to give anything away but let’s just say that their climb will be talked about in pubs in the Midlands, the South West and Spain for a lot longer than mine (and I ain’t got a problem with that).
Yep, gotten a WCF Publish service and client up and running. TBH the biggest issues where getting it linked into SQL Server Express. Did have some kind of caching issues too but that seems to have gone away.
Anyway, so now I have a system where:
- a file changes,
- And the File Watcher helper class, running on a seperate thread within a console app, raises an appropriate event,
- the event handler examines the file and the contents are split into a number of packets of data.
- This data is then passed to a File watcher specific gateway,
- This domain specific gateway then has a chat with a generic (I suppose messaging) gateway which decides to act as a WCF client
- This WCF client opens a channel to the Publish half of a Publish-Subscribe system all implementated in WCF and running under a console app host.
The next obvious step qould be to start building some subscribers for these events but TBH I took some rather large steps getting some of the pieces above to actually work. Actually most of it was fine except the WCF bits and they are a problem becuase they’re created using great chunks of pre-packaged functionality. So my TDD hat has effectively fallen off. I’m not too concerned that it happened - I mean all of the access to the WCF is from behind my own interfaces so there’s only one place to start changing/testing/mocking.
Also there’s always a bit of a chicken and egg situation with new technologies where to actually get it to initially work is actually more important than TDDing it (I think). As long as you then go back to the beginning and redo the work so that it’s TDD.
NB: I also spotted a bug in my code during integration testing and spent some time writing a test that covered the area of code that contained the bug, test failed, fixed bug, test passed. TDD back on course 