Constructing an independent ReadOnlyBase #2416
Unanswered
michaelcsikos
asked this question in
Questions
Replies: 1 comment 7 replies
-
I don't understand the scenario? You just want to create a readonly object without talking to the server? That's easily done by using [Fetch]
[RunLocal]
private void Fetch(...)
{
} Then var obj = await DataPortal.FetchAsync<...>(); |
Beta Was this translation helpful? Give feedback.
7 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
As we generally need to construct objects via the
DataPortal
rather than constructors, for aReadOnlyBase
which is independent and not part of aReadOnlyBindingListBase
whichDataPortal
method is the most appropriate?DataPortal.FetchChild<T>(...)
is convenient because it acceptsparams
thus being the most similar to a simple constructor with multiple parameters. Is this OK? Is there anything particularly special aboutFetchChild
for read-only objects?Beta Was this translation helpful? Give feedback.
All reactions