Capture all added methods and either leave the implementation in place or
 add them to the protocol description.
180946
def method_added(methodname)
      methodname = methodname.to_s
      if specification? and methodname !~ /^__protocol_check_/
        protocol_check = instance_method(methodname)
        parser = MethodParser.new(self, methodname)
        if parser.complex?
          define_method("__protocol_check_#{methodname}", protocol_check)
          understand methodname, protocol_check.arity, parser.block_arg?
        else
          understand methodname, protocol_check.arity, parser.block_arg?
        end
        remove_method methodname
      else
        super
      end
    end
487089
def module_include(base, mod)
      old_methods = {}

      mod.instance_methods.each do |sym|
        old_methods[sym] = base.instance_method(sym) if base.method_defined?(sym)
      end

      mod.instance_methods.each do |sym|
        method = mod.instance_method(sym)
        base.send(:define_method, sym, method)
      end

      yield
    ensure
      mod.instance_methods.each do |sym|
        base.send(:undef_method, sym) if base.method_defined?(sym)
      end
      old_methods.each do |sym, method|
        base.send(:define_method, sym, method)
      end
    end
1184677
public void addMethodInfo(final MethodInfo methodInfo) {
        ArgUtils.notNull(methodInfo, "methodInfo");
        
        removeMethodInfo(methodInfo.getMethodName());
        this.methodInfos.add(methodInfo);
    }
920531
def collect_methods
            list = @context.method_list
            unless @options.show_all
                list = list.find_all {|m| m.visibility == :public || m.visibility == :protected || m.force_documentation }
            end
            @methods = list.collect {|m| HtmlMethod.new(m, self, @options) }
        end
185376
def add_method(self, pattern):
        """"""
        def wrap(f):
            def frozen_function(class_instance, f):
                def _(pattern, *args, **kwargs):
                    return f(class_instance, pattern, *args, **kwargs)

                return _

            self.functions.append((frozen_function(self, f), pattern))
            return f

        return wrap
1007257
def track_method_call(definition, name, node)
      method   = definition.lookup(definition.method_call_type, name)
      current  = current_scope
      location = {
        :line   => node.line,
        :column => node.column,
        :file   => node.file
      }

      # Add the call to the current scope if we're dealing with a writable
      # method definition.
      if current.respond_to?(:calls) and !current.frozen?
        current.calls.push(
          MethodCallInfo.new(location.merge(:definition => method))
        )
      end

      # Add the caller to the called method, this allows for inverse lookups.
      unless method.frozen?
        method.callers.push(
          MethodCallInfo.new(location.merge(:definition => definition))
        )
      end
    end
1069719
private void addMethodDefTriples(URIReference objURI,
                                     DOReader reader,
                                     Set<Triple> set)
            throws ResourceIndexException {
        try {
            for (MethodDef element : getAbstractMethods(reader)) {
                add(objURI, MODEL.DEFINES_METHOD, element.methodName, set);
            }
        } catch (ResourceIndexException e) {
            throw e;
        } catch (Exception e) {
            throw new ResourceIndexException("Error adding method def "
                    + "triples", e);
        }
    }
66502
function appendMethods(list, addition) {
  for (var i = 0; i < addition.length; i++) {
    var method = addition[i];
    if (list.indexOf(method) === -1) {
      list.push(method);
    }
  }
}
34200
def method_wrapper(m):
    """"""

    if m.is_simple:
        def simple_method(self):
            """TODO: no docstring!"""
            return apply_transform(
                self.__service__, m.output_transform,
                grpc_call(self.__service__, m, unwrap(self)))

        return simple_method

    elif m.input_transform is not None:
        def transform_method(self, *args, **kwargs):
            """TODO: no docstring!"""
            request = m.input_transform(self, *args, **kwargs)
            return apply_transform(
                self.__service__, m.output_transform,
                grpc_call(self.__service__, m, request))

        return transform_method

    elif m.static:
        def static_method(cls, *args, **kwargs):
            """TODO: no docstring!"""
            request = make_static_request(m, *args, **kwargs)
            return apply_transform(
                cls.__stub__(__server__), m.output_transform,
                grpc_call(cls.__stub__(__server__), m, request))

        return static_method

    else:
        def request_method(self, *args, **kwargs):
            """TODO: no docstring!"""
            request = make_request(self, m, *args, **kwargs)
            return apply_transform(
                self.__service__, m.output_transform,
                grpc_call(self.__service__, m, request))

        return request_method
844677
protected void addAllLocalisationsForCleanUp()
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(tc, "addAllLocalisationsForCleanUp");

        _protoRealization.addAllLocalisationsForCleanUp(_singleServer);

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(tc, "addAllLocalisationsForCleanUp");
    }
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);
        }
    }
378025
def add_methods(self, names, methods):
        
        if isinstance(names, string_types):
            names = [names]
            methods = [methods]
        for name,method in zip(names, methods):
            setattr(self, name, types.MethodType(method, self))
801170
function() {
            var newMethods = $._.$.iot.extraCAMethods();
            $._.$.log && $._.$.log.debug('Adding CA methods:' +
                                         JSON.stringify(Object
                                                        .keys(newMethods)));
            myUtils.mixin($.handler, newMethods, true);
        }
458360
public function addMethod(Method $method): void
    {
        $this->methods[(string) $method->getFqsen()] = $method;
    }
1031360
def add_methods(methods_to_add):
        '''  '''
        for i in methods_to_add:
            try:
                Generator.add_method(*i)
            except Exception as ex:
                raise Exception('issue adding {} - {}'.format(repr(i), ex))
813830
def new_method_added(mod, meth)
      self.current_module = mod

      store[:temp] ||= {}
      METHODS.each do |e|
        store[e][meth.to_s] = store[:temp][e] if store[:temp][e]
      end
      if store[:temp][:option]
        (store[:options][meth.to_s] ||= {}).merge! store[:temp][:option]
      end
      during_new_method_added mod, meth
      store[:temp] = {}

      if SCRAPEABLE_METHODS.any? {|m| has_inspector_method?(meth, m) }
        set_arguments(mod, meth)
      end
    end
848093
public function addMethod($method, $callback)
        {
            $this->traceInternal("Added '" . $method . "' to " . __METHOD__ . "()");
            $this->callbacks[$method] = $callback;
        }