/** The general lookup method. * @param template the template describing the services we are looking for * @return object containing the results */ public final Lookup.Result lookup (Lookup.Template template) { for (;;) { AbstractLookup.ISE toRun = null; AbstractLookup.Storage t = enterStorage (); try { R r = new R (); ReferenceToResult newRef = new ReferenceToResult (r, this, template); newRef.next = t.registerReferenceToResult (newRef); return r; } catch (AbstractLookup.ISE ex) { toRun = ex; } finally { exitStorage (); } toRun.recover (this); // and try again } }
/** The general lookup method. * @param template the template describing the services we are looking for * @return object containing the results */ public final Lookup.Result lookup (Lookup.Template template) { for (;;) { AbstractLookup.ISE toRun = null; AbstractLookup.Storage t = enterStorage (); try { R r = new R (); ReferenceToResult newRef = new ReferenceToResult (r, this, template); newRef.next = t.registerReferenceToResult (newRef); return r; } catch (AbstractLookup.ISE ex) { toRun = ex; } finally { exitStorage (); } toRun.recover (this); // and try again } }
@Override public final <T> Lookup.Result<T> lookup(Lookup.Template<T> template) { beforeLookupResult(template); for (;;) { AbstractLookup.ISE toRun = null; AbstractLookup.Storage<?> t = enterStorage(); try { R<T> r = new R<T>(); ReferenceToResult<T> newRef = new ReferenceToResult<T>(r, this, template); newRef.next = t.registerReferenceToResult(newRef); return r; } catch (AbstractLookup.ISE ex) { toRun = ex; } finally { exitStorage(); } toRun.recover(this); // and try again } }
public final <T> Lookup.Result<T> lookup(Lookup.Template<T> template) { for (;;) { AbstractLookup.ISE toRun = null; AbstractLookup.Storage<?> t = enterStorage(); try { R<T> r = new R<T>(); ReferenceToResult<T> newRef = new ReferenceToResult<T>(r, this, template); newRef.next = t.registerReferenceToResult(newRef); return r; } catch (AbstractLookup.ISE ex) { toRun = ex; } finally { exitStorage(); } toRun.recover(this); // and try again } }
/** Clones the reference list to given Storage. * @param storage storage to clone to */ public void cloneList(AbstractLookup.Storage<?> storage) { ReferenceIterator it = new ReferenceIterator(this); while (it.next()) { ReferenceToResult<?> current = it.current(); ReferenceToResult<?> newRef = current.cloneRef(); newRef.next = storage.registerReferenceToResult(newRef); newRef.caches = current.caches; if (current.caches == current) { current.getResult().initItems(storage); } } }
/** Clones the reference list to given Storage. * @param storage storage to clone to */ public void cloneList (AbstractLookup.Storage storage) { ReferenceIterator it = new ReferenceIterator (this); while (it.next ()) { ReferenceToResult current = it.current (); ReferenceToResult newRef = new ReferenceToResult ( current.getResult (), current.lookup, current.template ); newRef.next = storage.registerReferenceToResult (newRef); newRef.caches = current.caches; if (current.caches == current) { current.getResult ().initItems (storage); } } } } // end of ReferenceToResult
/** Clones the reference list to given Storage. * @param storage storage to clone to */ public void cloneList(AbstractLookup.Storage<?> storage) { ReferenceIterator it = new ReferenceIterator(this); while (it.next()) { ReferenceToResult<?> current = it.current(); ReferenceToResult<?> newRef = current.cloneRef(); newRef.next = storage.registerReferenceToResult(newRef); newRef.caches = current.caches; if (current.caches == current) { current.getResult().initItems(storage); } } }
public org.openide.util.lookup.AbstractLookup.ReferenceToResult registerReferenceToResult(org.openide.util.lookup.AbstractLookup.ReferenceToResult newRef) { return delegate.registerReferenceToResult (newRef); }
/** Clones the reference list to given Storage. * @param storage storage to clone to */ public void cloneList (AbstractLookup.Storage storage) { ReferenceIterator it = new ReferenceIterator (this); while (it.next ()) { ReferenceToResult current = it.current (); ReferenceToResult newRef = new ReferenceToResult ( current.getResult (), current.lookup, current.template ); newRef.next = storage.registerReferenceToResult (newRef); newRef.caches = current.caches; if (current.caches == current) { current.getResult ().initItems (storage); } } } } // end of ReferenceToResult
public org.openide.util.lookup.AbstractLookup.ReferenceToResult registerReferenceToResult(org.openide.util.lookup.AbstractLookup.ReferenceToResult newRef) { return delegate.registerReferenceToResult (newRef); }
public org.openide.util.lookup.AbstractLookup.ReferenceToResult registerReferenceToResult( org.openide.util.lookup.AbstractLookup.ReferenceToResult newRef ) { return delegate.registerReferenceToResult(newRef); } }
public org.openide.util.lookup.AbstractLookup.ReferenceToResult registerReferenceToResult( org.openide.util.lookup.AbstractLookup.ReferenceToResult newRef ) { return delegate.registerReferenceToResult(newRef); } }
@Override public final <T> Lookup.Result<T> lookup(Lookup.Template<T> template) { beforeLookupResult(template); for (;;) { AbstractLookup.ISE toRun = null; AbstractLookup.Storage<?> t = enterStorage(); try { R<T> r = new R<T>(); ReferenceToResult<T> newRef = new ReferenceToResult<T>(r, this, template); newRef.next = t.registerReferenceToResult(newRef); return r; } catch (AbstractLookup.ISE ex) { toRun = ex; } finally { exitStorage(); } toRun.recover(this); // and try again } }
/** Clones the reference list to given Storage. * @param storage storage to clone to */ public void cloneList(AbstractLookup.Storage<?> storage) { ReferenceIterator it = new ReferenceIterator(this); while (it.next()) { ReferenceToResult<?> current = it.current(); ReferenceToResult<?> newRef = current.cloneRef(); newRef.next = storage.registerReferenceToResult(newRef); newRef.caches = current.caches; if (current.caches == current) { current.getResult().initItems(storage); } } }
public org.openide.util.lookup.AbstractLookup.ReferenceToResult registerReferenceToResult( org.openide.util.lookup.AbstractLookup.ReferenceToResult newRef ) { return delegate.registerReferenceToResult(newRef); } }