<s> package org . eclipse . jdt . core ; import org . eclipse . jdt . core . compiler . IProblem ; public abstract class CompletionRequestor { private int ignoreSet = 0 ; private String [ ] favoriteReferences ; private int requiredProposalAllowSet [ ] = null ; private boolean requireExtendedContext = false ; public CompletionRequestor ( ) { this ( false ) ; } public CompletionRequestor ( boolean ignoreAll ) { this . ignoreSet = ignoreAll ? 0xffffffff : 0x00000000 ; } public boolean isIgnored ( int completionProposalKind ) { if ( completionProposalKind < CompletionProposal . FIRST_KIND || completionProposalKind > CompletionProposal . LAST_KIND ) { throw new IllegalArgumentException ( "" + completionProposalKind ) ; } return 0 != ( this . ignoreSet & ( 1 << completionProposalKind ) ) ; } public void setIgnored ( int completionProposalKind , boolean ignore ) { if ( completionProposalKind < CompletionProposal . FIRST_KIND || completionProposalKind > CompletionProposal . LAST_KIND ) { throw new IllegalArgumentException ( "" + completionProposalKind ) ; } if ( ignore ) { this . ignoreSet |= ( 1 << completionProposalKind ) ; } else { this . ignoreSet &= ~ ( 1 << completionProposalKind ) ; } } public boolean isAllowingRequiredProposals ( int proposalKind , int requiredProposalKind ) { if ( proposalKind < CompletionProposal . FIRST_KIND || proposalKind > CompletionProposal . LAST_KIND ) { throw new IllegalArgumentException ( "" + requiredProposalKind ) ; } if ( requiredProposalKind < CompletionProposal . FIRST_KIND || requiredProposalKind > CompletionProposal . LAST_KIND ) { throw new IllegalArgumentException ( "" + requiredProposalKind ) ; } if ( this . requiredProposalAllowSet == null ) return false ; return 0 != ( this . requiredProposalAllowSet [ proposalKind ] & ( 1 << requiredProposalKind ) ) ; } public void setAllowsRequiredProposals ( int proposalKind , int requiredProposalKind , boolean allow ) { if ( proposalKind < CompletionProposal . FIRST_KIND || proposalKind > CompletionProposal . LAST_KIND ) { throw new IllegalArgumentException ( "" + requiredProposalKind ) ; } if ( requiredProposalKind < CompletionProposal . FIRST_KIND || requiredProposalKind > CompletionProposal . LAST_KIND ) { throw new IllegalArgumentException ( "" + requiredProposalKind ) ; } if ( this . requiredProposalAllowSet == null ) { this . requiredProposalAllowSet = new int [ CompletionProposal . LAST_KIND + 1 ] ; } if ( allow ) { this . requiredProposalAllowSet [ proposalKind ] |= ( 1 << requiredProposalKind ) ; } else { this . requiredProposalAllowSet [ proposalKind ] &= ~ ( 1 << requiredProposalKind ) ; } } public String [ ] getFavoriteReferences ( ) { return this . favoriteReferences ; } public void setFavoriteReferences ( String [ ] favoriteImports ) { this . favoriteReferences = favoriteImports ; } public void beginReporting ( ) { } public void endReporting ( ) { } public void completionFailure ( IProblem problem ) { } public abstract void accept ( CompletionProposal proposal ) ; public void acceptContext ( CompletionContext context ) { } public boolean isExtendedContextRequired ( ) { return this . requireExtendedContext ; } public void setRequireExtendedContext ( boolean require ) { this . requireExtendedContext = require ; } } </s>