Return ``True`` if the container can be safely extracted,
        that is, if all its entries are safe, ``False`` otherwise.

        :rtype: bool
        :raises: same as :func:`~aeneas.container.Container.entries`
492257
def is_safe(self):
        
        self.log(u"Checking if this container is safe")
        for entry in self.entries:
            if not self.is_entry_safe(entry):
                self.log([u"This container is not safe: found unsafe entry '%s'", entry])
                return False
        self.log(u"This container is safe")
        return True
423284
def is_removable(self, device):
        """"""
        if not self.is_handleable(device):
            return False
        if device.is_filesystem:
            return device.is_mounted
        if device.is_crypto:
            return device.is_unlocked
        if device.is_partition_table or device.is_drive:
            return any(self.is_removable(dev)
                       for dev in self.get_all_handleable()
                       if _is_parent_of(device, dev))
        return False
326767
def is_alive(self, container: Container) -> bool:
        
        uid = container.uid
        r = self.__api.get('containers/{}/alive'.format(uid))

        if r.status_code == 200:
            return r.json()

        if r.status_code == 404:
            raise KeyError("no container found with given UID: {}".format(uid))

        self.__api.handle_erroneous_response(r)
728682
def filter(self, entries):
        
        return [
            entry for entry in entries
            if self.split(entry)[0] in self.declarations
        ]
1163674
def _is_pickle_valid(self):
        
        if not os.path.exists(self._pickle_file):
            return False
        else:
            file_mtime = os.path.getmtime(self.logfile)
            pickle_mtime = os.path.getmtime(self._pickle_file)
            if file_mtime > pickle_mtime:
                return False
        return True
474017
public boolean hasHandled() {
    for(int i = 0; i < getNumEntries(); i++) {
      boolean handled = getEntry(i).hasHandled();
      if(handled) {
        return true;
      }
    }
    return false;
  }
113895
def safe_get(data, key_list):
        '''  '''
        for key in key_list:
            data = data.get(key, {})
        return data if data else 'plugin_failed'
794150
def is_valid(self):
        

        valid = True
        if not self.sons:
            valid = False
        else:
            for son in self.sons:
                if isinstance(son, DependencyNode) and not son.is_valid():
                    self.configuration_errors.extend(son.configuration_errors)
                    valid = False
        return valid
252027
def isPeBounded(self):
        
        boundImportsDir = self.ntHeaders.optionalHeader.dataDirectory[consts.BOUND_IMPORT_DIRECTORY]
        if boundImportsDir.rva.value and boundImportsDir.size.value:
            return True
        return False
908240
def revocable(self):
        
        if 'Revocable' in self._signature.subpackets:
            return bool(next(iter(self._signature.subpackets['Revocable'])))
        return True
372403
def safe_to_exit(self, *args, **kargs):
        
        if len(self.value) == self.instance_num:
            return True
        return False
1274819
def is_hidden_container(self, key, val):
        

        if key in ("layers", "classes", "styles", "symbols", "labels",
                   "outputformats", "features", "scaletokens",
                   "composites") and isinstance(val, list):
            return True
        else:
            return False
430594
def contains_container(self, path):
        
        path = make_path(path)
        try:
            self.get_container(path)
            return True
        except KeyError:
            return False
116020
def _verify_safe(self, this):
        """"""
        context = self._context
        if context & contexts.FAIL_NEXT:
            return False
        if context & contexts.WIKILINK_TITLE:
            if this == "]" or this == "{":
                self._context |= contexts.FAIL_NEXT
            elif this == "\n" or this == "[" or this == "}" or this == ">":
                return False
            elif this == "<":
                if self._read(1) == "!":
                    self._context |= contexts.FAIL_NEXT
                else:
                    return False
            return True
        elif context & contexts.EXT_LINK_TITLE:
            return this != "\n"
        elif context & contexts.TEMPLATE_NAME:
            if this == "{":
                self._context |= contexts.HAS_TEMPLATE | contexts.FAIL_NEXT
                return True
            if this == "}" or (this == "<" and self._read(1) == "!"):
                self._context |= contexts.FAIL_NEXT
                return True
            if this == "[" or this == "]" or this == "<" or this == ">":
                return False
            if this == "|":
                return True
            if context & contexts.HAS_TEXT:
                if context & contexts.FAIL_ON_TEXT:
                    if this is self.END or not this.isspace():
                        return False
                elif this == "\n":
                    self._context |= contexts.FAIL_ON_TEXT
            elif this is self.END or not this.isspace():
                self._context |= contexts.HAS_TEXT
            return True
        elif context & contexts.TAG_CLOSE:
            return this != "<"
        else:
            if context & contexts.FAIL_ON_EQUALS:
                if this == "=":
                    return False
            elif context & contexts.FAIL_ON_LBRACE:
                if this == "{" or (self._read(-1) == self._read(-2) == "{"):
                    if context & contexts.TEMPLATE:
                        self._context |= contexts.FAIL_ON_EQUALS
                    else:
                        self._context |= contexts.FAIL_NEXT
                    return True
                self._context ^= contexts.FAIL_ON_LBRACE
            elif context & contexts.FAIL_ON_RBRACE:
                if this == "}":
                    self._context |= contexts.FAIL_NEXT
                    return True
                self._context ^= contexts.FAIL_ON_RBRACE
            elif this == "{":
                self._context |= contexts.FAIL_ON_LBRACE
            elif this == "}":
                self._context |= contexts.FAIL_ON_RBRACE
            return True
1010126
def check_all(self, all_entries, *args, **kwargs):
        
        all_overlaps = 0
        while True:
            try:
                user_entries = all_entries.next()
            except StopIteration:
                return all_overlaps
            else:
                user_total_overlaps = self.check_entry(
                    user_entries, *args, **kwargs)
                all_overlaps += user_total_overlaps
354797
def _in_version(self, *versions):
        ""
        for version in versions:
            if (self._version == version
                or (isinstance(self._version, collections.Container) 
                    and version in self._version)):
                return True
        return False
436544
public boolean hasUnhandled() {
    for(int i = 0; i < getNumEntries(); i++) {
      boolean handled = getEntry(i).hasUnhandled();
      if(handled) {
        return true;
      }
    }
    return false;
  }