Skip to content

Improve next link paging generation usability #7618

Closed
@JoshLove-msft

Description

@JoshLove-msft

Currently, there is special behavior in the CreateRequest method for next link paging. The first parameter is the nextLink URI, which if null, is expected to mean that this is the initial request. This is brittle, and isn't enforced through public APIs in the generator. We should instead have two separate rest methods for next link operations - the normal CreateXXXRequest methods, and a new CreateNextXXXRequest method. CollectionResultDefinition should be updated to use the CreateXXXRequest method for the initial request and the other for subsequent requests. We should also no longer include the nextLink param in the generated CollectionResult types constructor. We should expose a public method on RestClientProvider, GetCreateNextRequestMethod.

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions