msgraph-sdk-javascript
msgraph-sdk-javascript copied to clipboard
Update design for task classes like LargeFileTaskUpload and PageIterator task.
Currently, when creating the LargeFileUpload object or the PageIterator object, we are passing a Client object which is used to make the requests.
The current design creates limitations in customizing the GraphRequest object options.
Example - To pass custom headers in the PageIterator, we pass a requestOptions parameter while creating the PageIterator object.
Another problem I came across was when working on #359. The response format of Outlook and OneDrive are different and I need to customize the ResponseType in the GraphRequest object.
Related to - https://github.com/microsoftgraph/msgraph-sdk-design/issues/37
The design of the task classes should be updated to allow easy customizations and changeability. The relations between the classes can be reengineered. Example - use a behavioral design pattern.
To be considered with #500 and #499
tracked now in sdk design