You have to get the column using
GRBColumn c = model.getCol(var),
see
http://www.gurobi.com/documentation/7.5/refman/cpp_grbmodel_getcol.html
This yields a GRBColumn object. With this you can query the number of non-zero
entries using iterate through the non-zero entries in the column by calling
c.size()
and then you can query the individual non-zero entries with c.getConstr(k) and
c.getCoef(k) with k going from 0 to c.size()-1.
If you want to get a dense representation (i.e., including the zeros) of the
column, then you would just start with a vector of all zeros that has a size
equal to the number of rows in the model, and then you iterate over the non-zero
entries of the column vector as described above, modifying the corresponding
entries in your dense vector while doing so.
Regards,
Tobias