@ Override public void sawOpcode ( int seen ) { if ( seen == Const . PUTFIELD ) { QMethod methodInfo = new QMethod ( getMethodName ( ) , getMethodSig ( ) ) ; Map < Map . Entry < String , String > , SourceLineAnnotation > fields = methodWrites . get ( methodInfo ) ; if ( fields == null ) { fields = new HashMap <> ( ) ; methodWrites . put ( methodInfo , fields ) ; } String fieldName = getNameConstantOperand ( ) ; String fieldSig = getSigConstantOperand ( ) ; FieldAnnotation fa = new FieldAnnotation ( getDottedClassName ( ) , fieldName , fieldSig , false ) ; fieldAnnotations . put ( fieldName , fa ) ; fields . put ( new AbstractMap . SimpleImmutableEntry ( fieldName , fieldSig ) , SourceLineAnnotation . fromVisitedInstruction ( this ) ) ; } }
implements the visitor to record storing of fields and where they occur