// File: /workspace/github_cpp_makefile_star2_O2/metopa[P]HTTP_Server/src/requests/CRequest.cpp
// Function: CRequest::parse()
void CRequest::parse() {
	clock_m = high_resolution_clock::now();
	try {
		parser_m.parse( inputMsg_m );
		switch ( parser_m.getType() ) {
			case RT_GET:
				generator_m = new CGetGenerator( parser_m.getResource() );
				break;
			case RT_HEAD:
				generator_m = new CHeadGenerator( parser_m.getResource() );
				break;
			case RT_OPTIONS:
				generator_m = new COptionsGenerator( parser_m.getResource() );
				break;
			default:
				generator_m = new CErrorGenerator( 501 ); //Not Implemented
		}
	}
	catch ( RequestParserException& e ) {
		Log.ger<>( DEBUG_REQUEST, e );
		if ( parser_m.getType() == RT_UNSUPPORTED )
			generator_m = new CErrorGenerator( 501 ); //Not Implemented
		else
			generator_m = new CErrorGenerator( 400 ); //Bad Request
	}

	catch ( MethodProhibitedException& e ) {
		Log.ger<>( DEBUG_REQUEST, e );
		generator_m = new CErrorGenerator( 405 ); //Method Not Allowed
	}

	catch ( FileNotFoundException& e ) {
		Log.ger<>( DEBUG_REQUEST, e );
		generator_m = new CErrorGenerator( 404 ); //Not Found
	}

	catch ( FileErrorException& e ) {
		Log.ger<>( DEBUG_REQUEST, e );
		generator_m = new CErrorGenerator( 409 ); //Conflict
	}

	catch ( PermissionDeniedException& e ) {
		Log.ger<>( DEBUG_REQUEST, e );
		generator_m = new CErrorGenerator( 403 ); //Forbidden
	}

	catch ( ServiceUnavailableException& e ) {
		Log.ger<>( DEBUG_REQUEST, e );
		generator_m = new CErrorGenerator( 503 ); //Service unavailable
	}

	catch ( InternalErrorException& e ) {
		Log.ger<>( DEBUG_REQUEST, e );
		generator_m = new CErrorGenerator( 500 ); //Internal Server Error
	}

	catch ( GeneralException& e ) {
		Log.ger<GeneralException&>( CRITICAL, e );
		generator_m = new CErrorGenerator( 500 ); //Internal Server Error
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
callq 0x5080
movq %rax, 0x48(%rbx)
leaq 0x50(%rbx), %r15
leaq 0x8(%rbx), %rsi
movq %r15, %rdi
callq 0x11040
movq %r15, %rdi
callq 0x11260
movl (%rax), %eax
testl %eax, %eax
je 0x104f7
cmpl $0x1, %eax
je 0x104d7
cmpl $0x2, %eax
jne 0x10517
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r13
movq %r15, %rdi
callq 0x11264
movq %r13, %rdi
movq %rax, %rsi
callq 0x11c48
jmp 0x1052f
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r13
movq %r15, %rdi
callq 0x11264
movq %r13, %rdi
movq %rax, %rsi
callq 0x11ac0
jmp 0x1052f
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r13
movq %r15, %rdi
callq 0x11264
movq %r13, %rdi
movq %rax, %rsi
callq 0x10970
jmp 0x1052f
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r13
movq %rax, %rdi
movl $0x1f5, %esi            # imm = 0x1F5
callq 0x116a0
movq %r13, 0x98(%rbx)
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
jmp 0x10546
jmp 0x10546
jmp 0x10546
movq %rdx, %r12
movq %rax, %r14
pushq $0x58
popq %rsi
movq %r13, %rdi
callq 0x5420
jmp 0x1055f
movq %rdx, %r12
movq %rax, %r14
cmpl $0x8, %r12d
jne 0x105ad
movq %r14, %rdi
callq 0x51f0
leaq 0x1107c(%rip), %rdi     # 0x215f0
pushq $0x7
popq %rsi
movq %rax, %rdx
callq 0x10d9e
movq %r15, %rdi
callq 0x11260
cmpl $0x3, (%rax)
jne 0x10627
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r15
movq %rax, %rdi
movl $0x1f5, %esi            # imm = 0x1F5
callq 0x116a0
jmp 0x1076e
cmpl $0x7, %r12d
jne 0x105ea
movq %r14, %rdi
callq 0x51f0
leaq 0x1102e(%rip), %rdi     # 0x215f0
pushq $0x7
popq %rsi
movq %rax, %rdx
callq 0x10d0a
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r15
movq %rax, %rdi
movl $0x195, %esi            # imm = 0x195
callq 0x116a0
jmp 0x1076e
cmpl $0x6, %r12d
jne 0x10644
movq %r14, %rdi
callq 0x51f0
leaq 0x10ff1(%rip), %rdi     # 0x215f0
pushq $0x7
popq %rsi
movq %rax, %rdx
callq 0x10c76
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r15
movq %rax, %rdi
movl $0x194, %esi            # imm = 0x194
callq 0x116a0
jmp 0x1076e
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r15
movq %rax, %rdi
movl $0x190, %esi            # imm = 0x190
callq 0x116a0
jmp 0x1076e
cmpl $0x5, %r12d
jne 0x10681
movq %r14, %rdi
callq 0x51f0
leaq 0x10f97(%rip), %rdi     # 0x215f0
pushq $0x7
popq %rsi
movq %rax, %rdx
callq 0x10be2
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r15
movq %rax, %rdi
movl $0x199, %esi            # imm = 0x199
callq 0x116a0
jmp 0x1076e
cmpl $0x4, %r12d
jne 0x106be
movq %r14, %rdi
callq 0x51f0
leaq 0x10f5a(%rip), %rdi     # 0x215f0
pushq $0x7
popq %rsi
movq %rax, %rdx
callq 0x10b4e
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r15
movq %rax, %rdi
movl $0x193, %esi            # imm = 0x193
callq 0x116a0
jmp 0x1076e
cmpl $0x3, %r12d
jne 0x106f8
movq %r14, %rdi
callq 0x51f0
leaq 0x10f1d(%rip), %rdi     # 0x215f0
pushq $0x7
popq %rsi
movq %rax, %rdx
callq 0x10aba
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r15
movq %rax, %rdi
movl $0x1f7, %esi            # imm = 0x1F7
callq 0x116a0
jmp 0x1076e
cmpl $0x2, %r12d
jne 0x10732
movq %r14, %rdi
callq 0x51f0
leaq 0x10ee3(%rip), %rdi     # 0x215f0
pushq $0x7
popq %rsi
movq %rax, %rdx
callq 0x10a26
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r15
movq %rax, %rdi
movl $0x1f4, %esi            # imm = 0x1F4
callq 0x116a0
jmp 0x1076e
cmpl $0x1, %r12d
jne 0x1085c
movq %r14, %rdi
callq 0x51f0
leaq 0x10ea5(%rip), %rdi     # 0x215f0
pushq $0x1
popq %rsi
movq %rax, %rdx
callq 0x10992
pushq $0x58
popq %rdi
callq 0x5410
movq %rax, %r15
movq %rax, %rdi
movl $0x1f4, %esi            # imm = 0x1F4
callq 0x116a0
movq %r15, 0x98(%rbx)
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x5700
movq %rax, %r14
pushq $0x58
popq %rsi
movq %r15, %rdi
callq 0x5420
jmp 0x107a6
movq %rax, %r14
pushq $0x58
popq %rsi
movq %r15, %rdi
callq 0x5420
jmp 0x107b3
movq %rax, %r14
callq 0x5700
jmp 0x1085c
movq %rax, %r14
callq 0x5700
jmp 0x1085c
movq %rax, %r14
pushq $0x58
popq %rsi
movq %r15, %rdi
callq 0x5420
jmp 0x107d0
movq %rax, %r14
callq 0x5700
jmp 0x1085c
movq %rax, %r14
pushq $0x58
popq %rsi
movq %r15, %rdi
callq 0x5420
jmp 0x107ed
movq %rax, %r14
callq 0x5700
jmp 0x1085c
movq %rax, %r14
pushq $0x58
popq %rsi
movq %r15, %rdi
callq 0x5420
jmp 0x10807
movq %rax, %r14
callq 0x5700
jmp 0x1085c
movq %rax, %r14
pushq $0x58
popq %rsi
movq %r15, %rdi
callq 0x5420
jmp 0x10823
jmp 0x1083a
movq %rax, %r14
callq 0x5700
jmp 0x1085c
movq %rax, %r14
pushq $0x58
popq %rsi
movq %r15, %rdi
callq 0x5420
jmp 0x1084d
movq %rax, %r14
pushq $0x58
popq %rsi
movq %r15, %rdi
callq 0x5420
jmp 0x10857
movq %rax, %r14
callq 0x5700
jmp 0x1085c
movq %rax, %r14
callq 0x5700
movq %r14, %rdi
callq 0x5770
movq %rax, %rdi
callq 0x7285