Best code examples for Java 8 HashSet class (java.util.HashSet)

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Java 8 HashSet class.
You can now enable Codota on your own code to easily search and navigate your Java codebase.

Java 8 HashSet examples from Open Source projects
This code example shows how to use the following methods:
import play.db.jpa.Model; 
 
@Entity 
public class CompositeIdForeignB extends Model { 
	@OneToMany(mappedBy = "compositeIdForeignB", fetch = FetchType.LAZY) 
	public Set<CompositeIdEntity> a2Bs = new HashSet<CompositeIdEntity>(); 
 
	public String testId; 
} 
Full Snippet Info
9
CodeRank
This code example shows how to use the following methods:
import play.db.jpa.Model; 
 
@Entity 
public class CompositeIdForeignA extends Model { 
	@OneToMany(mappedBy = "compositeIdForeignA", fetch = FetchType.LAZY) 
	public Set<CompositeIdEntity> a2Bs = new HashSet<CompositeIdEntity>(); 
	 
	public String testId; 
} 
Full Snippet Info
9
CodeRank
This code example shows how to use the following methods:
 
    private final FragmentManager fragmentManager;
 
    private final Resources resources;
 
    private final Set<String> tags = new HashSet<String>();
 
    /** 
     * @param activity 
     * @param defaultUser 
     */ 
    public HomePagerAdapter(final SherlockFragmentActivity activity,
            final boolean defaultUser) {
        super(activity);
 
        fragmentManager = activity.getSupportFragmentManager();
        resources = activity.getResources();
        this.defaultUser = defaultUser;
    } 
 
Full Snippet Info
9
CodeRank
This code example shows how to use the following methods:
public class SetConfig extends CollectionConfig { 
    private static final long serialVersionUID = 1L; 
 
    @Override 
    protected Collection<Object> createDefaultInstance() { 
        return new HashSet<Object>(); 
    } 
} 
Full Snippet Info
9
CodeRank
This code example shows how to use the following methods:
 
/** 
 * @author <a href="mailto:ales.justin@jboss.org">Ales Justin</a> 
 */ 
public class TOwner { 
    private Set<TInjectee> injectees = new HashSet<TInjectee>();
 
    public void addInjectee(TInjectee i) {
        System.out.println("add #i-b = " + injectees.size());
        injectees.add(i);
        System.out.println("add #i-a = " + injectees.size());
    } 
 
    public void removeInjectee(TInjectee i) {
        System.out.println("remove #i-b = " + injectees.size());
        injectees.remove(i);
        System.out.println("remove #i-a = " + injectees.size());
    } 
} 
Full Snippet Info
9
CodeRank
Related Java 8 HashSet Questions & Answers:
See Code Examples for Java 8 HashSet Methods: