// File: /workspace/github_cpp_makefile_star2_O1/minirop[P]JDecomqiler/src/ClassOutput.cpp
// Function: ClassOutput::generate(std::basic_ofstream<char, std::char_traits<char>>&)
void ClassOutput::generate(std::ofstream & file)
{
	if(isPublic)
		W("public ");
	if(isAbstract)
		W("abstract ");
	if(isFinal)
		W("final ");
	if(isInterface)
		W("interface ");
	else if(isEnum)
		W("enum ");
	else
		W("class ");
	
	W(name);
	if(extends != "Object")
	{
		W(" extends ");
		W(extends);
	}
	if(interfaces.size() > 0)
	{
		W(" implements ");
		W(interfaces[0]);
		for(std::size_t i = 1;i < interfaces.size();i++)
		{
			W(", ");
			W(interfaces[i]);
		}
	}
	W(" {\n");
	
	for(MethodOutput m : methods)
	{
		m.thisClass = name;
		m.parentClass = extends;
		m.generate(file);
	}
	
	for(FieldOutput f : fields)
	{
		f.generate(file);
	}
	
	W("}\n");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %rsi, %r13
movq %rdi, %r14
cmpb $0x1, 0x8b(%rdi)
jne 0x5617
leaq 0x16bcd(%rip), %rsi     # 0x1c1d7
movl $0x7, %edx
movq %r13, %rdi
callq 0x2280
cmpb $0x1, 0x89(%r14)
jne 0x5635
leaq 0x16bb7(%rip), %rsi     # 0x1c1df
movl $0x9, %edx
movq %r13, %rdi
callq 0x2280
cmpb $0x1, 0x88(%r14)
jne 0x5653
leaq 0x16ba3(%rip), %rsi     # 0x1c1e9
movl $0x6, %edx
movq %r13, %rdi
callq 0x2280
cmpb $0x1, 0x8a(%r14)
jne 0x566b
leaq 0x16b8c(%rip), %rsi     # 0x1c1f0
movl $0xa, %edx
jmp 0x568f
cmpb $0x1, 0x8d(%r14)
jne 0x5683
leaq 0x16b7f(%rip), %rsi     # 0x1c1fb
movl $0x5, %edx
jmp 0x568f
leaq 0x16b77(%rip), %rsi     # 0x1c201
movl $0x6, %edx
movq %r13, %rdi
callq 0x2280
movq (%r14), %rsi
movq 0x8(%r14), %rdx
movq %r13, %rdi
callq 0x2280
leaq 0x20(%r14), %rdi
leaq 0x16b57(%rip), %rsi     # 0x1c208
movq %rdi, -0x38(%rbp)
callq 0x20c0
testl %eax, %eax
je 0x56e2
leaq 0x16b4a(%rip), %rsi     # 0x1c20f
movl $0x9, %edx
movq %r13, %rdi
callq 0x2280
movq 0x20(%r14), %rsi
movq 0x28(%r14), %rdx
movq %r13, %rdi
callq 0x2280
movq 0x48(%r14), %rax
cmpq 0x40(%r14), %rax
je 0x5774
leaq 0x16b22(%rip), %rsi     # 0x1c219
movl $0xc, %edx
movq %r13, %rdi
callq 0x2280
movq 0x40(%r14), %rax
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq %r13, %rdi
callq 0x2280
movq 0x48(%r14), %rax
subq 0x40(%r14), %rax
cmpq $0x21, %rax
jb 0x5774
movl $0x1, %ebx
movl $0x28, %r15d
leaq 0x16aef(%rip), %r12     # 0x1c226
movl $0x2, %edx
movq %r13, %rdi
movq %r12, %rsi
callq 0x2280
movq 0x40(%r14), %rax
movq -0x8(%rax,%r15), %rsi
movq (%rax,%r15), %rdx
movq %r13, %rdi
callq 0x2280
movq 0x48(%r14), %rax
subq 0x40(%r14), %rax
incq %rbx
sarq $0x5, %rax
addq $0x20, %r15
cmpq %rax, %rbx
jb 0x5737
leaq 0x1709a(%rip), %rsi     # 0x1c815
movl $0x3, %edx
movq %r13, -0x30(%rbp)
movq %r13, %rdi
callq 0x2280
movq 0x58(%r14), %r12
movq 0x60(%r14), %r15
cmpq %r15, %r12
je 0x5850
leaq -0xe8(%rbp), %rbx
leaq -0xf8(%rbp), %r13
movq %r13, %rdi
movq %r12, %rsi
callq 0x59a0
leaq -0x78(%rbp), %rdi
movq %r14, %rsi
callq 0x2150
leaq -0x58(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x2150
movq %r13, %rdi
movq -0x30(%rbp), %rsi
callq 0x5da0
movq -0x58(%rbp), %rdi
leaq -0x48(%rbp), %rax
cmpq %rax, %rdi
je 0x57ed
callq 0x2200
movq -0x78(%rbp), %rdi
leaq -0x68(%rbp), %rax
cmpq %rax, %rdi
je 0x57ff
callq 0x2200
leaq -0xa0(%rbp), %rdi
callq 0x4326
leaq -0xb8(%rbp), %rdi
callq 0x42d8
movq -0xd8(%rbp), %rdi
leaq -0xc8(%rbp), %rax
cmpq %rax, %rdi
je 0x582f
callq 0x2200
movq -0xf8(%rbp), %rdi
cmpq %rbx, %rdi
je 0x5840
callq 0x2200
addq $0xc0, %r12
cmpq %r15, %r12
jne 0x57ab
movq 0x70(%r14), %r15
movq 0x78(%r14), %rbx
cmpq %rbx, %r15
je 0x591d
leaq -0xe8(%rbp), %r14
leaq -0xb8(%rbp), %r12
leaq -0xf8(%rbp), %r13
movq %r14, -0xf8(%rbp)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
movq %r13, %rdi
callq 0x4550
leaq -0xc8(%rbp), %rax
movq %rax, -0xd8(%rbp)
movq 0x20(%r15), %rsi
movq 0x28(%r15), %rdx
addq %rsi, %rdx
leaq -0xd8(%rbp), %rdi
callq 0x4550
addq $0x40, %r15
movq %r12, %rdi
movq %r15, %rsi
callq 0x5b86
movl 0x18(%r15), %eax
movl 0x1b(%r15), %ecx
movl %ecx, 0x4b(%r14)
movl %eax, 0x48(%r14)
movq %r13, %rdi
movq -0x30(%rbp), %rsi
callq 0x1a72c
movq %r12, %rdi
callq 0x4326
movq -0xd8(%rbp), %rdi
leaq -0xc8(%rbp), %rax
cmpq %rax, %rdi
je 0x58ff
callq 0x2200
movq -0xf8(%rbp), %rdi
cmpq %r14, %rdi
je 0x5910
callq 0x2200
addq $0x20, %r15
cmpq %rbx, %r15
jne 0x5876
leaq 0x16905(%rip), %rsi     # 0x1c229
movl $0x2, %edx
movq -0x30(%rbp), %rdi
callq 0x2280
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
jmp 0x5964
movq %rax, %rbx
movq -0xd8(%rbp), %rdi
leaq -0xc8(%rbp), %rax
cmpq %rax, %rdi
je 0x5964
callq 0x2200
movq -0xf8(%rbp), %rdi
cmpq %r14, %rdi
je 0x5997
callq 0x2200
jmp 0x5997
movq %rax, %rbx
leaq -0xf8(%rbp), %rdi
callq 0x419c
jmp 0x5997
movq %rax, %rbx
leaq -0xf8(%rbp), %rdi
callq 0x41da
movq %rbx, %rdi
callq 0x23b0
nop