Microsoft SDK for Java

fromShortArray

This method of the SafeArray Class initializes SafeArray elements from a Java array.

Syntax

public void fromShortArray(short ja[]);

If the SafeArray is multidimensional, it is treated as if it were a single linear array stored in column order. No matter what the index of the lower bound of the SafeArray is, the first element is initialized from element zero of the Java array.

If the Java array is shorter than the number of SafeArray elements, the remaining SafeArray elements are left unmodified. If the Java array is longer than the number of SafeArray elements, the extra elements are ignored.

Note   This method attempts all the usual type conversions. To achieve optimal performance, ensure that the element size of the source and destination arrays match exactly so that the method optimizes to a straight memory copy (memcpy).

Parameters

ja The Java array that contains the new values.

© 1999 Microsoft Corporation. All rights reserved. Terms of use.