Skip to main content
14 events
when toggle format what by license comment
Apr 12, 2017 at 7:31 history edited CommunityBot
replaced http://programmers.stackexchange.com/ with https://softwareengineering.stackexchange.com/
Aug 28, 2015 at 12:10 audit First posts
Aug 29, 2015 at 17:49
Aug 25, 2015 at 13:01 comment added Andy Properties generally shouldn't thrown exceptions; instead of a setter that throws ArgumentNullException, provide a SetClient method instead. Someone posted the link to an answer regarding this on the question.
Aug 25, 2015 at 3:35 comment added durron597 @Pharap I've edited that too. Thanks for your input.
Aug 25, 2015 at 3:34 history edited durron597 CC BY-SA 3.0
added 5 characters in body
Aug 25, 2015 at 3:33 comment added Pharap @durron597 I should have guessed that from the use of the term 'final' (in this case the corresponding C# keyword is readonly). I would have just edited but I felt a comment would serve to better explain why (for future readers). If you hadn't already given this answer I would be giving the exact same solution. Immutability is also a good idea, but it's not always as easy as one hopes.
Aug 25, 2015 at 3:22 history edited durron597 CC BY-SA 3.0
deleted 34 characters in body
Aug 25, 2015 at 3:21 comment added durron597 @Pharap I'm a Java programmer attempting to write C# code, I figured I'd make mistakes like that.
Aug 25, 2015 at 3:19 comment added Pharap No. Program code should never throw a NullReferenceException, it is thrown by the .Net VM "when there is an attempt to dereference a null object reference". You should be throwing an ArgumentNullException, which is thrown "when a null reference (Nothing in Visual Basic) is passed to a method that does not accept it as a valid argument."
Aug 25, 2015 at 2:36 comment added Mathieu Guindon Shouldn't these be ArgumentNullExceptions?
Aug 24, 2015 at 21:38 history edited durron597 CC BY-SA 3.0
added 68 characters in body
Aug 24, 2015 at 17:30 history edited durron597 CC BY-SA 3.0
added 414 characters in body
Aug 24, 2015 at 17:02 history edited user53019 CC BY-SA 3.0
minor idiomatic change
Aug 24, 2015 at 16:43 history answered durron597 CC BY-SA 3.0