Buggy code:
public void elementEncode ( XMLWriter writer , IPath projectPath , boolean indent , boolean newLine ) { } private void encodeExtraAttributes ( XMLWriter writer , boolean indent , boolean newLine ) { } private void encodeAccessRules ( XMLWriter writer , boolean indent , boolean newLine ) { } private void encodeAccessRule ( AccessRule accessRule , XMLWriter writer , boolean indent , boolean newLine ) { } public static IClasspathEntry elementDecode ( Element element , IJavaProject project ) { } private static void encodePatterns ( IPath [ ] patterns , String tag , Map parameters ) { } public boolean equals ( Object object ) { } private static boolean equalAttributes ( IClasspathAttribute [ ] firstAttributes , IClasspathAttribute [ ] secondAttributes ) { } private static boolean equalPatterns ( IPath [ ] firstPatterns , IPath [ ] secondPatterns ) { } public IAccessRule [ ] getAccessRules ( ) { } public AccessRuleSet getAccessRuleSet ( ) { } public int getContentKind ( ) { } public int getEntryKind ( ) { } public IPath [ ] getExclusionPatterns ( ) { } public IClasspathAttribute [ ] getExtraAttributes ( ) { } private String getMessageTemplate ( ) { } public IPath [ ] getInclusionPatterns ( ) { } public IPath getOutputLocation ( ) { } public IPath getPath ( ) { } public IPath getSourceAttachmentPath ( ) { } public IPath getSourceAttachmentRootPath ( ) { } public int hashCode ( ) { } public boolean isExported ( ) { } static int kindFromString ( String kindStr ) { } static String kindToString ( int kind ) { } public static IAccessRule [ ] getAccessRules ( IPath [ ] accessibleFiles , IPath [ ] nonAccessibleFiles ) { } public String toString ( ) { StringBuffer buffer = new StringBuffer ( ) ; buffer . append ( getPath ( ) . toString ( ) ) ; buffer . append ( '[' ) ; switch ( getEntryKind ( ) ) { case IClasspathEntry . CPE_LIBRARY : buffer . append ( "CPE_LIBRARY" ) ; break ; case IClasspathEntry . CPE_PROJECT : buffer . append ( "CPE_PROJECT" ) ; break ; case IClasspathEntry . CPE_SOURCE : buffer . append ( "CPE_SOURCE" ) ; break ; case IClasspathEntry . CPE_VARIABLE : buffer . append ( "CPE_VARIABLE" ) ; break ; case IClasspathEntry . CPE_CONTAINER : buffer . append ( "CPE_CONTAINER" ) ; break ; } buffer . append ( "][" ) ; switch ( getContentKind ( ) ) { case IPackageFragmentRoot . K_BINARY : buffer . append ( "K_BINARY" ) ; break ; case IPackageFragmentRoot . K_SOURCE : buffer . append ( "K_SOURCE" ) ; break ; case ClasspathEntry . K_OUTPUT : buffer . append ( "K_OUTPUT" ) ; break ; } buffer . append ( ']' ) ; if ( ( getSourceAttachmentPath ( ) ) != null ) { buffer . append ( "[sourcePath:" ) ; buffer . append ( getSourceAttachmentPath ( ) ) ; buffer . append ( ']' ) ; } if ( ( getSourceAttachmentRootPath ( ) ) != null ) { buffer . append ( "[rootPath:" ) ; buffer . append ( getSourceAttachmentRootPath ( ) ) ; buffer . append ( ']' ) ; } buffer . append ( "[isExported:" ) ; buffer . append ( this . isExported ) ; buffer . append ( ']' ) ; IPath [ ] patterns = this . inclusionPatterns ; int length ; if ( ( length = ( patterns == null ) ? 0 : patterns . length ) > 0 ) { buffer . append ( "[including:" ) ; for ( int i = 0 ; i < length ; i ++ ) { buffer . append ( patterns [ i ] ) ; if ( i != ( length - 1 ) ) { buffer . append ( '|' ) ; } } buffer . append ( ']' ) ; } patterns = this . exclusionPatterns ; if ( ( length = ( patterns == null ) ? 0 : patterns . length ) > 0 ) { buffer . append ( "[excluding:" ) ; for ( int i = 0 ; i < length ; i ++ ) { buffer . append ( patterns [ i ] ) ; if ( i != ( length - 1 ) ) { buffer . append ( '|' ) ; } } buffer . append ( ']' ) ; } if ( ( this . accessRuleSet ) != null ) { buffer . append ( '[' ) ; <START_BUG> buffer . append ( this . accessRuleSet ) ; <END_BUG> buffer . append ( ']' ) ; } if ( ( this . entryKind ) == ( IClasspathEntry . CPE_PROJECT ) ) { buffer . append ( "[combine<seq2seq4repair_space>access<seq2seq4repair_space>rules:" ) ; buffer . append ( this . combineAccessRules ) ; buffer . append ( ']' ) ; } if ( ( getOutputLocation ( ) ) != null ) { buffer . append ( "[output:" ) ; buffer . append ( getOutputLocation ( ) ) ; buffer . append ( ']' ) ; } if ( ( length = ( ( this . extraAttributes ) == null ) ? 0 : this . extraAttributes . length ) > 0 ) { buffer . append ( "[attributes:" ) ; for ( int i = 0 ; i < length ; i ++ ) { buffer . append ( this . extraAttributes [ i ] ) ; if ( i != ( length - 1 ) ) { buffer . append ( ',' ) ; } } buffer . append ( ']' ) ; } return buffer . toString ( ) ; } public String rootID ( ) { } public IClasspathEntry getResolvedEntry ( ) { } public static IJavaModelStatus validateClasspath ( IJavaProject javaProject , IClasspathEntry [ ] rawClasspath , IPath projectOutputLocation ) { } public static IJavaModelStatus validateClasspathEntry ( IJavaProject project , IClasspathEntry entry , boolean checkSourceAttachment , boolean recurseInContainers ) { } }

Fix:
buffer . append ( this . accessRuleSet . toString ( false ) ) ;