SlideShare a Scribd company logo
MSDN Presents…What’s New in Visual Studio 2010
What’s New in .NET 4.0
SharePoint 2010 for Developersi’m Dave Bost
dbost@microsoft.com
davebost.com
@davebost
http://thirstyDeveloper.com@thirstyd
get on with it…
What’s New:Visual Studio 2010
Huge List of New Features!Breakpoint LabelingBreakpoint SearchingBreakpoint Import/ExportDynamic Data ToolingWPF Tree VisualizerCall HierarchyImproved WPF ToolingHistorical DebuggingMini-Dump DebuggingQuick SearchBetter Multi-Monitor  SupportHighlight ReferencesParallel Stacks WindowParallel Tasks WindowDocument Map MarginGenerate From UsageConcurrency ProfilerInline Call TreeExtensible Test RunnerMVC ToolingWeb DeployJQuery IntellisenseSharePoint ToolingHTML SnippetsWeb.config TransformationClick-Once Enhancements for Microsoft Office
OverviewGeneral ImprovementsDebuggingParallelismWebExtensibility
General Improvements
Highlighting ReferencesCTRL+SHIFT+DOWN ARROW (forward) CTRL+SHIFT+UP ARROW (reverse) Automatic highlighting of a symbolCan be used with declarations, references, and many other symbols
Navigate ToCTRL + ,Provides search-as-you-type support for symbolsEnables quick searching based on case usage
Docking WindowsNew Guide DiamondWindows can be docked anywhereCan now pull document windows outside the IDE
Call Hierarchy (C# only)CTRL + K, TUsed to see calls to and from a methodGreat way to see calls at design time
ZoomCTRL + Mouse WheelNew feature that enhances the size of your codeVery useful for pair programming (or similar scenarios)
Generate from UsageUsed to automatically create stub codeEnables you to use classes and members before you define them
Intellisense Suggestion ModeCTRL + ALT + SPACEUsed when classes and members are used before they are definedHelps to reduce situations where IntelliSense inserts unintended text into the editor
General Improvements
Debugging
BreakpointsCan add labels to breakpointsAll breakpoints are now searchableImport / Export now available
Floating Data Tips
ThreadingCompletely redesigned threading windowNow provides filtering, call-stack searching and expansion, and groupingNew columns added:Affinity masksProcess namesManaged IDs
DumpsYou can save a dump file and debug it later, either on the build computer or on another computer that has the source files and debugging symbolsCan read dump files that contain information about managed code, unmanaged code, or a mixture of both
Parallel  Tasks and StacksUsed to visualize and debug parallel code that is written in C++, C#, or Visual BasicUsing the Parallel Stacks window, you can view multiple call stacks at the same time in a single viewParallel Tasks allow you to see multiple tasks and the corresponding status of those tasks
Debugging
Web
Code SnippetsSnippets are now available in web applicationsTwo major contextual areas:JavaScriptHTML
Code Snippets
DyanmicIntellisense for JavaScript
Web.config Transforms	You can create configuration file transforms to modify your project's Web.config file to work with various deployment environmentshttp://blogs.msdn.com/webdevtools
One-Click Web DeploymentWith Visual Studio 2010, MSDeploy is integrated directly into Visual StudioOnce you have your profiles configured, you can easily deploy to a given environment with a single click
Web
Extensibility
The Visual Studio Galleryhttp://visualstudiogallery.msdn.microsoft.com
Making Your Extensionshttp://msdn.microsoft.com/en-us/vsx/default.aspx
Extensions
ResourcesWhat’s New in Visual Studio 2010http://msdn.microsoft.com/en-us/library/bb386063(VS.100).aspxVisual Studio on MSDNhttp://msdn.microsoft.com/vstudioVisual Studio 2010 Tips and Trickshttp://blogs.msdn.com/zainnab
15 Minute Break
What’s New in the.NET Framework 4.0
From There to Here…SP13.53.0.NET 1.0.NET 1.1.NET 2.0.NET 4200220032008 CTP!2005-08CLR 1.0CLR 1.1CLR 2.0CLR 4
.NET Framework ArchitectureWPFWin FormsDLRASP.NETWCFAnd more!LINQBase Class LibrariesCommon Language RuntimeJIT & NGENGarbage CollectorSecurity ModelException HandlingLoader & Binder
OverviewClient ProfileVisualizationDataProgramming LanguagesCommon Language Runtime (CLR)Base Class Libraries (BCL)Web
Client Profile
Client ProfileSubset of the full .NET Framework Leveraged for faster deploymentsTwo SectionsClient ProfileExtendedStreamlined pieces of Windows Presentation Foundation (WPF)Windows FormsWindows Communication Foundation (WCF)ClickOnce
Visualization
Windows Presentation Foundation(WPF)New ControlsDataGridCalendarDatePickerVisual State ManagerTouch and ManipulationText
Calendar and DatePickerControsl
Data
Pluralization & Foreign Keys
Model-FirstExistingDatabaseGeneratedEntity DataModelDatabaseFirst (v1)GeneratedDatabaseEntity DataModelModelFirst (v2)
Model-First
POCOClass DefinitionEverythingNavigation Property DefinitionScalar Property Definition
Deferred / Lazy LoadingExplicitDeferred / lazy
Complex TypesVS.
Programming Languages
Visual BasicAuto-Implemented PropertiesShortened syntax that enables you to quickly specify a property of a class without having to write codeCollection InitializerShortened syntax that enables you to create a collection and populate it with an initial set of valuesImplicit Line ContinuationEnables you to continue a statement on the next consecutive line without using the underscore character Public Property Owner As String = "DefaultName"Function AddStuff(ByValfirst As Integer,ByValsecond As Integer                                                ) As IntegerReturnfirst +                                   secondEnd FunctionPublic PropertyItems As New List(Of String)= {“M“, “T“, “W“}
C#Dynamic TypeOperations that contain expressions of type dynamic are not resolved or type checked by the compiler. The compiler packages together information about the operation, and that information is later used to evaluate the operation at run timeOptional and Named ParametersNamed arguments enable you to specify an argument for a particular parameter by associating the argument with the parameter's name rather than with the parameter's position in the parameter list.Optional  arguments enable you to omit arguments for some parameters. Both techniques can be used with methods, indexers, constructors, and delegates.
C#:       - dynamic keyword      - named and optional parameters
F#IDE support for F#Interactive F# for prototyping codeAsynchronous constructsParallel constructsImmutable data types
Common Language Runtime(CLR)
Existing Side-By-Side (SxS)2.0 add-in3.0 add-in3.5 add-in1.1 add-in3.5.NET 1.13.0.NET 2.0Host Process (i.e. Outlook)
In-Process Side-By-Side (SxS)2.0 add-in3.0 add-in3.5 add-in4.0 add-in3.5.NET 4.03.0.NET 2.0Host Process (i.e. Outlook)
Base Class Libraries(BCL)
Task Parallel Library (TPL)Set of public types and APIs
System.Threading
System.Threading.Tasks// Sequentialforeach (var item in sourceCollection) {     Process(item); } // ParallelParallel.ForEach (sourceCollection, item => Process(item));
New Sync Primitives in .NET 4Thread-safe, scalable collectionsIProducerConsumerCollection<T>ConcurrentQueue<T>ConcurrentStack<T>ConcurrentBag<T>ConcurrentDictionary<TKey,TValue>Phases and work exchangeBarrier BlockingCollection<T>CountdownEventPartitioning{Orderable}Partitioner<T>Partitioner.CreateException handlingAggregateExceptionInitializationLazy<T>LazyInitializer.EnsureInitialized<T>ThreadLocal<T>LocksManualResetEventSlimSemaphoreSlimSpinLockSpinWaitCancellationCancellationToken{Source}ManyCore: http://microoftpdc.com/Sessions/P09-09  (50:00)
Parallelize For LoopsControl flow is a primary source of workParallelizable when iterations are (or can be made) independentSynchronousAll work quiesces, regularly or exceptionallyLots of knobsCancelation, breaking, task-local state, custom partitioning, scheduling, degree of parallelismforeach(var item in data) {   work(item);}for (int i = 0; i < n; i++) {   work(i);}StatementA();StatementB;StatementC();Parallel.ForEach(data, item=>{   work(item);});Parallel.For(0, n, i=> {   work(i);});Parallel.Invoke(   () => StatementA(),    () => StatementB,    () => StatementC());ManyCore: http://microsoftpdc.com/Sessions/P09-09
Parallel LINQ (PLINQ)Implements the full set of LINQ standard query operators
Extension methods for the IParallelEnumerable interface
Additional operators for parallel operationsfrom n in names.AsParallel().WithDegreeOfParallelism(ProcessorsToUse.Value)                       where n.Name.Equals(queryInfo.Name, StringComparison.InvariantCultureIgnoreCase) &&n.State == queryInfo.State && n.Year >= yearStart && n.Year <= yearEndorderbyn.Year ascending                       select n;
Parallelism
Design By ContractSystem.Diagnostics.ContractsCode Contracts introduce a way to specify contractual information that is not represented by a method or type’s signature aloneScenarios for using contracts include:Perform static bug finding, which enables some bugs to be found without executing the codeCreate guidance for automated testing tools to enhance test coverageCreate a standard notation for code behavior, which provides more information for documentationpublic Boolean ExampleMethod(String parameter) { if (parameter == null) throw newArgumentNullException("parameter must be non-null"); }http://msdn.microsoft.com/devlabs
Data TypesBigIntegerImmutable type that represents an arbitrarily large integer whose value in theory has no upper or lower boundsSortedSet<T>Provides a self-balancing tree that maintains data in sorted order after insertions, deletions, and searches
I/OMemory-Mapped FileUsed to edit very large files and to create shared memory for inter-process communicationStream.CopyToAllows you to copy the contents of one stream into another
Web
Model-View-Controller (MVC)Huge investment from MicrosoftAlternative to WebFormsModular ArchitectureMVC 2.0 Integrated in .NET Framework 4.0
ASP.NET WebformsAbility to set meta tagsMore control over view stateAdded and Updated browser definition filesASP.NET RoutingThe ability to persist selected rows in data controlsMore control over rendered HTML in the FormView and ListView controlsFiltering support for data source controls
Dynamic DataA RAD experience for quickly building a data-driven Web siteAutomatic validation that is based on constraints defined in the data modelThe ability to easily change the markup that is generated for fields in the GridView and DetailsView controls by using field templates
Web
Resources.NET Developer Centerhttp://msdn.microsoft.com/netData Developer Centerhttp://msdn.microsoft.com/dataConcurrency (Parallelism)http://msdn.microsoft.com/concurrencyASP.NET MVChttp://asp.net/mvcWPF and Windows Formshttp://windowsclient.net
15 Minute Break
SharePoint Development withVisual Studio 2010
SharePoint 2010EnhancementsNew object modelLINQ for SharePointNative support for SilverlightSandboxed SolutionsExternal data lists
OverviewSharePoint ProjectsEvent ReceiversDeployment & DebuggingWeb Parts
SharePoint Projects
Server Explorer
Packages
SharePoint ProjectsThennow
Empty Project
SharePoint Projects
Event Receivers
Event Receivers
Creating Event Receivers
Event Receivers
Deployment & Debugging
Deployment:  Project Creation
Properties:SharePoint Tab
Deployment
Debugging
Deployment & Debugging

More Related Content

MSDN Presents: Visual Studio 2010, .NET 4, SharePoint 2010 for Developers