fork download
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. /* Name of the class has to be "Main" only if the class is public. */
  8. class Ideone
  9. {
  10. public static void main (String[] args) throws java.lang.Exception
  11. {
  12.  
  13. String datos = "Central: xxx, IP dslam: 11.111.11.111, IP bras: 111.11.1.111, COID: 1111, Rack: 11, SubRack: 11, Slot_dslam: 11, Port_dslam: 1, Dslam_provider: 1111X, Community: xxxxxxx, Virtual_rack: 11 , Virtual_subrack: 11, SVLAN: 111, CVLAN: 1111, Erxslot: 1, Erxcard: 1, Erxport: 1, Provider_BRAS: XXXX, Model_BRAS:XX11, Nombre_BRAS:xxx-xxx-11,DSLAMPORTID: 111111 Datos:, xxxxx, 1111, 111, XXXX, xxxxphysical (xxxxx)= 1, admin (xxxx)= 1, Profile_XXX= 11 --->Invalid Profile Velocidades(xxxx): DOWN= 111, UP = 11";
  14.  
  15. String[] valores = datos.split(",");
  16.  
  17. for (String s : valores){
  18. s = s.replace(":", "");
  19. System.out.println(s);
  20. }
  21. }
  22. }
Success #stdin #stdout 0.05s 4386816KB
stdin
Standard input is empty
stdout
Central xxx
 IP dslam 11.111.11.111
 IP bras 111.11.1.111
 COID 1111
 Rack 11
 SubRack 11
 Slot_dslam 11
 Port_dslam 1
 Dslam_provider 1111X
 Community xxxxxxx
 Virtual_rack 11 
 Virtual_subrack 11
 SVLAN 111
 CVLAN 1111
 Erxslot 1
 Erxcard 1
 Erxport 1
  Provider_BRAS XXXX
 Model_BRASXX11
 Nombre_BRASxxx-xxx-11
DSLAMPORTID 111111 Datos
 xxxxx
 1111
 111
 XXXX
 xxxxphysical (xxxxx)= 1
 admin (xxxx)= 1
 Profile_XXX= 11 --->Invalid Profile Velocidades(xxxx) DOWN= 111
 UP = 11