Class BookmarksRequestBuilder

java.lang.Object
com.microsoft.kiota.BaseRequestBuilder
com.microsoft.graph.search.bookmarks.BookmarksRequestBuilder

@Generated("com.microsoft.kiota") public class BookmarksRequestBuilder extends com.microsoft.kiota.BaseRequestBuilder
Provides operations to manage the bookmarks property of the microsoft.graph.searchEntity entity.
  • Constructor Details

    • BookmarksRequestBuilder

      public BookmarksRequestBuilder(@Nonnull HashMap<String,Object> pathParameters, @Nonnull com.microsoft.kiota.RequestAdapter requestAdapter)
      Instantiates a new BookmarksRequestBuilder and sets the default values.
      Parameters:
      pathParameters - Path parameters for the request
      requestAdapter - The request adapter to use to execute the requests.
    • BookmarksRequestBuilder

      public BookmarksRequestBuilder(@Nonnull String rawUrl, @Nonnull com.microsoft.kiota.RequestAdapter requestAdapter)
      Instantiates a new BookmarksRequestBuilder and sets the default values.
      Parameters:
      rawUrl - The raw URL to use for the request builder.
      requestAdapter - The request adapter to use to execute the requests.
  • Method Details

    • count

      @Nonnull public CountRequestBuilder count()
      Provides operations to count the resources in the collection.
      Returns:
      a CountRequestBuilder
    • byBookmarkId

      @Nonnull public BookmarkItemRequestBuilder byBookmarkId(@Nonnull String bookmarkId)
      Provides operations to manage the bookmarks property of the microsoft.graph.searchEntity entity.
      Parameters:
      bookmarkId - The unique identifier of bookmark
      Returns:
      a BookmarkItemRequestBuilder
    • get

      @Nullable public BookmarkCollectionResponse get()
      Get a list of bookmark objects and their properties.
      Returns:
      a BookmarkCollectionResponse
      Throws:
      ODataError - When receiving a 4XX or 5XX status code
      See Also:
    • get

      @Nullable public BookmarkCollectionResponse get(@Nullable Consumer<BookmarksRequestBuilder.GetRequestConfiguration> requestConfiguration)
      Get a list of bookmark objects and their properties.
      Parameters:
      requestConfiguration - Configuration for the request such as headers, query parameters, and middleware options.
      Returns:
      a BookmarkCollectionResponse
      Throws:
      ODataError - When receiving a 4XX or 5XX status code
      See Also:
    • post

      @Nullable public Bookmark post(@Nonnull Bookmark body)
      Create a new bookmark object.
      Parameters:
      body - The request body
      Returns:
      a Bookmark
      Throws:
      ODataError - When receiving a 4XX or 5XX status code
      See Also:
    • post

      @Nullable public Bookmark post(@Nonnull Bookmark body, @Nullable Consumer<BookmarksRequestBuilder.PostRequestConfiguration> requestConfiguration)
      Create a new bookmark object.
      Parameters:
      body - The request body
      requestConfiguration - Configuration for the request such as headers, query parameters, and middleware options.
      Returns:
      a Bookmark
      Throws:
      ODataError - When receiving a 4XX or 5XX status code
      See Also:
    • toGetRequestInformation

      @Nonnull public com.microsoft.kiota.RequestInformation toGetRequestInformation()
      Get a list of bookmark objects and their properties.
      Returns:
      a RequestInformation
    • toGetRequestInformation

      @Nonnull public com.microsoft.kiota.RequestInformation toGetRequestInformation(@Nullable Consumer<BookmarksRequestBuilder.GetRequestConfiguration> requestConfiguration)
      Get a list of bookmark objects and their properties.
      Parameters:
      requestConfiguration - Configuration for the request such as headers, query parameters, and middleware options.
      Returns:
      a RequestInformation
    • toPostRequestInformation

      @Nonnull public com.microsoft.kiota.RequestInformation toPostRequestInformation(@Nonnull Bookmark body)
      Create a new bookmark object.
      Parameters:
      body - The request body
      Returns:
      a RequestInformation
    • toPostRequestInformation

      @Nonnull public com.microsoft.kiota.RequestInformation toPostRequestInformation(@Nonnull Bookmark body, @Nullable Consumer<BookmarksRequestBuilder.PostRequestConfiguration> requestConfiguration)
      Create a new bookmark object.
      Parameters:
      body - The request body
      requestConfiguration - Configuration for the request such as headers, query parameters, and middleware options.
      Returns:
      a RequestInformation
    • withUrl

      @Nonnull public BookmarksRequestBuilder withUrl(@Nonnull String rawUrl)
      Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored.
      Parameters:
      rawUrl - The raw URL to use for the request builder.
      Returns:
      a BookmarksRequestBuilder