This method is called when the parser finishes creating the element. This particularly means that it has done everything you would expect it to have done after it encounters the > at the end of the tag (for HTML or XML). This includes setting the attributes, setting the document / form, and placing the element into the tree at its proper place.
For container elements, this is called *before* any of the children are created or added into the tree.
NOTE: this is currently only called for input and button, in the HTML content sink. If you want to call it on your element, modify the content sink of your choice to do so. This is an efficiency measure.
If you also need to determine whether the parser is the one creating your element (through createElement() or cloneNode() generally) then add a boolean aFromParser to the NS_NewXXX() constructor for your element and have the parser pass true. See nsHTMLInputElement.cpp and nsHTMLContentSink::MakeContentObject().