O slideshow foi denunciado.
Utilizamos seu perfil e dados de atividades no LinkedIn para personalizar e exibir anúncios mais relevantes. Altere suas preferências de anúncios quando desejar.
Visual Studio 2008
Agenda <ul><li>Multitargetting   </li></ul><ul><li>Occasionally connected Systems </li></ul><ul><li>Office Applications </...
Release History
Multitargetting <ul><li>No longer a hard link between Visual Studio and the application’s target framework  </li></ul>VS 2...
Sync Framework & Services <ul><li>Connected </li></ul><ul><li>Single data source </li></ul><ul><li>Database driven </li></...
ADO.NET Sync Services Client App Sync Services <ul><li>No active connection to the database required </li></ul><ul><li>Dat...
{  ADO.NET Sync Services   }
Office Applications (VSTO)
Ribbon Customization <ul><li>New Look and Feel for Office UI </li></ul><ul><li>Replaces Command Bars in “the big 5” Office...
Custom Task & Actions Panes <ul><li>VSTO simplifies and speeds up task pane UI design process with visual designers and .N...
Outlook Form Region Features <ul><li>New technology in Outlook 2007 for enhancing and replacing Outlook’s built-in forms <...
{  Office Applications   }
Client Applications
{  WPF Support in VS2008   }
WF and WCF
ASP.NET Web Applications
{  WCF Support in VS2008, ASP.NET Applications   }
Language Features in VS 2008 <ul><li>Most are LINQ enablers </li></ul>VB9 C# 3 Collection Initialisers Partial Methods Aut...
C# 3.0: Local Variable Type Inference <ul><li>Local variable type inference is a feature in C# 3.0 where you can use the  ...
C# 3.0: Object Initializers public   class   Point  { private   int  x, y; public   int  X {  get  {  return  x; }  set  {...
C# 3.0: Anonymous Types  <ul><li>Different anonymous object initializers that define properties with same names in  the sa...
C# 3.0: Extension Methods <ul><li>Extend existing types with additional methods. </li></ul>namespace  MyStuff { public   s...
C# 3.0:  Lambda Expressions delegate   string   SomeDelegate ( string  s); private   static   string  TestMethod1( string ...
{  C# 3.0   }
Language INtegrated Query? <ul><li>Lots of code written today in order to  loop, filter, sort, group, etc. </li></ul><ul><...
Why Have LINQ? <ul><li>Access to common data like XML or SQL is harder than accessing in memory objects; </li></ul><ul><li...
Language Integrated Query from  data   in  someDataSource join   otherData  in  someOtherSource   on  keyExpr   equals  ke...
How Does LINQ Work? <ul><li>Implementations already present in the .NET Framework for those cases </li></ul><ul><li>Compil...
IEnumerable & IQueryable? <ul><li>IEnumerable – query is executed in memory </li></ul>Execute Execute where select where s...
LINQ to SQL from  c  in  db.Customers where  c.City ==  &quot;London&quot; select  c.CompanyName; IQueryable<T> SELECT Com...
{  LINQ to Objects,   LINQ to SQL   }
Summary <ul><li>Visual Studio 2008 </li></ul><ul><ul><li>Great for Windows Vista Development </li></ul></ul><ul><ul><li>Gr...
Resources <ul><li>http://msdn.microsoft.com/en-us/vstudio   </li></ul><ul><li>http://msdn.microsoft.com/en-us/sync   </li>...
Próximos SlideShares
Carregando em…5
×

Visual studio 2008

960 visualizações

Publicada em

Publicada em: Educação, Tecnologia
  • Seja o primeiro a comentar

  • Seja a primeira pessoa a gostar disto

Visual studio 2008

  1. 1. Visual Studio 2008
  2. 2. Agenda <ul><li>Multitargetting </li></ul><ul><li>Occasionally connected Systems </li></ul><ul><li>Office Applications </li></ul><ul><li>Client Applications </li></ul><ul><li>Windows Communication Foundation </li></ul><ul><li>ASP.NET Web Applications </li></ul><ul><li>C# 3.0 and LINQ </li></ul>
  3. 3. Release History
  4. 4. Multitargetting <ul><li>No longer a hard link between Visual Studio and the application’s target framework </li></ul>VS 2008
  5. 5. Sync Framework & Services <ul><li>Connected </li></ul><ul><li>Single data source </li></ul><ul><li>Database driven </li></ul><ul><li>Hard coded </li></ul><ul><li>Monolithic & rigid </li></ul><ul><li>Occasionally connected </li></ul><ul><li>Multiple data sources </li></ul><ul><li>Information based </li></ul><ul><li>Model driven </li></ul><ul><li>SOA </li></ul>
  6. 6. ADO.NET Sync Services Client App Sync Services <ul><li>No active connection to the database required </li></ul><ul><li>Data is persisted using SQL Server Everywhere Edition </li></ul><ul><li>Local Change Tracking for Sending Updates When Connected </li></ul><ul><li>VS2008 Developer Productivity </li></ul><ul><ul><li>“ Pay to Play”, RAD Component Architecture Leveraging Developers ADO.NET Knowledge </li></ul></ul><ul><ul><li>Auto Creation of Database and Table Schema </li></ul></ul>SQL Server Everywhere Edition SQL Server
  7. 7. { ADO.NET Sync Services }
  8. 8. Office Applications (VSTO)
  9. 9. Ribbon Customization <ul><li>New Look and Feel for Office UI </li></ul><ul><li>Replaces Command Bars in “the big 5” Office apps </li></ul><ul><li>VSTO Ribbon Designer </li></ul>Tab Group Control Ribbon
  10. 10. Custom Task & Actions Panes <ul><li>VSTO simplifies and speeds up task pane UI design process with visual designers and .NET hookup </li></ul><ul><ul><li>Actions Pane </li></ul></ul><ul><ul><ul><li>More robust, easier to program alternative to Office’s built-in “Smart Document” technology </li></ul></ul></ul><ul><ul><li>Custom Task Pane </li></ul></ul><ul><ul><ul><li>The same general idea as Actions Pane, only on the application add-in level, not individual doc </li></ul></ul></ul>
  11. 11. Outlook Form Region Features <ul><li>New technology in Outlook 2007 for enhancing and replacing Outlook’s built-in forms </li></ul><ul><li>Code behind form region is implemented as COM add-in </li></ul><ul><li>New controls provide built-in look & feel and data binding to Outlook data </li></ul>
  12. 12. { Office Applications }
  13. 13. Client Applications
  14. 14. { WPF Support in VS2008 }
  15. 15. WF and WCF
  16. 16. ASP.NET Web Applications
  17. 17. { WCF Support in VS2008, ASP.NET Applications }
  18. 18. Language Features in VS 2008 <ul><li>Most are LINQ enablers </li></ul>VB9 C# 3 Collection Initialisers Partial Methods Automatic Properties Extension Methods Object Initialisers Anonymous Types Local Type Inference Lambda expressions If Ternary Operator Nullable Syntax Lambda statements
  19. 19. C# 3.0: Local Variable Type Inference <ul><li>Local variable type inference is a feature in C# 3.0 where you can use the var keyword instead of explicitly specifying the type of a variable. The C# 3.0 compiler makes the type of the variable match the type of the right side of the assignment. </li></ul>public void Foo() { var i = 5; var s = &quot;Hello&quot; ; var d = 1.0; var z; // compiler error, no initializer z = DateTime .Today; }
  20. 20. C# 3.0: Object Initializers public class Point { private int x, y; public int X { get { return x; } set { x = value ; } } public int Y { get { return y; } set { y = value ; } } } Point a = new Point { X = 0, Y = 1 }; Point a = new Point (); a.X = 0; a.Y = 1; Field or property assignments
  21. 21. C# 3.0: Anonymous Types <ul><li>Different anonymous object initializers that define properties with same names in the same order generate the same anonymous type </li></ul>var emp = new { Name = &quot;Fons&quot; , Salary = 2000, DateTime .Today.Year }; var year = emp.Year; class XXX { public string Name { get ; set ; } public int Salary { get ; set ; } public int Year { get ; set ; } }
  22. 22. C# 3.0: Extension Methods <ul><li>Extend existing types with additional methods. </li></ul>namespace MyStuff { public static class Util { public static bool IsWeekend( this DateTime value) { return (value.DayOfWeek == DayOfWeek .Sunday || value.DayOfWeek == DayOfWeek .Saturday); } } } using MyStuff; Brings extensions into scope dt.IsWeekend()  MyStuff.Util.IsWeekend(dt) DateTime dt = DateTime .Today; bool b = dt.IsWeekend();
  23. 23. C# 3.0: Lambda Expressions delegate string SomeDelegate ( string s); private static string TestMethod1( string s) { return s.ToUpper(); } ... SomeDelegate d1 = new SomeDelegate (TestMethod1); string a = d1( &quot;abcde&quot; ); SomeDelegate d3 = delegate ( string s) { return s.ToUpper(); }; string a = d3( &quot;abcde&quot; ); SomeDelegate d4 = s => s.ToUpper(); string a = d4( &quot;abcde&quot; ); SomeDelegate d2 = TestMethod1; string a = d2( &quot;abcde&quot; ); Delegate Inference Anonymous Method Lambda Expression OO Function- Pointer C# 1.x C# 2.0 C# 2.0 C# 3.0
  24. 24. { C# 3.0 }
  25. 25. Language INtegrated Query? <ul><li>Lots of code written today in order to loop, filter, sort, group, etc. </li></ul><ul><li>Why not build better support for this? </li></ul>sort loop sum
  26. 26. Why Have LINQ? <ul><li>Access to common data like XML or SQL is harder than accessing in memory objects; </li></ul><ul><li>Why not have better API’s than this? </li></ul>hope! pray! hope!
  27. 27. Language Integrated Query from data in someDataSource join otherData in someOtherSource on keyExpr equals keyExpr (into itemName )? let someVariable = someExpression where somePredicate orderby ( expression (ascending | descending)?)* select expression group expression by keyExpression   into itemName .NET Framework V3.5 Language Features ( C# V3 and VB V9 ) Custom Objects XML SQL
  28. 28. How Does LINQ Work? <ul><li>Implementations already present in the .NET Framework for those cases </li></ul><ul><li>Compiler rewrites as method calls </li></ul><ul><li>No need to implement Select() etc. if myData is either </li></ul>IEnumerable IQueryable
  29. 29. IEnumerable & IQueryable? <ul><li>IEnumerable – query is executed in memory </li></ul>Execute Execute where select where select Parse & Execute <ul><li>IQueryable – query is parsed then translated to SQL and finally executed on to the database </li></ul>
  30. 30. LINQ to SQL from c in db.Customers where c.City == &quot;London&quot; select c.CompanyName; IQueryable<T> SELECT CompanyName FROM Customer WHERE City = 'London' SQL Query or SProc Resultset Objects db.Customers.InsertOnSubmit(c1); c2.City = &quot;Asten&quot; ; db.Customers.DeleteOnSubmit(c3); SubmitChanges() INSERT INTO Customer … UPDATE Customer … DELETE FROM Customer … DML or SProcs Application LINQ to SQL SQL Server
  31. 31. { LINQ to Objects, LINQ to SQL }
  32. 32. Summary <ul><li>Visual Studio 2008 </li></ul><ul><ul><li>Great for Windows Vista Development </li></ul></ul><ul><ul><li>Great for Client Development </li></ul></ul><ul><ul><li>Great for Web Development </li></ul></ul><ul><ul><li>Great for Database Applications Development </li></ul></ul><ul><ul><li>Great for .NET Framework v3.5 </li></ul></ul><ul><li>Service Pack 1 will add even more features </li></ul><ul><ul><li>ADO.NET Entity Framework </li></ul></ul><ul><ul><li>ADO.NET Data Services </li></ul></ul><ul><ul><li>ASP.NET Dynamic Data </li></ul></ul>
  33. 33. Resources <ul><li>http://msdn.microsoft.com/en-us/vstudio </li></ul><ul><li>http://msdn.microsoft.com/en-us/sync </li></ul><ul><li>http://msdn.microsoft.com/en-us/office </li></ul><ul><li>http://windowsclient.net </li></ul><ul><li>http://netfx3.com/content/WCFHome.aspx </li></ul><ul><li>http://www.asp.net </li></ul><ul><li>http://msdn.microsoft.com/en-us/vcsharp </li></ul><ul><li>http://www.datadeveloper.net </li></ul><ul><li>Visual Studio 2008 Upgrade Training </li></ul><ul><ul><li>http://www.reflectionit.nl/Training/default.aspx#orcas </li></ul></ul>

×