I would suggest downloading the CSLA source code and samples (especially the ProjectTracker sample) and taking a look at the code. The best way to learn something quickly is to build something.
, dataportal.
. CSLA:
[Serializable()]
public class Widget : Csla.BusinessBase<Widget>
{
private Widget()
{
}
}
dataportal , . , , , . factory:
[Serializable()]
public class Widget : Csla.BusinessBase<Widget>
{
private Widget()
{
}
public static Widget Fetch(int id)
{
return Csla.DataPortal.Fetch<Widget>(new Csla.SingleCriteria<Widget, int>(id));
}
}
dataportal, CSLA.
[Serializable()]
public class Widget : Csla.BusinessBase<Widget>
{
private Widget()
{
}
public static Widget Fetch(int id)
{
return Csla.DataPortal.Fetch<Widget>(new Csla.SingleCriteria<Widget, int>(id));
}
private void DataPortal_Fetch(Csla.SingleCriteria<Widget, int> criteria)
{
}
}
, , - .. , /, ..
, .
http://lhotka.net/cslanet/Download.aspx