CSLA .NET

From Rockford Lhotka's Expert C# 2008 and VB 2008 Business Objects books

BrokenRules DataBinding

rated by 0 users
This post has 2 Replies | 2 Followers

Not Ranked
Posts 6
jokiz Posted: Thu, Jun 22 2006 11:29 PM
i can see that RulesCollection has the ToString() to return string representation of the broken rules newline delimited.  In my opinion, it would be better to also have a public method which return all string representations of the broken rules (as StringCollection perhaps) for better flexibility in displaying them in UI.

Although I can work around since CSLA already exposes the underlying rules with GetRulesCollection(), and one can databind it's Description with a repeater, i'd rather have it encapsulated (it's where csla is good at).  Parsing the newline delimited string to obtain a list/array is somewhat dirty to me...
(x-a)(x-b)(x-c)...(x-z)
Top 10 Contributor
Posts 7,309
Good idea. In version 2.1 I am adding a ToArray() method to the BrokenRulesCollection class, so you can easily get a string array with the descriptions using that method.

Rocky

Not Ranked
Posts 6
jokiz replied on Sun, Jun 25 2006 8:11 AM
RockfordLhotka:
Good idea. In version 2.1 I am adding a ToArray() method to the BrokenRulesCollection class, so you can easily get a string array with the descriptions using that method.

cool, thanks!
(x-a)(x-b)(x-c)...(x-z)
Page 1 of 1 (3 items) | RSS

Please contact Magenic for your .NET consulting
and CSLA .NET mentoring needs.
Please consider making a donation to help support the ongoing development of CSLA .NET.

Make donation through PayPal - it's fast, free and secure!
Why donate?
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