android-java error
<p>i am trying a develop a application..following is a snippet </p>

<pre><code>class metro_nodes {
public String station;
public GeoPoint point; }

public class mainscreen extends MapActivity {
/** Called when the activity is first created. */

MapController controller;
double latitude,longitude;
LocationManager loc;
Location lastknownloc;
LocationListener loclistener;
List&lt;GeoPoint&gt; geopoints = new ArrayList&lt;GeoPoint&gt;();
MapView mapView;
private LinkedList&lt;metro_nodes&gt; station_location = new LinkedList&lt;metro_nodes&gt;();
metro_nodes anand_nagar;
anand_nagar.station = "anand_nagar";
    }
</code></pre>

<p>now in the second last line its giving -"Syntax error on token "station", VariableDeclaratorId expected after this token"</p>

<p>if i put curly braces around this statement then error get removed..but then i get java lang null pointer exception...
whats the problm ??</p>
