Implement init function to retrieve parameters.