def list_by_management_group_as_lazy(management_group_id, custom_headers:nil)
      response = list_by_management_group_async(management_group_id, custom_headers:custom_headers).value!
      unless response.nil?
        page = response.body
        page.next_method = Proc.new do |next_page_link|
          list_by_management_group_next_async(next_page_link, custom_headers:custom_headers)
        end
        page
      end
    end
def list_by_management_group_as_lazy(management_group_id, custom_headers:nil)
      response = list_by_management_group_async(management_group_id, custom_headers:custom_headers).value!
      unless response.nil?
        page = response.body
        page.next_method = Proc.new do |next_page_link|
          list_by_management_group_next_async(next_page_link, custom_headers:custom_headers)
        end
        page
      end
    end
Gets all the policy set definitions for a subscription at management group.

 @param management_group_id [String] The ID of the management group.
 @param custom_headers [Hash{String => String}] A hash of custom headers that
 will be added to the HTTP request.

 @return [PolicySetDefinitionListResult] which provide lazy access to pages of
 the response.