Problem with the inerface (Service Class)

Topics: General Discussion Forum, July and December Releases Forum
Apr 10, 2008 at 1:55 PM
Edited Apr 10, 2008 at 1:58 PM
HI,
in the initial stage of my project i created different Interfaces for different OPerations.
like..
Related with all the UserDetails(add,delete,update,delete) i have used one interface class.
so like that i am having 5 interfaces. So if i wanna make all of them undera single shell, that is in this case if i am generating the proxy classes i will get 5 diferent proxy classes. Calling this proxy classes from the client is a teadious job.
for eg: my proxy classes are :-

1) UserClient
2) EmployeeClient
3) HRClient
4) xxxxxx
5) xxxxxxx


so if i am callign this proxy classes from the client side, i have to do like...
UserClient u1=new userClient()
u1.class1();
u1.class2();


like for all the proxy classes we have to give somethign like this, instaed of creating object for every proxy classes i must be able to initialize a single class, and must call all the methods or operations.

Since i am using different proxy classes i know that i have to create an object, and through that object we have to call.

if i wanna something like this.
proxyclient client=new proxyclient(); --------------> this should be a single proxy class which integrates al the operations and Dc

usign this single proxy i must be able to access any operation.

what should i do inoder to perform like this ? This is my requirement..
please someody help me up.......

pls....plss..



Hopefully,
Nimi
Developer
Apr 10, 2008 at 11:32 PM
My suggestion is to have one interface that aggregates the others so you will end up with one proxy class that derives from "ClientBase<IAggregatedInterface>" that will contain all other operations of each interface. Naturally you will also need a service implementation class (and its endpoint) that will implement this interface and works as a stub for the resto of the implementation classes.