Android List to Array Convert toShortArray(final List pItems)

Here you can find the source of toShortArray(final List pItems)

Description

to Short Array

Declaration

public static final short[] toShortArray(final List<Short> pItems) 

Method Source Code

//package com.java2s;
import java.util.List;

public class Main {
    public static final short[] toShortArray(final List<Short> pItems) {
        final short[] out = new short[pItems.size()];
        for (int i = out.length - 1; i >= 0; i--) {
            out[i] = pItems.get(i);//from   ww  w .  jav  a  2s . c o  m
        }
        return out;
    }
}

Related

  1. toCharArray(final List pItems)
  2. toDoubleArray(final List pItems)
  3. toFloatArray(final List pItems)
  4. toIntArray(final List pItems)
  5. toLongArray(final List pItems)