Coming in May: Improved IDE support for DA LINQ

Another area that will see a big focus in the upcoming Summer releases of Data Abstract is ease of use for DA LINQ.

DA LINQ is an awesome technology, but currently has a bit of a learning curve because the Visual Studio IDE doesn’t expose it as well as it could. For 5.0.39, this will change.

One challenge when working with DA LINQ is creating (and updating) the source files that contains the stronly-typed classes that represent your schema. Right now, you need to locate your LinqRmeoteDataAdapter component, right-click and choose “Create DA LINQ Classes”, possibly locate your .daSchema file, and pick a destination file. That’s a lot of clicks.

In .39, we’ll be exposing several IDE features that will make this much easier. One of them that i just finished implementing last night, is a so called “Custom Tool” that can handle generating and updating this code automatically. “Custom Tools” are a generic VS feature that allow source files to generated from other files in the project. One prominent custom tool that comes with Visual Studio is the tool that generates .Designer.pas files for your XSD files, when using traditional DataSet data access model.

DA LINQ now has its own custom tool that can be attached to .daSchema files (simply put “SchemaDALinqGenerator” into the Custom Tool field of the files property inspector), and a corresponding source file will be generated and maintained, automatically:

In the example below, we see the DA Server that drives our website – yes, our entire remobjects.com website is DA LINQ driven – and nested below the ROWebsite4Database-ServerService.daSchema schema file, you can see the .pas file containing all the LINQ classes for this schema:

In addition to the custom tool – which of course depends on the schema being part of the project – there will also be options in the menu and in Solution Explorer to import and update DA LINQ classes from external schemas, for use in client-only solutions that do not include the schema.

These new features will be in the next beta drop of Data Abstract for .NET, and ship in May.

by marc hoffman, April 14th, 2009

6 Responses to “Coming in May: Improved IDE support for DA LINQ”

  1. Thank you marc, I’m really excited about this tool. I hope you don’t mind, but I have few questions.

    1. Will this work with Silverlight applications? Currently I have to create a seperate WinForms app to use the linqRemoteDataAdapter to utilize the “Create DA LINQ Classes for Local Schema File…” option.

    2. The Table Definitions that are created, will they be Silverlight compatible? I have to go and heavily modify the TableDefinitions.cs that is generated and remove all references to ICloneable as well as a few other references.

    Hopefully I’m not misunderstanding the purpose of this tool and how it could possibly relate to question one and two.

    3. Last but not least I have a issue registered as #6464 which has to deal with DataAbstract for Delphi server. It has problems with processing DynamicWhere that holds ParameterExpression. This came about when using DA Linq within Silverlight with a DA Delphi Server. I was curious if this will be fixed in the next release.

    Regards,

    Jeremy Brown

  2. marc hoffman [Member] says:

    Jeremy,

    Yes, this will work with Silverlight, as well (matter of fact, that was one of the things that prompted that we needed better tooling there). We’ll also look at getting the DA LINQ code Silverlight-compatible from the get-go, yes. #6464 is fixed as far as i can see in our issue tracking, so it should ship in the next beta and in the May release.

    yours,
    marc

  3. marc hoffman [Member] says:

    Jeremy: quick update: there will be an additional SchemaDALinqGeneratorForSilverlight custom tool that can be used to generate SL-compatible code. There’ll also be an option in the dialog, when you go thru the LinqRemoteDataAdapter UI to generate code.

    Note that the Silverlight code will of course be upwards compatible to be used on the desktop version – it just misses IPropertyChanging and IClonable (which don’t exist in Silverlight 2.0). If you don’t need those, the same set of DA LINQ classes can be used on Silverlight and desktop.

  4. Thank you marc, I’ll be patiently waiting for the next beta.
    <1 minute passes by, 2 minutes, 3 minutes>
    Okay, time to wear out the refresh button on the beta page! Okay, so maybe not that patiently :)

    Regards,
    Jeremy

  5. Hi marc,

    I soooo glad to see this, in addition I’m really excited about the emphasis on SL, will the new tool also create the DomainContext stuff that was introduced in SL3? this would be way too cool as in SL3 things have been enhanced dramatically for LOB applications and would really like to see DA fully take advantage of these new stuff.

    Just a question, would the source for this tool be avail? if so even if the enhancements are not made now it would still allow us to do it on our own.

    Regards,
    Shloma

  6. marc hoffman [Member] says:

    Shloma, we’ll need to see how to best support SL3 without breaking compatibility for those still using SL2 – after all 3.0 is still in beta.

    We don;t current;y ship the source for the tools and IDE integration, but i guess we could make this part available, say on code.remobjects.col. i’ll see what i can do.

    yours,
    marc

Leave a Reply