Inserts a <Color> value into the array. Does not deallocate or destroy the <Color> object. May incur re-allocation costs depending on the size of any allocated reserve.
int32 Insert( int32 p_nIndex, Color p_oColor )
Parameter Type | Parameter Name | Documentation |
---|---|---|
int32 | p_nIndex | The index at which to insert the <Color> object. |
<Color> | p_oColor | The <Color> object to insert into the <ColorArray>. |
import library "app_service_console_util.ssl";
import library "type_color_array_util.ssl";
auto Color r = new Color( 1, 1, 1, 255 );
auto Color g = new Color( 2, 2, 2, 255 );
auto Color b = new Color( 3, 3, 3, 255 );
auto ColorArray data;
data.Add( r );
data.Add( g );
data.Insert( 0, b );
LibColorArray.Out( data );
COLORARRAY OUTPUT generated by TYPE_COLOR_ARRAY_UTIL.SSL
3,
3,
3,
255,
1,
1,
1,
255,
2,
2,
2,
255