Click here to Skip to main content
15,887,596 members
Home / Discussions / C#
   

C#

 
GeneralRe: Skipping locked section already in use Pin
PIEBALDconsult15-May-12 14:56
mvePIEBALDconsult15-May-12 14:56 
GeneralRe: Skipping locked section already in use Pin
Ravi Bhavnani15-May-12 15:02
professionalRavi Bhavnani15-May-12 15:02 
GeneralRe: Skipping locked section already in use Pin
PIEBALDconsult15-May-12 17:21
mvePIEBALDconsult15-May-12 17:21 
GeneralRe: Skipping locked section already in use Pin
jschell16-May-12 9:04
jschell16-May-12 9:04 
GeneralRe: Skipping locked section already in use Pin
Pete O'Hanlon15-May-12 8:20
mvePete O'Hanlon15-May-12 8:20 
GeneralRe: Skipping locked section already in use Pin
Sentenryu15-May-12 8:39
Sentenryu15-May-12 8:39 
GeneralRe: Skipping locked section already in use Pin
jschell15-May-12 9:02
jschell15-May-12 9:02 
GeneralRe: Skipping locked section already in use Pin
Pete O'Hanlon15-May-12 21:43
mvePete O'Hanlon15-May-12 21:43 
jschell wrote:
For the first problem sometime the very nature of the need dictates
serialization anyways.

In that case, you shouldn't be parallelising the code at this point. This concern was raised specifically for the case where you have a parallel architecture that has to be throttled because of a singleton.

jschell wrote:
As for the second problem there are trivial solutions for most problems of that
nature, for example just implementing a Reset() method.

So, we're talking about introducing a method just to get through a test; not for any other purpose.

I think you misunderstood my point. I wasn't arguing that you should never use a singleton; I was just showing what the weaknesses are. If you are comfortable that you understand the pattern sufficiently well, and that you know exactly how your code is going to be used, then you can make an informed decision. If you don't know what the weaknesses are, then you can end up causing all sorts of problems for yourself.

*pre-emptive celebratory nipple tassle jiggle* - Sean Ewington

"Mind bleach! Send me mind bleach!" - Nagy Vilmos


CodeStash - Online Snippet Management | My blog | MoXAML PowerToys | Mole 2010 - debugging made easier

GeneralRe: Skipping locked section already in use Pin
jschell16-May-12 9:07
jschell16-May-12 9:07 
GeneralRe: Skipping locked section already in use Pin
BobJanova16-May-12 0:39
BobJanova16-May-12 0:39 
Questioncollapsing xml elements into attributes in c# Pin
swjam15-May-12 2:26
swjam15-May-12 2:26 
AnswerRe: collapsing xml elements into attributes in c# Pin
Pete O'Hanlon15-May-12 2:31
mvePete O'Hanlon15-May-12 2:31 
GeneralRe: collapsing xml elements into attributes in c# Pin
swjam15-May-12 2:49
swjam15-May-12 2:49 
GeneralRe: collapsing xml elements into attributes in c# Pin
Pete O'Hanlon15-May-12 2:51
mvePete O'Hanlon15-May-12 2:51 
AnswerRe: collapsing xml elements into attributes in c# Pin
PIEBALDconsult15-May-12 3:35
mvePIEBALDconsult15-May-12 3:35 
JokeRe: collapsing xml elements into attributes in c# Pin
swjam15-May-12 4:39
swjam15-May-12 4:39 
GeneralRe: collapsing xml elements into attributes in c# Pin
Dave Kreskowiak15-May-12 5:02
mveDave Kreskowiak15-May-12 5:02 
GeneralRe: collapsing xml elements into attributes in c# Pin
PIEBALDconsult15-May-12 5:37
mvePIEBALDconsult15-May-12 5:37 
GeneralRe: collapsing xml elements into attributes in c# Pin
Dave Kreskowiak15-May-12 7:26
mveDave Kreskowiak15-May-12 7:26 
GeneralRe: collapsing xml elements into attributes in c# Pin
PIEBALDconsult15-May-12 5:38
mvePIEBALDconsult15-May-12 5:38 
GeneralRe: collapsing xml elements into attributes in c# Pin
Mycroft Holmes15-May-12 14:28
professionalMycroft Holmes15-May-12 14:28 
GeneralRe: collapsing xml elements into attributes in c# Pin
PIEBALDconsult15-May-12 14:34
mvePIEBALDconsult15-May-12 14:34 
QuestionRedirecting output from an unmanaged dll Pin
andreas0414-May-12 23:19
andreas0414-May-12 23:19 
AnswerRe: Redirecting output from an unmanaged dll Pin
BobJanova15-May-12 0:27
BobJanova15-May-12 0:27 
AnswerRe: Redirecting output from an unmanaged dll Pin
Richard MacCutchan15-May-12 1:37
mveRichard MacCutchan15-May-12 1:37 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.