Closed GoogleCodeExporter closed 9 years ago
Hello,
Could you create a new forum post for this issue and ask this question and see
what the general consensus is.
Thanks
-Blake Niemyjski
Original comment by bniemyjski
on 8 Jun 2010 at 8:31
If CSLA 4.0 business rules memory management is better than the 3.8.2 CSLA
Security approach, then I vote for incorporating the code in the business
rules. See http://forums.lhotka.net/forums/p/9053/43030.aspx#43030, which is
built with Codesmith CSLA templates and highlights some poor memory usage for
security objects.
Original comment by JenasysD...@gmail.com
on 9 Jun 2010 at 11:41
In CSLA 4, the issue isn't that it is a child object so much as the fact that
protected methods aren't serializable in Silverlight. You don't really need the
AddObjectAuthorizationRules in the Silverlight dll of your business objects
because the .NET side calls it as well and the dataportal deals with it
accordingly. It usually doesn't even call the AddObjectAuthorizationRules
except I find in uncommon cases so I see where it could seem that the reason is
because it is a child object. if you just add #if !SILVERLIGHT block around the
AddObjectAuthorizationRules() method you will avoid having to make it public.
UPDATE: that answer may have seemed convoluted, so to sum up once more, you
only want AddObjectAuthorizationRules() method to be in your .NET Business
Object library, not your Silverlight Business Object library, because
AddObjectAuthorizationRules() is not needed on the silverlight side, and as you
can see, it causes an error if it tries to call it due to Silverlight
limitations with serialization.
Original comment by geoff.ma...@gmail.com
on 10 Jun 2010 at 2:24
Original comment by bniemyjski
on 10 Jun 2010 at 2:48
I have updated the templates to wrap the AddObjectAuthorizationRules methods in
#if !SILVERLIGHT compiler directives, if IncludeSilverlightSupport is enabled.
I have attached the updated templates for c#.
Original comment by RoyMunso...@gmail.com
on 17 Jun 2010 at 3:56
Attachments:
Hello,
This has been fixed in revision 1716.
Thanks
-Blake Niemyjski
Original comment by bniemyjski
on 19 Jun 2010 at 8:18
Original comment by bniemyjski
on 21 Jun 2010 at 8:08
Original issue reported on code.google.com by
RoyMunso...@gmail.com
on 4 Jun 2010 at 12:16