FAQ
 
 
Cover  \ Exhibition  \ Learning  \ Reference  \ Download  \ Discourse   
      Linguagem \ Ambiente \ Bibliotecas \ Comparação
 
   
   
Resumida (A-Z) \ Completa (A-Z)  
   
  Referência para Processing (BETA) version 91+. Se você tem uma versão anterior, utilize a documentação inclusa em seu software. Se você encontrar quaisquer erros ou tiver quaisquer comentários, leve ao nosso conhecimento.  
Nome  

splice()

   
Exemplos  
String sa1[] = { "OH ", "NY ", "CA "}; 
sa1 = splice(sa1, "KY ", 1); 
print(sa1);  // Prints "OH KY NY CA " 
println(); 
String sa2[] = { "VA ", "CO ", "IL "  }; 
sa1 = splice(sa1, sa2, 2); 
print(sa1);  // Prints "OH KY VA CO IL NY CA " 

Descrição   Inserts a value or array of values into an existing array. The first two parameters must be of the same datatype. The array parameter defines the array which will be modified and the second parameter defines the data which will be inserted.
   
Sintaxe  
splice(array, value, index)
splice(array, array2, index)
   
Parâmetros  
array   booleans[], bytes[], chars[], ints[], floats[], or Strings[]: base array

value   booleans, bytes, chars, ints, floats, or Strings: value to be spliced in

array2   booleans[], bytes[], chars[], ints[], floats[], Strings[]: array to be spliced in

index   int: position in the array from which to insert data

   
Retorno   Array (the same datatype as the input)
   
Utilização   Web & Applicações
   
Relacionado   contract()
subset()
 
 






   
 
Original em inglês atualizado em: Fri Jul 15 16:36:10 PDT 2005
Tradução para o Português do Brasil: Luiz Ernesto Merkle
Atuallizada em: 30 de novembro de 2005, 9h00 (BRST)
 
 








Creative Commons License
 
  Processing é um projeto aberto iniciado por Ben Fry e Casey Reas  
  © Info