@Override protected void doGetRestorableState(RestorableSupport rs, RestorableSupport.StateObject context) { super.doGetRestorableState(rs, context); rs.addStateValueAsBoolean(context, "enableCaps", this.enableCaps); if (this.locations != null) rs.addStateValueAsLatLonList(context, "locations", this.locations); }
protected void doGetRestorableState(RestorableSupport rs, RestorableSupport.StateObject context) { super.doGetRestorableState(rs, context); if (this.boundaries.getContourCount() > 0) { RestorableSupport.StateObject so = rs.addStateObject(context, "boundaries"); for (int i = 0; i < this.boundaries.getContourCount(); i++) { rs.addStateValueAsLatLonList(so, "boundary", this.boundaries.getContour(i)); } } }