[dba-VB] C#: Did you know - private fields ...

Gustav Brock gustav at cactus.dk
Sun Jun 24 11:37:37 CDT 2012


Hi Shamil

That would be nice. No hurry though, and I don't know how likely it would be for me to use an Access backend only * SQL Server of some sort would be first choice.

/gustav


>>> Salakhetdinov Shamil <mcp2004 at mail.ru> 24-06-12 17:49 >>>
Hi Gustav --

Yes, it's interesting code reading/reviewing, and even more interesting/useful *isto debug/trace it using many provided samples/testing methods, although its latest version is converted to VS2012 and it does use MS testing framework.
So I have had to downgrade it to VS2010 (removing some C# 5.0 async features) and to edit to make it using NUnit Framework. 
I have also got selected only the sources related to the MS Access backend.
And it can be now unit-tested/debugged/traced under VS2010 + NUnit Framework 2.5.10.
I can send the result "derivative" work off-line to the interested Access-D/dba-VB devs - and we may try to "code review" it here from time to time, and to exchange opinions...*
I suppose such a "derivative work" lays within MS-PL?

http://www.opensource.org/licenses/MS-PL

Thank you.

-- Shamil


Sun, 24 Jun 2012 14:45:23 +0200 от "Gustav Brock" <gustav at cactus.dk>:
 
  
  
Hi Shamil

Thanks for this pointer. I noticed the blog which explains and documents it in full:

LINQ: Building an IQueryable provider series
http://blogs.msdn.com/mattwar/pages/linq-links.aspx

Will have to study this a quiet(!?) day.

/gustav


>>> Salakhetdinov Shamil <mcp2004 at mail.ru> 24-06-12 13:35 >>>
Hi Gustav --

I have also never attempted to do so (refer private fields/properties of another instance of the same class) - the subject coding technique is coming from here:

http://iqtoolkit.codeplex.com/SourceControl/changeset/view/89802#2219382

It's in CompundKey.cs - CompoundKey class.

It's also interesting to note that this class has one public constructor with param array 

public CompoundKey(params object[] values)

and this constructor is also called when CompoundKey class is instantiated this way:

CompoundKey key = new CompoundKey()*

with paramarray object array initialized to an empty but not null array.*

Thank you.

-- Shamil


Sun, 24 Jun 2012 11:09:02 +0200 от "Gustav Brock" <gustav at cactus.dk>:
*
**
**
Hi Shamil

No I didn't. On the other hand, I've never attempted to do so. As you and most others, I use naming conventions to separate local variables and fields from public.

/gustav




More information about the dba-VB mailing list