Convert from CPP to Objective-C

<Jacob>

Registered
I need someone to convert this code to Objective-C.
Code:
void UEncryption::SimpleEncryptDecrypt(Handle ioHandle)
{
	if (!ioHandle) return;
	const char *data="Good";
	Size handleSize=::GetHandleSize(ioHandle);
	
	for (Size index=0; index<handleSize; index++)
	{
		// xor with char from keyword string
		(*ioHandle)[index]^=*data;

		// wrap when a null char is hit
		data++;
		if (!*data) data="Good";
	}
}

Thank you,
Jacob
 
Back
Top