REST APIs Client OM Farm Site List Data External Lists Query Result Set REST APIs Client OM Farm Site List Data External Lists.

Download Report

Transcript REST APIs Client OM Farm Site List Data External Lists Query Result Set REST APIs Client OM Farm Site List Data External Lists.

REST APIs
Client OM
Farm
Site
List Data
External Lists
Query
Result Set
REST APIs
Client OM
Farm
Site
List Data
External Lists
http://msdn.microsoft.com/en-us
/library/cc907912.aspx
REST APIs
Client OM
Farm
Site
List Data
External Lists
Sample: Original LINQ query
from p in data.Projects
where
p.Client.City == "Chicago"
select new
{
Name = p.Title,
ClientName = p.Client.Title,
Budget = p.BudgetHours
};
<Query>
<Where>
<And>
<BeginsWith>
<FieldRef Name="ContentTypeId" />
<Value Type="ContentTypeId">0x0100</Value>
</BeginsWith>
<Eq>
<FieldRef Name="ClientCity" />
<Value Type="Lookup">Chicago</Value>
</Eq>
</And>
</Where>
</Query>
<ViewFields>
<FieldRef Name="Title" />
<FieldRef Name="ClientTitle" />
<FieldRef Name="BudgetHours" />
</ViewFields>
<ProjectedFields>
<Field Name="ClientTitle" Type="Lookup"
List="Client" ShowField="Title" />
<Field Name="ClientCity" Type="Lookup"
List="Client" ShowField="City" />
</ProjectedFields>
<Joins>
<Join Type="LEFT" ListAlias="Client">
<!--List Name: Clients-->
<Eq>
<FieldRef Name="Client" RefType="ID" />
<FieldRef List="Client" Name="ID" />
</Eq>
</Join>
</Joins>
Sample: Original LINQ query
from tc in data.Timecards
where
tc.Id == 4
group tc by tc.WorkDate.Value.ToString("MM/yy") into tcs
select new
{
Month = tcs.Key,
Total = tcs.Sum(t => t.Hours)
};
Sample: Generated CAML Query
<Query>
<Where>
<And>
<BeginsWith>
<FieldRef Name="ContentTypeId" />
<Value Type="ContentTypeId">0x0100</Value>
</BeginsWith>
<Eq>
<FieldRef Name="ID" />
<Value Type="Counter">4</Value>
</Eq>
</And>
</Where>
</Query>
<ViewFields>
<FieldRef Name="StaffId" />
<FieldRef Name="WorkDate" />
<FieldRef Name="Hours" />
<FieldRef Name="Project" />
<FieldRef Name="ID" />
<FieldRef Name="owshiddenversion" />
<FieldRef Name="Title" />
</ViewFields>
<RowLimit Paged="TRUE">2147483647</RowLimit>
Client OM
On SharePoint Server
On Remote Computer
Site / List Objects
Traverse Relationships
Calling Pattern (Direct)
Calling Pattern (Callback)
Strongly-Typed
(Columns as Properties)
Server OM
REST
LINQ to SharePoint
Managed Client OMs
JavaScript Client OM
Full URL Context
Server-relative Context Only
StringCollection
string[] Array
Null, infinity
Nan, positive/negative infinity
Explicit FBA support
Context FBA support
Create, Update, Commit
Create, Commit, Update
No FormDigest Required
Needs <SharePoint:FormDigest>
Standard Server OM Identity
No RoleDefinitionBindingCollection Identity
SPWeb Locale for Comparisons
Invariant Culture for Comparisons
http://sharepoint.microsoft.com
http://sharepoint.microsoft.com
http://msdn.microsoft.com/sharepoint
http://technet.microsoft.com/sharepoint
http://blogs.msdn.com/sharepoint
www.microsoft.com/teched
www.microsoft.com/learning
http://microsoft.com/technet
http://microsoft.com/msdn
Sign up for Tech·Ed 2011 and save $500
starting June 8 – June 31st
http://northamerica.msteched.com/registration
You can also register at the
North America 2011 kiosk located at registration
Join us in Atlanta next year