Geo::TigerLine::Record::2 - TIGER/Line 2006 Complete Chain Shape Coordinates
use Geo::TigerLine::Record::2; @records = Geo::TigerLine::Record::2->parse_file($fh); @records = Geo::TigerLine::Record::2->parse_file($fh, \&callback); $record = Geo::TigerLine::Record::2->new(\%fields); $record->rt(); $record->version(); $record->tlid(); $record->rtsq(); $record->long1(); $record->lat1(); $record->long2(); $record->lat2(); $record->long3(); $record->lat3(); $record->long4(); $record->lat4(); $record->long5(); $record->lat5(); $record->long6(); $record->lat6(); $record->long7(); $record->lat7(); $record->long8(); $record->lat8(); $record->long9(); $record->lat9(); $record->long10(); $record->lat10();
This is a class representing record type 2 of the TIGER/Line 2006 census geographic database. Each object is one record. It also contains methods to parse TIGER/Line record type 2 files and turn them into objects.
This is intended as an intermediate format between pulling the raw data out of the simplistic TIGER/Line data files into something more sophisticated (a process you should only have to do once). As such, it's not very fast, but its careful, easy to use and performs some verifications on the data being read.
As this class is autogenerated by mk_parsers, think before you modify this file. It's OO, so consider sub-classing instead.
These are simple get/set accessors for each field of a record generated from the TIGER/Line 2006 data dictionary. They perform some data validation.
$data = $record->rt(); $record->rt($data);
Record Type.
Expects alphanumeric data of no more than 1 characters. $data cannot be blank and should be left justified.
$data = $record->version(); $record->version($data);
Version Number.
Expects numeric data of no more than 4 characters. $data cannot be blank and should be left justified.
$data = $record->tlid(); $record->tlid($data);
TIGER/Line ID, Permanent 1-Cell Number.
Expects numeric data of no more than 10 characters. $data cannot be blank and should be right justified.
$data = $record->rtsq(); $record->rtsq($data);
Record Sequence Number.
Expects numeric data of no more than 3 characters. $data cannot be blank and should be right justified.
$data = $record->long1(); $record->long1($data);
Point 1, Longitude.
$data = $record->lat1(); $record->lat1($data);
Point 1, Latitude.
Expects numeric data of no more than 9 characters. $data cannot be blank and should be right justified.
$data = $record->long2(); $record->long2($data);
Point 2, Longitude.
Expects numeric data of no more than 10 characters. $data can be blank and should be right justified.
$data = $record->lat2(); $record->lat2($data);
Point 2, Latitude.
Expects numeric data of no more than 9 characters. $data can be blank and should be right justified.
$data = $record->long3(); $record->long3($data);
Point 3, Longitude.
$data = $record->lat3(); $record->lat3($data);
Point 3, Latitude.
$data = $record->long4(); $record->long4($data);
Point 4, Longitude.
$data = $record->lat4(); $record->lat4($data);
Point 4, Latitude.
$data = $record->long5(); $record->long5($data);
Point 5, Longitude.
$data = $record->lat5(); $record->lat5($data);
Point 5, Latitude.
$data = $record->long6(); $record->long6($data);
Point 6, Longitude.
$data = $record->lat6(); $record->lat6($data);
Point 6, Latitude.
$data = $record->long7(); $record->long7($data);
Point 7, Longitude.
$data = $record->lat7(); $record->lat7($data);
Point 7, Latitude.
$data = $record->long8(); $record->long8($data);
Point 8, Longitude.
$data = $record->lat8(); $record->lat8($data);
Point 8, Latitude.
$data = $record->long9(); $record->long9($data);
Point 9, Longitude.
$data = $record->lat9(); $record->lat9($data);
Point 9, Latitude.
$data = $record->long10(); $record->long10($data);
Point 10, Longitude.
$data = $record->lat10(); $record->lat10($data);
Point 10, Latitude.
This is the original TIGER/Line 2006 data dictionary from which this class was generated.
Record Type 2 - Complete Chain Shape Coordinates Field BV Fmt Type Beg End Len Description RT No L A 1 1 1 Record Type VERSION No L N 2 5 4 Version Number TLID No R N 6 15 10 TIGER/Line ID, Permanent 1-Cell Number RTSQ No R N 16 18 3 Record Sequence Number LONG1 No R N 19 28 10 Point 1, Longitude LAT1 No R N 29 37 9 Point 1, Latitude LONG2 Yes R N 38 47 10 Point 2, Longitude LAT2 Yes R N 48 56 9 Point 2, Latitude LONG3 Yes R N 57 66 10 Point 3, Longitude LAT3 Yes R N 67 75 9 Point 3, Latitude LONG4 Yes R N 76 85 10 Point 4, Longitude LAT4 Yes R N 86 94 9 Point 4, Latitude LONG5 Yes R N 95 104 10 Point 5, Longitude LAT5 Yes R N 105 113 9 Point 5, Latitude LONG6 Yes R N 114 123 10 Point 6, Longitude LAT6 Yes R N 124 132 9 Point 6, Latitude LONG7 Yes R N 133 142 10 Point 7, Longitude LAT7 Yes R N 143 151 9 Point 7, Latitude LONG8 Yes R N 152 161 10 Point 8, Longitude LAT8 Yes R N 162 170 9 Point 8, Latitude LONG9 Yes R N 171 180 10 Point 9, Longitude LAT9 Yes R N 181 189 9 Point 9, Latitude LONG10 Yes R N 190 199 10 Point 10, Longitude LAT10 Yes R N 200 208 9 Point 10, Latitude
Michael G Schwern <schwern@pobox.com>
Geo::TigerLine, mk_parsers
To install Geo::TigerLine, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Geo::TigerLine
CPAN shell
perl -MCPAN -e shell install Geo::TigerLine
For more information on module installation, please visit the detailed CPAN module installation guide.