Reorganise general module files

Move files containing general module features and settings to its own
folder.
Also moved the ruby extensions file to its own folder.
This creates better separation between the general module code and the
specific DICOM related code.
Note that the file with deprecated code was also moved to the general
folder.