-
Notifications
You must be signed in to change notification settings - Fork 23
Update to ODL 9.x preview, .NET 10 support and bump version to 3.x preview1 #59
New issue
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
Changes from all commits
8f58a03
a4e0350
5ef0fa8
722db7f
617bf11
7282684
b25d32e
43762ce
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,15 +1,15 @@ | ||
| <Project> | ||
| <!-- Set the version number: major, minor, build and release (i.e. alpha, beta or blank for RTM)--> | ||
| <PropertyGroup> | ||
| <VersionMajor Condition="'$(VersionMajor)' == ''">2</VersionMajor> | ||
| <VersionMajor Condition="'$(VersionMajor)' == ''">3</VersionMajor> | ||
| <VersionMinor Condition="'$(VersionMinor)' == ''">0</VersionMinor> | ||
| <VersionBuild Condition="'$(VersionBuild)' == ''">0</VersionBuild> | ||
| <VersionRelease Condition="'$(VersionRelease)' == ''"></VersionRelease> | ||
| <VersionRelease Condition="'$(VersionRelease)' == ''">preview.1</VersionRelease> | ||
| </PropertyGroup> | ||
|
|
||
| <!-- For NuGet Package Dependencies --> | ||
| <PropertyGroup> | ||
| <ODataLibPackageDependency>[8.0.0, 9.0.0)</ODataLibPackageDependency> | ||
| <ODataLibPackageDependency>[9.0.0-preview.3, 10.0.0)</ODataLibPackageDependency> | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Curious if this works
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @gathogojr This should work. It ensures the package uses ODL
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I could bump the version in a different PR
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @WanjohiSammy I think the version is fine. What I was curious about is whether the part |
||
| <SystemComponentPackageDependency>[4.6.0,)</SystemComponentPackageDependency> | ||
| </PropertyGroup> | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -11,12 +11,23 @@ namespace Microsoft.OData.ModelBuilder | |
| public static class PrimitivePropertyConfigurationExtensions | ||
| { | ||
| /// <summary> | ||
| /// If this primitive property is <see cref="System.DateTime"/>, this method will make the target | ||
| /// Edm type kind as <see cref="Date"/> | ||
| /// If this primitive property is <see cref="System.DateTime"/> or <see cref="System.DateOnly"/>, this method will make the target | ||
| /// Edm type kind as <see cref="EdmPrimitiveTypeKind.Date"/> | ||
| /// </summary> | ||
| /// <param name="property">Reference to the calling primitive property configuration.</param> | ||
| /// <returns>Returns itself so that multiple calls can be chained.</returns> | ||
| public static PrimitivePropertyConfiguration AsDate(this PrimitivePropertyConfiguration property) | ||
| { | ||
| return property.AsDateOnly(); | ||
| } | ||
|
|
||
| /// <summary> | ||
| /// If this primitive property is <see cref="System.DateTime"/> or <see cref="System.DateOnly"/>, this method will make the target | ||
| /// Edm type kind as <see cref="EdmPrimitiveTypeKind.Date"/> | ||
| /// </summary> | ||
| /// <param name="property">Reference to the calling primitive property configuration.</param> | ||
| /// <returns>Returns itself so that multiple calls can be chained.</returns> | ||
| public static PrimitivePropertyConfiguration AsDateOnly(this PrimitivePropertyConfiguration property) | ||
| { | ||
| if (property == null) | ||
| { | ||
|
|
@@ -35,18 +46,29 @@ public static PrimitivePropertyConfiguration AsDate(this PrimitivePropertyConfig | |
|
|
||
| /// <summary> | ||
| /// If this primitive property is <see cref="System.TimeSpan"/>, this method will make the target | ||
| /// Edm type kind as <see cref="TimeOfDay"/> | ||
| /// Edm type kind as <see cref="EdmPrimitiveTypeKind.TimeOfDay"/> | ||
| /// </summary> | ||
| /// <param name="property">Reference to the calling primitive property configuration.</param> | ||
| /// <returns>Returns itself so that multiple calls can be chained.</returns> | ||
| public static PrimitivePropertyConfiguration AsTimeOfDay(this PrimitivePropertyConfiguration property) | ||
| { | ||
| return property.AsTimeOnly(); | ||
| } | ||
|
|
||
| /// <summary> | ||
| /// If this primitive property is <see cref="System.TimeSpan"/> or <see cref="System.TimeOnly"/>, this method will make the target | ||
| /// Edm type kind as <see cref="EdmPrimitiveTypeKind.TimeOfDay"/> | ||
| /// </summary> | ||
| /// <param name="property">Reference to the calling primitive property configuration.</param> | ||
| /// <returns>Returns itself so that multiple calls can be chained.</returns> | ||
| public static PrimitivePropertyConfiguration AsTimeOnly(this PrimitivePropertyConfiguration property) | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Again, I'm a bit confused here. This method is named
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The The
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @WanjohiSammy Why can't one of Same argument around
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @gathogojr This is updated with this commit b25d32e |
||
| { | ||
| if (property == null) | ||
| { | ||
| throw Error.ArgumentNull("property"); | ||
| } | ||
|
|
||
| if (!TypeHelper.IsTimeSpan(property.RelatedClrType)) | ||
| if (!TypeHelper.IsTimeSpan(property.RelatedClrType) && !TypeHelper.IsTimeOnly(property.RelatedClrType)) | ||
| { | ||
| throw Error.Argument("property", SRResources.MustBeTimeSpanProperty, property.PropertyInfo.Name, | ||
| property.DeclaringType.FullName); | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we should add
dev-3.xrather replacerelease-1.x, just in case one was to create a pull request against therelease-1.xbranchThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is updated through commit 43762ce