Added all required functionality.