tasks/rdfstore/index.js
function(ctx)
{
   // TODO: reduce calls to this function by caching keywords in processor
   // state
   
   var rval =
   {
      '@id': '@id',
      '@language': '@language',
      '@literal': '@literal',
      '@type': '@type'
   };
   
   if(ctx)
   {
      // gather keyword aliases from context
      var keywords = {};
      for(var key in ctx)
      {
         if(ctx[key].constructor === String && ctx[key] in rval)
         {
            keywords[ctx[key]] = key;
         }
      }
      
      // overwrite keywords
      for(var key in keywords)
      {
         rval[key] = keywords[key];
      }
   }
   
   return rval;
}
function(ctx)
{
   // TODO: reduce calls to this function by caching keywords in processor
   // state
   
   var rval =
   {
      '@id': '@id',
      '@language': '@language',
      '@literal': '@literal',
      '@type': '@type'
   };
   
   if(ctx)
   {
      // gather keyword aliases from context
      var keywords = {};
      for(var key in ctx)
      {
         if(ctx[key].constructor === String && ctx[key] in rval)
         {
            keywords[ctx[key]] = key;
         }
      }
      
      // overwrite keywords
      for(var key in keywords)
      {
         rval[key] = keywords[key];
      }
   }
   
   return rval;
}
function ( ctx ) { // TODO: reduce calls to this function by caching keywords in processor // state var rval = { '@id' : '@id' , '@language' : '@language' , '@literal' : '@literal' , '@type' : '@type' } ; if ( ctx ) { // gather keyword aliases from context var keywords = { } ; for ( var key in ctx ) { if ( ctx [ key ] . constructor === String && ctx [ key ] in rval ) { keywords [ ctx [ key ] ] = key ; } } // overwrite keywords for ( var key in keywords ) { rval [ key ] = keywords [ key ] ; } } return rval ; }
Gets the keywords from a context.

@param ctx the context.

@return the keywords.
Gets the keywords from a context .