CSLA .NET

Vibrant discussion about CSLA .NET and using the framework to build great business applications.

CSLA4.1: SaveAsync is not marked as virtual

rated by 0 users
Not Answered This post has 0 verified answers | 1 Reply | 2 Followers

Top 500 Contributor
15 Posts
chrduf posted on Fri, Jun 29 2012 2:15 PM

Can you make the "public async System.Threading.Tasks.Task<T> SaveAsync()" a virtual function?

All Replies

Top 10 Contributor
9,270 Posts

I will look at that.

I have been looking through some of the things we've made virtual, and not all are correct.

For example, some of the Save overloads ultimately call Save(bool). We've made several virtual, which means you can't tell which one to override to _really_ override the behavior in all cases. In reality, there's exactly one Save you need to override to globally change the desired behavior, and overriding the others is almost certainly bug-prone...

It is possible SaveAsync is a complete copy of Save, but I hope not - I need to look at the code to be sure.

Rocky

Page 1 of 1 (2 items) | RSS

Copyright (c) 2006-2010 Marimer LLC. All rights reserved.
Email admin@lhotka.net for support.
Powered by Community Server (Non-Commercial Edition), by Telligent Systems