Mates at any level in assembly document

Hi All,

I want to define mates for assembly documents.The top level document can contain many assemblies; which contain occurences as well as suboccurences. If I want to define the mating between occurence of one assembly and occurence of the other assembly ; then what is the ideal approach for creating mates?

Is finding the same parent for both occurences and then playing with that document object ? 


Always work with Top document and get the objects in respect to the top level document and then apply mates ?


Is there any difference in mates applied at such levels?

Here one can try mates at any level which Solid Edge support . Thats why need solution which helps to apply mates between any objects in the document tree. 


Please provide if anybody tried such codes(For all mates) ?