dotnet/examples/ManagedCPP/example-DMS.cpp
Go to the documentation of this file.
1 using namespace System;
2 using namespace NETGeographicLib;
3 
5 {
6  try {
7  {
8  System::String^ dms = "30d14'45.6\"S";
10  double ang = DMS::Decode(dms, type);
11  Console::WriteLine(String::Format("Type: {0} String: {1}", type, ang));
12  }
13  {
14  double ang = -30.245715;
15  System::String^ dms = DMS::Encode(ang, 6, DMS::Flag::LATITUDE, 0);
16  Console::WriteLine(String::Format("Latitude: {0}", dms));
17  }
18  }
19  catch (GeographicErr^ e) {
20  Console::WriteLine( String::Format( "Caught exception: {0}", e->Message ) );
21  return -1;
22  }
23  return 0;
24 }
int main(array< System::String^>^)
Exception class for NETGeographicLib.
Definition: numpy.h:543
Array< double, 1, 3 > e(1./3., 0.5, 2.)


gtsam
Author(s):
autogenerated on Sat May 8 2021 02:42:02