Lines Matching refs:cls
344 def __new__(cls, *args, **kwargs): argument
352 return base_cls.__new__(cls, *args)
366 cls = collections.namedtuple(name, field_names)
367 cls.struct_fmt = ''.join(ty for name, ty in fields)
368 cls.struct_size = struct.calcsize(cls.struct_fmt)
369 def unpack_from(cls, buf, offset=0): argument
370 unpacked = struct.unpack_from(cls.struct_fmt, buf, offset)
371 return cls.__new__(cls, *unpacked)
372 cls.unpack_from = classmethod(unpack_from)
373 return cls
671 def parse_struct(cls, fmt, offset, error_msg): argument
673 return cls._make(struct.unpack_from(fmt, buf, offset))
937 def extract_dex_string(cls, buf, offset=0): argument
943 def extract_uleb128(cls, buf, offset=0): argument
998 def enumerate_dex_strings_buf(cls, buf, offset=0, data_offset=None): argument
1000 header = cls.Header.unpack_from(buf, offset=offset)
1012 StringId = cls.StringId
1023 offset += cls.extract_uleb128(buf, offset)[1]
1026 yield cls.extract_dex_string(buf, offset)
1030 def enumerate_dex_strings_apk(cls, apk_file_path): argument
1032 for name in cls.generate_classes_dex_names():
1036 for s in cls.enumerate_dex_strings_buf(dex_file_content):
1043 def is_vdex_file(cls, vdex_file_path): argument
1098 def enumerate_dex_strings_vdex_buf(cls, buf): argument
1109 VdexHeader = cls.VdexHeader0
1111 VdexHeader = cls.VdexHeader1
1113 VdexHeader = cls.VdexHeader16
1115 VdexHeader = cls.VdexHeader19
1137 offset += cls.DexSectionHeader.struct_size
1154 dex_header = cls.Header.unpack_from(buf, offset)
1156 for s in cls.enumerate_dex_strings_buf(buf, offset):
1164 def enumerate_dex_strings_vdex(cls, vdex_file_path): argument
1166 return cls.enumerate_dex_strings_vdex_buf(vdex_file.read())
1170 def enumerate_dex_strings(cls, path): argument
1173 if cls.is_vdex_file(path):
1225 def _normalize_tag(cls, tag): argument
1227 tag = cls._TAG_ALIASES.get(tag, tag)
1228 if tag not in cls.TAGS:
1267 def is_tag_visible(cls, from_tag, to_tag): argument
1268 return to_tag in cls._TAG_VISIBILITY[from_tag]
1481 def load_from_path_or_default(cls, path): argument
1681 def create_vndk_dir_suffix(cls, version): argument
1687 def create_vndk_sp_dir_name(cls, version): argument
1689 return 'vndk-sp' + cls.create_vndk_dir_suffix(version)
1693 def create_vndk_dir_name(cls, version): argument
1695 return 'vndk' + cls.create_vndk_dir_suffix(version)
1699 def extract_version_from_name(cls, name): argument
1711 def extract_path_component(cls, path, index): argument
1726 def extract_version_from_path(cls, path): argument
1728 component = cls.extract_path_component(path, 3)
1731 return cls.extract_version_from_name(component)
1735 def is_in_vndk_dir(cls, path): argument
1737 component = cls.extract_path_component(path, 3)
1747 def is_in_vndk_sp_dir(cls, path): argument
1749 component = cls.extract_path_component(path, 3)
1756 def create_vndk_search_paths(cls, lib_dir, version): argument
1758 vndk_sp_name = cls.create_vndk_sp_dir_name(version)
1759 vndk_name = cls.create_vndk_dir_name(version)
1768 def create_default(cls): argument
1776 def create_from_version(cls, version): argument
1784 def create_from_dirs(cls, system_dirs, vendor_dirs): argument
1795 version = cls.extract_version_from_name(name)
1814 return VNDKLibDir(cls.sorted_version(versions))
1843 def _get_property(cls, property_file, name): argument
1852 def get_ro_vndk_version(cls, vendor_dirs): argument
1858 result = cls._get_property(
1868 def sorted_version(cls, versions): argument
2888 def compute_deps_closure(cls, root_set, is_excluded, argument
2892 return cls._compute_closure(root_set, is_excluded, get_successors)
2896 def compute_users_closure(cls, root_set, is_excluded, argument
2900 return cls._compute_closure(root_set, is_excluded, get_successors)