I am trying to write/find some code in Java which reads dxf files and stores geometry from the \"Entities\" section into arrays so that I can later import that information i
For some feedback of general interest read Reading .DXF files
There's a number of Java libraries that implement a DXF reader/writer like kabeja (Open Source) and de-caff (a free viewer, the libraries it's based on are available commercially).
A word of warning: DXF is way more complicated than it looks at first sight, so if you select a solution test it thoroughly on your data.