def __init__(self,request_adapter: RequestAdapter, path_parameters: Union[str, dict[str, Any]], q: Optional[str] = None) -> None:
        """
        Instantiates a new SearchWithQRequestBuilder and sets the default values.
        param path_parameters: The raw url or the url-template parameters for the request.
        param q: Usage: q='{q}'
        param request_adapter: The request adapter to use to execute the requests.
        Returns: None
        """
        if isinstance(path_parameters, dict):
            path_parameters['q'] = q
        super().__init__(request_adapter, "{+baseurl}/drives/{drive%2Did}/items/{driveItem%2Did}/search(q='{q}'){?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", path_parameters)

        Instantiates a new SearchWithQRequestBuilder and sets the default values.
        param path_parameters: The raw url or the url-template parameters for the request.
        param q: Usage: q='{q}'
        param request_adapter: The request adapter to use to execute the requests.
        Returns: None
        
msgraph/generated/drives/item/items/item/search_with_q/search_with_q_request_builder.py