bool ArcNet::Node_Processing (Db_File *fh) { Node_File *file = (Node_File *) fh; XYZ_Point point; if (First_Record ()) { arcview_node.Num_Points (1); } if (Network_Service::Node_Processing (file)) { arcview_node.Copy_Fields (file); point.x = file->X (); point.y = file->Y (); point.z = file->Z (); arcview_node.points.Set (1, &point); if (!arcview_node.Write_Record ()) { Error ("Writing ArcView Node File"); } return (true); } return (false); }
int Data_Service::Put_Node_Data (Node_File &file, Node_Data &data) { file.Node (data.Node ()); file.X (UnRound (data.X ())); file.Y (UnRound (data.Y ())); file.Z (UnRound (data.Z ())); file.Subarea (data.Subarea ()); file.Partition (data.Partition ()); file.Notes (data.Notes ()); if (!file.Write ()) { Error (String ("Writing %s") % file.File_Type ()); } return (1); }
bool ArcNet::Get_Node_Data (Node_File &file, Node_Data &node_rec) { if (Data_Service::Get_Node_Data (file, node_rec)) { if (arcview_node.Is_Open ()) { arcview_node.Copy_Fields (file); XYZ_Point *point = arcview_node.Get_Points (); point->x = file.X (); point->y = file.Y (); point->z = file.Z (); if (!arcview_node.Write_Record ()) { Error (String ("Writing %s") % arcview_node.File_Type ()); } } return (true); } return (false); }