Assume I make a custom Object:
function MyObject() {
  // define some properties
}
Now I want define a private method in the prototype:
MyObject.prototype = {
  // by doing this I defined a public method, how can I define a private method?
  myMethod: function() {
    //some code
  }
}
Then I want to call the function in the constructor like this:
function MyObject() {
  // define some properties
  call myMethod()
}
How can I do it?
 
     
    