[]
        
(Showing Draft Content)

C1.LiveLinq.LiveViewExtensions.AsUpdatable

AsUpdatable Method

AsUpdatable<T>(View<T>)

Specifies a view as updatable.

Declaration
public static View<T> AsUpdatable<T>(this View<T> view)
Parameters
Type Name Description
View<T> view

The view to specify as updatable.

Returns
Type Description
View<T>

The same view.

Type Parameters
Name Description
T

The type of the elements in the view.

Remarks

This method is used with Join operation to specify which of the two parts of the join you want to be updatable.

Properties exposed by a view can be updatable or read-only. Updatable properties of a view can be modified directly in the view. Read-only properties of a view cannot be modified directly in the view, but they still reflect up-to-date values of the source, so the difference is often not critical, you can always modify corresponding property in the source, that will automatically change the property in the view.

Only one of the two arguments of a Join can be updatable, the one you qualified with AsUpdatable(). In absence of this qualification, both parts of the join are read-only. For example, in

from c in customers.AsLive()
join o in orders.AsLive().AsUpdatable() on o.CustomerID equals c.CustomerID
select new { c.CustomerName, o.OrderDate, o.OrderAmount }
CustomerName is read-only, and OrderDate and OrderAmount are updatable.
See Also