optional/null-able OUT parameter in C# -


i have method has several overrides. in 1 of more expanded overrides, want return out parameter not in simpler overrides. example:

public bool ispossible(string param1, int param2) public bool ispossible(string param1, int param2, out bool param3) 

the way achieving this, so:

public bool ispossible(string param1, int param2) {     bool temp;     return ispossible(param1, param2, out temp); } 

is there better way achieve this? can (or should i) use null-able out parameter?

that looks fine me. out cannot optional technical reasons (it needs point valid instance).


Comments

Popular posts from this blog

c++ - Is it possible to compile a VST on linux? -

c# - SharpSVN - How to get the previous revision? -

php cli reading files and how to fix it? -