protected String getUniqueId ( final Session session ) { if ( cached_id != null ) { return cached_id ; } // // Calculated an new Id // // this line ripped from the "describe" method // seems to help with some types like "equal" cached_id = new String ( ) ; // // If object is a leaf node, then we'll use John's original code... // Otherwise we need to generate and Id based on what our children are // if ( getType ( ) != OpTypes . VALUE && getType ( ) != OpTypes . COLUMN ) { // // Horribly inefficient, but it works for now... // traverse ( this , session ) ; } long nodeId = session . getNodeIdForExpression ( this ) ; cached_id = Long . toString ( nodeId ) ; return cached_id ; }
Get the hex address of this Expression Object in memory to be used as a unique identifier .