// File: /workspace/github_c_makefile_star2_O2/enzo1982[P]smooth/classes/i18n/section.cpp
// Function: smooth::I18n::Section::Parse(smooth::XML::Node*)
S::Errors::Error S::I18n::Section::Parse(XML::Node *section)
{
	if (section == NIL) return Error();

	static String	 sectionNode	 = "section";
	static String	 nameAttribute	 = "name";
	static String	 entryNode	 = "entry";
	static String	 stringAttribute = "string";

	if (section->GetAttributeByName(nameAttribute) != NIL) SetName(section->GetAttributeByName(nameAttribute)->GetContent());

	for (Int i = 0; i < section->GetNOfNodes(); i++)
	{
		XML::Node	*entry = section->GetNthNode(i);

		if (entry->GetName() == entryNode && entry->GetAttributeByName(stringAttribute) != NIL)
		{
			strings.Add(entry->GetContent(), entry->GetAttributeByName(stringAttribute)->GetContent().ComputeCRC32());
		}
		else if (entry->GetName() == sectionNode && entry->GetAttributeByName(nameAttribute) != NIL)
		{
			Section	*section = new Section();

			section->Parse(entry);

			sections.Add(section, section->GetName().ComputeCRC32());
		}
	}

	return Success();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
testq %rdx, %rdx
je 0x970ae
movq %rdx, %r14
movq %rsi, %rbx
movb 0xcddcd(%rip), %al      # 0x164ce0
testb %al, %al
movq %rdi, 0x10(%rsp)
je 0x970d4
movb 0xcddda(%rip), %al      # 0x164d00
testb %al, %al
je 0x97126
movb 0xcddec(%rip), %al      # 0x164d20
testb %al, %al
je 0x97178
movb 0xcddfe(%rip), %al      # 0x164d40
testb %al, %al
je 0x971ca
leaq 0xcdd97(%rip), %rsi     # 0x164ce8
movq %r14, %rdi
callq 0x5a060
testq %rax, %rax
je 0x96f81
leaq 0xcdd83(%rip), %rsi     # 0x164ce8
movq %r14, %rdi
callq 0x5a060
movq %rax, %rdi
callq 0x56780
leaq 0x8(%rbx), %rdi
movq %rax, %rsi
callq 0x56630
leaq 0x40(%rbx), %rax
movq %rax, 0x20(%rsp)
addq $0x98, %rbx
movq %rbx, 0x18(%rsp)
leaq 0xcdd6b(%rip), %r13     # 0x164d08
leaq 0xcdd84(%rip), %rbp     # 0x164d28
xorl %r15d, %r15d
movq %r14, %rdi
callq 0x57130
cmpl %eax, %r15d
jge 0x970a5
movq %r14, %rdi
movl %r15d, %esi
callq 0x590b0
movq %rax, %r12
movq %rax, %rdi
callq 0x58fd0
movq %rax, %rdi
movq %r13, %rsi
callq 0x56960
testb %al, %al
je 0x97024
movq %r12, %rdi
movq %rbp, %rsi
callq 0x5a060
testq %rax, %rax
je 0x97024
movq %r12, %rdi
callq 0x5a160
movq %rax, %rbx
movq %r12, %rdi
movq %rbp, %rsi
callq 0x5a060
movq %rax, %rdi
callq 0x56780
movq %rax, %rdi
callq 0x56680
movq 0x20(%rsp), %rdi
movq %rbx, %rsi
movl %eax, %edx
callq 0x64e48
jmp 0x9709d
movq %r12, %rdi
callq 0x58fd0
movq %rax, %rdi
leaq 0xcdc92(%rip), %rsi     # 0x164cc8
callq 0x56960
testb %al, %al
je 0x9709d
movq %r12, %rdi
leaq 0xcdc9f(%rip), %rsi     # 0x164ce8
callq 0x5a060
testq %rax, %rax
je 0x9709d
movl $0xf0, %edi
callq 0x56700
movq %rax, %rbx
movq %rax, %rdi
callq 0x57560
movq %rbx, 0x8(%rsp)
movq (%rbx), %rax
leaq 0x28(%rsp), %rdi
movq %rbx, %rsi
movq %r12, %rdx
callq *0x10(%rax)
movq 0x8(%rsp), %rdi
addq $0x8, %rdi
callq 0x56680
movq 0x18(%rsp), %rdi
leaq 0x8(%rsp), %rsi
movl %eax, %edx
callq 0x97280
incl %r15d
jmp 0x96fa7
movq 0x10(%rsp), %rdi
xorl %ecx, %ecx
jmp 0x970b1
pushq $-0x1
popq %rcx
movq 0xca610(%rip), %rax     # 0x1616c8
addq $0x10, %rax
movq %rax, (%rdi)
movl %ecx, 0x8(%rdi)
movq %rdi, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xcdc05(%rip), %rdi     # 0x164ce0
callq 0x57210
testl %eax, %eax
je 0x96f20
leaq 0xcdbd9(%rip), %rdi     # 0x164cc8
leaq 0x5012a(%rip), %rsi     # 0xe7220
callq 0x58c40
movq 0xcae2e(%rip), %rdi     # 0x161f30
leaq 0xcdbbf(%rip), %rsi     # 0x164cc8
leaq 0xcd130(%rip), %rdx     # 0x164240
callq 0x590a0
leaq 0xcdbc4(%rip), %rdi     # 0x164ce0
callq 0x57cf0
jmp 0x96f20
leaq 0xcdbd3(%rip), %rdi     # 0x164d00
callq 0x57210
testl %eax, %eax
je 0x96f2e
leaq 0xcdba7(%rip), %rdi     # 0x164ce8
leaq 0x6c3ec(%rip), %rsi     # 0x103534
callq 0x58c40
movq 0xcaddc(%rip), %rdi     # 0x161f30
leaq 0xcdb8d(%rip), %rsi     # 0x164ce8
leaq 0xcd0de(%rip), %rdx     # 0x164240
callq 0x590a0
leaq 0xcdb92(%rip), %rdi     # 0x164d00
callq 0x57cf0
jmp 0x96f2e
leaq 0xcdba1(%rip), %rdi     # 0x164d20
callq 0x57210
testl %eax, %eax
je 0x96f3c
leaq 0xcdb75(%rip), %rdi     # 0x164d08
leaq 0x5008e(%rip), %rsi     # 0xe7228
callq 0x58c40
movq 0xcad8a(%rip), %rdi     # 0x161f30
leaq 0xcdb5b(%rip), %rsi     # 0x164d08
leaq 0xcd08c(%rip), %rdx     # 0x164240
callq 0x590a0
leaq 0xcdb60(%rip), %rdi     # 0x164d20
callq 0x57cf0
jmp 0x96f3c
leaq 0xcdb6f(%rip), %rdi     # 0x164d40
callq 0x57210
testl %eax, %eax
je 0x96f4a
leaq 0xcdb43(%rip), %rdi     # 0x164d28
leaq 0x50042(%rip), %rsi     # 0xe722e
callq 0x58c40
movq 0xcad38(%rip), %rdi     # 0x161f30
leaq 0xcdb29(%rip), %rsi     # 0x164d28
leaq 0xcd03a(%rip), %rdx     # 0x164240
callq 0x590a0
leaq 0xcdb2e(%rip), %rdi     # 0x164d40
callq 0x57cf0
jmp 0x96f4a
movq %rax, %r14
leaq 0xcdb1a(%rip), %rdi     # 0x164d40
jmp 0x9724a
movq %rax, %r14
leaq 0xcdaee(%rip), %rdi     # 0x164d20
jmp 0x9724a
movq %rax, %r14
leaq 0xcdac2(%rip), %rdi     # 0x164d00
jmp 0x9724a
movq %rax, %r14
leaq 0xcda96(%rip), %rdi     # 0x164ce0
callq 0x57520
jmp 0x97261
movq %rax, %r14
movl $0xf0, %esi
movq %rbx, %rdi
callq 0x564c0
movq %r14, %rdi
callq 0x58260
nop