Here you can find the source of getSize(List
public static <V> int getSize(List<V> sourceList)
//package com.java2s; //License from project: Open Source License import java.util.List; public class Main { public static <V> int getSize(List<V> sourceList) { return sourceList == null ? 0 : sourceList.size(); }/*from w ww .jav a 2 s . c o m*/ }