@@ -71,8 +71,8 @@ protected BasicIotAnyVector(ExtendedDataInput in) throws IOException {
71
71
}
72
72
73
73
public Entity get (int index ) {
74
- if (index >= indexs . rows ())
75
- throw new RuntimeException (String .format ("index %s out of %s." , index , indexs . rows ()));
74
+ if (index >=rows ())
75
+ throw new RuntimeException (String .format ("index %s out of rows %s." , index , rows ()));
76
76
77
77
BasicInt curDataType = (BasicInt ) indexsDataType .get (index );
78
78
BasicInt curIndex = (BasicInt ) indexs .get (index );
@@ -119,7 +119,7 @@ public DATA_TYPE getDataType() {
119
119
120
120
@ Override
121
121
public int rows () {
122
- return subVector . size () + 1 ;
122
+ return indexs . rows () ;
123
123
}
124
124
125
125
@ JsonIgnore
@@ -144,7 +144,7 @@ public void Append(Vector value) {
144
144
145
145
public String getString (){
146
146
StringBuilder sb = new StringBuilder ("[" );
147
- for (int i = 0 ; i < indexs . rows (); i ++)
147
+ for (int i = 0 ; i < rows (); i ++)
148
148
sb .append (getString (i )).append ("," );
149
149
150
150
sb .setLength (sb .length () - 1 );
@@ -169,13 +169,13 @@ public int serialize(int indexStart, int offect, int targetNumElement, AbstractV
169
169
170
170
@ Override
171
171
protected void writeVectorToOutputStream (ExtendedDataOutput out ) throws IOException {
172
- int [] tmpIntArray = new int [indexs . rows () * 2 + 2 ];
172
+ int [] tmpIntArray = new int [rows () * 2 + 2 ];
173
173
174
- tmpIntArray [0 ] = indexs . rows ();
174
+ tmpIntArray [0 ] = rows ();
175
175
tmpIntArray [1 ] = subVector .size ();
176
176
177
- System .arraycopy (indexs .getdataArray (), 0 , tmpIntArray ,2 , indexs . rows ());
178
- System .arraycopy (indexsDataType .getdataArray (), 0 , tmpIntArray , indexs . rows () + 2 , indexsDataType .size );
177
+ System .arraycopy (indexs .getdataArray (), 0 , tmpIntArray ,2 , rows ());
178
+ System .arraycopy (indexsDataType .getdataArray (), 0 , tmpIntArray , rows () + 2 , indexsDataType .size );
179
179
BasicIntVector intVector = new BasicIntVector (tmpIntArray );
180
180
181
181
Entity [] entities = new Entity [1 + subVector .size ()];
0 commit comments