This is a migrated thread and some comments may be shown as answers.

ORM With Channel Factory

1 Answer 65 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
G. Deward
Top achievements
Rank 1
G. Deward asked on 13 Jul 2012, 08:09 PM
How can I separate the DTOs/interfaces for individual objects?  Can Telerik ORM create them separately?

I currently use the Channel Factory to create my own proxy without going through SvcUtil or .NET's proxy generator.  This allows me to keep my service interfaces and DTOs in a separate "Contracts" project and only distribute what is absolutely essential to the client application in my nTier product.  Unfortunately, if I want to include ANY of Telerik's DTOs I must either reference the DataService project in my Client project OR pull the Transport.cs file into my "Contracts" project... which means that my entire schema is exposed to anyone with a decompiler.

Please help.

Thanks -
- G. Deward

1 Answer, 1 is accepted

Sort by
0
Serge
Telerik team
answered on 17 Jul 2012, 02:59 PM
Hello Greg, 

 The Add OpenAccess Service wizard is simply a tool for generating a service, should you choose to you can always move the generated DTO classes (or interfaces) in a separate project/assembly. It will be a little troublesome when updating the service using the wizard but is still the way to go. 

There is also something else, once you have a service generated and running, and simply add a reference to that service using the Add Service Reference option in Visual Studio, by default you will have created proxy objects on the client that you will use. There isn't a need to reuse same interfaces or DTOs on the client, given that similar ones will be created for you. So a customer using your application will only be able to decompile the proxy classes that are exposed from your service. 

I hope this is helpful, do let us know if you need something else. 
 
Kind regards,
Serge
the Telerik team
OpenAccess ORM Q2'12 Now Available! Get your hands on all the new stuff.
Tags
General Discussions
Asked by
G. Deward
Top achievements
Rank 1
Answers by
Serge
Telerik team
Share this question
or