Here you can find the source of containsBasedOnEntryIdentity(final List> list, final Object object)
public static boolean containsBasedOnEntryIdentity(final List<?> list, final Object object)
//package com.java2s; /****************************************************************************** * Copyright (c) 2015 Oracle and Liferay * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * * Contributors://from www .ja v a 2 s .c o m * Konstantin Komissarchik - initial implementation and ongoing maintenance * Gregory Amerson - [358295] Need access to selection in list property editor ******************************************************************************/ import java.util.List; public class Main { public static boolean containsBasedOnEntryIdentity(final List<?> list, final Object object) { for (Object obj : list) { if (obj == object) { return true; } } return false; } }