Adds information to the definition list that causes the app to "phone
home" and see if there are upgrades available.

Currently added to the dashboard only. Nothing renders with this method.
It is public so it can be added by plugins.
170500
public function AddUpdateCheck() {
      if (C('Garden.NoUpdateCheck'))
         return;

      // Check to see if the application needs to phone-home for updates. Doing
      // this here because this method is always called when admin pages are
      // loaded regardless of the application loading them.
      $UpdateCheckDate = Gdn::Config('Garden.UpdateCheckDate', '');
      if (
         $UpdateCheckDate == '' // was not previous defined
         || !IsTimestamp($UpdateCheckDate) // was not a valid timestamp
         || $UpdateCheckDate < strtotime("-1 day") // was not done within the last day
      ) {
         $UpdateData = array();
         
         // Grab all of the plugins & versions
         $Plugins = Gdn::PluginManager()->AvailablePlugins();
         foreach ($Plugins as $Plugin => $Info) {
            $Name = ArrayValue('Name', $Info, $Plugin);
            $Version = ArrayValue('Version', $Info, '');
            if ($Version != '')
               $UpdateData[] = array(
                  'Name' => $Name,
                  'Version' => $Version,
                  'Type' => 'Plugin'
               );
         }
         
         // Grab all of the applications & versions
         $ApplicationManager = Gdn::Factory('ApplicationManager');
         $Applications = $ApplicationManager->AvailableApplications();
         foreach ($Applications as $Application => $Info) {
            $Name = ArrayValue('Name', $Info, $Application);
            $Version = ArrayValue('Version', $Info, '');
            if ($Version != '')
               $UpdateData[] = array(
                  'Name' => $Name,
                  'Version' => $Version,
                  'Type' => 'Application'
               );
         }

         // Grab all of the themes & versions
         $ThemeManager = new Gdn_ThemeManager;
         $Themes = $ThemeManager->AvailableThemes();
         foreach ($Themes as $Theme => $Info) {
            $Name = ArrayValue('Name', $Info, $Theme);
            $Version = ArrayValue('Version', $Info, '');
            if ($Version != '')
               $UpdateData[] = array(
                  'Name' => $Name,
                  'Version' => $Version,
                  'Type' => 'Theme'
               );
         }

         // Dump the entire set of information into the definition list (jQuery
         // will pick it up and ping the VanillaForums.org server with this info).
         $this->AddDefinition('UpdateChecks', Gdn_Format::Serialize($UpdateData));
      }
   }
1136463
public void addPoi(final Poi BLIP) {
        if (pois.keySet().contains(BLIP.getName())) {
            updatePoi(BLIP.getName(), BLIP.getLocation());
        } else {
            pois.put(BLIP.getName(), BLIP);
        }
        checkForBlips();
    }
688962
def _addappt(self, iden, appt):
        '''
        
        '''
        if appt.nexttime:
            heapq.heappush(self.apptheap, appt)
        self.appts[iden] = appt
        if self.apptheap and self.apptheap[0] is appt:
            self._wake_event.set()
18866
def add_plugin(self, plugin, call):
        
        meth = getattr(plugin, call, None)
        if meth is not None:
            self.plugins.append((plugin, meth))
1371111
private static boolean addCallback(String applicationId, DelayedCallback callback) {
		boolean isFirst = false;
		List<DelayedCallback> list = BACKLOG.get(applicationId);
		if (null == list) {
			list = new ArrayList<DelayedCallback>();
			BACKLOG.put(applicationId, list);
			isFirst = true;
		}
		list.add(callback);
		return isFirst;
	}
289122
protected function setDefinitions()
    {
        //  Define where we should look
        $aDefinitionLocations   = [];
        $aDefinitionLocations[] = NAILS_COMMON_PATH . 'config/app_notifications.php';

        foreach (Components::modules() as $oModule) {
            $aDefinitionLocations[] = $oModule->path . $oModule->moduleName . '/config/app_notifications.php';
        }

        $aDefinitionLocations[] = NAILS_APP_PATH . 'application/config/app_notifications.php';

        //  Find definitions
        foreach ($aDefinitionLocations as $sPath) {
            $this->loadDefinitions($sPath);
        }

        //  Put into a vague order
        ksort($this->notifications);
    }
