@Test public void testRemove() { logger.info("remove"); Configuration configuration = getConfiguration(); Dataframe dataset = new Dataframe(configuration); AssociativeArray xData1 = new AssociativeArray(); xData1.put("1", true); dataset.add(new Record(xData1, null)); AssociativeArray xData2 = new AssociativeArray(); xData2.put("2", 1.0); dataset.add(new Record(xData2, null)); AssociativeArray xData3 = new AssociativeArray(); xData3.put("3", (short)1); dataset.add(new Record(xData3, null)); AssociativeArray xData4 = new AssociativeArray(); xData4.put("4", "s"); dataset.add(new Record(xData4, null)); dataset.remove(2); assertEquals(3, dataset.size()); dataset.close(); }
@Override public boolean remove(Object o) { Integer id = indexOf((Record) o); if(id == null) { return false; } remove(id); return true; }
Dataframe implements Collection<Record>, Copyable<Dataframe>, Savable { @Override public boolean remove(Object o) { Integer id = indexOf((Record) o); if(id == null) { return false; } remove(id); return true; } }
Dataframe implements Collection<Record>, Copyable<Dataframe>, Savable { @Override public boolean remove(Object o) { Integer id = indexOf((Record) o); if(id == null) { return false; } remove(id); return true; } Dataframe(Configuration configuration); private  Dataframe(String storageName, Configuration configuration); private  Dataframe(Configuration configuration, TypeInference.DataType yDataType, Map<String, TypeInference.DataType> xDataTypes); }
Dataframe implements Collection<Record>, Copyable<Dataframe>, Savable { @Override public boolean remove(Object o) { Integer id = indexOf((Record) o); if(id == null) { return false; } remove(id); return true; } Dataframe(Configuration configuration); private  Dataframe(String storageName, Configuration configuration); private  Dataframe(Configuration configuration, TypeInference.DataType yDataType, Map<String, TypeInference.DataType> xDataTypes); void save(String storageName); void delete(); @Override void close(); @Override int size(); @Override boolean isEmpty(); @Override void clear(); @Override boolean add(Record r); @Override boolean contains(Object o); @Override boolean addAll(Collection<? extends Record> c); @Override boolean containsAll(Collection<?> c); @Override Object[] toArray(); @Override @SuppressWarnings("unchecked") T[] toArray(T[] a); @Override Iterator<Record> iterator(); @Override Stream<Record> stream(); @Override boolean remove(Object o); @Override boolean removeAll(Collection<?> c); @Override boolean retainAll(Collection<?> c); Record remove(Integer id); Integer indexOf(Record o); Record get(Integer id); Integer addRecord(Record r); Integer set(Integer rId, Record r); int xColumnSize(); TypeInference.DataType getYDataType(); Map<Object, TypeInference.DataType> getXDataTypes(); FlatDataList getXColumn(Object column); FlatDataList getYColumn(); void dropXColumns(Set<Object> columnSet); Dataframe getSubset(FlatDataList idsCollection); void recalculateMeta(); @Override Dataframe copy(); Iterable<Map.Entry<Integer, Record>> entries(); Iterable<Integer> index(); Iterable<Record> values(); Record _unsafe_set(Integer rId, Record r); }
Dataframe implements Collection<Record>, Copyable<Dataframe>, Savable { @Override public boolean remove(Object o) { Integer id = indexOf((Record) o); if(id == null) { return false; } remove(id); return true; } Dataframe(Configuration configuration); private  Dataframe(String storageName, Configuration configuration); private  Dataframe(Configuration configuration, TypeInference.DataType yDataType, Map<String, TypeInference.DataType> xDataTypes); void save(String storageName); void delete(); @Override void close(); @Override int size(); @Override boolean isEmpty(); @Override void clear(); @Override boolean add(Record r); @Override boolean contains(Object o); @Override boolean addAll(Collection<? extends Record> c); @Override boolean containsAll(Collection<?> c); @Override Object[] toArray(); @Override @SuppressWarnings("unchecked") T[] toArray(T[] a); @Override Iterator<Record> iterator(); @Override Stream<Record> stream(); @Override boolean remove(Object o); @Override boolean removeAll(Collection<?> c); @Override boolean retainAll(Collection<?> c); Record remove(Integer id); Integer indexOf(Record o); Record get(Integer id); Integer addRecord(Record r); Integer set(Integer rId, Record r); int xColumnSize(); TypeInference.DataType getYDataType(); Map<Object, TypeInference.DataType> getXDataTypes(); FlatDataList getXColumn(Object column); FlatDataList getYColumn(); void dropXColumns(Set<Object> columnSet); Dataframe getSubset(FlatDataList idsCollection); void recalculateMeta(); @Override Dataframe copy(); Iterable<Map.Entry<Integer, Record>> entries(); Iterable<Integer> index(); Iterable<Record> values(); Record _unsafe_set(Integer rId, Record r); static final String COLUMN_NAME_Y; static final String COLUMN_NAME_CONSTANT; }