Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 281788 Details for
Bug 560018
Multiple errors running clean-up for lambda and method references on Platform UI repo
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
After switching to lambda, error flagged
MappedSet.java (text/x-java), 836 bytes, created by
Jeff Johnston
on 2020-02-11 14:09:31 EST
(
hide
)
Description:
After switching to lambda, error flagged
Filename:
MIME Type:
Creator:
Jeff Johnston
Created:
2020-02-11 14:09:31 EST
Size:
836 bytes
patch
obsolete
>package p1; > >import java.util.HashSet; >import java.util.Iterator; >import java.util.Map; >import java.util.Set; > >import org.eclipse.core.databinding.observable.set.ISetChangeListener; > > >@SuppressWarnings({"rawtypes", "unchecked", "javadoc"}) >public class MappedSet { > private final Map wrappedMap; > private ISetChangeListener domainListener = event -> { > Set additions = new HashSet(); > for (Iterator it = event.diff.getAdditions().iterator(); it.hasNext();) { > Object added = it.next(); > Object mapValue = wrappedMap.get(added); > if (handleAddition(mapValue)) { > additions.add(mapValue); > } > } > }; > > public MappedSet(Map map) { > this.wrappedMap = map; > } > > public ISetChangeListener getDomainListener() { > return domainListener; > } > > private boolean handleAddition(Object o) { > return o.equals(wrappedMap.get(0)); > } > >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 560018
:
281787
| 281788 |
281789