784460
def add_plate(self, plate_definition):
        
        values = self.get_plate_values(plate_definition)

        # TODO: We should also be checking that the plate is defined over all of the values of the parent plate
        self.plates[plate_definition.plate_id] = Plate(
            plate_id=plate_definition.plate_id,
            meta_data_id=plate_definition.meta_data_id,
            values=values,
            parent_plate=self.plates[plate_definition.parent_plate] if plate_definition.parent_plate else None)

        logging.debug("Added plate: {}".format(self.plates[plate_definition.plate_id]))
1079051
def add_service(self, service):
        
        if (self.service is None):
            self.service = service
        elif (isinstance(self.service, dict)):
            self.service = [self.service, service]
        else:
            self.service.append(service)
601516
def add_future(self, future, callback):
        
        assert is_future(future)
        callback = stack_context.wrap(callback)
        future.add_done_callback(
            lambda future: self.add_callback(callback, future))
359939
def add_callback(self, func):
        
        if func is None: return
        func_list = to_list(func)

        if not hasattr(self, 'callback_list'):
            self.callback_list = func_list
        else:
            self.callback_list.extend(func_list)
924513
def AddMemberDefinition(self, member_definition):
    
    self.members.append(member_definition)
    member_definition.family_definition = self
1164411
def DEFINE_list(self, name, default, help, constant=False):
    """"""
    self.AddOption(
        type_info.List(
            name=name,
            default=default,
            description=help,
            validator=type_info.String()),
        constant=constant)
355591
def metadata_add_description(self):
        
        service_description = {}
        if (self.args.json):
            service_description = json.loads(self.args.json)
        if (self.args.url):
            if "url" in service_description:
                raise Exception("json service description already contains url field")
            service_description["url"] = self.args.url
        if (self.args.description):
            if "description" in service_description:
                raise Exception("json service description already contains description field")
            service_description["description"] = self.args.description
        metadata = load_mpe_service_metadata(self.args.metadata_file)
        # merge with old service_description if necessary
        if ("service_description" in metadata):
            service_description = {**metadata["service_description"], **service_description}
        metadata.set_simple_field("service_description", service_description)
        metadata.save_pretty(self.args.metadata_file)
763146
public void add(T method)
    {
        // check for overridden method
        if (isOverrideMethod(method)) {
            return;
        }

        // Add to the list of managed methods
        _methods.put(method.getName() + method.getArgTypes(), method);

        // Ensure that all added methods have a unique index
        Object nameValue = _nameMap.get(method.getName());
        if (nameValue == null)
        {
            // first method with this name, considered unique (for now)
            _nameMap.put(method.getName(), method);
        }
        else
        {
            int nextIndex;
            if (nameValue instanceof AptMethod)
            {
                // 2nd method with this name, add index to original and start indexing
                ((AptMethod)nameValue).setIndex(0);
                nextIndex = 1;
            }
            else
            {
                // 3rd (or later) method with this name, continue indexing
                nextIndex = ((Integer)nameValue).intValue();
            }

            method.setIndex(nextIndex++);
            _nameMap.put(method.getName(), nextIndex);
        }
    }
515817
function _addExtension(category, callback) {
        if (!callback || typeof callback !== "function") {
            console.error("Attempt to add FileTreeView", category, "extension without a callback function");
            return;
        }
        var callbackList = _extensions.get(category);
        if (!callbackList) {
            callbackList = Immutable.List();
        }
        callbackList = callbackList.push(callback);
        _extensions = _extensions.set(category, callbackList);
    }
971062
@Override
  public void addToList() {
    meldungStart();
    if (Config.getStop()) {
      meldungThreadUndFertig();
    } else {
      if (CrawlerTool.loadLongMax()) {
        addCategories();
        meldungAddMax(listeThemen.size());

        for (int t = 0; t < getMaxThreadLaufen(); ++t) {
          Thread th = new CategoryLoader();
          th.setName(getSendername() + t);
          th.start();
        }

      } else {
        addTage();
        meldungAddMax(listeThemen.size());
        for (int t = 0; t < getMaxThreadLaufen(); ++t) {
          Thread th = new ThemaLaden();
          th.setName(getSendername() + t);
          th.start();
        }
      }
    }
  }
795580
def _add_request_entry(self, entry=()):
        
        if not self._lookup_request_entry(entry):
            self.request_entry.append(entry)