Q:

What does JQuery $(document).trigger(self.MY_FUNCTION) do?

I found the following code in a JavaScript object: 
;(function(App, $, undefined){

    if (typeof App == 'undefined') window.App = {};

    App.SomeObject = { 

         MY_FUNCTION: 'myfunction',

         myfunction: function(element) {
                var self = App.SomeObject;
                if (element.getSize() < 1) {
                   // case 1
                } else {
                       // case 2
                }

        },

        secondFunction: function() {
            var self = App.SomeObject;
            $(document).trigger(self.MY_FUNCTION);
        }

    }

})(App, jQuery);

In secondFunction I call
$(document).trigger(self.MY_FUNCTION);

What is this line actually doing?
When I call $(document).trigger(self.MY_FUNCTION); from another function which arguments is myfunction called with?
Edit: I copied this example from some other code but I did not get the meaning. I also see the following at some other part of the code:
myfunction(someElement);
$(document).trigger(self.MY_FUNCTION);

I do not get what it means.
Edit: From the JQuery trigger documentation I know that trigger will call the member function myfunction of SomeObject, but I do not know which parameters are being used. From my understanding the method will not work without any parameter because if (element.getSize() < 1) will give an error.     

A:

jQuery trigger use in 2 way:
A) .trigger( eventType [, extraParameters ] )
eventType
           Type: String
           A string containing a JavaScript event type, such as click or submit.

extraParameters
           Type: Array or PlainObject
           Additional parameters to pass along to the event handler.

B) .trigger( event [, extraParameters ] )
event
          Type: Event
          A jQuery.Event object.

extraParameters
          Type: Array or PlainObject
          Additional parameters to pass along to the event handler.

So you can fire and event by Trigger (Native events [click, submit,...] and Custom events [designed by jQuery Codes])
.
Edited:
In your case your are trying trigger one of document custom evens but some parts of you codes are Incomplete
You must assign your behavior to ducument first, then fire it with trigger.
I wrote a sample for you with explain each step HERE
Complete Code:
;(function($){
    App=$;

    console.log("Step 1 >> The class of My Object is defining as SomeObject \r\n.")
    App.SomeObject = { 
         BehaviorName: 'TestBehavior',

         TestBehavior: function(target, myElement) {
             console.log("Step 6 >> TestBehavior is Running now...\r\n.");
             var self = App.SomeObject;
             if ($(myElement).width() < 100) {
                 console.log("Step 7 >> element.width ("+$(myElement).width()+") is less than 100px\r\n.");
             } else {
                 console.log("Step 7 >> element.width ("+$(myElement).width()+") is greater than 100px\r\n.");
             }
        },
        secondFunction: function(myElement) {
            console.log("Step 4 >> secondFunction is Running now...\r\n.");
            var self = App.SomeObject;
            console.log("Step 5 >> Firing one of document custom events by TRIGGER and this details:\r\n          EvenType  =  self.BehaviorName (='TestBehavior')    &   otherParameters  =  element\r\n.");
            $(document).trigger(self.BehaviorName,myElement);
        }
    }        
})(jQuery);

console.log("Step 2 >> Assining a new behavior to the page document with this detail:\r\n          eventType = BehaviorName value of SomeObject    &   Handler  =  TestBehavior of SomeObject\r\n.")
$(document).on($.SomeObject.BehaviorName,$.SomeObject.TestBehavior);
console.log("Step 3 >> Calling secondFunction of SomeObject\r\n.")
$.SomeObject.secondFunction($('#sampleElement'));

Result:

Then your trigger can fire the assigned custom event to ducument, by using a EventType (as string) and extraParameters << using method A

