Upload
chaya-caris
View
216
Download
2
Embed Size (px)
Citation preview
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Usama Wahab Khan
Solution Architect ,Microsoft Technical Community Leader,Microsoft Certified Trained ,MCPD ,MCTS , MCTIP. For SharePoint and .NET /AzureVice -President, Technology Middle east and Europe (DAVIGOLD LLC)
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
User Groups
Join US
http://uaesharepoint.org/
•Dev Saturday UAE
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Agenda
• OVERVIEW NEW API SHAREPOINT
• CSOM JSOM INTRODUCTION
• REST IMPROVEMENT
• New JS based Modern Frameworks (JS
Knockout)
• DEMO
• New tools
• Cloud App.
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
• Portals and Collaboration
• Search
• Enterprise Content Management
• Web Content Management
• Social and Communities
• Business Connectivity Services
• Business Intelligence
SharePoint Server 2013 Workloads
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Entry Points for Developers in SharePoint 2013
Server-side object model Managed code Windows PowerShell
Client.svc Client-side object models REST/OData clients
Declarative customizations
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
What's New in SharePoint 15
Cloud App Model
Familiar programming model using web standards
Development tools
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
What's New in SharePoint 15
Core platform enhancements
Mobility
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
What's New in SharePoint 15
Business Connectivity Services
Application services
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
SharePoint 2013 APIs Improvements
· More Web Standards (Odata,Oauth)· More Client Side Support · Improved Rest Model and EndPoint· Odata URL base Query Engine · OAuth Web base identity system. · Mobile Templates.
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
SharePoint 2013 APIs Improvements By Features
Feature .NET Framework or Silverlight object models
JavaScript object model REST/OData endpoints called from a Windows platform or JavaScript
Object-oriented programming Yes Yes No
Batch processing Yes Yes No
APIs for conditional processing and exception handling
Yes No No
Availability of LINQ syntax Yes No No
Combining list data from different SharePoint web applications
Yes No Yes
Familiarity to experienced REST/OData developers
No No Yes
Similarity to non-Windows programming or JavaScript programming
No Yes Yes
Strong typing for list item fields No (except with LINQ) No Yes, from Windows platformNo, from JavaScript
Leveraging jQuery, Knockout, and other JavaScript libraries
No
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
The device on which the code runs.
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Preview us CSOM
Everything WAS
client.svc
Issues with CSOM•No Direct Access to client.svc Web Service•Must use a Proxy or Supported End Points• Supports .NET Silverlight & JavaScript
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
2010 CSOM
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
SharePoint 2013 CSOM
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Changes in SharePoint 2013x
Extended REST Support for Client.svc
New APIs
•New APIs for Server Functionality • API for Windows Phone Development
For More Informationhttp://tinyurl.com/SP2013Odata
Client.svc with REST Clients
•Direct Access to client.svc Web Service• Access HTTP GET, PUT, Merge, POST Requests•OData Implementation•Writing Code from NON Microsoft Apps
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
New CSOM API Support
E-Discovery
TaxonomySearch
Workflow
Sharing
User Profiles
Analytics
PublishingFeeds
IRMBusiness Data
Lists
Support both Server Side code and REST
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
SharePoint 2013 CSOM Architecture
CSilverlight Library
.NET CLR Library
JavaScript Library
_api
Execute Query
Server
Client
OData
Custom Client Code
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Changes in SharePoint 2013 CSOM
• Microsoft.SharePoint.Client.dll and Microsoft.SharePoint.Client.RunTime.dll• Available in SharePoint Foundation• contains the core classes
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Customization packaging and deployment options
Farm
• Full trust solutions• Customizations to
file system of servers
• Classic model from 2007
Sandbox
• Declarative elements
• Partially trusted code service still included for limited server side support
SP Apps
• New Apps model• Deployed from
corporate catalog or office market place
• Manage permission and licenses specifically
• Preferred option
Development & Customization
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
DemoManaged Client OM
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
DemoJavaScript Client OM
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
MVVM
Separation of powers/interestsModel
Holds the informationIndependent of UI
View Formats the informationState representation of the view model
ViewModelEncapsulates behaviorCode representation of data and operations
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Knockout.js
JavaScript LibraryFree, Open SourceNo dependencies (other than JavaScript)Compatible with all major browsersUsed to implement Model View ViewModel pattern2-Way Data BindingNotify subscribers about changes
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
What’s REST and Why?
Significant Industry Momentum
Simple and Easier to Use• Easier than SOAP Based WS’s•Higher Productivity using JavaScript and JQuery• Results as JSON and ATOM
How to Query• Everything is URL• Results can be cached on Proxy Servers.
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
REST in SharePoint 2010
ListData.svc
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
REST in SharePoint 2013
NEW : CSOM URLS can go through /_api/folder
Replace
• http://intranet/_vti_bin/client.svc/web with• http://intranet/_api/web/
• Lot more simple URL• Helps in 256 Character
Limit of URLs in browser• ListData.svc is still there
for backword compatiability
• OLD Aps will still work but needs to be updated
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Client OM and OData
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
What is OData?
Access to Information Across Platforms
Uses HTTP Verbs Get, Put, Delete, Merge, Post
Support for all kind of Data, RD, FS, CMS or Web
Built on top of HTTP, ATOM and JSON
Web Protocol for Basic CRUD Operations on Data
Brand New Data Access API
More Information @ http://www.odata.org/
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Methods will be mapped into eitherOData Maps CRUD Operations to HTTP Verbs
OData Implementation Details
Update Mapped to PUT or MERGE
Delete Mapped to DELETE
Service Operation via POST, PUT, MERGE or Delete
Insert Mapped to POST
Read mapped to GETNavigation Operations e.g. List.getByTitle via a GET Request
More Information @ http://www.odata.org/
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
URLsService Root URI : http://intranet.contoso.com/_api/
Resource Path – SQL Table or Web or List
Query Strings Options – $Filter, $select, $orderby
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
REST – Return ATOM XML vs. JSON
Control data format response with ACCEPT header
ATOM-PUB XML
• Verbose• Easier to Read• ACCEPT = application/atom+xml
JSON
• Condensed notation• Smaller payload• ACCEPT = application/json;odata=verbose;
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Managing Objects to Resources
Example REST URLS http://Intranet.consoto.com/_api/web/ http://Intranet.consoto.com/_api/web/Lists http://Intranet.consoto.com/_api/web/Lists/
getByTitle(‘Customers’) http://Intranet.consoto.com/_
api/web/getAvailableWebTemplates(lcid=1033 http://Intranet.consoto.com/_api/web/ http://intranet.consoto.com/_api/web/Lists/
getByTitle(‘Customers’)/Items(0)/?$select CustomerName,CustomerId,Address
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Summary
CSOMNow Covers More Important for App Development
RESTImproved SyntaxEasy to Use with JavaScript than C#
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Some Great Resources
http://msdn.microsoft.com/en-us/library/jj164060.aspx http://msdn.microsoft.com/en-us/library/jj163201.aspx http://msdn.microsoft.com/en-us/library/jj164022.aspx http://msdn.microsoft.com/en-us/library/jj163800.aspx http://msdn.microsoft.com/en-us/library/fp142385.aspx http://msdn.microsoft.com/en-us/library/fp142380.aspx http://msdn.microsoft.com/en-us/library/fp142386.aspx http://msdn.microsoft.com/en-us/library/jj193034(v=office.15
).aspx
http://code.msdn.microsoft.com/office/SharePoint-2013-Perform-a-1bf3e87d/view/SourceCode#content
http://msdn.microsoft.com/en-us/library/jj860569.aspx
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Office 365 Cloud Business AppVisual Studio 2013 introduces a new project template for Office 365 Cloud Business App to enable developers to quickly build modern business applications that can integrate with and extend the Office 365 platform experience. The Cloud Business App template provides a rich set of tools and built-in functionality that make it easy to work with data and leverage Office 365 services such as identity and social.
• Build Supper Quick Apps.• Connect SQL Server based Data Sources.• Create Multiple Screens for all Devices.• Use Workflow with Cloud Business App.• Essay debugging. • Field Validation.
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Office 365 Cloud Business App
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Office 365 Cloud Business App
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.
Office 365 Cloud Business App
©2012 Microsoft Corporation. All rights reserved. Content based on SharePoint 15 Technical Preview and published July 2012.