The below code is just a bit of a guess as I don't know which library you're using. You probably need a line like
JOYSTICK Joystick;
Look at the examples that come with the library. Please post a link to the library if you need further help; it does not seem to be a standard Arduino one.