code: function ( id, queryDef ) {
          if (!this.layerDefs) {
              this.layerDefs = {};
          }
          if (queryDef) {
              this.layerDefs[id] = queryDef;
          } else {
              delete this.layerDefs[id];
          }
      }
docs: Method: setLayerFilter
  addTile creates a tile, initializes it, and adds it to the layer div.
  
  Parameters:
  id - {String} The id of the layer to which the filter applies.
  queryDef - {String} A sql-ish query filter, for more detail see the ESRI
  documentation at http://sampleserver1.arcgisonline.com/ArcGIS/SDK/REST/export.html