-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change anything requiring additional web requests to be a method instead of a property #40
Comments
properties on objects that are filled at the creation of the object are fine, but otherwise it just looks nicer in the code as a property, but having a method to retrieve it asyncronously if wanted could be done just fine |
I'm leaning towards anything that comes as data with the actual json should be a property. Anything that fires an additional web request should be a method. |
I like that idea. Properties shouldn't be that complex anyway. |
Is this what we've decided on, then? Properties requiring another web call are getting moved to Methods? |
Yes i think that's the best way to handle it
…On Jan 18, 2017 5:14 PM, "Andrew" ***@***.***> wrote:
Is this what we've decided on, then? Properties requiring another web call
are getting moved to Methods?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#40 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHDuEN5m1zcah00y3nS-U7pRDgKqN6UFks5rTpzwgaJpZM4LREtk>
.
|
Historically things have been pulled via Properties on an object like
Subreddit.Moderators
. Changing everything over to async, this doesn't always work the best as it can't actually call an async method in the getter of a property. You can get around this by callingTask.Run()
, but you lose performance benefits from async if I am understanding everything correctly.Thoughts on how this should be designed going forward? 2.0 is going to break enough stuff that we can safely redesign it however we want most likely.
The text was updated successfully, but these errors were encountered: