Get the handler of a given node.
330412
def _get_handler(self, node_id):
        """"""
        handler = self._get_attrs(node_id).get(self.HANDLER, self._default_handler)

        # Here we make sure the handler is an instance of `BasicNodeHandler` or inherited
        # types. While generally being bad Python practice, we still need it here as an
        # invalid handler can cause IDA to crash.
        if not isinstance(handler, BasicNodeHandler):
            idaapi.msg(("Invalid handler for node {}: {}. All handlers must inherit from"
                        "`BasicNodeHandler`.").format(node_id, handler))
            handler = self._default_handler
        return handler
10574
function getHandler(x) {
			if(isPromise(x)) {
				return x._handler.join();
			}
			return maybeThenable(x) ? getHandlerUntrusted(x) : new Fulfilled(x);
		}
611370
def is_handler(cls, name, value):
        """"""
        signal_name = False
        config = None
        if callable(value) and hasattr(value, SPEC_CONTAINER_MEMBER_NAME):
                spec = getattr(value, SPEC_CONTAINER_MEMBER_NAME)
                if spec['kind'] == 'handler':
                    signal_name = spec['name']
                    config = spec['config']
        return signal_name, config
1140388
def get(self, node_id):
        
        if (self._registry[node_id].monotonic_timestamp + self.TIMEOUT) < time.monotonic():
            self._call_event_handlers(self.UpdateEvent(self._registry[node_id],
                                                       self.UpdateEvent.EVENT_ID_OFFLINE))
            del self._registry[node_id]
        return self._registry[node_id]
868214
def _get_handler_from_keyword(self, keyword):
        '''  '''
        if EXECUTION_CONTEXTS.current is None:
            raise RobotNotRunningError('Cannot access execution context')
        return EXECUTION_CONTEXTS.current.get_handler(keyword)
1173104
function getHandler(fn) {
    if (isFunction(fn) && fn.actionHandler) {
        return function (req, res, next) {
            terminateMethods.map(function (method) {
                res[method] = getWrappedResponse(res[method]);
            });
            callHandler(fn, req, res, next);
        };
    } else {
        return fn;
    }
}
71178
function getNodeLength(node) {
	switch (node.nodeType) {
		case Node.PROCESSING_INSTRUCTION_NODE:
		case Node.DOCUMENT_TYPE_NODE:
			return 0;

		case Node.TEXT_NODE:
		case Node.COMMENT_NODE:
			return node.length;

		default:
			return node.childNodes.length;
	}
}
175454
function(nodes) {
      if (nodes.length == 0) return nodes;
      var results = [], n;
      for (var i = 0, l = nodes.length; i < l; i++)
        if (!(n = nodes[i])._counted) {
          n._counted = true;
          results.push(Element.extend(n));
        }
      return Selector.handlers.unmark(results);
    }
1083131
def parse_Element(self, node):
        
        name = node.tagName
        ignores = self.ignores
        if name in ignores:
            return
        attr = "do_%s" % name
        if hasattr(self, attr):
            handlerMethod = getattr(self, attr)
            handlerMethod(node)
        else:
            self.generic_parse(node)
161628
static Node getExceptionHandler(Node n) {
    for (Node cur = n;
        !cur.isScript() && !cur.isFunction();
        cur = cur.getParent()) {
      Node catchNode = getCatchHandlerForBlock(cur);
      if (catchNode != null) {
        return catchNode;
      }
    }
    return null;
  }
1147336
def try_except_handler(self, node):
        """"""
        # List all excepted exception's names
        excepted_types = []
        for handler in node.handlers:
            if handler.type is None:
                excepted_types = None
                break

            if isinstance(handler.type, ast.Tuple):
                excepted_types.extend([exception_type for exception_type
                                       in handler.type.elts])

            else:
                excepted_types.append(handler.type)

        new_exception_list = self.ignore_exceptions

        if self.ignore_exceptions is not None:
            if excepted_types is None:
                new_exception_list = None
            else:
                new_exception_list = list(set(excepted_types +
                                              self.ignore_exceptions))

        # Set the new ignore list, and save the old one
        old_exception_handlers, self.ignore_exceptions = \
            self.ignore_exceptions, new_exception_list

        # Run recursively on all sub nodes with the new ignore list
        node.body = [self.visit(node_item) for node_item in node.body]

        # Revert changes from ignore list
        self.ignore_exceptions = old_exception_handlers
601796
def handler(self, handler_class):
        """"""
        self.handler_class = handler_class
        # we take the docstring from the handler class, not the methods
        if self.docs is None and handler_class.__doc__:
            self.docs = clean_docstring(handler_class.__doc__)
        return handler_class
1047411
def get_node(request):
    """"""
    api_major_int = 2 if d1_gmn.app.views.util.is_v2_api(request) else 1
    node_pretty_xml = d1_gmn.app.node.get_pretty_xml(api_major_int)
    return django.http.HttpResponse(node_pretty_xml, d1_common.const.CONTENT_TYPE_XML)
1363178
def handler(event):
    """"""
    def decorator(fn):
        def apply(cls):
            event.connect(fn, sender=cls)
            return cls

        fn.apply = apply
        return fn
    return decorator
3108
function(node) {
            node = Y.Dom.get(node);
            if (!node) {
            }

            return Y.Dom.getChildrenBy(node);
        }
1093247
def get_node(self, key):
        
        self._check_if_open()
        try:
            if not key.startswith('/'):
                key = '/' + key
            return self._handle.get_node(self.root, key)
        except _table_mod.exceptions.NoSuchNodeError:
            return None
61283
function(node) {
            node = Y.Dom.get(node);
            if (!node) {
                YAHOO.log('getChildren failed: invalid node argument', 'error', 'Dom');
            }

            return Y.Dom.getChildrenBy(node);
        }