Rockford Lhotka
    CTO at Magenic
    Author, speaker, software architect
    Creator of the CSLA .NET framework

Home
Blog
CSLA .NET
Magenic
Speaking
Publications
About me
Contact me

Login

Version 2.0.1 Change Log

 

This document is the change log for version 2.0.1 of CSLA .NET.

 

Csla – CslaDataSource control

  • Major change to the way the business object’s metadata is loaded. It is now loaded using a temporary AppDomain so it is possible to refresh the metadata without restarting the IDE. At the moment the solution is a bit of a hack, and while it appears to work, I would like to find a better solution.

 

CSLA .NET Base classes (all six)

  • Add Initialize() method to all base classes (protected, virtual). This method is called before anything else (like AddBusinessRules()) and is intended to support code generators that choose to use a partial class scheme. This method allows the generated code to set up event handlers so the user code can add business and authorization rules during the object's initialization phase.

 

Csla\Core\IEditableBusinessObject

  • New interface added to support polymorphic child objects in BusinessListBase-derived collections.

 

Csla\Core\BusinessBase

  • Implements IEditableBusinessObject.

 

Csla\BusinessBase & Csla\ReadOnlyBase

  • Changed the Equals() implementation to avoid a possible null reference exception.

 

Csla\BusinessListBase

  • Added a Protected property to return the EditLevel value of the collection to match the same property in BusinessBase. This property makes it easier to implement some lazy loading scenarios.
  • Restrict generic parameter C to IEditableBusinessObject instead of Core.BusinessBase.

 

Csla\NameValueListBase & Csla\ReadOnlyListBase

  • [C# only] The OnDataPortalInvoke() method name had a typo which has now been fixed.

 

Csla\DataPortal\ApplicationContext

  • The ClientContext value is now stored in the current AppDomain when on a Windows client. There is no change to how it is stored in IIS, or in COM+.
  • The ClientContext property is now threadsafe (which means that GetClientContex() and SetClientContext() are also threadsafe). However, if you do use ClientContext from a multithreaded client application, it is up to you to use the SyncRoot property on the collection itself to ensure thread safety – all I have done is to make the access to the collection through ApplicationContext become safe.

 

Csla\Web\CslaDataSourceView

  • TotalRowCount was not being handled properly. It is now returned through the args parameter rather than as a result of the select call.

 

Csla\Utilities

  • Fix bug with how Nullable(Of T) types are handled.
  • Improve how the underlying type behind a Nullable<T> type is determined.
  • Change the scope of the class to public so its methods can be used by business code. This is particularly important for C#, as Utilities includes the IsNumeric() and CallByName() methods, which are very useful in implementing validation rule methods.

 

Csla\Data\DataMapper

  • Add support for coercing enumerated value types, where if the property is an enumerated type and the inbound value is a string the Map() method will call System.Enum.Parse().
  • Renamed SetValue() to SetPropertyValue() and changed the SetPropertyValue() method’s scope to Public to allow for easier testing, and for possible other uses.

 

Csla\DataPortal\Client\RemotingProxy

  • Add support for an a CslaAlwaysImpersonate configuration setting, so if this setting is set to true in appSettings:
    <add key="CslaAlwaysImpersonate" value="true" />
    then the Remoting proxy will always pass the client-side Windows credentials to the server, even if the data portal is configured to use custom authentication.

 

Csla\DataPortal\MethodCaller

  • Fix bug with how GetMethod() finds overloaded methods – specifically how it was unable to find overloads in an abstract, generic base class.

 

Csla\Validation\CommonRules

  • [VB only] Fix StringMaxLength rule implementation to match C# implementation so it can handle Nothing values – which are possible from ASP.NET data binding.
  • Enhance MinValue() and MaxValue() rules to work with any IComparable type.
  • Change the regex for email validation to support lower-case email names and to avoid false positives of addresses containing spaces.

 

Csla\Windows\ReadWriteAuthorization

  • Removed unneeded propertyName parameter from ApplyReadRules() and ApplyWriteRules() methods

 

Csla\SortedBindingList

  • [C# only] Fixed bug with a null reference check.

 

Csla\SmartDate

  • [C# only] Fixed bug with the <= operator.

 

Csla\Core\UndoableBase

  • [C# only] AcceptChanges() was missing a check to make sure that the field's DeclaringType matches the currentType. This check was in CopyState() and UndoChanges() and has now been added to AcceptChanges() as well.
  • Enhance CopyState() and UndoChanges() to better support lazy loading of child objects by properly restoring null/Nothing values in UndoChanges(). This means that if CopyState() is called when a child field is null, then a child object is loaded and then UndoChanges() is called, the field will be restored to null.

 

Csla\Snippets

  • Updated property generation to mark the properties with a compiler directive to prevent inlining – thus ensuring that PropertyHasChanged(), CanReadProperty() and CanWriteProperty() work in release mode.
  • Fixed name of AddValidationRules() to AddBusinessRules().

 

ProjectTracker

  • Updated properties in the business classes to mark the properties with a compiler directive to prevent inlining – thus ensuring that PropertyHasChanged(), CanReadProperty() and CanWriteProperty() work in release mode.
  • [C# only] Fixed an e.Keys parameter from “id” to “Id” in ProjectEdit.aspx.
  • Fixed how the child BindingSource object is reset when re-binding the data to a Windows Form in ProjectEdit and ResourceEdit.
 

(Updated 5/26/2006)