in the methods of your class call the fm modules bdc open, bdc dynpro etc etc.
Incidently the following include will have a decent amount of code for the BDC bits.
A good way is to start sm35 to record what you are doing on the screen. When you've finished go to your recording in SM35 and click on CREATE PROGRAM - it will create most of the code for you including the screen fields -- you'll need to edit a bit of course as you don't need everything that will be shown.
Debugging in the CREATE PROGRAM might show you a decent generic way of generating BDC's which you could easily do via a class.
Note however using BDC's is the LEAST PREFRERRED WAY of performing work and should only be used as a LAST RESORT if there really is no other way. A lot of new BAPI's and Classes are now available which can do away with the need for BDC's in most cases.