-
Notifications
You must be signed in to change notification settings - Fork 351
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
POC for writing instance annotations and odata.count for expanded resource sets #2194
base: release-7.x
Are you sure you want to change the base?
Conversation
this.WriteAnnotationAndCountAtStartExpandedFeedShouldPass(ODataFormat.Json, expectedPayload, EntitySet); | ||
} | ||
|
||
private void WriteAnnotationAndCountAtStartExpandedFeedShouldPass(ODataFormat format, string expectedPayload, IEdmNavigationSource navigationSource) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -92,6 +94,24 @@ public Uri AssociationLinkUrl | |||
} | |||
} | |||
|
|||
/// <summary>Gets or sets the number of items in the resource set.</summary> | |||
/// <returns>The number of items in the resource set.</returns> | |||
public long? Count |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what about if the nested resource info is single?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have added a validation!
This PR has Quantification details
Why proper sizing of changes matters
Optimal pull request sizes drive a better predictable PR flow as they strike a
What can I do to optimize my changes
How to interpret the change counts in git diff output
Was this comment helpful? 👍 :ok_hand: :thumbsdown: (Email) |
@@ -92,6 +97,36 @@ public Uri AssociationLinkUrl | |||
} | |||
} | |||
|
|||
/// <summary>Gets or sets the number of items in the resource set.</summary> | |||
/// <returns>The number of items in the resource set.</returns> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Noet: you don't really need the section for a property -- you cover what it returns in the summary.
@corranrogue9 -- This is a good item to put on the 8.0 list. We don't have a good way to fix this in 7.x without being a breaking change. @KenitoInc has more context, and a design doc that describes the different options. |
Issues
POC for writing instance annotations for expanded resoource sets
Description
In this POC, we are adding 2 properties to the
ODataNestedResourceInfo
public long? Count
public ICollection<ODataInstanceAnnotation> InstanceAnnotations
So we can write the instance annotations and odata.count for an expanded resource set as follows:
Checklist (Uncheck if it is not completed)
Additional work necessary
If documentation update is needed, please add "Docs Needed" label to the issue and provide details about the required document change in the issue.