Creating a Class / Object with JQuery

Creating a Class / Object with JQuery

Hello

I know this is really basic, but can someone point me in the right direction? I'd like to create a JS class/object where "this" is a reference in the object to its properties and methods. Something like this - only I haven't quite got it:

  1. var nameOfClass = ({
  2.       function nameOfClass(options) {
  3.             //code here
  4.       },
  5.       nameOfClass.prototype = {
  6.             initialize: function(options) {
  7.                   //first method
  8.             },
  9.             run: function() {
  10.                   //another method and so on
  11.             }
  12.       }
  13.       return nameOfClass;
  14. })();
What am I doing wrong - and how do I call this class once I've got it created properly?

Thanks a lot guys!!