B2G/gecko/toolkit/components/places/tests/queries/test_tags.js
/**
 * Executes a callback function in a "scoped" database state.  A bookmark
 * is added and tagged before the callback is called, and afterward the
 * database is cleared.
 *
 * @param aTags
 *        A bookmark will be added and tagged with this array of tags
 * @param aCallback
 *        A function that will be called after the bookmark has been tagged
 */
Executes a callback function in a "scoped" database state.  A bookmark
is added and tagged before the callback is called, and afterward the
database is cleared.

@param aTags
A bookmark will be added and tagged with this array of tags
@param aCallback
A function that will be called after the bookmark has been tagged
Executes a callback function in a " scoped " database state . A bookmark is added and tagged before the callback is called and afterward the database is cleared . @param aTags A bookmark will be added and tagged with this array of tags @param aCallback A function that will be called after the bookmark has been tagged
function doWithBookmark(aTags, aCallback) {
  addBookmark(TEST_URI);
  PlacesUtils.tagging.tagURI(TEST_URI, aTags);
  aCallback(TEST_URI);
  PlacesUtils.tagging.untagURI(TEST_URI, aTags);
  cleanDatabase(run_next_test);
}
function doWithBookmark ( aTags , aCallback ) { addBookmark ( TEST_URI ) ; PlacesUtils . tagging . tagURI ( TEST_URI , aTags ) ; aCallback ( TEST_URI ) ; PlacesUtils . tagging . untagURI ( TEST_URI , aTags ) ; cleanDatabase ( run_next_test ) ; }
Executes a callback function in a "scoped" database state.
Executes a callback function in a " scoped " database state .