summaryrefslogtreecommitdiff
path: root/lib/dojo/data/api/Identity.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/dojo/data/api/Identity.js')
-rw-r--r--lib/dojo/data/api/Identity.js31
1 files changed, 16 insertions, 15 deletions
diff --git a/lib/dojo/data/api/Identity.js b/lib/dojo/data/api/Identity.js
index 7a1caeb53..9d99f3d64 100644
--- a/lib/dojo/data/api/Identity.js
+++ b/lib/dojo/data/api/Identity.js
@@ -1,5 +1,5 @@
/*
- Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved.
+ Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved.
Available via Academic Free License >= 2.1 OR the modified BSD license.
see: http://dojotoolkit.org/license for details
*/
@@ -10,6 +10,7 @@ dojo._hasResource["dojo.data.api.Identity"] = true;
dojo.provide("dojo.data.api.Identity");
dojo.require("dojo.data.api.Read");
+
dojo.declare("dojo.data.api.Identity", dojo.data.api.Read, {
// summary:
// This is an abstract API that data provider implementations conform to.
@@ -17,7 +18,7 @@ dojo.declare("dojo.data.api.Identity", dojo.data.api.Read, {
// methods unimplemented.
getFeatures: function(){
- // summary:
+ // summary:
// See dojo.data.api.Read.getFeatures()
return {
'dojo.data.api.Read': true,
@@ -45,16 +46,16 @@ dojo.declare("dojo.data.api.Identity", dojo.data.api.Read, {
getIdentityAttributes: function(/* item */ item){
// summary:
- // Returns an array of attribute names that are used to generate the identity.
+ // Returns an array of attribute names that are used to generate the identity.
// For most stores, this is a single attribute, but for some complex stores
// such as RDB backed stores that use compound (multi-attribute) identifiers
// it can be more than one. If the identity is not composed of attributes
// on the item, it will return null. This function is intended to identify
// the attributes that comprise the identity so that so that during a render
- // of all attributes, the UI can hide the the identity information if it
+ // of all attributes, the UI can hide the the identity information if it
// chooses.
// item:
- // The item from the store from which to obtain the array of public attributes that
+ // The item from the store from which to obtain the array of public attributes that
// compose the identifier, if any.
// example:
// | var itemId = store.getIdentity(kermit);
@@ -67,14 +68,14 @@ dojo.declare("dojo.data.api.Identity", dojo.data.api.Read, {
fetchItemByIdentity: function(/* object */ keywordArgs){
// summary:
- // Given the identity of an item, this method returns the item that has
- // that identity through the onItem callback. Conforming implementations
- // should return null if there is no item with the given identity.
- // Implementations of fetchItemByIdentity() may sometimes return an item
- // from a local cache and may sometimes fetch an item from a remote server,
+ // Given the identity of an item, this method returns the item that has
+ // that identity through the onItem callback. Conforming implementations
+ // should return null if there is no item with the given identity.
+ // Implementations of fetchItemByIdentity() may sometimes return an item
+ // from a local cache and may sometimes fetch an item from a remote server,
//
// keywordArgs:
- // An anonymous object that defines the item to locate and callbacks to invoke when the
+ // An anonymous object that defines the item to locate and callbacks to invoke when the
// item has been located and load has completed. The format of the object is as follows:
// {
// identity: string|object,
@@ -84,9 +85,9 @@ dojo.declare("dojo.data.api.Identity", dojo.data.api.Read, {
// }
// The *identity* parameter.
// The identity parameter is the identity of the item you wish to locate and load
- // This attribute is required. It should be a string or an object that toString()
+ // This attribute is required. It should be a string or an object that toString()
// can be called on.
- //
+ //
// The *onItem* parameter.
// Function(item)
// The onItem parameter is the callback to invoke when the item has been loaded. It takes only one
@@ -98,12 +99,12 @@ dojo.declare("dojo.data.api.Identity", dojo.data.api.Read, {
// parameter, the error object
//
// The *scope* parameter.
- // If a scope object is provided, all of the callback functions (onItem,
+ // If a scope object is provided, all of the callback functions (onItem,
// onError, etc) will be invoked in the context of the scope object.
// In the body of the callback function, the value of the "this"
// keyword will be the scope object. If no scope object is provided,
// the callback functions will be called in the context of dojo.global.
- // For example, onItem.call(scope, item, request) vs.
+ // For example, onItem.call(scope, item, request) vs.
// onItem.call(dojo.global, item, request)
if(!this.isItemLoaded(keywordArgs.item)){
throw new Error('Unimplemented API: dojo.data.api.Identity.fetchItemByIdentity');