Click here to Skip to main content
15,891,136 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
GeneralRe: I suspect there's a Pattern for This: Optional Parameters vs. Overloading Pin
M-Badger16-May-13 9:58
M-Badger16-May-13 9:58 
GeneralRe: I suspect there's a Pattern for This: Optional Parameters vs. Overloading Pin
Eddy Vluggen16-May-13 11:26
professionalEddy Vluggen16-May-13 11:26 
AnswerRe: I suspect there's a Pattern for This: Optional Parameters vs. Overloading Pin
jschell16-May-13 7:57
jschell16-May-13 7:57 
GeneralRe: I suspect there's a Pattern for This: Optional Parameters vs. Overloading Pin
M-Badger16-May-13 8:37
M-Badger16-May-13 8:37 
GeneralRe: I suspect there's a Pattern for This: Optional Parameters vs. Overloading Pin
jschell17-May-13 10:13
jschell17-May-13 10:13 
AnswerRe: I suspect there's a Pattern for This: Optional Parameters vs. Overloading Pin
TnTinMn16-May-13 13:37
TnTinMn16-May-13 13:37 
GeneralRe: I suspect there's a Pattern for This: Optional Parameters vs. Overloading Pin
M-Badger17-May-13 6:49
M-Badger17-May-13 6:49 
GeneralRe: I suspect there's a Pattern for This: Optional Parameters vs. Overloading Pin
TnTinMn17-May-13 8:33
TnTinMn17-May-13 8:33 
Quote:
That one had occured but it meant that a user of the class would need to know that the overload without a method would give ByLuminosity, which was the bit that felt unintuitive.

The issue of being intuitive is very subjective. I see the intuitive part being to use the "ToGreyScale" method and even that may require some explanation. At some point a programmer has to demonstrate some competence and look at the provided documentation. This is the reason that I showed the visual studio intellisense support using xml comments in the code I posted (see: Documenting Your Code With XML Comments). Providing this documentation is your responsibility as the developer and you should not be relying on something being intuitive as a substitute for proper documentation. Paste the extension method code I provided into a project and observe the intellisence pop-ups when you try to use the defined methods.

Quote:
BTW, thanks for the piece, I assume that's how extension methods work?

Assume nothing Poke tongue | ;-P when coding. Use your friendly search engine and research it yourself. I have found that this general query works well in the major search engines:

msdn TopicYouWant -social"

The reason for the "-social" is to try to eliminate results from the msdn help forums and to focus on the documentation pages.

So much for my preaching for the day, have a good weekend. Blush | :O
GeneralRe: I suspect there's a Pattern for This: Optional Parameters vs. Overloading Pin
M-Badger17-May-13 21:47
M-Badger17-May-13 21:47 
QuestionAssembly Loading Pin
#realJSOP14-May-13 5:10
mve#realJSOP14-May-13 5:10 
AnswerRe: Assembly Loading Pin
Jasmine250114-May-13 6:18
Jasmine250114-May-13 6:18 
GeneralRe: Assembly Loading Pin
#realJSOP14-May-13 6:57
mve#realJSOP14-May-13 6:57 
GeneralRe: Assembly Loading Pin
Jasmine250114-May-13 7:12
Jasmine250114-May-13 7:12 
AnswerRe: Assembly Loading Pin
jschell14-May-13 9:22
jschell14-May-13 9:22 
GeneralRe: Assembly Loading Pin
Jasmine250114-May-13 11:36
Jasmine250114-May-13 11:36 
GeneralRe: Assembly Loading Pin
jschell15-May-13 8:23
jschell15-May-13 8:23 
AnswerRe: Assembly Loading Pin
Abhinav S15-May-13 8:16
Abhinav S15-May-13 8:16 
QuestionThe equivalent of 'OninitDlg()' Pin
Bram van Kampen10-May-13 13:51
Bram van Kampen10-May-13 13:51 
AnswerRe: The equivalent of 'OninitDlg()' Pin
dusty_dex10-May-13 14:18
dusty_dex10-May-13 14:18 
GeneralRe: The equivalent of 'OninitDlg()' Pin
Bram van Kampen12-May-13 13:03
Bram van Kampen12-May-13 13:03 
GeneralRe: The equivalent of 'OninitDlg()' Pin
dusty_dex12-May-13 13:42
dusty_dex12-May-13 13:42 
GeneralRe: The equivalent of 'OninitDlg()' Pin
Bram van Kampen13-May-13 13:06
Bram van Kampen13-May-13 13:06 
AnswerRe: The equivalent of 'OninitDlg()' Pin
Richard MacCutchan12-May-13 21:03
mveRichard MacCutchan12-May-13 21:03 
GeneralRe: The equivalent of 'OninitDlg()' Pin
Bram van Kampen13-May-13 14:22
Bram van Kampen13-May-13 14:22 
GeneralRe: The equivalent of 'OninitDlg()' Pin
Richard MacCutchan13-May-13 20:54
mveRichard MacCutchan13-May-13 20:54 

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.