s24344,
что-то класс тут не в тему, в jquery такой паттерн-плагин
https://learn.jquery.com/plugins/basic-plugin-creation/
$.fn.myNewPlugin = function() {
return this.each(function() {
// Do something to each element here.
});
};
$('selector').myNewPlugin();