Skip to content

Rust Guidelines: Paging page types should reference the current model/iterator guidance #9951

Description

@azure-sdk-automation

Bad code snippet:

pub struct FeedPage<T> {}

What it should do:
The current Rust guidance is out of date. The feedback in APIView correctly points to the cited paging/model guidelines, but those guidelines no longer reflect the intended shape for Rust paging types in azure_data_cosmos. Please update the official Rust guideline so it clearly describes the current requirements for page types (including azure_core::Model and IntoIterator behavior, if still applicable).

Good code snippet:

pub struct FeedPage<T> {
    // page fields
}

impl<T> azure_core::Model for FeedPage<T> {
    // current expected implementation
}

impl<T> IntoIterator for FeedPage<T> {
    type Item = T;
    type IntoIter = std::vec::IntoIter<T>;

    fn into_iter(self) -> Self::IntoIter {
        // iterate over page items
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    customer-reportedIssues that are reported by GitHub users external to the Azure organization.needs-triageWorkflow: This is a new issue that needs to be triaged to the appropriate team.questionThe issue doesn't require a change to the product in order to be resolved. Most issues start as that

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions