use of com.revolsys.record.io.RecordReader in project com.revolsys.open by revolsys.
the class EpsgCoordinateSystemsLoader method loadCoordOperationParam.
private void loadCoordOperationParam() {
try (RecordReader reader = newReader("/public/epsg_coordoperationparam", "parameter_code");
ChannelWriter writer = newWriter("coordOperationParam")) {
for (final Record record : reader) {
writeInt(writer, record, "parameter_code");
writeString(writer, record, "parameter_name");
writeDeprecated(writer, record);
}
}
}
use of com.revolsys.record.io.RecordReader in project com.revolsys.open by revolsys.
the class EpsgCoordinateSystemsLoader method loadCoordOperationParamUsage.
/**
* Order of parameters for a coordOperation
*/
private void loadCoordOperationParamUsage() {
try (RecordReader reader = newReader("/public/epsg_coordoperationparamusage", "coord_op_method_code", "sort_order");
ChannelWriter writer = newWriter("coordOperationParamUsage")) {
for (final Record record : reader) {
writeInt(writer, record, "coord_op_method_code");
writeInt(writer, record, "parameter_code");
writeInt(writer, record, "sort_order");
writeCodeByte(writer, record, "param_sign_reversal", PARAM_SIGN_REVERSAL);
}
}
}
use of com.revolsys.record.io.RecordReader in project com.revolsys.open by revolsys.
the class EpsgCoordinateSystemsLoader method loadDatum.
private void loadDatum() throws IOException {
final List<String> datumTypes = Arrays.asList("geodetic", "vertical", "engineering");
try (final RecordReader reader = newReader("/public/epsg_datum", "datum_code");
ChannelWriter writer = newWriter("datum")) {
for (final Record record : reader) {
writeInt(writer, record, "datum_code");
writeString(writer, record, "datum_name");
writeCodeByte(writer, record, "datum_type", datumTypes);
writeInt(writer, record, "ellipsoid_code", 0);
writeInt(writer, record, "prime_meridian_code", 0);
writeInt(writer, record, "area_of_use_code");
writeDeprecated(writer, record);
}
}
}
use of com.revolsys.record.io.RecordReader in project com.revolsys.open by revolsys.
the class EpsgCoordinateSystemsLoader method loadArea.
private void loadArea() {
try (final RecordReader reader = newReader("/public/epsg_area", "area_code");
ChannelWriter writer = newWriter("area")) {
for (final Record record : reader) {
writeInt(writer, record, "area_code");
writeString(writer, record, "area_name");
writeDouble(writer, record, "area_west_bound_lon");
writeDouble(writer, record, "area_south_bound_lat");
writeDouble(writer, record, "area_east_bound_lon");
writeDouble(writer, record, "area_north_bound_lat");
writeDeprecated(writer, record);
}
}
}
use of com.revolsys.record.io.RecordReader in project com.revolsys.open by revolsys.
the class EpsgCoordinateSystemsLoader method loadPrimeMeridian.
private void loadPrimeMeridian() throws IOException {
try (final RecordReader reader = newReader("/public/epsg_primemeridian", "prime_meridian_code");
ChannelWriter writer = newWriter("primeMeridian")) {
for (final Record record : reader) {
writeInt(writer, record, "prime_meridian_code");
writeString(writer, record, "prime_meridian_name");
writeInt(writer, record, "uom_code");
writeDouble(writer, record, "greenwich_longitude");
if (isDeprecated(record)) {
System.err.println("Add deprecated support to prime meridian");
}
}
}
}
Aggregations