// File: /workspace/github_cpp_makefile_star2_O3/viniciu21[P]PetLolja/./src/PetFera.cpp
// Function: Petfera::salvar_doc_funcio()
void Petfera::salvar_doc_funcio()
{
	vector<string> chaves{"ID", "Classe", "Nome", "Numero", "contato", "Funcao", "Cpf", "Email", "Nivel", "seguranca", "Inscricao", "CRMV"};

	ifstream arqCache("cache_funcio.dat");
	ofstream arqDados("temp_func.dat");
	ofstream arqDados_csv("../banco/Dados_csv_funci.csv");
	vector<string> tokens_funcio;
	string linha;

	string palavra;

	while (arqCache >> linha)
	{
		if (linha != " " && linha != "==============")
		{
			tokens_funcio.push_back(linha);
		}
	}

	for (auto &novo : tokens_funcio)
	{
		arqDados << novo << endl;
	}

	for (unsigned int i = 0; i < tokens_funcio.size(); ++i)
	{
		for (unsigned int j = 0; j < chaves.size(); ++j)
		{
			if (tokens_funcio[i] == chaves[j] || tokens_funcio[i] == "|")
			{
				tokens_funcio[i] = "";
			}
		}
	}

	for (auto &novo : tokens_funcio)
	{
		if (novo == "." && novo != "")
		{
			arqDados_csv << "" << endl;
		}
		else if (novo != "")
		{
			arqDados_csv << novo << ";";
		}
	}

	inicio();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x688, %rsp            # imm = 0x688
movq %rdi, %r12
leaq -0x2a0(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x1d077(%rip), %rsi     # 0x2f2b2
leaq 0x1d072(%rip), %rdx     # 0x2f2b4
leaq -0x2b0(%rbp), %r14
movq %r14, %rdi
callq 0x1e0e2
leaq -0x290(%rbp), %r15
leaq -0x280(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x1d04b(%rip), %rsi     # 0x2f2b5
leaq 0x1d04a(%rip), %rdx     # 0x2f2bb
movq %r15, %rdi
callq 0x1e0e2
leaq -0x270(%rbp), %r15
leaq -0x260(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x1d02a(%rip), %rsi     # 0x2f2bc
leaq 0x1d027(%rip), %rdx     # 0x2f2c0
movq %r15, %rdi
callq 0x1e0e2
leaq -0x250(%rbp), %r15
leaq -0x240(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x1d107(%rip), %rsi     # 0x2f3c1
leaq 0x1d106(%rip), %rdx     # 0x2f3c7
movq %r15, %rdi
callq 0x1e0e2
leaq -0x230(%rbp), %r15
leaq -0x220(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x1d0e6(%rip), %rsi     # 0x2f3c8
leaq 0x1d0e6(%rip), %rdx     # 0x2f3cf
movq %r15, %rdi
callq 0x1e0e2
leaq -0x210(%rbp), %r15
leaq -0x200(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x1d0c6(%rip), %rsi     # 0x2f3d0
leaq 0x1d0c5(%rip), %rdx     # 0x2f3d6
movq %r15, %rdi
callq 0x1e0e2
leaq -0x1f0(%rbp), %r15
leaq -0x1e0(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x1d0a5(%rip), %rsi     # 0x2f3d7
leaq 0x1d0a1(%rip), %rdx     # 0x2f3da
movq %r15, %rdi
callq 0x1e0e2
leaq -0x1d0(%rbp), %r15
leaq -0x1c0(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x1d081(%rip), %rsi     # 0x2f3db
leaq 0x1d07f(%rip), %rdx     # 0x2f3e0
movq %r15, %rdi
callq 0x1e0e2
leaq -0x1b0(%rbp), %r15
leaq -0x1a0(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x1d05f(%rip), %rsi     # 0x2f3e1
leaq 0x1d05d(%rip), %rdx     # 0x2f3e6
movq %r15, %rdi
callq 0x1e0e2
leaq -0x190(%rbp), %r15
leaq -0x180(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x1caac(%rip), %rsi     # 0x2ee56
leaq 0x1caae(%rip), %rdx     # 0x2ee5f
movq %r15, %rdi
callq 0x1e0e2
leaq -0x170(%rbp), %r15
leaq -0x160(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x1d015(%rip), %rsi     # 0x2f3e7
leaq 0x1d017(%rip), %rdx     # 0x2f3f0
movq %r15, %rdi
callq 0x1e0e2
leaq -0x150(%rbp), %r15
leaq -0x140(%rbp), %rbx
movq %rbx, -0x10(%rbx)
leaq 0x1ca3d(%rip), %rsi     # 0x2ee37
leaq 0x1ca3a(%rip), %rdx     # 0x2ee3b
movq %r15, %rdi
callq 0x1e0e2
leaq -0x58(%rbp), %rdi
leaq -0x2b0(%rbp), %rsi
leaq -0x6b0(%rbp), %rcx
movl $0xc, %edx
callq 0x1e09a
movq $-0x180, %r14           # imm = 0xFE80
movq -0x10(%rbx), %rdi
cmpq %rdi, %rbx
je 0x12440
movq (%rbx), %rsi
incq %rsi
callq 0x41d0
addq $-0x20, %rbx
addq $0x20, %r14
jne 0x1242c
leaq 0x1baf7(%rip), %rsi     # 0x2df48
leaq -0x2b0(%rbp), %rdi
movl $0x8, %edx
callq 0x4310
leaq 0x1cf88(%rip), %rsi     # 0x2f3f1
leaq -0x6b0(%rbp), %rdi
movl $0x10, %edx
callq 0x41f0
movq %r12, -0x60(%rbp)
leaq 0x1b45b(%rip), %rsi     # 0x2d8e0
leaq -0x4b0(%rbp), %rdi
movl $0x10, %edx
callq 0x41f0
xorps %xmm0, %xmm0
leaq -0x40(%rbp), %rbx
movaps %xmm0, (%rbx)
xorl %eax, %eax
movq %rax, 0x10(%rbx)
leaq -0x78(%rbp), %rcx
movq %rcx, -0x10(%rcx)
movq %rax, -0x8(%rcx)
movb %al, (%rcx)
leaq -0x98(%rbp), %rcx
movq %rcx, -0x10(%rcx)
movq %rax, -0x8(%rcx)
movb %al, (%rcx)
leaq -0x2b0(%rbp), %r14
leaq -0x88(%rbp), %r12
leaq 0x1d543(%rip), %r13     # 0x2fa1d
leaq 0x1b0f1(%rip), %r15     # 0x2d5d2
movq %r14, %rdi
movq %r12, %rsi
callq 0x4220
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x12525
movq %r12, %rdi
movq %r13, %rsi
callq 0x4090
testl %eax, %eax
je 0x124e1
movq %r12, %rdi
movq %r15, %rsi
callq 0x4090
testl %eax, %eax
je 0x124e1
movq %rbx, %rdi
movq %r12, %rsi
callq 0x1de8c
jmp 0x124e1
movq -0x40(%rbp), %r15
movq -0x38(%rbp), %r12
cmpq %r12, %r15
je 0x12731
leaq -0x6b0(%rbp), %rbx
movq (%r15), %rsi
movq 0x8(%r15), %rdx
movq %rbx, %rdi
callq 0x4210
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x41b0
movsbl %al, %esi
movq %r14, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4120
addq $0x20, %r15
cmpq %r12, %r15
jne 0x1253d
movq -0x40(%rbp), %r12
movq -0x38(%rbp), %r15
cmpq %r12, %r15
je 0x12731
movq -0x58(%rbp), %rax
movq -0x50(%rbp), %rcx
xorl %r13d, %r13d
xorl %esi, %esi
cmpq %rax, %rcx
je 0x12650
movq %rsi, -0x68(%rbp)
movl $0x1, %ebx
shlq $0x5, %r13
xorl %edx, %edx
movq -0x40(%rbp), %r14
leaq (%r14,%r13), %r12
shlq $0x5, %rdx
movq 0x8(%r14,%r13), %r15
cmpq 0x8(%rax,%rdx), %r15
jne 0x125e8
testq %r15, %r15
je 0x12606
addq %rdx, %rax
movq (%rax), %rsi
movq (%r12), %rdi
movq %r15, %rdx
callq 0x41e0
testl %eax, %eax
je 0x12609
movq %r12, %rdi
leaq 0x1cdcb(%rip), %rsi     # 0x2f3bd
callq 0x4090
testl %eax, %eax
jne 0x12623
movq -0x40(%rbp), %r14
movq 0x8(%r14,%r13), %r15
jmp 0x12609
xorl %r15d, %r15d
addq %r13, %r14
movq %r14, %rdi
xorl %esi, %esi
movq %r15, %rdx
leaq 0x1b417(%rip), %rcx     # 0x2da32
xorl %r8d, %r8d
callq 0x42a0
movl %ebx, %edx
movq -0x58(%rbp), %rax
movq -0x50(%rbp), %rcx
movq %rcx, %rsi
subq %rax, %rsi
sarq $0x5, %rsi
incl %ebx
cmpq %rdx, %rsi
ja 0x125b5
movq -0x40(%rbp), %r12
movq -0x38(%rbp), %r15
movq -0x68(%rbp), %rsi
jmp 0x12653
movq %rax, %rcx
incl %esi
movq %r15, %rdx
subq %r12, %rdx
sarq $0x5, %rdx
movq %rsi, %r13
cmpq %rsi, %rdx
ja 0x1259d
cmpq %r15, %r12
je 0x12731
leaq 0x1ab9a(%rip), %rbx     # 0x2d215
leaq 0x1b3b0(%rip), %r13     # 0x2da32
leaq 0x1cd36(%rip), %r14     # 0x2f3bf
movq %r12, %rdi
movq %rbx, %rsi
callq 0x4090
testl %eax, %eax
je 0x126ce
movq %r12, %rdi
movq %r13, %rsi
callq 0x4090
testl %eax, %eax
je 0x12724
movq (%r12), %rsi
movq 0x8(%r12), %rdx
leaq -0x4b0(%rbp), %rdi
callq 0x4210
movl $0x1, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x4210
jmp 0x12724
movq %r12, %rdi
movq %r13, %rsi
callq 0x4090
testl %eax, %eax
je 0x12698
leaq -0x4b0(%rbp), %rdi
movq %r13, %rsi
xorl %edx, %edx
callq 0x4210
movq -0x4b0(%rbp), %rax
movq -0x18(%rax), %rdi
leaq -0x4b0(%rbp), %rax
addq %rax, %rdi
movl $0xa, %esi
callq 0x41b0
movsbl %al, %esi
leaq -0x4b0(%rbp), %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4120
addq $0x20, %r12
cmpq %r15, %r12
jne 0x12689
movq -0x60(%rbp), %rdi
callq 0x10c4e
movq -0xa8(%rbp), %rdi
leaq -0x98(%rbp), %rax
cmpq %rax, %rdi
je 0x1275c
movq -0x98(%rbp), %rsi
incq %rsi
callq 0x41d0
movq -0x88(%rbp), %rdi
leaq -0x78(%rbp), %rax
cmpq %rax, %rdi
je 0x12778
movq -0x78(%rbp), %rsi
incq %rsi
callq 0x41d0
leaq -0x40(%rbp), %rdi
callq 0x1ded8
movq 0x28838(%rip), %rax     # 0x3afc0
movq (%rax), %rbx
movq 0x18(%rax), %r14
leaq -0x4a8(%rbp), %rdi
movq %rbx, -0x8(%rdi)
movq -0x18(%rbx), %rax
movq %r14, -0x4b0(%rbp,%rax)
callq 0x4180
movl $0xf8, %r15d
leaq -0x4b0(%rbp), %rdi
addq %r15, %rdi
callq 0x40a0
leaq -0x6a8(%rbp), %rdi
movq %rbx, -0x8(%rdi)
movq -0x18(%rbx), %rax
movq %r14, -0x6b0(%rbp,%rax)
callq 0x4180
leaq -0x6b0(%rbp), %rdi
addq %r15, %rdi
callq 0x40a0
leaq -0x2b0(%rbp), %rdi
callq 0x4070
leaq -0x58(%rbp), %rdi
callq 0x1ded8
addq $0x688, %rsp            # imm = 0x688
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x12899
movq %rax, %rbx
jmp 0x128ef
movq %rax, %rbx
jmp 0x128fb
movq %rax, %rbx
jmp 0x12907
movq %rax, %rbx
leaq -0x130(%rbp), %rdi
leaq -0x2b0(%rbp), %rsi
callq 0x4340
jmp 0x12910
jmp 0x1285e
jmp 0x1285e
jmp 0x1285e
jmp 0x1285e
jmp 0x1285e
jmp 0x1285e
jmp 0x1285e
jmp 0x1285e
jmp 0x1285e
jmp 0x1285e
movq %rax, %rbx
addq $-0x10, %r15
movq -0x10(%r15), %rdi
cmpq %rdi, %r15
je 0x12879
movq (%r15), %rsi
incq %rsi
callq 0x41d0
leaq -0x20(%r15), %rax
addq $-0x10, %r15
cmpq %r14, %r15
movq %rax, %r15
jne 0x12865
jmp 0x12910
movq %rax, %rbx
jmp 0x12910
jmp 0x12899
jmp 0x12899
jmp 0x12899
movq %rax, %rbx
movq -0xa8(%rbp), %rdi
leaq -0x98(%rbp), %rax
cmpq %rax, %rdi
je 0x128be
movq -0x98(%rbp), %rsi
incq %rsi
callq 0x41d0
movq -0x88(%rbp), %rdi
leaq -0x78(%rbp), %rax
cmpq %rax, %rdi
je 0x128da
movq -0x78(%rbp), %rsi
incq %rsi
callq 0x41d0
leaq -0x40(%rbp), %rdi
callq 0x1ded8
leaq -0x4b0(%rbp), %rdi
callq 0x4270
leaq -0x6b0(%rbp), %rdi
callq 0x4270
leaq -0x2b0(%rbp), %rdi
callq 0x4070
leaq -0x58(%rbp), %rdi
callq 0x1ded8
movq %rbx, %rdi
callq 0x42f0