def add_register_user(<EOL>self, username, first_name, last_name, email, password="<STR_LIT>", hashed_password="<STR_LIT>"<EOL>):
register_user = self.registeruser_model()<EOL>register_user.username = username<EOL>register_user.email = email<EOL>register_user.first_name = first_name<EOL>register_user.last_name = last_name<EOL>if hashed_password:<EOL><INDENT>register_user.password = hashed_password<EOL><DEDENT>else:<EOL><INDENT>register_user.password = generate_password_hash(password)<EOL><DEDENT>register_user.registration_hash = str(uuid.uuid1())<EOL>try:<EOL><INDENT>self.get_session.add(register_user)<EOL>self.get_session.commit()<EOL>return register_user<EOL><DEDENT>except Exception as e:<EOL><INDENT>log.error(c.LOGMSG_ERR_SEC_ADD_REGISTER_USER.format(str(e)))<EOL>self.appbuilder.get_session.rollback()<EOL>return None<EOL><DEDENT>
Add a registration request for the user.

:rtype : RegisterUser