from __future__ import annotations
from collections.abc import Callable
from kiota_abstractions.base_request_builder import BaseRequestBuilder
from kiota_abstractions.get_path_parameters import get_path_parameters
from kiota_abstractions.request_adapter import RequestAdapter
from typing import Any, Optional, TYPE_CHECKING, Union

if TYPE_CHECKING:
    from .item.with_diff_item_request_builder import WithDiffItemRequestBuilder

class DiffsRequestBuilder(BaseRequestBuilder):
    """
    Builds and executes requests for operations under /construction/index/v2/projects/{projectId}/diffs
    """
    def __init__(self,request_adapter: RequestAdapter, path_parameters: Union[str, dict[str, Any]]) -> None:
        """
        Instantiates a new DiffsRequestBuilder and sets the default values.
        param path_parameters: The raw url or the url-template parameters for the request.
        param request_adapter: The request adapter to use to execute the requests.
        Returns: None
        """
        super().__init__(request_adapter, "{+baseurl}/construction/index/v2/projects/{projectId}/diffs", path_parameters)
    
    def by_diff_id(self,diff_id: str) -> WithDiffItemRequestBuilder:
        """
        Gets an item from the Autodesk.ACC.construction.index.v2.projects.item.diffs.item collection
        param diff_id: The diff ID.
        Returns: WithDiffItemRequestBuilder
        """
        if diff_id is None:
            raise TypeError("diff_id cannot be null.")
        from .item.with_diff_item_request_builder import WithDiffItemRequestBuilder

        url_tpl_params = get_path_parameters(self.path_parameters)
        url_tpl_params["diffId"] = diff_id
        return WithDiffItemRequestBuilder(self.request_adapter, url_tpl_params)
    

