private boolean equivFields ( JSField one , JSField two ) { if ( one instanceof JSDynamic ) { return two instanceof JSDynamic ; } else if ( one instanceof JSEnum ) { return two instanceof JSEnum ; } else if ( one instanceof JSPrimitive ) { return ( two instanceof JSPrimitive ) && ( ( JSPrimitive ) one ) . getTypeCode ( ) == ( ( JSPrimitive ) two ) . getTypeCode ( ) ; } else if ( one instanceof JSVariant ) { // we assume without checking that JSVariants in this context must be boxed return ( two instanceof JSVariant ) && ( ( JSVariant ) one ) . getBoxed ( ) . getID ( ) == ( ( JSVariant ) two ) . getBoxed ( ) . getID ( ) ; } else return false ; }
here is too specialized .