/** * Creates a new <code>BitVectorDto</code> object that posesses the same characteristics as a * given <code>BitVector</code>. * * @param id the internal id to give to this BitVectorDto object. * @param v the <code>BitVector</code> from which data will be obtained. * @return a <code>BitVectorDto</code> based on the information (size, bits) found in the <code> * BitVector</code> <b>v</b>. */ public static BitVectorDto toDto(long id, BitVector v) { BitVectorDto d = new BitVectorDto(); d.setId(id); d.setSize(v.size()); d.setBits(v.getBits()); return d; }