Static Public Member Functions | |
| static void | main (String[] args) |
Definition at line 3 of file Strings1.java.
| static void Strings1::main | ( | String[] | args | ) | [inline, static] |
Definition at line 5 of file Strings1.java.
00006 { 00007 int col=4; 00008 int row=2; 00009 int r,c,k; 00010 String [] b=new String [row*col]; 00011 String [] d=new String[row*col]; 00012 00013 SciStringArray a = new SciStringArray("A",row,col); 00014 Scilab.Exec("A=['Aaa','Bbb','Ccc','Ddd';'Eee','Fff','Ggg','Hhh'];"); 00015 a.Get(); 00016 System.out.println("----------------------------------------------------"); 00017 for(r=1;r<=a.getRow();r++) 00018 { 00019 for(c=1;c<=a.getCol();c++) 00020 { 00021 System.out.print("A("+(r)+","+(c)+")="+a.GetElement(r,c)+" "); 00022 } 00023 System.out.println(" "); 00024 } 00025 System.out.println("----------------------------------------------------"); 00026 00027 b=a.getData(); 00028 00029 for(r=0;r<row;r++) 00030 { 00031 for(c=0;c<col;c++) 00032 { 00033 System.out.print("b("+r+","+(c)+")="+ b[c*row+r] +" "); 00034 } 00035 System.out.println(" "); 00036 } 00037 System.out.println("----------------------------------------------------"); 00038 00039 00040 for (k=0;k<row*col;k++) 00041 { 00042 d[k]=new String("Sentence ")+k; 00043 } 00044 00045 SciStringArray D = new SciStringArray("D",2,4,d); 00046 D.Send(); 00047 00048 }
1.5.1