Conversation
Hi @terrajobst, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution! The agreement was validated by .NET Foundation and real humans are currently evaluating your PR. TTYL, DNFBOT; |
* [Introducing .NET Standard][netstandard-post] blog post | ||
* [Intro to .NET Standard](https://channel9.msdn.com/Blogs/Seth-Juarez/What-is-NET-Standard) video | ||
* [Q&A](https://channel9.msdn.com/Shows/On-NET/Immo-Landwerth-Net-Standard) video | ||
|
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.
should we link to the docs too?
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.
No idea why this didn't occur to me. Fixed.
## Is the API set of a .NET Standard version fixed? | ||
|
||
Yes. A specific version of .NET Standard remains frozen once shipped. New APIs | ||
will first become availabe in specific .NET platforms, such as .NET Core. If we |
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.
typo: availabe
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.
Fixed
The primary reason we expose this type in .NET Standard is because the usage is | ||
fairly high and typically not associated with creating new app domains but for | ||
interacting with the current app domain, such as registering an unhandled | ||
exception handla or asking for the application's base directory. |
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.
typo: handla
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.
I swear I know how handler is being spelled 😄 . Fixed.
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.
Or maybe you're becoming a gansta 😄
## Is `System.Data` part of .NET Standard? | ||
|
||
.NET Standard will contain the abstractions (`DbProvider`, | ||
`DbProviderFactories`, `DbConnection`, `IDbConnection` etc) as well as the the |
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.
the the
APIs will not be supported everywhere and throw `PlatformNotSupportedException`. | ||
While that isn't ideal, it's much simpler than the alternatives, which are: | ||
|
||
* Using `#if`, i.e. cross-compile |
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.
i.e. : Don't use. Use that is instead. (MSFT style guide) although I'm not completely sure this would be the right meaning here
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.
Fixed
|
||
There is nothing language specific about .NET Standard. From a language view | ||
point, the only tie-in to .NET Standard are the language-specific runtime APIs | ||
(e.g. `Mirosoft.CSharp`, `Microsoft.VisualBasic`, `FSharp.Core` etc) and the |
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.
e.g. : Don't use. Use for example instead. (MSFT style guide)
nit: etc -> , etc.
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.
Both fixed throughout
|
||
## How do I know which .NET Standard version I should target? | ||
|
||
When choosing a .NET Standard version you should consider this trade-off: |
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.
nit: missing comma after version
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.
Fixed
|
||
So generally speaking, you should target the lowest version you get away with. | ||
To inform your decision, you should consider the compatibility matrix and the | ||
APIs additions linked fromt the table above. |
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.
typo: fromt
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.
Fixed
changes between versions. | ||
2. **Immutable**. Once shipped, .NET Standard versions are frozen. | ||
|
||
New APIs will first become availabe in specific .NET platforms, such as .NET |
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.
typo: availabe
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.
Fixed
To inform your decision, you should consider the compatibility matrix and the | ||
APIs additions linked fromt the table above. | ||
|
||
# Versining rules |
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.
typo: Versining
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.
Fixed
|
||
## Why is JSON.NET not part of .NET Standard? | ||
|
||
Today, the best library for dealing with JSON is JSON.NET. But by adding it to |
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.
"The best" is debatable as many people prefer other libraries like ServiceStack.Text, Jil, SimpleJson for various reasons and whether it's the best or not is irrelevant for the argument you're trying to make in this section.
"One of the best" or "One of the most popular" is better IMHO.
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.
Fair enough
## Will Unity implement .NET Standard? | ||
|
||
Yes. We're working with Unity to make sure this is a smooth experience. In | ||
general, since Unity is a fork of Mono and it will mostly get .NET Standard |
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.
remove and
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.
Fixed
## What's the difference between .NET Standard Library and .NET Platform Standard? | ||
|
||
These were terms we used in earlier discussions. We only have one concept today | ||
called *.NET Standard*. |
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.
What about the NETStandard.Library
nuget package people see in project.json today? Will this go away?
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.
We don't know yet; we'll mostly likely reuse that name for the NuGet package but we don't know yet how that is showing up in .csproj. That's why I left it out for now.
These were terms we used in earlier discussions. We only have one concept today | ||
called *.NET Standard*. | ||
|
||
## Can you explain the assemblies and type fowarding in more detail? |
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.
forwarding
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.
Fixed
|.NET Framework |→| 4.5 | 4.5.1| 4.6|→|→|→| 4.6.1| | ||
|Mono |→|→|→|→|→|→|→| vNext| | ||
|Xamarin.iOS |→|→|→|→|→|→|→| vNext| | ||
|Xamarin.Android |→|→|→|→|→|→|→| vNext| |
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.
The following Mono/Xamarin versions supported netstandard1.6:
- Mono 4.6
- Xamarin.iOS 10.0 (Cycle 8)
- Xamarin.Android 7.0 (Cycle 8)
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.
Cool, will fix those.
@@ -0,0 +1,15 @@ | |||
# .NET Standard 1.0 | |||
|
|||
* [APIs](netstandard1.0_ref.md) |
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.
Commenting here since GH won't let me comment on this file:
You could do csharp instead of
diff in the _ref files to get nice syntax highlighting for C#.
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.
Good call! Fixed.
## I still don't get it. Can you provide an analogy that makes sense for a dev? | ||
|
||
David Fowler provided a [developer analogy][netstandard-analogy] that explains | ||
.NET Standard in terms of interfaces and classes. |
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.
Should @davidfowl's analogy be updated to include .Net Standard 2.0?
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.
Yes. Filed #63 to track this.
## How does .NET Standard versioning work? | ||
|
||
Think of the .NET Standard versions as concentric circles: higher versions | ||
incorporate all APIs from previous versions. |
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.
I though NS 2.0 does not incorporate all APIs from NS 1.6. Should that be mentioned here?
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.
Now it does :-) See here.
two different types can live in separate assemblies but we don't have a | ||
mechanism to split a single type across two different assemblies. In those | ||
cases, we leave the members on the type and let platforms that cannot | ||
meaningfully implement them throw `PlatformNotSupportedException`. |
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.
I'm confused, above you said that MarshalByRefObject
will be exposed, but MarshalByRefObject.CreateObjRef
won't. But, if I understand it correctly, this section says that if you expose a type, you also expose all its members.
Assuming others are likely to be confused just like I am, should this be clarified?
|Universal Windows Platform |→|→|→|→| 10.0|→|→| vNext| | ||
|Windows |→| 8.0| 8.1| | | | | | | ||
|Windows Phone |→|→| 8.1| | | | | | | ||
|Windows Phone Silverlight | 8.0| | | | | | | | |
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 article does not mention the whole "NS 2.0 is not a superset of NS 1.6" issue at all. Why not?
As a consequence, for example the table implies that .Net Framework 4.6.1 supports .Net Standard 1.6 or that to run on .Net Framework 4.6.1 and .Net Core 1.0, you can target .Net Standard 1.6.
Unless something changed, I think this should not be ignored.
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.
Nevermind, the changes in #61 explain that this is no longer true. Though that means that the "Introducing .NET Standard" blog post linked at the start of the FAQ is now out of date.
|
||
There is nothing language specific about .NET Standard. From a language view | ||
point, the only tie-in to .NET Standard are the language-specific runtime APIs | ||
(e.g. `Mirosoft.CSharp`, `Microsoft.VisualBasic`, `FSharp.Core` etc) and the |
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.
typo MIcrosoft
|
||
* The columns represent .NET Standard versions. The header is a link to a | ||
document that shows which APIs got added in that version of .NET Standard. | ||
* The rows indicate which version of a given .NET platform implemens a given |
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.
typo implements
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.
Fixed
94c790f
to
3268a04
Compare
|
||
## Why is JSON.NET not part of .NET Standard? | ||
|
||
Today, one of the most popular library for dealing with JSON is JSON.NET. But by |
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.
library libraries
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.
Fixed
3268a04
to
9a32065
Compare
This fixes #35.
This moves the .NET Standard support matrix out of the .NET Standard 2.0 spec and adds searchable refs and diffs for the existing .NET Standard versions.
In addition, this adds the FAQ that answers the questions folks asked on our blog and in issue #35.
@weshaggard, give a quick read to see whether that works.