Project Description

JaySvcUtil.exe is a command line tool that downloads an OData service definition ($metadata) and creates a full featured JayData / JavaScript client environment by generating the necessary boilerplate code for you. All you need to do is to include the generated context file and you can start using the OData service with the high level, JavaScript optimized JayData API that supports JavaScript Language Query (JSLQ) and crud operations.

If you are a data API developer you can distribute the generated context and let your users handle data with a manner.

As an example we will use the Northwind database made available online for testing purposes by Microsoft.

Using JaySvcUtil

C:\jaydata>JaySvcUtil.exe –-metadataUri http://services.odata.org/Northwind/Northwind.svc/$metadata

--out northwind.js --namespace Northwind

JaySvcUtil commandline parameters

parameter description default value
metadataUri  / m Required. The uri of the oData $metadata definition. Can be an online resource or a local file as well  
out  / o The name of the generated output file. JayDataContext.js
namespace The namespace of the generated JayData EntitContext class. Taken from the service metadata.
contextBaseClass The name of the base class for the generated entity context. $data.EntityContext
entityBaseClass The name of the base class for the generated entity types. $data.Entity
entitySetBaseClass The name of the base class for the generated entity sets. $data.EntitySet
collectionBaseClass The name of the base class for the generated entity sets. Default is Array
autoCreateContext Create an instance of the context with default
parameters.
true
contextInstanceName The name of the automatically generated context instance under the context namespace. Default is context
help

Displays parameter options

 
username The username to authenticate with  
password The account password  
domain The login domain (for NTLM/Window auth)  

 

More info
You can download JayData from the JayData CodePlex project

To see JaySvc util in action, watch the video about creating an Northwind product editor with JayData and OData provider or go through the OData-based HTML5 application tutorial.

Last edited Jun 6, 2012 at 1:52 PM by JayDataOrg, version 5