Commit graph

330 commits

Author SHA1 Message Date
Irvine Sunday da7f51abbf
Resolves response schemas of actions/functions that return collection (#117)
* Update response schema of action/functions that return a collection

* Update Title to use entity type name for the previous segment

* Update test files data appropriately
2021-09-21 12:05:41 +03:00
Irvine Sunday 3cce51566f
Skips generation of action/function paths for non-contained nav. props. (#115)
* Do not create actions/functions for non-containment nav. props

* Add test for Function Operations
2021-09-14 23:23:52 +03:00
Irvine Sunday 611067f2d3
[Enhancement] Creates DELETE operation for collection-valued nav. props $ref paths (#112)
* Generate collection nav. prop. entity paths for non-contained nav. props

* Revert previous changes

* Paths with DELETE operations for collection-valued nav. prop. $ref paths

* Don't create extra path for OData Key segment when creating DELETE for $ref

* Update tests

* Update test files

* Minor update to test commit signing

* Another minor update to trigger commit signing

* Update tests appropriately
2021-08-26 22:25:55 +03:00
Irvine Sunday e6a5e52e11
[Fix] Generate paths for stream properties in base types of entities (#110)
* Get all properties declared in type def. including base types

* Update/refactor tests to validate stream props. of base types are captured

* Refactor Handler class to use encapsulation to define navigation sources
2021-08-18 16:33:26 +03:00
Irvine Sunday e8ecb37c96
Fix: Expand containment navigation properties (#94)
* Expand all containment nav props; retrieve Media Entity paths prior to expanding

* Update path count to account for expanded containment nav. props.

* Remove containment in sample CSDL

Expanding workbook nav. props leads to many paths  since the containment levels go very deep

* Check for navigability of navigation props

* Comment correction

* Fix broken tests

* Check whether navigation is allowed to a navigation property

* Update tests; add tests to validate navigability of navigation properties

* Update test CSDL doc. with sample NavigationRestrictions annotations

* Concise code; move declaration closer to usage

Co-authored-by: Irvine Sunday <irochand@microsoft.com>
2021-07-09 09:55:55 -07:00
Irvine Sunday 72cd85d3ae
Set parameters' explode property to false (#108)
* Set Explode property to false for Style: Form

* Add tests for creating OrderBy, Select, Expand parameters

* Rename test method for clarity

Co-authored-by: Irvine Sunday <irochand@microsoft.com>
2021-07-09 09:55:32 -07:00
Sam Xu 9f55c250a1
Update versioning.props 2021-05-06 09:50:48 -07:00
Irvine Sunday b1fed423ab
Describes path operations descriptions from vocabulary annotations (#104)
* Add support for operation descriptions and update tests

* Update tests for Entityset paths operations descriptions

* Code cleanup

* Update test OpenAPI output files.

Co-authored-by: Irvine Sunday <irochand@microsoft.com>
2021-05-04 17:36:03 -07:00
Irvine Sunday 9d6bdd5ae0 Add async await to make UI more responsive 2021-05-04 17:35:42 -07:00
Jukka Snellman 830eb357c7 add support for EdmTypeKind.TypeDefinition 2021-04-19 09:22:40 -07:00
Sam Xu 5531eb3c3c 1. Update the version to 1.0.7
2. Add PublicApi analyzier
3. Add config for ShowMsDocGroupPath
2021-04-13 10:04:06 -07:00
Irvine Sunday 4c685b568b
Fix: Removes example property in path parameter objects (#92)
* Remove example property in Parameters

This helps in avoiding duplication with examples property. They are mutually exclusive. DocumentationURL prop. which used to be set in example property is now set within descriptions property.

* Update src/Microsoft.OpenApi.OData.Reader/Operation/OperationHandler.cs

Co-authored-by: Charles Wahome <thewahome.cw@gmail.com>

* Remove duplicate variable declaration

* Minor refactoring

To help trigger build

Co-authored-by: Irvine Sunday <irochand@microsoft.com>
Co-authored-by: Charles Wahome <thewahome.cw@gmail.com>
Co-authored-by: Sam Xu <saxu@microsoft.com>
2021-04-09 13:40:52 -07:00
Irvine Sunday 32e673eea0
Fixes potential duplicate operationIds in action/function paths (#98)
* Include EntityType name of ODataKeySegment in Action/Function paths

This helps in preventing potential duplicate operationIds in entity vs entityset functions/actions

* Update tests to validate action/function duplicate operationId fix

* Update test files' action/function operationIds

* Redesign how we retrieve the segment identifiers

* Update test files in line with new segment retrieval redesign

Co-authored-by: Irvine Sunday <irochand@microsoft.com>
2021-04-09 13:38:59 -07:00
Sam Xu b4d3ae36af Add key and operation (function) parameter mapping 2021-02-10 17:45:14 -08:00
Sam Xu 05e10c94eb update the version to 1.0.6 2021-02-10 16:09:55 -08:00
Sam Xu aa5b0f0bc7 Add Metadata, segment and related path handler and operation handler, expand ODataPath to accept PathTemplate 2021-02-10 16:08:27 -08:00
Gareth Jones e1763727f5 Fix paths when operation is bound to a type derived from the type of a
navigation property. (#88)
2021-02-10 16:07:31 -08:00
Sam Xu 1643ba5ea1 Add Path provider and path prefix provider into setting 2021-02-08 19:57:15 -08:00
Sam Xu 5a83e6b553 update the version to 1.0.5 2021-02-05 18:00:19 -08:00
Sam Xu f98b9ce40d update the docs 2021-02-05 17:56:46 -08:00
Sam Xu dfbf083d53 Push changes from microsoft graph (#86) 2021-02-05 17:42:10 -08:00
Gareth Jones c1aa5a6f94
Add model reference support to library and command line utility. (#81)
* Support many conversion options in the command-line tool.
Support local reference files in file-based csdl in the library and command-line tool.

* Added tests for references.

* Updates from github review.
2021-01-14 16:56:26 -08:00
edevoogd f6f26df6f2
Fix casing of OpenAPI type "String" for RefPatchOperationHandler and RefPostOperationHandler (#78)
* Fix casing from "String" to "string"

* Fix tests resources

Co-authored-by: Sam Xu <saxu@microsoft.com>
2020-11-30 17:08:41 -08:00
Sam Xu f08180c648
Update to version 1.0.4 2020-07-21 12:44:10 -07:00
Irvine Sunday 00ed4207fe
Allows schema examples to be optional (#73)
* Adds Links to EntitySet type response objects

* Adds links to the test OpenAPI docs.

* Refactor to use Utils class for nullability checks

* Modify link generator to handle all instances of IEdmEntityType

* Update arguments

* Add new Link properties

* Update test files with links properties

* Rename parameter

* Fix OpenAPI Link generation

* Reorder Parameters generation before Responses

This is important so that the parameters info can be used for Links generation

* Update test files to validate Link fixes

* Fix links and add optional setting

* Update test for Links

* Revert project PlatformTarget

* Add comment

* Add setting for enabling/disabling showing of schema examples

* Add setting to show schema examples to allow tests to pass

* Update test doc. to test disabling of showing of schema examples

* Refactor to remove unnecessary Link creation of collection of entities

* Revert platform target to default - AnyCPU

* Add helpful comment

* Grammar nit fix

Co-authored-by: Irvine Sunday <v-irsund@microsoft.com>
Co-authored-by: Irvine Sunday <irochand@microsoft.com>
2020-07-21 10:54:50 -04:00
Irvine Sunday 9d44019639
Fixes OpenAPI Links and makes them optional (#72)
* Adds Links to EntitySet type response objects

* Adds links to the test OpenAPI docs.

* Refactor to use Utils class for nullability checks

* Modify link generator to handle all instances of IEdmEntityType

* Update arguments

* Add new Link properties

* Update test files with links properties

* Rename parameter

* Fix OpenAPI Link generation

* Reorder Parameters generation before Responses

This is important so that the parameters info can be used for Links generation

* Update test files to validate Link fixes

* Fix links and add optional setting

* Update test for Links

* Revert project PlatformTarget

* Add comment

* Refactor to remove unnecessary Link creation of collection of entities

* Revert platform target to default - AnyCPU

* Add helpful comment

* Grammar nit fix

Co-authored-by: Irvine Sunday <v-irsund@microsoft.com>
Co-authored-by: Irvine Sunday <irochand@microsoft.com>
2020-07-20 09:54:58 -04:00
Sam Xu c58a6136f3
Update version to 1.0.3 2020-06-04 14:37:41 -07:00
Sam Xu e0135613d6 output the xml file, add into nuget package, fix the build warning 2020-06-04 11:13:38 -07:00
Sam Xu ff057525da
Update versioning.props 2020-05-25 12:02:01 -07:00
Sam Xu a7ee00dbf4 Add Delete to containment navigation property and for non-containment navigation property 2020-05-21 10:58:43 -07:00
Sam Xu 8e7d94dcba
Update azure-pipelines_nightly.yml 2020-05-20 15:31:52 -07:00
Sam Xu 0b2f951f49
Update azure-pipelines_rolling.yml 2020-05-20 15:26:15 -07:00
Gareth Jones 1270385b8d Added simple PathPrefix to ConvertSettings to match ODataRoute prefix without affecting 'servers' declaration in OAS file. 2020-05-12 23:34:24 -07:00
Irvine Sunday a9278f0e29
Adds Links to EntitySet type Get response objects (#57)
* Adds Links to EntitySet type response objects

* Adds links to the test OpenAPI docs.

* Refactor to use Utils class for nullability checks

* Modify link generator to handle all instances of IEdmEntityType

* Update arguments

* Add new Link properties

* Update test files with links properties

* Rename parameter

Co-authored-by: Irvine Sunday <v-irsund@microsoft.com>
2020-04-15 12:46:28 -07:00
Irvine Sunday 3a00f2a540 Adds support for replacing base type references with their derived types #55 2020-04-02 19:47:28 -07:00
Sam Xu 112c566aee Update azure-pipelines_nightly.yml for Azure Pipelines 2020-03-30 09:36:54 -07:00
Sam Xu f75bbb0e9d add the azure pipelines nightly 2020-03-30 09:33:44 -07:00
Sam Xu cedcc7de94
Update README.md 2020-03-29 21:46:40 -07:00
Sam Xu ceb6ff1699 add azure pipeline rolling yml 2020-03-29 21:29:12 -07:00
Sam Xu 90f5f8c4b5 Fix the failing test cases 2020-03-29 20:24:38 -07:00
Sam Xu f07876624b Fix the failing test cases 2020-03-29 15:52:16 -07:00
Joe Glombek db8bff25c6 Change all query parameters from "simple" to "form"
"simple" is not supported in query parameters for OpenAPI v3. https://swagger.io/docs/specification/describing-parameters/
2020-03-29 12:54:33 -07:00
Irvine Sunday f723b671d8
Adds discriminator support to OpenApi (#54)
* Adding setting for discriminator value support

* Adding the discriminator value constant

* Adding discriminator support during schema generation

Co-authored-by: Irvine Sunday <v-irsund@microsoft.com>
2020-03-25 09:50:00 -07:00
Darrel 2755da6a59
Merge pull request #52 from irvinesunday/master
Adds support for paging through entities collection
2020-03-24 09:19:26 -04:00
Irvine Sunday af05aa66bb Refactoring code to pick the configurable pageable operation name 2020-03-23 20:27:51 +03:00
Irvine Sunday a9aac32b4b Adding config setting for the pageable operation name 2020-03-23 20:26:22 +03:00
Irvine Sunday dd11818c1b Documentation text update 2020-03-23 20:25:57 +03:00
Irvine Sunday 5ab49e14e3 Code refactoring to conditionally set pagination 2020-03-23 19:53:01 +03:00
Irvine Sunday 148a1df873 Adding pagination config settings 2020-03-23 19:51:31 +03:00
Irvine Sunday b7a3ab76f1 Removing unnecessary using directive 2020-03-19 11:16:13 +03:00