Active or desactive page indexation using robots meta tag

@method setCrawling
@param {boolean} index
@return {boolean} follow
548101
function(index, follow) {
            if (_.isNull(follow)) follow = index;
            var value = "";
            value = index ? "index" : "noindex";
            value =  value + "," + (follow ? "follow" : "nofollow");
            this.meta("robots", value);
            return this;
        }
171629
function interceptIndex(request, response, next) {
	if (args.index === true && request.path === '/') {
		request.path = '/index.json';
	}
	return next();
}
668515
function(index) {
        links[currentTrack].classList.remove('active');
        currentTrack = index;
        links[currentTrack].classList.add('active');
        wavesurfer.load(links[currentTrack].href);
    }
574258
function setActivePage() {
		
			$('.page').removeClass('active').hide();
			var path = $.address.path();
			path = path.slice(1, path.length);
			path = giveDetailUrl() != -1 ? portfolioKeyword : path;
			if(path == "") {  // if hash tag doesnt exists - go to first page
				var firstPage = $('.vs-nav li').first().find('a').attr('href');
				path = firstPage.slice(2,firstPage.length);
				$.address.path(path);
				return false;
				}
			
			// show page
			$('#'+ path).fadeIn();
			$('.page.active').hide();
			$('#'+ path).addClass('active');
			setCurrentMenuItem();
			
			if(path.indexOf(portfolioKeyword) != -1) {
				setTimeout(function() { setMasonry(); }, 100);
			} 
			$("body").scrollTop(0);

	}
1241805
function(index, event) {
        this.index = index;

        var rows = this.element.find('li');

        rows
            .removeClass('is-active')
            .find('a')
                .aria('selected', false);

        // Select
        if (index >= 0) {
            if (this.items[index]) {
                var item = this.items[index];

                rows.eq(index)
                    .addClass('is-active')
                    .find('a')
                        .aria('selected', true);

                this.input.val(item.title);

                this.fireEvent(event || 'select', [item, index]);
            }

        // Reset
        } else {
            this.input.val(this.term);

            this.fireEvent('reset');
        }
    }
17185
function(mode, index) {
			var keyModes = this._keyModes;
			if (index !== undefined) {
				keyModes.splice(index, 0, mode);
			} else {
				keyModes.push(mode);
			}
			//TODO: API needed for this
			if (mode._modeAdded) {
				mode._modeAdded();
			}
		}
600532
def set_index(self, index):
        
        item = index.internalPointer()
        self.actionunit = item.internal_data()
        self.setEnabled(bool(self.actionunit.status.traceback))
1175069
function( item, index ) {
        $.console.assert(item, "[World.setItemIndex] item is required");
        $.console.assert(index !== undefined, "[World.setItemIndex] index is required");

        var oldIndex = this.getIndexOfItem( item );

        if ( index >= this._items.length ) {
            throw new Error( "Index bigger than number of layers." );
        }

        if ( index === oldIndex || oldIndex === -1 ) {
            return;
        }

        this._items.splice( oldIndex, 1 );
        this._items.splice( index, 0, item );
        this._needsDraw = true;

        /**
         * Raised when the order of the indexes has been changed.
         * @event item-index-change
         * @memberOf OpenSeadragon.World
         * @type {object}
         * @property {OpenSeadragon.World} eventSource - A reference to the World which raised the event.
         * @property {OpenSeadragon.TiledImage} item - The item whose index has
         * been changed
         * @property {Number} previousIndex - The previous index of the item
         * @property {Number} newIndex - The new index of the item
         * @property {?Object} userData - Arbitrary subscriber-defined object.
         */
        this.raiseEvent( 'item-index-change', {
            item: item,
            previousIndex: oldIndex,
            newIndex: index
        } );
    }
1032112
function (index) {
            var self = this;
            if (typeof index === 'number') {
                if (index >= self.length) {
                    return null;
                } else {
                    return new Node(self[index]);
                }
            } else {
                return new Node(index);
            }
        }
