// File: /workspace/github_cpp_makefile_star2_O2/Karunika[P]Taxi_Agency_OODB/./src/TaxiAgency.cpp
// Function: TaxiAgency::import_current_shifts(char const*)
void TaxiAgency::import_current_shifts(const char* CURRENT_SHIFTS_FILE){
    ifstream File;
    File.open(CURRENT_SHIFTS_FILE);
    Shift shift;
    if(File.is_open()){
        string t, fields[Shift::ShiftAttributesCount];
        getline(File, t); // skip heading row
        while(getline(File, t)){
            populate_fields(t, fields, Shift::ShiftAttributesCount);
            shift = Shift(fields[0].substr(0, fields[0].length()-2),
                        fields[1].substr(1, fields[1].length()-2),
                        fields[2].substr(1, fields[2].length()-2),
                        stoi(fields[3]),
                        stoi(fields[4]));

            current_shifts.push_back(shift);
        }
        File.close();
    }else{
        throw runtime_error("File couldn't be resolved");
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x418, %rsp            # imm = 0x418
movq %rsi, %rbx
movq %rdi, -0x30(%rbp)
leaq -0x3a0(%rbp), %r14
movq %r14, %rdi
callq 0x42e0
pushq $0x8
popq %rdx
movq %r14, %rdi
movq %rbx, %rsi
callq 0x41e0
leaq -0x198(%rbp), %rdi
callq 0x1206c
leaq -0x328(%rbp), %rdi
callq 0x40d0
testb %al, %al
je 0x1072c
leaq -0x68(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movq %rsp, -0x38(%rbp)
movb $0x0, (%rax)
movl 0xdd6b(%rip), %r14d     # 0x1e29c
movq %rsp, %rbx
movq %r14, %rax
shlq $0x5, %rax
subq %rax, %rbx
movq %rbx, %rsp
testq %r14, %r14
je 0x10560
leaq 0x10(%rbx), %rcx
movq %rcx, -0x10(%rcx)
andq $0x0, -0x8(%rcx)
movb $0x0, (%rcx)
addq $0x20, %rcx
addq $-0x20, %rax
jne 0x1054a
leaq -0x3a0(%rbp), %rdi
leaq -0x78(%rbp), %rsi
callq 0x4080
leaq 0x20(%rbx), %rax
movq %rax, -0x58(%rbp)
leaq 0x40(%rbx), %rax
movq %rax, -0x50(%rbp)
leaq 0x60(%rbx), %rax
movq %rax, -0x48(%rbp)
leaq 0x80(%rbx), %rax
movq %rax, -0x40(%rbp)
addq $0x48, -0x30(%rbp)
leaq -0xf8(%rbp), %r15
leaq -0x440(%rbp), %r12
leaq -0x3a0(%rbp), %rdi
leaq -0x78(%rbp), %rsi
callq 0x4080
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x106d0
leaq -0xd8(%rbp), %rdi
leaq -0x78(%rbp), %rsi
callq 0x4360
movl 0xdcbe(%rip), %edx      # 0x1e29c
leaq -0xd8(%rbp), %r13
movq %r13, %rdi
movq %rbx, %rsi
callq 0xe410
movq %r13, %rdi
callq 0x4170
movq 0x8(%rbx), %rcx
addq $-0x2, %rcx
leaq -0xb8(%rbp), %rdi
movq %rbx, %rsi
xorl %edx, %edx
callq 0x42c0
movq 0x28(%rbx), %rcx
addq $-0x2, %rcx
leaq -0x98(%rbp), %rdi
movq -0x58(%rbp), %rsi
pushq $0x1
popq %r13
movq %r13, %rdx
callq 0x42c0
movq 0x48(%rbx), %rcx
addq $-0x2, %rcx
movq %r15, %rdi
movq -0x50(%rbp), %rsi
movq %r13, %rdx
callq 0x42c0
movq -0x48(%rbp), %rdi
xorl %esi, %esi
pushq $0xa
popq %rdx
callq 0x11b99
movl %eax, %r13d
movq -0x40(%rbp), %rdi
xorl %esi, %esi
pushq $0xa
popq %rdx
callq 0x11b99
movq %r12, %rdi
leaq -0xb8(%rbp), %rsi
leaq -0x98(%rbp), %rdx
movq %r15, %rcx
movl %r13d, %r8d
movl %eax, %r9d
callq 0xc9f4
leaq -0x198(%rbp), %r13
movq %r13, %rdi
movq %r12, %rsi
callq 0x121ba
movq %r12, %rdi
callq 0x12206
movq %r15, %rdi
callq 0x4170
leaq -0x98(%rbp), %rdi
callq 0x4170
leaq -0xb8(%rbp), %rdi
callq 0x4170
movq -0x30(%rbp), %rdi
movq %r13, %rsi
callq 0x12238
jmp 0x105a6
leaq -0x3a0(%rbp), %rdi
callq 0x40a0
testq %r14, %r14
je 0x106f8
addq $-0x20, %rbx
shlq $0x5, %r14
leaq (%rbx,%r14), %rdi
callq 0x4170
addq $-0x20, %r14
jne 0x106e9
movq -0x38(%rbp), %rsp
leaq -0x78(%rbp), %rdi
callq 0x4170
leaq -0x198(%rbp), %rdi
callq 0x12206
leaq -0x3a0(%rbp), %rdi
callq 0x40e0
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
pushq $0x10
popq %rdi
callq 0x4190
movq %rax, %rbx
leaq 0x50e7(%rip), %rsi      # 0x15825
movq %rax, %rdi
callq 0x4130
movq 0xd89b(%rip), %rsi      # 0x1dfe8
movq 0xd814(%rip), %rdx      # 0x1df68
movq %rbx, %rdi
callq 0x4410
movq %rax, %r15
jmp 0x107e0
movq %rax, %r15
movq %rbx, %rdi
callq 0x4220
jmp 0x107e0
jmp 0x10770
movq %rax, %r15
jmp 0x107ec
jmp 0x107b8
jmp 0x107b8
movq %rax, %r15
jmp 0x1079e
movq %rax, %r15
leaq -0xd8(%rbp), %rdi
jmp 0x107b1
movq %rax, %r15
jmp 0x107aa
movq %rax, %r15
leaq -0xf8(%rbp), %rdi
callq 0x4170
leaq -0x98(%rbp), %rdi
callq 0x4170
leaq -0xb8(%rbp), %rdi
callq 0x4170
jmp 0x107bb
movq %rax, %r15
testq %r14, %r14
je 0x107d7
addq $-0x20, %rbx
shlq $0x5, %r14
leaq (%rbx,%r14), %rdi
callq 0x4170
addq $-0x20, %r14
jne 0x107c8
leaq -0x78(%rbp), %rdi
callq 0x4170
leaq -0x198(%rbp), %rdi
callq 0x12206
leaq -0x3a0(%rbp), %rdi
callq 0x40e0
movq %r15, %rdi
callq 0x4450