-
Notifications
You must be signed in to change notification settings - Fork 393
Deprecate more usage of QuantityType #1019
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
d66bed2
21e2e2d
2dd8544
6ada751
219dbf4
ad38f66
be6da6e
156a10e
325cdaa
4a224d4
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,4 +1,4 @@ | ||
// Licensed under MIT No Attribution, see LICENSE file at the root. | ||
// Licensed under MIT No Attribution, see LICENSE file at the root. | ||
// Copyright 2013 Andreas Gullberg Larsen ([email protected]). Maintained at https://github.com/angularsen/UnitsNet. | ||
|
||
using System; | ||
|
@@ -194,6 +194,7 @@ private void GenerateStaticProperties() | |
/// <summary> | ||
/// The <see cref=""QuantityType"" /> of this quantity. | ||
/// </summary> | ||
[Obsolete(""QuantityType will be removed in the future. Use the Info property instead."")] | ||
public static QuantityType QuantityType {{ get; }} = QuantityType.{_quantity.Name}; | ||
|
||
/// <summary> | ||
|
@@ -235,6 +236,7 @@ private void GenerateProperties() | |
/// <summary> | ||
/// The <see cref=""QuantityType"" /> of this quantity. | ||
/// </summary> | ||
[Obsolete(""QuantityType will be removed in the future. Use the Info property instead."")] | ||
public QuantityType Type => {_quantity.Name}.QuantityType; | ||
|
||
/// <summary> | ||
|
@@ -585,7 +587,7 @@ public bool Equals({_quantity.Name} other, double tolerance, ComparisonType comp | |
/// <returns>A hash code for the current {_quantity.Name}.</returns> | ||
public override int GetHashCode() | ||
{{ | ||
return new {{ QuantityType, Value, Unit }}.GetHashCode(); | ||
return new {{ Info.Name, Value, Unit }}.GetHashCode(); | ||
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. Matching implementation to main library |
||
}} | ||
|
||
#endregion | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
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.
This was no longer used anywhere