Gather all "new" |Node| or |Element| objects.

        See the main documentation on module |devicetools| for further
        information.
775767
def extract_new(cls) -> DevicesTypeUnbound:
        
        devices = cls.get_handlerclass()(*_selection[cls])
        _selection[cls].clear()
        return devices
817916
function all(sl, context) {
    var nodeList;
    if (supportQuerySelector && !nes.debug) {
      try {
        nodeList = toArray((context || doc).querySelectorAll(sl));
      } catch (e) {
        nodeList = get(sl, context);
      }
    } else {
      nodeList = get(sl, context);
    }
    return nodeList;
  }
455778
function gather() {
  var codes = {}
  var key

  for (key in doctypes) {
    codes[cleanDoctype(key)] = doctypes[key]
  }

  return codes
}
817932
def visit_dictcomp(self, node, parent):
        """"""
        newnode = nodes.DictComp(node.lineno, node.col_offset, parent)
        newnode.postinit(
            self.visit(node.key, newnode),
            self.visit(node.value, newnode),
            [self.visit(child, newnode) for child in node.generators],
        )
        return newnode
350331
def get_nodes(self, request, *args, **kwargs):
        
        # ListSerializerMixin.list returns a serializer object
        return (self.list(request, *args, **kwargs)).data
360922
def ready(self):
        
        from .models import LayerExternal
        from nodeshot.core.layers.views import LayerNodeListMixin

        def get_nodes(self, request, *args, **kwargs):
            try:
                external = self.layer.external
            except LayerExternal.DoesNotExist:
                external = False
            # override view get_nodes method if we have a custom one
            if external and self.layer.is_external and hasattr(external, 'get_nodes'):
                return external.get_nodes(self.__class__.__name__, request.query_params)
            # otherwise return the standard one
            else:
                return (self.list(request, *args, **kwargs)).data

        LayerNodeListMixin.get_nodes = get_nodes
941699
def nodes(self) -> iter:
        """"""
        yield from (elem for elem, subs in self.inclusions.items() if subs == ())
1242562
def get_nodes_by_selector(self, selector, not_selector=None):
        
        nodes = self.parsed(selector)

        if not_selector is not None:
            nodes = nodes.not_(not_selector)

        return nodes
1217147
def gather(self, analysis, node):
        "'"
        assert issubclass(analysis, Analysis)
        a = analysis()
        a.attach(self)
        return a.run(node)
343043
def nodes_in(self, name) -> iter:
        """"""
        yield from (node for node in self.all_in(name) if self.is_node(node))
1099062
function getTextNodes(el) {
  el = el || document.body

  var doc = el.ownerDocument || document
    , walker = doc.createTreeWalker(el, NodeFilter.SHOW_TEXT, null, false)
    , textNodes = []
    , node

  while (node = walker.nextNode()) {
    textNodes.push(node)
  }
  return textNodes
}
707125
def newDevices(self, interface_id, dev_descriptions):
        """"""
        LOG.debug("RPCFunctions.newDevices: interface_id = %s, dev_descriptions = %s" % (
            interface_id, str(dev_descriptions)))
        remote = interface_id.split('-')[-1]
        if remote not in self._devices_raw:
            self._devices_raw[remote] = []
        if remote not in self._devices_raw_dict:
            self._devices_raw_dict[remote] = {}
        for d in dev_descriptions:
            self._devices_raw[remote].append(d)
            self._devices_raw_dict[remote][d['ADDRESS']] = d
        self.saveDevices(remote)
        self.createDeviceObjects(interface_id)
        if self.systemcallback:
            self.systemcallback('newDevices', interface_id, dev_descriptions)
        return True
1328173
def new
      @element = Humpyard::config.element_types[params[:type]].new(
        :page_id => params[:page_id], 
        :container_id => params[:container_id].to_i > 0 ? params[:container_id].to_i : nil,
        :page_yield_name => params[:yield_name].blank? ? 'main' : params[:yield_name],
        :shared_state => 0)
      
      authorize! :create, @element.element 
      
      @element_type = params[:type]
      @prev = Humpyard::Element.find_by_id(params[:prev_id])
      @next = Humpyard::Element.find_by_id(params[:next_id])
      
      render :partial => 'edit'
    end
836920
def gather!
      ::Knowledge::Initializer.new(
        adapters: enabled_adapters,
        params: additionnal_params,
        setter: setter,
        variables: variables
      ).run
    end
1355274
def node_from_elem(elem, nodefactory=Node, lazy=()):
    
    children = list(elem)
    lineno = getattr(elem, 'lineno', None)
    if not children:
        return nodefactory(elem.tag, dict(elem.attrib), elem.text,
                           lineno=lineno)
    if striptag(elem.tag) in lazy:
        nodes = (node_from_elem(ch, nodefactory, lazy) for ch in children)
    else:
        nodes = [node_from_elem(ch, nodefactory, lazy) for ch in children]
    return nodefactory(elem.tag, dict(elem.attrib), nodes=nodes, lineno=lineno)
256115
def get_nodes(self, node_id=None, **kwargs):
        
        return self.get_elements(Node, elem_id=node_id, **kwargs)
1325912
def _gather_event_handlers(self):
        
        self._extract_event_handlers_from_container(self)
        for module in self.modules:
            self._extract_event_handlers_from_container(module)