198569
function queryIndex(query) {
  try {
    if (query.length) {
      var results = index.search(query);
      if (results.length === 0) {
        // Add a relaxed search in the title for the first word in the query
        // E.g. if the search is "ngCont guide" then we search for "ngCont guide titleWords:ngCont*"
        var titleQuery = 'titleWords:*' + query.split(' ', 1)[0] + '*';
        results = index.search(query + ' ' + titleQuery);
      }
      // Map the hits into info about each page to be returned as results
      return results.map(function(hit) { return pages[hit.ref]; });
    }
  } catch(e) {
    // If the search query cannot be parsed the index throws an error
    // Log it and recover
    console.log(e);
  }
  return [];
}
398303
function crawLink($,result,linkTag, callback) {
      var link = $(linkTag).attr('href');
      var parentUrl = result.url;

      if (link) {

          var rel =  $(linkTag).attr('rel');

          if (result.linkTypes.indexOf(rel) > 0) {
              var linkUri = URI.linkToURI(parentUrl, link);

              pm.crawlLink(parentUrl, linkUri, null, null, function(){
                addLinkToQueue(result, parentUrl, linkUri, null, null, callback);
              });
          }
          else {
            callback();
          }
      }
      else {
        callback();
      }
}
1301752
public void selectByIndex(int index) {
        getDispatcher().beforeSelect(this, index);
        
        new Select(getElement()).selectByIndex(index);
        if (Config.getBoolConfigProperty(ConfigProperty.ENABLE_GUI_LOGGING)) {
            logUIActions(UIActions.SELECTED, Integer.toString(index));
        }
        
        getDispatcher().afterSelect(this, index);
    }
266674
public StateVertex crawlIndex() {
		LOG.debug("Setting up vertex of the index page");

		if (basicAuthUrl != null) {
			browser.goToUrl(basicAuthUrl);
		}

		browser.goToUrl(url);

		// Run url first load plugin to clear the application state
		plugins.runOnUrlFirstLoadPlugins(context);

		plugins.runOnUrlLoadPlugins(context);
		StateVertex index = vertexFactory.createIndex(url.toString(), browser.getStrippedDom(),
				stateComparator.getStrippedDom(browser), browser);
		Preconditions.checkArgument(index.getId() == StateVertex.INDEX_ID,
				"It seems some the index state is crawled more than once.");

		LOG.debug("Parsing the index for candidate elements");
		ImmutableList<CandidateElement> extract = candidateExtractor.extract(index);

		plugins.runPreStateCrawlingPlugins(context, extract, index);

		candidateActionCache.addActions(extract, index);

		return index;

	}
265419
function(index) {
            this.removeChild(YUD.getElementsByClassName(this.CLASSES.PANEL, this.CONFIG.ITEM_WRAPPER_TAG_NAME, this)[index]); 
            var aNewPanels = []; 
            var nLength = this._panels.length;
            for(var i=0;i<nLength;i++) {
                if(i !== index) {
                    aNewPanels.push(this._panels[i]);
                }
            }
            this._panels = aNewPanels;
            var t= YAHOO.lang.later(0, this, function(){this._fixTabIndexes();this.fireEvent(stateChangedEvent);});
        }
562641
public void setSlidingDrawer(int index, int status){
		if(config.commandLogging){
			Log.d(config.commandLoggingTag, "setSlidingDrawer("+index+", "+status+")");
		}
		
		setSlidingDrawer(waiter.waitForAndGetView(index, SlidingDrawer.class), status);
	}
477885
function( index ) {
			var cloneChildren = this.children.splice( index, this.children.length - index ),
				clone = this.clone();

			for ( var i = 0; i < cloneChildren.length; ++i )
				cloneChildren[ i ].parent = clone;

			clone.children = cloneChildren;

			if ( cloneChildren[ 0 ] )
				cloneChildren[ 0 ].previous = null;

			if ( index > 0 )
				this.children[ index - 1 ].next = null;

			this.parent.add( clone, this.getIndex() + 1 );

			return clone;
		}
517254
function scrollToIndex(index) {
    var duration = 400;
    var start = window.pageYOffset;
    var end = index * window.innerHeight;
    var amount = end - start;
    var startTime = +new Date();

    var easing = function easing(k) {
      return -0.5 * (Math.cos(Math.PI * k) - 1);
    };

    var step = function step(value /* , percent */) {
      window.scrollTo(0, value);
    };

    var complete = function complete() {
      isScrolling = false;
    };

    var looper = function looper() {
      var now = +new Date();
      var remainingTime = startTime + duration - now;
      var percent = 1 - (remainingTime / duration || 0);

      // Abort if already past 100%.
      if (percent >= 1) {
        // Make sure it always finishes with 1.
        step(end, 1);
        complete();
        return;
      }

      // Apply easing.
      percent = easing(percent);

      // Tick.
      step(start + amount * percent, percent);

      // Request animation frame.
      requestAnimationFrame(looper);
    };

    isScrolling = true;
    requestAnimationFrame(looper);
  }