locked
Interfaces in framework RRS feed

  • General discussion

  •  

    I'm a relative newcomer to the Sync Framework, so please excuse me if this is a dumb question.

     

    I was surprised to find that the classes in the framework library don't seem to define and/or use interfaces, rather just base classes. I was interested in creating some unit tests for my sync code, and wanted to isolate the agent, client and server providers for testing. I think this would be a lot easier if they used interfaces, rather than base class references.

     

    Has any thought been given to adding/using these?

     

    I'd be interested to find out what prompted the current design decision - especially when other frameworks (ASP.NET MVC comes to mind) seem to be embracing this approach.

     

    -david

     

     

    • Moved by Max Wang_1983 Thursday, April 21, 2011 10:03 PM forum consolidation (From:SyncFx - Technical Discussion [ReadOnly])
    Saturday, June 28, 2008 12:32 PM

All replies

  •  

    Programming with interfaces is a dual edged sword. The idea behind using interfaces is that you can change the implementation without affecting clients who consume the interface. However using an interface adds overhead as it pertains to discovering the specific instance at runtime. In scenarios where performance is critical this additional overhead should not treated casually.

     

    Thanks

    Raman

    Wednesday, July 2, 2008 12:56 AM