Welcome to mirror list, hosted at ThFree Co, Russian Federation.

externally_paginated_array.rb « graphql « gitlab « lib - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 873d7f4efdfe57e0cb751e1d05d77b9edbf37bb1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# frozen_string_literal: true

module Gitlab
  module Graphql
    class ExternallyPaginatedArray < Array
      attr_reader :start_cursor, :end_cursor

      def initialize(previous_cursor, next_cursor, *args)
        super(args)
        @start_cursor = previous_cursor
        @end_cursor = next_cursor
      end
    end
  end
end