简体   繁体   English

Visual Studio 2013 Windows Phone项目模板的疑问

[英]Visual Studio 2013 windows phone project templates doubts

I have updated my code to WP 8.1 and wanted to organise it better by using Class Libraries. 我已经将代码更新为WP 8.1,并希望通过使用类库更好地进行组织。

The doubt comes when I find there are 2 Class library project templates for Windows Phone: 当我发现Windows Phone有2个类库项目模板时,就会出现疑问:

  1. Class Library (Windows Phone) 类库(Windows Phone)
  2. Class Library (Windows Phone Silverlight) 类库(Windows Phone Silverlight)

If i select template 1, i see the assemblies referenced by default are .NET for Windows Store Apps and Windows Phone 8.1 如果我选择模板1,则看到默认引用的程序集是Windows Store Apps和Windows Phone 8.1的.NET。

If i select template 2, i got asked the target version of the Windows Phone OS (8.0 or 8.1) and the assemblies references by default are .NET for Windows Phone and Windows Phone. 如果选择模板2,则会询问Windows Phone OS的目标版本(8.0或8.1),并且默认情况下,程序集引用是Windows Phone和Windows Phone的.NET。

Do you know the differences between them? 您知道它们之间的区别吗? I have looked into the matter and seems it depends if you want to load the .NET runtime namespaces or not, am i correct? 我已经调查了这件事,似乎这取决于您是否要加载.NET运行时名称空间,对吗? Are there any more differences? 还有其他区别吗?

The class library type will depend on whether your main app will be a Windows Phone 8.1 Silverlight app, or Windows Phone 8.1 XAML app. 类库的类型取决于您的主应用程序是Windows Phone 8.1 Silverlight应用程序还是Windows Phone 8.1 XAML应用程序。

The advantage of WP8.1 XAML app is that it is converged with Windows 8.1 - you can even create an Universal App that shares almost all code and xaml between the Win8 and WP8.1 apps. WP8.1 XAML应用程序的优势在于它与Windows 8.1融合-您甚至可以创建一个通用应用程序,该应用程序在Win8和WP8.1应用程序之间共享几乎所有代码和xaml。

The advantage of WP8.1 Silverlight app is that it is more closer to the old WP8.0 app - less changes are required, and also it has access to some APIs not available to WP8.1 XAML apps. WP8.1 Silverlight应用程序的优点是,它更接近于旧的WP8.0应用程序-需要的更改更少,并且可以访问WP8.1 XAML应用程序不可用的一些API。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Visual Studio 2013中缺少Windows Phone全景图模板 - Windows Phone Panorama templates missing from visual studio 2013 是否可以在visual studio 2013 update 2中创建一个新的Windows Phone 8项目? - Is it possible to create a new windows phone 8 project in visual studio 2013 update 2? 在Visual Studio 2013 Windows Phone 8项目中将TypeBindConflicts放在哪里? - Where to put TypeBindConflicts in visual studio 2013 windows phone 8 project? 在Visual Studio 2013中将项目模板加倍? - Doubled project templates in Visual Studio 2013? Visual Studio 2013 Ultimate没有Windows Phone 8模板 - Visual Studio 2013 Ultimate no Windows Phone 8 template Windows Phone的Visual Studio 2013设计器无法正常工作 - Visual Studio 2013 designer for Windows Phone not working 在Visual Studio 2013中的“新建项目”对话框中缺少项目模板 - Missing project templates in “New Project” dialog box in Visual Studio 2013 '关联应用程序与商店'选项没有显示是视觉工作室终极2013年的Windows Phone 8.1 Silverlight项目 - 'Associate App with the store' option is not showing is visual studio ultimate 2013 for windows phone 8.1 silverlight project 在Visual Studio Pro 2013中添加WCF服务/项目模板吗? - Adding WCF Services / Project Templates in Visual Studio Pro 2013? 在Visual Studio中创建Windows Phone项目的副本 - create a copy of a windows phone project in visual studio
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM