We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Goal: provide syntax examples for the Jetson service below:
This is the service to model: https://gist.github.com/wtrocki/0493510a85d1b65d12f3bfaf48d5629c
{ "$Version": "4.0", "Jetsons.Models": { "company": { "$Kind": "EntityType", "$Key": [ "stockSymbol" ], "stockSymbol": {}, "name": { "$Nullable": true }, "incorporated": { "$Type": "Edm.DateTimeOffset", "$Precision": 0 }, "employees": { "$Kind": "NavigationProperty", "$Collection": true, "$Type": "Jetsons.Models.employee", "$ContainsTarget": true } }, "employee": { "$Kind": "EntityType", "$Key": [ "id" ], "id": { "$Type": "Edm.Int32" }, "firstName": { "$Nullable": true }, "lastName": { "$Nullable": true }, "title": { "$Nullable": true } }, "youreFired": [ { "$Kind": "Action", "$IsBound": true, "$Parameter": [ { "$Name": "employee", "$Type": "Jetsons.Models.employee", "$Nullable": true }, { "$Name": "reason", "$Unicode": false } ] } ], "topEmployees": [ { "$Kind": "Function", "$IsBound": true, "$Parameter": [ { "$Name": "company", "$Type": "Jetsons.Models.company", "$Nullable": true }, { "$Name": "num", "$Type": "Edm.Int32" } ], "$ReturnType": { "$Collection": true, "$Type": "Jetsons.Models.employee" } } ], "Container": { "$Kind": "EntityContainer", "competitors": { "$Collection": true, "$Type": "Jetsons.Models.company" }, "company": { "$Type": "Jetsons.Models.company" } } }, "$EntityContainer": "Jetsons.Models.Container" }
<edmx:Edmx xmlns:edmx="http://docs.oasis-open.org/odata/ns/edmx" Version="4.0"> <edmx:DataServices> <Schema xmlns="http://docs.oasis-open.org/odata/ns/edm" Namespace="Jetsons.Models"> <EntityType Name="company"> <Key> <PropertyRef Name="stockSymbol" /> </Key> <Property Name="stockSymbol" Type="Edm.String" Nullable="false" /> <Property Name="name" Type="Edm.String" /> <Property Name="incorporated" Type="Edm.DateTimeOffset" Nullable="false" /> <NavigationProperty Name="employees" Type="Collection(Jetsons.Models.employee)" ContainsTarget="true" /> </EntityType> <EntityType Name="employee"> <Key> <PropertyRef Name="id" /> </Key> <Property Name="id" Type="Edm.Int32" Nullable="false" /> <Property Name="firstName" Type="Edm.String" /> <Property Name="lastName" Type="Edm.String" /> <Property Name="title" Type="Edm.String" /> </EntityType> <Action Name="youreFired" IsBound="true"> <Parameter Name="employee" Type="Jetsons.Models.employee" /> <Parameter Name="reason" Type="Edm.String" Nullable="false" Unicode="false" /> </Action> <Function Name="topEmployees" IsBound="true"> <Parameter Name="company" Type="Jetsons.Models.company" /> <Parameter Name="num" Type="Edm.Int32" Nullable="false" /> <ReturnType Type="Collection(Jetsons.Models.employee)" /> </Function> <EntityContainer Name="Container"> <EntitySet Name="competitors" EntityType="Jetsons.Models.company" /> <Singleton Name="company" Type="Jetsons.Models.company" /> </EntityContainer> </Schema> </edmx:DataServices> </edmx:Edmx>
The text was updated successfully, but these errors were encountered:
Here's how it would look like in GraphQL-based RSDL. We probably would shorten @RapidX to just @X.
@RapidX
@X
Note that @RapidAction on a query field is totally counter to GraphQL's strict separation of queries and mutations.
@RapidAction
type company { stockSymbol: String! @RapidID name: String incorporated: DateTimeOffset! employees: [employee] topEmployees(num: Int32): [employee] } type employee { id: Int32! @RapidID firstName: String lastName: String title: String youreFired(reason: String) @RapidAction } type Query { company: company competitors: [company] } type Mutation { company: company @RapidUpdate competitors: company @RapidCreate @RapidUpdate @RapidDelete }
Sorry, something went wrong.
Decision: use custom DSL prototyped by @chrisspre, see #91
ralfhandl
chrisspre
No branches or pull requests
Goal: provide syntax examples for the Jetson service below:
This is the service to model:
https://gist.github.com/wtrocki/0493510a85d1b65d12f3bfaf48d5629c
The text was updated successfully, but these errors were encountered: