buggy_function
stringlengths
1
391k
fixed_function
stringlengths
0
392k
public TypeBinding resolveType(BlockScope scope) { // due to syntax lhs may be only a NameReference, a FieldReference or an ArrayReference this.constant = Constant.NotAConstant; if (!(this.lhs instanceof Reference) || this.lhs.isThis()) { scope.problemReporter().expressionShouldBeAVariable(this.lhs); return null...
public TypeBinding resolveType(BlockScope scope) { // due to syntax lhs may be only a NameReference, a FieldReference or an ArrayReference this.constant = Constant.NotAConstant; if (!(this.lhs instanceof Reference) || this.lhs.isThis()) { scope.problemReporter().expressionShouldBeAVariable(this.lhs); return null...
public void save(IProgressMonitor progress, boolean force) throws JavaModelException { // determine if saving is required if (isReadOnly() || this.file == null) { return; } synchronized (this.lock) { if (!hasUnsavedChanges()) return; // use a platform operation to update the resource contents try {...
public void save(IProgressMonitor progress, boolean force) throws JavaModelException { // determine if saving is required if (isReadOnly() || this.file == null) { return; } synchronized (this.lock) { if (!hasUnsavedChanges()) return; // use a platform operation to update the resource contents try {...
protected int resolveLevel(MessageSend messageSend) { MethodBinding method = messageSend.binding; if (method != null) method = method.original(); if (method == null) return INACCURATE_MATCH; int methodLevel = matchMethod(method); if (methodLevel == IMPOSSIBLE_MATCH) return IMPOSSIBLE_MATCH; // receiver type c...
protected int resolveLevel(MessageSend messageSend) { MethodBinding method = messageSend.binding; if (method != null) method = method.original(); if (method == null) return INACCURATE_MATCH; int methodLevel = matchMethod(method); if (methodLevel == IMPOSSIBLE_MATCH) return IMPOSSIBLE_MATCH; // receiver type c...
public void createControl(Composite parent) { if (getControl() != null) return; partReference.addPropertyListener(this); // Create view form. control = new Composite(parent, SWT.NONE); control.setLayout(new FillLayout()); // the part should never be visi...
public void createControl(Composite parent) { if (getControl() != null) return; partReference.addPropertyListener(this); // Create view form. control = new Composite(parent, SWT.NONE); control.setLayout(new FillLayout()); // the part should never be visi...
public void mouseClicked(MouseEvent event) { if(event.getClickCount()<2 || event.isPopupTrigger()){ return; }else if(event.getClickCount()>1 && event.getButton() == MouseEvent.BUTTON2_MASK){ return; } TableColumnModel colModel = getColumnModel(); int index = colModel.getColumnIndexAtX...
public void mouseClicked(MouseEvent event) { if(event.getClickCount()<2 || event.isPopupTrigger()){ return; }else if(event.getClickCount()>1 && ((event.getModifiers() & MouseEvent.BUTTON2_MASK)>0)){ return; } TableColumnModel colModel = getColumnModel(); int index = colModel.getColumn...
public final static String NA = "?"; static final long serialVersionUID = -1325822038990805636L; // Check if we are running in IBM's visual age. static boolean inVisualAge = false; static { try { Class dummy = Loader.loadClass("com.ibm.uvm.tools.DebugSupport"); inVisualAge = true; Log...
public final static String NA = "?"; static final long serialVersionUID = -1325822038990805636L; // Check if we are running in IBM's visual age. static boolean inVisualAge = false; static { try { Class dummy = Class.forName("com.ibm.uvm.tools.DebugSupport"); inVisualAge = true; LogLog...
public String toString(){ return "indexing " + resource.getName(); }
public String toString(){ return "indexing "/*nonNLS*/ + resource.getName(); }
protected void stopService() { try { // Remove SM from JNDI new InitialContext().unbind(JNDI_NAME); } catch (CommunicationException e) { // Do nothing, the naming services is already stopped } } catch (Exception e) { lo...
protected void stopService() { try { // Remove SM from JNDI new InitialContext().unbind(JNDI_NAME); } catch (CommunicationException e) { // Do nothing, the naming services is already stopped } catch (Exception e) { log....
protected boolean parseHtmlTag(int previousPosition, int endTextPosition) throws InvalidInputException { if (!this.parseHtmlTags) return false; boolean closing = false; boolean valid = false; boolean incremented = false; int start = this.scanner.currentPosition; int currentPosition = start; int...
protected boolean parseHtmlTag(int previousPosition, int endTextPosition) throws InvalidInputException { if (!this.parseHtmlTags) return false; boolean closing = false; boolean valid = false; boolean incremented = false; int start = this.scanner.currentPosition; int currentPosition = start; int...
public IJavaElement getWorkingCopy() throws JavaModelException { return this.getWorkingCopy(null, null); }
public IJavaElement getWorkingCopy() throws JavaModelException { return this.getWorkingCopy(null, null, null); }
public final int sourceStart() { return this.scope.referenceContext.sourceStart; } SimpleLookupTable storedAnnotations(boolean forceInitialize) { if (forceInitialize && this.storedAnnotations == null) { this.scope.referenceCompilationUnit().compilationResult.hasAnnotations = true; if (!this.scope.environment().gl...
public final int sourceStart() { return this.scope.referenceContext.sourceStart; } SimpleLookupTable storedAnnotations(boolean forceInitialize) { if (forceInitialize && this.storedAnnotations == null && this.scope != null) { // scope null when no annotation cached, and type got processed fully (159631) this.scope.r...
public int getNodeType() { return CONTINUE_STATEMENT; } /* (omit javadoc for this method) * Method declared on ASTNode. */ ASTNode clone(AST target) { ContinueStatement result = new ContinueStatement(target); result.setSourceRange(this.getStartPosition(), this.getLength()); result.copyLeadingComment(th...
public int getNodeType() { return CONTINUE_STATEMENT; } /* (omit javadoc for this method) * Method declared on ASTNode. */ ASTNode clone0(AST target) { ContinueStatement result = new ContinueStatement(target); result.setSourceRange(this.getStartPosition(), this.getLength()); result.copyLeadingComment(t...
public int getNodeType() { return VARIABLE_DECLARATION_EXPRESSION; } /* (omit javadoc for this method) * Method declared on ASTNode. */ ASTNode clone(AST target) { VariableDeclarationExpression result = new VariableDeclarationExpression(target); result.setSourceRange(this.getStartPosition(), this.get...
public int getNodeType() { return VARIABLE_DECLARATION_EXPRESSION; } /* (omit javadoc for this method) * Method declared on ASTNode. */ ASTNode clone0(AST target) { VariableDeclarationExpression result = new VariableDeclarationExpression(target); result.setSourceRange(this.getStartPosition(), this.ge...
public UMLAddDialog(Vector choices, Vector selected, String title, ListCellRenderer renderer, boolean multiselectAllowed, boolean exclusive) { if (choices == null) throw new IllegalArgumentException("There should allways be choices in UMLAddDialog"); if (exclusive && selected != null && !selected.isEmpty()) { c...
public UMLAddDialog(Vector choices, Vector selected, String title, ListCellRenderer renderer, boolean multiselectAllowed, boolean exclusive) { if (choices == null) throw new IllegalArgumentException("There should allways be choices in UMLAddDialog"); if (exclusive && selected != null && !selected.isEmpty()) { c...
public Collection getAllPossibleNamespaces(MModelElement m) { List ret = new ArrayList(); if (m == null) return ret; MNamespace model = ProjectManager.getManager().getCurrentProject().getModel(); if (isValidNamespace(m, model)) ret.add(model); ...
public Collection getAllPossibleNamespaces(MModelElement m) { List ret = new ArrayList(); if (m == null) return ret; MNamespace model = ProjectManager.getManager().getCurrentProject().getRoot(); if (isValidNamespace(m, model)) ret.add(model); ...
public void setTabHeight(int height) { tabFolder.setTabHeight(height + 1); }
public void setTabHeight(int height) { tabFolder.setTabHeight(height); }
extends BaseAttachment package org.tigris.scarab.om; // JDK classes import java.util.*; // Turbine classes import org.apache.turbine.om.*; import org.apache.turbine.om.peer.BasePeer; import org.apache.turbine.util.db.Criteria; import org.apache.turbine.util.ObjectUtils; import org.apache.turbine.util.StringUtils; im...
extends BaseAttachment package org.tigris.scarab.om; // JDK classes import java.util.*; // Turbine classes import org.apache.turbine.om.*; import org.apache.turbine.om.peer.BasePeer; import org.apache.turbine.util.db.Criteria; import org.apache.turbine.util.ObjectUtils; import org.apache.turbine.util.StringUtils; im...
public RegisterViewer(View view, String position) { super(new BorderLayout()); this.view = view; JLabel label = new JLabel( jEdit.getProperty("view-registers.title")); label.setBorder(new EmptyBorder(0,0,3,0)); add(BorderLayout.NORTH,label); DefaultListModel registerModel = new DefaultListModel(); r...
public RegisterViewer(View view, String position) { super(new BorderLayout()); this.view = view; JLabel label = new JLabel( jEdit.getProperty("view-registers.title")); label.setBorder(new EmptyBorder(0,0,3,0)); add(BorderLayout.NORTH,label); DefaultListModel registerModel = new DefaultListModel(); r...
public void describeLayout(StringBuffer buf) { if (this instanceof ILayoutContainer) { LayoutPart[] children = ((ILayoutContainer)this).getChildren(); int visibleChildren = 0; for (int idx = 0; idx < children.length; idx++) { LayoutPart next = children[idx]; if (!(next instanceof PartPlaceholder)...
public void describeLayout(StringBuffer buf) { if (this instanceof ILayoutContainer) { LayoutPart[] children = ((ILayoutContainer)this).getChildren(); int visibleChildren = 0; for (int idx = 0; idx < children.length; idx++) { LayoutPart next = children[idx]; if (!(next instanceof PartPlaceholder)...
public static ClusterRegistry getRegistry(NamingContextHostPort[] hp) throws RemoteException { int n = hp.length; if (n == 0) return null; ClusterRegistry r = getRegistry(hp[0].host, hp[0].port); if (n == 1) return r; ClusterRegistryImplCStub cstub = new ClusterRegist...
public static ClusterRegistry getRegistry(NamingContextHostPort[] hp) throws RemoteException { int n = hp.length; if (n == 0) return null; ClusterRegistry r = getRegistry(hp[0].host, hp[0].port); if (n == 1) return r; ClusterRegistryImpl_Cluster cstub = new ClusterReg...
public void generateSyntheticFieldInitializationsIfNecessary( MethodScope methodScope, CodeStream codeStream, ReferenceBinding declaringClass) { if (!declaringClass.isNestedType()) return; NestedTypeBinding nestedType = (NestedTypeBinding) declaringClass; SyntheticArgumentBinding[] syntheticArgs = ...
public void generateSyntheticFieldInitializationsIfNecessary( MethodScope methodScope, CodeStream codeStream, ReferenceBinding declaringClass) { if (!declaringClass.isNestedType()) return; NestedTypeBinding nestedType = (NestedTypeBinding) declaringClass; SyntheticArgumentBinding[] syntheticArgs = ...
public void loadDefaultPosition() { super.dock(messageViewerDockable, IDock.REGION.CENTER); }
public void loadDefaultPosition() { //super.dock(messageViewerDockable, IDock.REGION.CENTER); }
public final int problemId() { return problemId; }
public final int problemId() { return this.problemId; }
public ClasspathEntry combineWith(IClasspathEntry referringEntry) { if (referringEntry == null) return this; if (referringEntry.isExported() || referringEntry.getInclusionPatterns().length > 0 || referringEntry.getExclusionPatterns().length > 0) { return new ClasspathEntry( this.getContentKind...
public ClasspathEntry combineWith(IClasspathEntry referringEntry) { if (referringEntry == null) return this; if (referringEntry.isExported() || referringEntry.getInclusionPatterns().length > 0 || referringEntry.getExclusionPatterns().length > 0) { return new ClasspathEntry( this.getContentKind...
public Object getPlugin(String name, Object[] args) throws Exception { ColumbaLogger.log.info("name=" + name); ColumbaLogger.log.info("arguments=" + args); String className = getPluginClassName(name, "class"); ColumbaLogger.log.info("class=" + className); if (classN...
public Object getPlugin(String name, Object[] args) throws Exception { ColumbaLogger.log.info("name=" + name); ColumbaLogger.log.info("arguments=" + args); String className = getPluginClassName(name, "class"); ColumbaLogger.log.info("class=" + className); if (classN...
public static String getSystemProperty(String key, String def) { try { return System.getProperty(key, def); } catch(SecurityException e) { LogLog.debug("Was not allowed to read system property \""+key+"\"."); return def; } }
public static String getSystemProperty(String key, String def) { try { return System.getProperty(key, def); } catch(Throwable e) { // MS-Java throws com.ms.security.SecurityExceptionEx LogLog.debug("Was not allowed to read system property \""+key+"\"."); return def; } }
private static Mnemonic types = new TypeMnemonic(); static { types.add(A, "A"); types.add(NS, "NS"); types.add(MD, "MD"); types.add(MF, "MF"); types.add(CNAME, "CNAME"); types.add(SOA, "SOA"); types.add(MB, "MB"); types.add(MG, "MG"); types.add(MR, "MR"); types.add(NULL, "NULL"); types.add(WKS, "WKS"); typ...
private static Mnemonic types = new TypeMnemonic(); static { types.add(A, "A"); types.add(NS, "NS"); types.add(MD, "MD"); types.add(MF, "MF"); types.add(CNAME, "CNAME"); types.add(SOA, "SOA"); types.add(MB, "MB"); types.add(MG, "MG"); types.add(MR, "MR"); types.add(NULL, "NULL"); types.add(WKS, "WKS"); typ...
public CodeSnippetClassFile( org.eclipse.jdt.internal.compiler.lookup.SourceTypeBinding aType, org.eclipse.jdt.internal.compiler.ClassFile enclosingClassFile, boolean creatingProblemType) { /** * INTERNAL USE-ONLY * This methods creates a new instance of the receiver. * * @param aType org.eclipse.jdt.intern...
public CodeSnippetClassFile( org.eclipse.jdt.internal.compiler.lookup.SourceTypeBinding aType, org.eclipse.jdt.internal.compiler.ClassFile enclosingClassFile, boolean creatingProblemType) { /** * INTERNAL USE-ONLY * This methods creates a new instance of the receiver. * * @param aType org.eclipse.jdt.intern...
public TypeBinding resolveTypeExpecting(BlockScope scope, TypeBinding expectedTb) { // Array initializers can only occur on the right hand side of an assignment // expression, therefore the expected type contains the valid information // concerning the type that must be enforced by the elements of the array init...
public TypeBinding resolveTypeExpecting(BlockScope scope, TypeBinding expectedTb) { // Array initializers can only occur on the right hand side of an assignment // expression, therefore the expected type contains the valid information // concerning the type that must be enforced by the elements of the array init...
public boolean close() { if (showShortcutTab()) { lastSelectedMenuIndex = menusCombo.getSelectionIndex(); } lastSelectedTab = tabFolder.getSelectionIndex(); StructuredSelection selection = (StructuredSelection) actionSetsViewer .getSelection(); if ...
public boolean close() { if (showShortcutTab()) { lastSelectedMenuIndex = menusCombo.getSelectionIndex(); } lastSelectedTab = tabFolder.getSelectionIndex(); IStructuredSelection selection = (IStructuredSelection) actionSetsViewer .getSelection(); i...
protected void processAnnotations() { int newUnitSize = 0; int newClassFilesSize = 0; int bottom = 0; int top = this.unitsToProcess.length; ReferenceBinding[] binaryTypeBindingsTemp = this.referenceBindings; if (top == 0 && binaryTypeBindingsTemp == null) return; this.referenceBindings = null; do { ...
protected void processAnnotations() { int newUnitSize = 0; int newClassFilesSize = 0; int bottom = 0; int top = this.unitsToProcess.length; ReferenceBinding[] binaryTypeBindingsTemp = this.referenceBindings; if (top == 0 && binaryTypeBindingsTemp == null) return; this.referenceBindings = null; do { ...
public void service(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { Request req=((HttpServletRequestFacade)request).getRealRequest(); Context ctx=req.getContext(); String realm=ctx.getRealmName(); if( "FORM".equals( ctx.getAuthMethod() )) { // the co...
public void service(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { Request req=((HttpServletRequestFacade)request).getRealRequest(); Context ctx=req.getContext(); String realm=ctx.getRealmName(); if( "EXPERIMENTAL_FORM".equals( ctx.getAuthMethod() )) { ...
public Object addMessage(InputStream in, Attributes attributes ) throws Exception { // get headerlist before adding a message getHeaderList(); int size = in.available(); // call addMessage of superclass LocalFolder // to do the dirty work Object newUid = super.addMe...
public Object addMessage(InputStream in, Attributes attributes ) throws Exception { // get headerlist before adding a message getHeaderList(); int size = in.available(); // call addMessage of superclass LocalFolder // to do the dirty work Object newUid = super.addMe...
protected void toStringInfo(int tab, StringBuffer buffer, Object info) { buffer.append(this.tabString(tab)); buffer.append("import "); //$NON-NLS-1$ toStringName(buffer); if (info == null) { buffer.append(" (not open)"); //$NON-NLS-1$ } } }
protected void toStringInfo(int tab, StringBuffer buffer, Object info, boolean showResolvedInfo) { buffer.append(this.tabString(tab)); buffer.append("import "); //$NON-NLS-1$ toStringName(buffer); if (info == null) { buffer.append(" (not open)"); //$NON-NLS-1$ } } }
private Record parseRR(MyStringTokenizer st, boolean useLast, Record last, Name origin) throws IOException { Name name; int ttl; short type, dclass; if (!useLast) name = Name.fromString(st.nextToken(), origin); else name = last.getName(); String s = st.nextToken(); try { ttl = TTL.parseTTL(s); s = st....
private Record parseRR(MyStringTokenizer st, boolean useLast, Record last, Name origin) throws IOException { Name name; int ttl; short type, dclass; if (!useLast) name = Name.fromString(st.nextToken(), origin); else name = last.getName(); String s = st.nextToken(); try { ttl = TTL.parseTTL(s); s = st....
public static void selectAndConfigure( URL url, String clazz, LoggerRepository hierarchy) { Configurator configurator = null; String filename = url.getFile(); if ((clazz == null) && (filename != null) && filename.endsWith(".xml")) { clazz = "org.apache.log4j.xml.DOMConfigurator"; } if ...
public static void selectAndConfigure( URL url, String clazz, LoggerRepository hierarchy) { Configurator configurator = null; String filename = url.getFile(); if ((clazz == null) && (filename != null) && filename.endsWith(".xml")) { clazz = "org.apache.log4j.joran.JoranConfigurator"; } ...
private ILabelDecorator decorator;
public boolean isFull() { return true; } }
public int compare(Viewer testViewer, Object e1, Object e2) { return ((Comparable) e1).compareTo(e2); } }); ProgressTreeContentProvider provider = new ProgressTreeContentProvider( viewer, !Policy.DEBUG_SHOW_SYSTEM_JOBS); ...
public int compare(Viewer testViewer, Object e1, Object e2) { return ((Comparable) e1).compareTo(e2); } }); ProgressTreeContentProvider provider = new ProgressTreeContentProvider( viewer, Policy.DEBUG_SHOW_SYSTEM_JOBS); ...
public void locateMatches(SearchDocument[] indexMatches, SearchPattern pattern, IJavaSearchScope scope, SearchRequestor requestor, IProgressMonitor monitor) throws CoreException { MatchLocator matchLocator = new MatchLocator( pattern, requestor, scope, monitor == null ? null : new SubProg...
public void locateMatches(SearchDocument[] indexMatches, SearchPattern pattern, IJavaSearchScope scope, SearchRequestor requestor, IProgressMonitor monitor) throws CoreException { MatchLocator matchLocator = new MatchLocator( pattern, requestor, scope, monitor ); /* eliminating false...
private ASTNode internalCreateAST(IProgressMonitor monitor) { boolean needToResolveBindings = this.resolveBindings; switch(this.astKind) { case K_CLASS_BODY_DECLARATIONS : case K_EXPRESSION : case K_STATEMENTS : if (this.rawSource != null) { if (this.sourceOffset + this.sourceLength > this.rawSou...
private ASTNode internalCreateAST(IProgressMonitor monitor) { boolean needToResolveBindings = this.resolveBindings; switch(this.astKind) { case K_CLASS_BODY_DECLARATIONS : case K_EXPRESSION : case K_STATEMENTS : if (this.rawSource != null) { if (this.sourceOffset + this.sourceLength > this.rawSou...
public SetResponse addMessage(Message in) { boolean isAuth = in.getHeader().getFlag(Flags.AA); Record question = in.getQuestion(); Name qname; Name curname; int qtype; int qclass; int cred; int rcode = in.getHeader().getRcode(); boolean haveAnswer = false; boolean completed = false; RRset [] answers, auth, a...
public SetResponse addMessage(Message in) { boolean isAuth = in.getHeader().getFlag(Flags.AA); Record question = in.getQuestion(); Name qname; Name curname; int qtype; int qclass; int cred; int rcode = in.getHeader().getRcode(); boolean haveAnswer = false; boolean completed = false; RRset [] answers, auth, a...
private void configureFromProject(IJavaProject project) throws JavaModelException { workspace= project.getJavaModel().getWorkspace(); fPackageFragmentRoots= ((JavaProject) project).getAllPackageFragmentRoots(); fPackageFragments= new Hashtable(); IPackageFragment[] frags= ((JavaProject) project).getAllPackageF...
private void configureFromProject(IJavaProject project) throws JavaModelException { workspace= project.getJavaModel().getWorkspace(); fPackageFragmentRoots= ((JavaProject) project).getAllPackageFragmentRoots(); fPackageFragments= new Hashtable(); IPackageFragment[] frags= ((JavaProject) project).getPackageFrag...
public boolean hideView(IViewReference ref) { // If the view is locked just return. ViewPane pane = getPane(ref); // Remove the view from the current presentation. if (isFastView(ref)) { if (pane != null) { pane.setFast(false); //force an update of the toolbar } ...
public boolean hideView(IViewReference ref) { // If the view is locked just return. ViewPane pane = getPane(ref); // Remove the view from the current presentation. if (isFastView(ref)) { if (pane != null) { pane.setFast(false); //force an update of the toolbar } ...
private KeyBindingManager() { super(); AcceleratorRegistry acceleratorRegistry = WorkbenchPlugin.getDefault().getAcceleratorRegistry(); AcceleratorConfiguration[] acceleratorConfigurations = acceleratorRegistry.getConfigurations(); for (int i = 0; i < acceleratorConfigurations.length; i++) ...
private KeyBindingManager() { super(); AcceleratorRegistry acceleratorRegistry = WorkbenchPlugin.getDefault().getAcceleratorRegistry(); AcceleratorConfiguration[] acceleratorConfigurations = acceleratorRegistry.getConfigurations(); for (int i = 0; i < acceleratorConfigurations.length; i++) ...
public void aboutToResolve(Scope scope) { getTypeBinding(scope.parent); // step up from the ClassScope }
public void aboutToResolve(Scope scope) { getTypeBinding(scope); }
private CompilationUnitScope scope; /** * The working copy owner that defines the context in which this resolver is creating the bindings. */ WorkingCopyOwner workingCopyOwner; /* * The compilation unit resolver that 'compile' the requested ASTs during batching */ CompilationUnitResolver compilationUni...
private CompilationUnitScope scope; /** * The working copy owner that defines the context in which this resolver is creating the bindings. */ WorkingCopyOwner workingCopyOwner; /* * The compilation unit resolver that 'compile' the requested ASTs during batching */ CompilationUnitResolver compilationUni...
public void testCopyMessageAttribute2() throws Exception { // add message "0.eml" as inputstream to folder String input = FolderTstHelper.getString(0); System.out.println("input=" + input); // create stream from string ByteArrayInputStream inputStream = FolderTstHelper ...
public void testCopyMessageAttribute2() throws Exception { // add message "0.eml" as inputstream to folder String input = FolderTstHelper.getString(0); System.out.println("input=" + input); // create stream from string ByteArrayInputStream inputStream = FolderTstHelper ...
public void finished() { try { op.finish(); setDisplayText(""); } catch (Exception e) { // Must create a ExceptionProcessor e.printStackTrace(); } unregister(); boss.operationFinished(op, this); }
public void finished() { try { op.finish(); //setDisplayText(""); } catch (Exception e) { // Must create a ExceptionProcessor e.printStackTrace(); } unregister(); boss.operationFinished(op, this); }
public Object getConstantValue() { if (!this.binding.isConstantValue()) { return null; } Constant c = this.binding.constant; switch (c.typeID()) { case TypeIds.T_boolean: return Boolean.valueOf(c.booleanValue()); case TypeIds.T_byte: return new Byte(c.byteValue()); case TypeIds.T_char: ...
public Object getConstantValue() { if (!this.binding.isConstantValue() || this.binding.constant == null) { return null; } Constant c = this.binding.constant; switch (c.typeID()) { case TypeIds.T_boolean: return Boolean.valueOf(c.booleanValue()); case TypeIds.T_byte: return new Byte(c.byteValue...
final public boolean isPotentiallyAssigned(FieldBinding field) { // We do not want to complain in unreachable code if (this == DeadEnd) return false; return isPotentiallyAssigned(field.id); }
final public boolean isPotentiallyAssigned(FieldBinding field) { // We do not want to complain in unreachable code if ((this == DeadEnd) || (this.isFakeReachable)) return false; return isPotentiallyAssigned(field.id); }
protected Image getImage() { return JFaceResources.getImageRegistry().get(DLG_IMG_WARNING); } }
public Image getImage() { return JFaceResources.getImageRegistry().get(DLG_IMG_WARNING); } }
public static byte [] fromString(String str) { if (str.length() % 4 != 0) { return null; } ByteArrayOutputStream bs = new ByteArrayOutputStream(); DataOutputStream ds = new DataOutputStream(bs); for (int i = 0; i < (str.length() + 3) / 4; i++) { short [] s = new short[4]; short [] t = new short[3]; for (...
public static byte [] fromString(String str) { if (str.length() % 4 != 0) { return null; } ByteArrayOutputStream bs = new ByteArrayOutputStream(); DataOutputStream ds = new DataOutputStream(bs); for (int i = 0; i < (str.length() + 3) / 4; i++) { short [] s = new short[4]; short [] t = new short[3]; for (...
protected void notifyListener(RunListener each) throws Exception { each.testAssumptionFailed(description, e); }; }.run(); }
protected void notifyListener(RunListener each) throws Exception { each.testAssumptionInvalid(description, e); }; }.run(); }
public boolean fromPlugin() { return desc instanceof IPluginContribution && ((IPluginContribution) desc).fromPlugin(); }
public boolean fromPlugin() { return desc instanceof IPluginContribution && ((IPluginContribution) desc).getPluginId() != null; }
public RepeatedTest(Test test, int repeat) { super(test); if (repeat < 0) throw new IllegalArgumentException("Repetition count must be > 0"); fTimesRepeat= repeat; }
public RepeatedTest(Test test, int repeat) { super(test); if (repeat < 0) throw new IllegalArgumentException("Repetition count must be >= 0"); fTimesRepeat= repeat; }
public void init() throws ServletException { contextF = getServletContext(); context = ((ServletContextFacade)getServletContext()).getRealContext(); // doesn't change - set it in init! docBase = context.getDocBase(); if (! docBase.endsWith("/")) { docBase += "/"; } // ensure docB...
public void init() throws ServletException { contextF = getServletContext(); context = ((ServletContextFacade)getServletContext()).getRealContext(); // doesn't change - set it in init! docBase = context.getDocBase(); if (! docBase.endsWith("/")) { docBase += "/"; } // ensure docB...
private String getTimeString() { Date date = FinishedJobs.getInstance().getFinishDate(info); if (date != null) { return DateFormat.getTimeInstance(DateFormat.SHORT).format(date); } return null; } /** * Refresh the contents of the receiver. * */ void refresh() { // Don't refresh if not visible ...
private String getTimeString() { Date date = FinishedJobs.getInstance().getFinishDate(info); if (date != null) { return DateFormat.getTimeInstance(DateFormat.SHORT).format(date); } return null; } /** * Refresh the contents of the receiver. * */ void refresh() { // Don't refresh if not visible ...
public void assert(boolean assertion, String msg) { if(!assertion) this.error(msg); } /** Call the appenders in the hierrachy starting at <code>this</code>. If no appenders could be found, emit a warning. <p>This method always calls all the appenders inherited form the h...
public void assert(boolean assertion, String msg) { if(!assertion) this.error(msg); } /** Call the appenders in the hierrachy starting at <code>this</code>. If no appenders could be found, emit a warning. <p>This method calls all the appenders inherited from the hierarch...
protected void readContributions(String id, String tag, String extensionPoint) { cache = null; currentContribution = null; targetID = id; targetContributionTag = tag; readRegistry(Platform.getPluginRegistry(), PlatformUI.PLUGIN_ID, extensionPoint); }
protected void readContributions(String id, String tag, String extensionPoint) { cache = null; currentContribution = null; targetID = id; targetContributionTag = tag; readRegistry(Platform.getExtensionRegistry(), PlatformUI.PLUGIN_ID, extensionPoint); }
protected void buildModelList() { removeAllElements(); addElement(getTarget().getNamespace()); }
protected void buildModelList() { removeAllElements(); addElement(((MModelElement)getTarget()).getNamespace()); }
public ActionGoToEdit(String tabName) { super(tabName); _tabName = tabName; }
public ActionGoToEdit(String tabName) { super(tabName, NO_ICON); _tabName = tabName; }
public static void main(String argv[]) { if(argv.length != 2) { Usage(); } ProgramInit(argv); double delta; System.out.println(); for(int i = 0; i < CAT_ARRAY.length; i++) { delta = SimpleMessage(CAT_ARRAY[i], SHORT_MSG, runLength); System.out.println("Simple argum...
public static void main(String argv[]) { if(argv.length != 2) { Usage(); } ProgramInit(argv); double delta; System.out.println(); for(int i = 0; i < CAT_ARRAY.length; i++) { delta = SimpleMessage(CAT_ARRAY[i], SHORT_MSG, runLength); System.out.println("Simple argum...
private ASTNode parseBlockStatements( TypeDeclaration type, CompilationUnitDeclaration unit, int position) { //members TypeDeclaration[] memberTypes = type.memberTypes; if (memberTypes != null) { int length = memberTypes.length; for (int i = 0; i < length; i++) { TypeDeclaration memberType = memb...
private ASTNode parseBlockStatements( TypeDeclaration type, CompilationUnitDeclaration unit, int position) { //members TypeDeclaration[] memberTypes = type.memberTypes; if (memberTypes != null) { int length = memberTypes.length; for (int i = 0; i < length; i++) { TypeDeclaration memberType = memb...
public final int getCommentIndex(int position) { if (this.commentPositions == null) return -1; int length = this.commentPositions.length; if (length == 0) { return -1; } int g = 0, d = length - 1; int m = 0; while (g <= d) { m = (g + d) / 2; int bound = this.commentPositions[m][1]; if (bou...
public final int getCommentIndex(int position) { if (this.commentPositions == null) return -1; int length = this.commentPositions.length; if (length == 0) { return -1; } int g = 0, d = length - 1; int m = 0; while (g <= d) { m = g + (d - g) / 2; int bound = this.commentPositions[m][1]; if ...
public static String[] typeParameterSignatures(AbstractMethodDeclaration method) { Argument[] args = method.arguments; if (args != null) { int length = args.length; String[] signatures = new String[length]; for (int i = 0; i < args.length; i++) { Argument arg = args[i]; signatures[i] = typeSignatu...
public static String[] typeParameterSignatures(AbstractMethodDeclaration method) { Argument[] args = method.arguments; if (args != null) { int length = args.length; String[] signatures = new String[length]; for (int i = 0; i < args.length; i++) { Argument arg = args[i]; signatures[i] = typeSignatu...
private int matchLevel(NameReference nameRef, boolean resolve) { if (!resolve) { if (this.simpleName == null) { return this.needsResolve ? POSSIBLE_MATCH : ACCURATE_MATCH; } else { if (nameRef instanceof SingleNameReference) { if (this.matchesName(this.simpleName, ((SingleNameReference)nameRef).token)) {...
private int matchLevel(NameReference nameRef, boolean resolve) { if (!resolve) { if (this.simpleName == null) { return this.needsResolve ? POSSIBLE_MATCH : ACCURATE_MATCH; } else { if (nameRef instanceof SingleNameReference) { if (this.matchesName(this.simpleName, ((SingleNameReference)nameRef).token)) {...
public void init(JDBCStoreManager manager) throws DeploymentException { super.init(manager); try { Class psClass = Thread.currentThread().getContextClassLoader().loadClass(className); method = psClass.getMethod(methodName, null); } catch(ClassNotFoundException e) ...
public void init(JDBCStoreManager manager) throws DeploymentException { super.init(manager); try { Class psClass = GetTCLAction.getContextClassLoader().loadClass(className); method = psClass.getMethod(methodName, null); } catch(ClassNotFoundException e) { ...
public IJavaElement getPrimaryElement(boolean checkOwner) { if (checkOwner) { CompilationUnit cu = (CompilationUnit)getAncestor(COMPILATION_UNIT); if (cu.owner == DefaultWorkingCopyOwner.PRIMARY) return this; } IJavaElement parent = fParent.getPrimaryElement(false); return ((IType)parent).getInitializer(this.oc...
public IJavaElement getPrimaryElement(boolean checkOwner) { if (checkOwner) { CompilationUnit cu = (CompilationUnit)getAncestor(COMPILATION_UNIT); if (cu.isPrimary()) return this; } IJavaElement parent = fParent.getPrimaryElement(false); return ((IType)parent).getInitializer(this.occurrenceCount); }
public static IGroupModelPartial createGroupPartial(IGroupModel group, IContactFolder folder) { if (group == null) throw new IllegalArgumentException("group == null"); if (folder == null) throw new IllegalArgumentException("folder == null"); IGroupModelPartial groupPartial = new GroupPartial(folder.get...
public static IGroupModelPartial createGroupPartial(IGroupModel group, IContactFolder folder) { if (group == null) throw new IllegalArgumentException("group == null"); if (folder == null) throw new IllegalArgumentException("folder == null"); IGroupModelPartial groupPartial = new GroupModelPartial(folde...
private String removeIndentAndNewLines(String code, IDocument document, ICompilationUnit cu) { IJavaProject project = cu.getJavaProject(); Map options = project.getOptions(true/*inherit JavaCore options*/); int tabWidth; try { tabWidth = Integer.parseInt((String) options.get(DefaultCodeFormatterConstants.FORMATTE...
private String removeIndentAndNewLines(String code, IDocument document, ICompilationUnit cu) { IJavaProject project = cu.getJavaProject(); Map options = project.getOptions(true/*inherit JavaCore options*/); int tabWidth; try { tabWidth = Integer.parseInt((String) options.get(DefaultCodeFormatterConstants.FORMATTE...
public void acceptResult(CompilationResult result) { // In Batch mode, we write out the class files, hold onto the dependency info // & additional types and report problems. // In Incremental mode, when writing out a class file we need to compare it // against the previous file, remembering if structural changes o...
public void acceptResult(CompilationResult result) { // In Batch mode, we write out the class files, hold onto the dependency info // & additional types and report problems. // In Incremental mode, when writing out a class file we need to compare it // against the previous file, remembering if structural changes o...
public void cleanUp() { if (this.types != null) { for (int i = 0, max = this.types.length; i < max; i++) { cleanUp(this.types[i]); } for (int i = 0, max = this.localTypeCount; i < max; i++) { LocalTypeBinding localType = localTypes[i]; // null out the type's scope backpointers localType.s...
public void cleanUp() { if (this.types != null) { for (int i = 0, max = this.types.length; i < max; i++) { cleanUp(this.types[i]); } for (int i = 0, max = this.localTypeCount; i < max; i++) { LocalTypeBinding localType = localTypes[i]; // null out the type's scope backpointers localType.s...
public void setUp() { vectorAppender = new VectorAppender(); vectorAppender.setDelay(DELAY); asyncAppender.addAppender(vectorAppender); asyncAppender.activate(); root.addAppender(asyncAppender); }
public void setUp() { vectorAppender = new VectorAppender(); vectorAppender.setDelay(DELAY); asyncAppender.addAppender(vectorAppender); asyncAppender.activateOptions(); root.addAppender(asyncAppender); }
public void traverse(MethodBinding methodBinding, int maxLocals, byte[] bytecodes, int codeOffset, int codeLength, ArrayList frames, boolean isClinit) { StackMapFrameCodeStream stackMapFrameCodeStream = (StackMapFrameCodeStream) this.codeStream; int[] framePositions = stackMapFrameCodeStream.getFramePositions(); ...
public void traverse(MethodBinding methodBinding, int maxLocals, byte[] bytecodes, int codeOffset, int codeLength, ArrayList frames, boolean isClinit) { StackMapFrameCodeStream stackMapFrameCodeStream = (StackMapFrameCodeStream) this.codeStream; int[] framePositions = stackMapFrameCodeStream.getFramePositions(); ...
public void actionPerformed(ActionEvent e) { String action = e.getActionCommand(); if (action.equals("CLOSE")) { setVisible(false); } else if (action.equals("ADD")) { Filter filter = FilterList.createEmptyFilter(); if (showFilterDialog(filter)) { filterList.add(filter); listView.update(); ...
public void actionPerformed(ActionEvent e) { String action = e.getActionCommand(); if (action.equals("CLOSE")) { setVisible(false); } else if (action.equals("ADD")) { Filter filter = FilterList.createDefaultFilter(); if (showFilterDialog(filter)) { filterList.add(filter); listView.update(); ...
public DeclarationOfReferencedMethodsPattern(IJavaElement enclosingElement) { super(false, true, null, PATTERN_MATCH, false, null, null, null, null, null, null, null); this.enclosingElement = enclosingElement; this.knownMethods = new SimpleSet(); this.mustResolve = true; }
public DeclarationOfReferencedMethodsPattern(IJavaElement enclosingElement) { super(false, true, null, null, null, null, null, null, null, null, R_PATTERN_MATCH); this.enclosingElement = enclosingElement; this.knownMethods = new SimpleSet(); this.mustResolve = true; }
public void append(LoggingEvent event) { // Set the NDC and thread name for the calling thread as these // LoggingEvent fields were not set at event creation time. event.getNDC(); event.getThreadName(); // Get a copy of this thread's MDC. event.createProperties(); if (locationInfo) { ...
public void append(LoggingEvent event) { // Set the NDC and thread name for the calling thread as these // LoggingEvent fields were not set at event creation time. event.getNDC(); event.getThreadName(); // Get a copy of this thread's MDC. event.initializeProperties(); if (locationInfo) {...
public void resolve(BlockScope scope) { exceptionType = exception.resolveTypeExpecting(scope, scope.getJavaLangThrowable()); if (exceptionType == NullBinding && scope.problemReporter().options.complianceLevel <= CompilerOptions.JDK1_3){ // if compliant with 1.4, this problem will not be reported sc...
public void resolve(BlockScope scope) { exceptionType = exception.resolveTypeExpecting(scope, scope.getJavaLangThrowable()); if (exceptionType == NullBinding && scope.environment().options.complianceLevel <= CompilerOptions.JDK1_3){ // if compliant with 1.4, this problem will not be reported scope....
import org.columba.api.command.ICommandReference; // The contents of this file are subject to the Mozilla Public License Version // 1.1 //(the "License"); you may not use this file except in compliance with the //License. You may obtain a copy of the License at http://www.mozilla.org/MPL/ // //Software distributed und...
import org.columba.api.command.ICommandReference; // The contents of this file are subject to the Mozilla Public License Version // 1.1 //(the "License"); you may not use this file except in compliance with the //License. You may obtain a copy of the License at http://www.mozilla.org/MPL/ // //Software distributed und...
public int getNodeType() { return WHILE_STATEMENT; } /* (omit javadoc for this method) * Method declared on ASTNode. */ ASTNode clone(AST target) { WhileStatement result = new WhileStatement(target); result.setSourceRange(this.getStartPosition(), this.getLength()); result.setLeadingComment(getLeadingCo...
public int getNodeType() { return WHILE_STATEMENT; } /* (omit javadoc for this method) * Method declared on ASTNode. */ ASTNode clone(AST target) { WhileStatement result = new WhileStatement(target); result.setSourceRange(this.getStartPosition(), this.getLength()); result.copyLeadingComment(this); re...
public RolloverButton() { if(method != null) { try { method.invoke(this,new Boolean[] { Boolean.TRUE }); } catch(Exception e) { Log.log(Log.ERROR,this,e); } } else { setBorder(new EtchedBorder()); setBorderPainted(false); setMargin(new Insets(0,0,0,0)); setRequestFocus...
public RolloverButton() { if(method != null) { try { method.invoke(this,new Boolean[] { Boolean.TRUE }); } catch(Exception e) { Log.log(Log.ERROR,this,e); } } else { setBorder(new EtchedBorder()); setBorderPainted(false); setMargin(new Insets(1,1,1,1)); setRequestFocus...
public synchronized void enable(String name, boolean state) { for (int i = 0; i < getItemCount(); i++) { JMenuItem item = getItem(i); if (name.equals(item.getLabel())) { item.setEnabled(state); return; } } }
public synchronized void enable(String name, boolean state) { for (int i = 0; i < getItemCount(); i++) { JMenuItem item = getItem(i); if (name.equals(item.getText())) { item.setEnabled(state); return; } } }
private void fireActivityManagerChanged() { if (activityManagerListeners != null) for (int i = 0; i < activityManagerListeners.size(); i++) { if (activityManagerEvent == null) activityManagerEvent = new ActivityManagerEvent(this); ((IActivityManagerListener) activityManagerListeners.get(i))....
private void fireActivityManagerChanged() { if (activityManagerListeners != null) for (int i = 0; i < activityManagerListeners.size(); i++) { if (activityManagerEvent == null) activityManagerEvent = new ActivityManagerEvent(this, false, false, false); ((IActivityManagerListener) activityMana...
public interface ILocalVariable extends IJavaElement, ISourceReference, IAnnotatable { /******************************************************************************* * Copyright (c) 2000, 2006 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under...
public interface ILocalVariable extends IJavaElement, ISourceReference, IAnnotatable { /******************************************************************************* * Copyright (c) 2000, 2006 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under...
extends BaseAttributeVote package org.tigris.scarab.om; // JDK classes import java.util.*; // Turbine classes import org.apache.turbine.om.*; import org.apache.turbine.om.peer.BasePeer; import org.apache.turbine.util.db.Criteria; import org.apache.turbine.util.ObjectUtils; import org.apache.turbine.util.StringUtils;...
extends BaseAttributeVote package org.tigris.scarab.om; // JDK classes import java.util.*; // Turbine classes import org.apache.turbine.om.*; import org.apache.turbine.om.peer.BasePeer; import org.apache.turbine.util.db.Criteria; import org.apache.turbine.util.ObjectUtils; import org.apache.turbine.util.StringUtils;...
public TextViewer(MessageController mediator) { super(); this.mediator = mediator; initHTMLViewerPlugin(); setLayout(new BorderLayout()); add(viewerPlugin.getView(), BorderLayout.CENTER); initConfiguration(); initStyleSheet(); // FocusManager.getInstance().registerComponent(new MyFocusOwner()); ...
public TextViewer(MessageController mediator) { super(); this.mediator = mediator; initHTMLViewerPlugin(); setLayout(new BorderLayout()); add(viewerPlugin.getView(), BorderLayout.CENTER); initConfiguration(); initStyleSheet(); // FocusManager.getInstance().registerComponent(new MyFocusOwner()); ...
public TextFigure() { fOriginX = 0; fOriginY = 0; fFont = createCurrentFont(); setAttribute(FigureAttributeConstant.FILL_COLOR.getName(), ColorMap.color("None")); fText = new String(""); fSizeIsDirty = true; }
public TextFigure() { fOriginX = 0; fOriginY = 0; fFont = createCurrentFont(); setAttribute(FigureAttributeConstant.FILL_COLOR, ColorMap.color("None")); fText = new String(""); fSizeIsDirty = true; }
public void actionPerformed(ActionEvent e) { CalendarFrameMediator calendarFrame = (CalendarFrameMediator) frameMediator; calendarFrame.goToday(); }
public void actionPerformed(ActionEvent e) { CalendarFrameMediator calendarFrame = (CalendarFrameMediator) frameMediator; calendarFrame.getCalendarView().viewToday(); }
protected void configureShell(Shell shell) { super.configureShell(shell); String title=perspective.getDesc().getLabel(); title = NLS.bind(WorkbenchMessages.ActionSetSelection_customize,title); shell.setText(title); //$NON-NLS-1$ window.getWorkbench().getHelpSystem()....
protected void configureShell(Shell shell) { super.configureShell(shell); String title=perspective.getDesc().getLabel(); title = NLS.bind(WorkbenchMessages.ActionSetSelection_customize,title); shell.setText(title); window.getWorkbench().getHelpSystem().setHelp(shell,...
private Hashtable getDefaultOptionsNoInitialization() { Map defaultOptionsMap = new CompilerOptions().getMap(); // compiler defaults // Override some compiler defaults defaultOptionsMap.put(JavaCore.COMPILER_LOCAL_VARIABLE_ATTR, JavaCore.GENERATE); defaultOptionsMap.put(JavaCore.COMPILER_CODEGEN_UNUSED_LOCA...
private Hashtable getDefaultOptionsNoInitialization() { Map defaultOptionsMap = new CompilerOptions().getMap(); // compiler defaults // Override some compiler defaults defaultOptionsMap.put(JavaCore.COMPILER_LOCAL_VARIABLE_ATTR, JavaCore.GENERATE); defaultOptionsMap.put(JavaCore.COMPILER_CODEGEN_UNUSED_LOCA...
private void showStatusAdapter(StatusAdapter statusAdapter, boolean block) { if (!PlatformUI.isWorkbenchRunning()) { // we are shutting down, so just log WorkbenchPlugin.log(statusAdapter.getStatus()); return; } getStatusDialogManager().addStatusAdapter(statusAdapter, block); if (block) { Shell s...
private void showStatusAdapter(StatusAdapter statusAdapter, boolean block) { if (!PlatformUI.isWorkbenchRunning()) { // we are shutting down, so just log WorkbenchPlugin.log(statusAdapter.getStatus()); return; } getStatusDialogManager().addStatusAdapter(statusAdapter, block); if (block) { Shell s...
public Component getTreeCellRendererComponent(JTree tree, Object value, boolean sel, boolean expanded, boolean leaf, int row, boolean hasFocus) { Component r = super.getTreeCellRendererComponent(tree, value, sel, ...
public Component getTreeCellRendererComponent(JTree tree, Object value, boolean sel, boolean expanded, boolean leaf, int row, boolean hasFocus) { Component r = super.getTreeCellRendererComponent(tree, value, sel, ...
public void execute(Worker worker) throws Exception { FolderCommandReference[] r = (FolderCommandReference[]) getReferences(); FolderCommandAdapter adapter = new FolderCommandAdapter(r); // there can be only one reference for this command Folder srcFolder = (Folder) adapter.getSourceFolderReferences()[0].g...
public void execute(Worker worker) throws Exception { FolderCommandReference[] r = (FolderCommandReference[]) getReferences(); FolderCommandAdapter adapter = new FolderCommandAdapter(r); // there can be only one reference for this command Folder srcFolder = (Folder) adapter.getSourceFolderReferences()[0].g...
protected void setUp() throws Exception { // create config-folder File file = new File("test_config"); file.mkdir(); new Config(file); Logging.DEBUG = true; Logging.createDefaultHandler(); ShutdownManager.getInstance(); new AddressbookMain(); // now load all available plugins PluginManage...
protected void setUp() throws Exception { // create config-folder File file = new File("test_config"); file.mkdir(); new Config(file); Logging.DEBUG = true; Logging.createDefaultHandler(); ShutdownManager.getInstance(); new AddressbookMain(); // now load all available plugins PluginManage...
public void handleException(Throwable e) { // just skip the item if there's an error, // e.g. in the calculation of the shortened name WorkbenchPlugin.log("Error in ReopenEditorMenu.fill: " + e); //$NON-NLS-1$ } }); ...
public void handleException(Throwable e) { // just skip the item if there's an error, // e.g. in the calculation of the shortened name WorkbenchPlugin.log(getClass(), "fill", e); //$NON-NLS-1$ } }); } ...
public void valueChanged(ListSelectionEvent event) { try { //adjust description field DefaultMailboxImporter importer = (DefaultMailboxImporter) pluginHandler.getPlugin((String) data.getData( "Plugin.ID"), null); String description = importer.getDe...
public void valueChanged(ListSelectionEvent event) { try { //adjust description field DefaultMailboxImporter importer = (DefaultMailboxImporter) pluginHandler.getPlugin((String) data.getData( "Plugin.ID"), null); String description = importer.getDe...
public static IPath getClasspathVariable(final String variableName) { JavaModelManager manager = JavaModelManager.getJavaModelManager(); IPath variablePath = manager.variableGet(variableName); if (variablePath == JavaModelManager.VARIABLE_INITIALIZATION_IN_PROGRESS){ return manager.getPreviousSessionVa...
public static IPath getClasspathVariable(final String variableName) { JavaModelManager manager = JavaModelManager.getJavaModelManager(); IPath variablePath = manager.variableGet(variableName); if (variablePath == JavaModelManager.VARIABLE_INITIALIZATION_IN_PROGRESS){ return manager.getPreviousSessionVa...
public void search(IWorkspace workspace, String patternString, int searchFor, int limitTo, IJavaSearchScope scope, IJavaSearchResultCollector resultCollector) throws JavaModelException { search(workspace, createSearchPattern(patternString, searchFor, limitTo, false), scope, resultCollector); }
public void search(IWorkspace workspace, String patternString, int searchFor, int limitTo, IJavaSearchScope scope, IJavaSearchResultCollector resultCollector) throws JavaModelException { search(workspace, createSearchPattern(patternString, searchFor, limitTo, true), scope, resultCollector); }
public synchronized boolean tryToGetLock(Object locker) { // Is it already locked from locker ? if( this.locker == locker) return true; // Check if locked if( locked ) { return false; } else { locked = true; this.locker = locker; return true; } }
public synchronized boolean tryToGetLock(Object locker) { // Is it already locked from locker ? if( this.locker == locker && locker!=null) return true; // Check if locked if( locked ) { return false; } else { locked = true; this.locker = locker; return true; } }
public int literalIndex(MethodBinding aMethodBinding) { int index; final TypeBinding constantPoolDeclaringClass = aMethodBinding.constantPoolDeclaringClass(); final char[] declaringClassConstantPoolName = constantPoolDeclaringClass.constantPoolName(); final char[] selector = aMethodBinding.selector; final char[] s...
public int literalIndex(MethodBinding aMethodBinding) { int index; final TypeBinding constantPoolDeclaringClass = aMethodBinding.constantPoolDeclaringClass(); final char[] declaringClassConstantPoolName = constantPoolDeclaringClass.constantPoolName(); final char[] selector = aMethodBinding.selector; final char[] s...