Skip to content

Commit

Permalink
Apply attribute macro to OffersForAccountRequest
Browse files Browse the repository at this point in the history
  • Loading branch information
kevin-pease authored and tluijken committed Aug 22, 2024
1 parent 8f84ed8 commit a186f6f
Showing 1 changed file with 3 additions and 13 deletions.
16 changes: 3 additions & 13 deletions stellar_rust_sdk/src/offers/offers_for_account_request.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
use crate::models::*;
use stellar_rust_sdk_derive::Pagination;
use crate::Paginatable;
use stellar_rust_sdk_derive::pagination;

/// Represents the ID of an account for which the offers are to be retrieved.
#[derive(Default, Clone)]
Expand All @@ -9,21 +8,12 @@ pub struct OfferAccountId(String);
/// Represents the absence of the ID of an account for which the offers are to be retrieved.
#[derive(Default, Clone)]
pub struct NoOfferAccountId;
#[derive(Default)]

#[derive(Pagination)]
#[pagination]
#[derive(Default)]
pub struct OffersForAccountRequest<I> {
/// The ID of the account for which the offers are to be retrieved.
account_id: I,
/// A pointer to a specific location in a collection of responses, derived from the
/// `paging_token` value of a record. Used for pagination control in the API response.
cursor: Option<u32>,
/// Specifies the maximum number of records to be returned in a single response.
/// The range for this parameter is from 1 to 200. The default value is set to 10.
limit: Option<u8>,
/// Determines the [`Order`] of the records in the response. Valid options are [`Order::Asc`] (ascending)
/// and [`Order::Desc`] (descending). If not specified, it defaults to ascending.
order: Option<Order>,
}

impl OffersForAccountRequest<NoOfferAccountId> {
Expand Down

0 comments on commit a186f6f

Please sign in to comment.