// File: bluesky466[P]ResourcesParser/ResourcesParserInterpreter.cpp
// Function: ResourcesParserInterpreter::parserId(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
void ResourcesParserInterpreter::parserId(const string& id) {
	uint32_t uid;
	if(0 == strncmp(id.c_str(), "0x", 2)) {
		istringstream(id)>>hex>>uid;
	} else {
		istringstream(id)>>uid;
	}
	vector<ResourcesParser::ResTableTypePtr> resTableTypePtrs = mParser->getResTableTypesForId(uid);
	if(resTableTypePtrs.empty()) {
		cout <<"can't find resource for " <<id <<endl;
	} else {
		ResourcesParser::PackageResourcePtr pPackage = mParser->getPackageResouceForId(uid);
		uint32_t typeId = TYPE_ID(uid);
		uint32_t entryId = ENTRY_ID(uid);
		string type = ResourcesParser::getStringFromResStringPool(pPackage->pTypes, typeId-1);
		for(ResourcesParser::ResTableTypePtr pResTableType : resTableTypePtrs) {
			ResTable_entry* pEntry = pResTableType->entries[entryId];
			Res_value* pValue = pResTableType->values[entryId];
			if(nullptr != pEntry) {
				cout <<getConfigDirectory(pResTableType->header.config, type) << " : ";
				parserEntry(uid, pPackage->pKeys, pEntry, pValue, type, "");
				cout <<endl;
			}
		}
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x480, %rsp            # imm = 0x480
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x420(%rbp)
movq -0x10(%rbp), %rdi
callq 0x30f0
movq %rax, %rdi
leaq 0x14259(%rip), %rsi     # 0x1a12a
movl $0x2, %edx
callq 0x3130
movl %eax, %ecx
xorl %eax, %eax
cmpl %ecx, %eax
jne 0x5f61
movq -0x10(%rbp), %rsi
leaq -0x198(%rbp), %rdi
movq %rdi, -0x430(%rbp)
movl $0x8, %edx
callq 0x3420
movq -0x430(%rbp), %rdi
leaq 0xbc3(%rip), %rsi       # 0x6ad0
callq 0x6b30
movq %rax, -0x428(%rbp)
jmp 0x5f1b
movq -0x428(%rbp), %rdi
leaq -0x14(%rbp), %rsi
callq 0x6b00
jmp 0x5f2d
leaq -0x198(%rbp), %rdi
callq 0x3120
jmp 0x5fc0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1a0(%rbp)
movl %eax, -0x1a4(%rbp)
leaq -0x198(%rbp), %rdi
callq 0x3120
jmp 0x641c
movq -0x10(%rbp), %rsi
leaq -0x328(%rbp), %rdi
movq %rdi, -0x438(%rbp)
movl $0x8, %edx
callq 0x3420
movq -0x438(%rbp), %rdi
leaq -0x14(%rbp), %rsi
callq 0x6b00
jmp 0x5f8f
leaq -0x328(%rbp), %rdi
callq 0x3120
jmp 0x5fc0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1a0(%rbp)
movl %eax, -0x1a4(%rbp)
leaq -0x328(%rbp), %rdi
callq 0x3120
jmp 0x641c
movq -0x420(%rbp), %rax
movq (%rax), %rsi
movl -0x14(%rbp), %edx
leaq -0x340(%rbp), %rdi
callq 0xaed0
leaq -0x340(%rbp), %rdi
callq 0x6b60
testb $0x1, %al
jne 0x5feb
jmp 0x6051
movq 0x20fd6(%rip), %rdi     # 0x26fc8
leaq 0x1413c(%rip), %rsi     # 0x1a135
callq 0x3260
movq %rax, -0x440(%rbp)
jmp 0x6007
movq -0x440(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x3230
movq %rax, -0x448(%rbp)
jmp 0x6020
movq -0x448(%rbp), %rdi
movq 0x20f7a(%rip), %rsi     # 0x26fa8
callq 0x3290
jmp 0x6035
jmp 0x63fb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1a0(%rbp)
movl %eax, -0x1a4(%rbp)
jmp 0x6410
movq -0x420(%rbp), %rax
movq (%rax), %rsi
movl -0x14(%rbp), %edx
leaq -0x350(%rbp), %rdi
callq 0xae30
jmp 0x606c
movzbl -0x12(%rbp), %eax
movl %eax, -0x354(%rbp)
movzwl -0x14(%rbp), %eax
movl %eax, -0x358(%rbp)
leaq -0x350(%rbp), %rdi
callq 0x6550
movq %rax, %rsi
addq $0x120, %rsi            # imm = 0x120
leaq -0x388(%rbp), %rdi
movq %rdi, -0x450(%rbp)
callq 0x6570
movq -0x450(%rbp), %rsi
movl -0x354(%rbp), %edx
decl %edx
leaq -0x378(%rbp), %rdi
callq 0xa9b0
jmp 0x60c6
leaq -0x388(%rbp), %rdi
callq 0x43a0
leaq -0x340(%rbp), %rax
movq %rax, -0x390(%rbp)
movq -0x390(%rbp), %rdi
callq 0x6790
movq %rax, -0x398(%rbp)
movq -0x390(%rbp), %rdi
callq 0x67c0
movq %rax, -0x3a0(%rbp)
leaq -0x398(%rbp), %rdi
leaq -0x3a0(%rbp), %rsi
callq 0x67f0
testb $0x1, %al
jne 0x6122
jmp 0x63d3
leaq -0x398(%rbp), %rdi
callq 0x6830
movq %rax, %rsi
leaq -0x3b0(%rbp), %rdi
callq 0x6850
leaq -0x3b0(%rbp), %rdi
callq 0x6880
movq %rax, %rdi
addq $0x60, %rdi
movl -0x358(%rbp), %eax
movl %eax, %esi
callq 0x68c0
movq (%rax), %rax
movq %rax, -0x3b8(%rbp)
leaq -0x3b0(%rbp), %rdi
callq 0x6880
movq %rax, %rdi
addq $0x78, %rdi
movl -0x358(%rbp), %eax
movl %eax, %esi
callq 0x69c0
movq (%rax), %rax
movq %rax, -0x3c0(%rbp)
xorl %eax, %eax
cmpq -0x3b8(%rbp), %rax
je 0x639c
leaq -0x3b0(%rbp), %rdi
callq 0x6880
movq %rax, %rsi
addq $0x14, %rsi
leaq -0x3e0(%rbp), %rdi
leaq -0x378(%rbp), %rdx
callq 0x68e0
jmp 0x61c8
movq 0x20df9(%rip), %rdi     # 0x26fc8
leaq -0x3e0(%rbp), %rsi
callq 0x3230
movq %rax, -0x458(%rbp)
jmp 0x61e4
movq -0x458(%rbp), %rdi
leaq 0x13f5c(%rip), %rsi     # 0x1a14e
callq 0x3260
jmp 0x61f9
leaq -0x3e0(%rbp), %rdi
callq 0x34a8
movl -0x14(%rbp), %eax
movl %eax, -0x474(%rbp)
leaq -0x350(%rbp), %rdi
callq 0x6550
movq %rax, %rsi
addq $0x130, %rsi            # imm = 0x130
leaq -0x3f0(%rbp), %rdi
callq 0x6570
movq -0x3b8(%rbp), %rax
movq %rax, -0x470(%rbp)
movq -0x3c0(%rbp), %rax
movq %rax, -0x468(%rbp)
leaq -0x411(%rbp), %rdi
movq %rdi, -0x460(%rbp)
callq 0x3460
movq -0x460(%rbp), %rdx
leaq 0x13eb8(%rip), %rsi     # 0x1a125
leaq -0x410(%rbp), %rdi
callq 0x3360
jmp 0x627b
movq -0x468(%rbp), %r8
movq -0x470(%rbp), %rcx
movl -0x474(%rbp), %esi
movq -0x420(%rbp), %rdi
movq %rsp, %rax
leaq -0x410(%rbp), %rdx
movq %rdx, (%rax)
leaq -0x3f0(%rbp), %rdx
leaq -0x378(%rbp), %r9
callq 0x54f0
jmp 0x62b8
leaq -0x410(%rbp), %rdi
callq 0x34a8
leaq -0x411(%rbp), %rdi
callq 0x32a0
leaq -0x3f0(%rbp), %rdi
callq 0x43a0
movq 0x20ce5(%rip), %rdi     # 0x26fc8
movq 0x20cbe(%rip), %rsi     # 0x26fa8
callq 0x3290
jmp 0x62f1
jmp 0x639c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1a0(%rbp)
movl %eax, -0x1a4(%rbp)
leaq -0x388(%rbp), %rdi
callq 0x43a0
jmp 0x63ed
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1a0(%rbp)
movl %eax, -0x1a4(%rbp)
jmp 0x63b9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1a0(%rbp)
movl %eax, -0x1a4(%rbp)
leaq -0x3e0(%rbp), %rdi
callq 0x34a8
jmp 0x63b9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1a0(%rbp)
movl %eax, -0x1a4(%rbp)
jmp 0x6382
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1a0(%rbp)
movl %eax, -0x1a4(%rbp)
leaq -0x410(%rbp), %rdi
callq 0x34a8
leaq -0x411(%rbp), %rdi
callq 0x32a0
leaq -0x3f0(%rbp), %rdi
callq 0x43a0
jmp 0x63b9
leaq -0x3b0(%rbp), %rdi
callq 0x6a60
leaq -0x398(%rbp), %rdi
callq 0x6a80
jmp 0x6106
leaq -0x3b0(%rbp), %rdi
callq 0x6a60
leaq -0x378(%rbp), %rdi
callq 0x34a8
jmp 0x63ed
leaq -0x378(%rbp), %rdi
callq 0x34a8
leaq -0x350(%rbp), %rdi
callq 0x4820
jmp 0x63fb
leaq -0x350(%rbp), %rdi
callq 0x4820
jmp 0x6410
leaq -0x340(%rbp), %rdi
callq 0x6ba0
addq $0x480, %rsp            # imm = 0x480
popq %rbp
retq
leaq -0x340(%rbp), %rdi
callq 0x6ba0
movq -0x1a0(%rbp), %rdi
callq 0x3450
nopl (%rax,%rax)