Skip to content
This repository has been archived by the owner on Sep 13, 2022. It is now read-only.

Add FAQ #62

Merged
merged 2 commits into from Oct 14, 2016
Merged

Add FAQ #62

merged 2 commits into from Oct 14, 2016

Conversation

terrajobst
Copy link
Member

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.

@dnfclas
Copy link

dnfclas commented Oct 14, 2016

Hi @terrajobst, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!

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

Copy link

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?

Copy link
Member Author

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
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo: availabe

Copy link
Member Author

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.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo: handla

Copy link
Member Author

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.

Copy link

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
Copy link

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
Copy link

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

Copy link
Member Author

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
Copy link

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.

Copy link
Member Author

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:
Copy link

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

Copy link
Member Author

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.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo: fromt

Copy link
Member Author

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
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo: availabe

Copy link
Member Author

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
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo: Versining

Copy link
Member Author

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
Copy link
Member

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.

Copy link
Member Author

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
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove and

Copy link
Member Author

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*.
Copy link
Member

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?

Copy link
Member Author

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?
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

forwarding

Copy link
Member Author

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|
Copy link
Member

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)

Copy link
Member Author

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)
Copy link
Member

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#.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good call! Fixed.

akoeplinger referenced this pull request Oct 14, 2016
This fixes #35.
## 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.
Copy link

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?

Copy link
Member Author

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.
Copy link

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?

Copy link
Member Author

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`.
Copy link

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| | | | | | | |
Copy link

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.

Copy link

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.

This fixes #35.

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
Copy link
Member

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
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo implements

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@terrajobst terrajobst force-pushed the terrajobst/faq branch 4 times, most recently from 94c790f to 3268a04 Compare October 14, 2016 17:10

## 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
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

library libraries

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@terrajobst terrajobst self-assigned this Oct 14, 2016
@terrajobst terrajobst merged commit 4419038 into master Oct 14, 2016
@terrajobst terrajobst deleted the terrajobst/faq branch October 14, 2016 17:18
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

RCF: Creating an FAQ
6 participants