Skip to content

Commit d67e31c

Browse files
committed
add description
1 parent a7dfa83 commit d67e31c

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Port of the [open-location-code](https://github.com/google/open-location-code) library (also known as [plus codes](https://plus.codes)) for identifying geo areas.
44

5-
This ports commit (a6eb95b)[https://github.com/google/open-location-code/commit/a6eb95b4d2f934e94dae4f092260caf7f3db7967]
5+
This ports commit [a6eb95b](https://github.com/google/open-location-code/commit/a6eb95b4d2f934e94dae4f092260caf7f3db7967).
66

77
## Example
88

@@ -11,12 +11,12 @@ normal usage:
1111
```d
1212
import openlocationcode;
1313
14-
// get geo coordinates from plus code
14+
// get geo coordinates from plus code string
1515
OpenLocationCode plusCode = OpenLocationCode.fromString("8FVC2222+22GCCCC");
1616
writeln(plusCode.decode());
1717
// ->
1818
19-
// get plus code from geo coordinates
19+
// get plus code string from geo coordinates
2020
OpenLocationCode generatedPlusCode = OpenLocationCode.encode(lat, lon);
2121
writeln(generatedPlusCode.code);
2222
```
@@ -28,7 +28,7 @@ writeln(generatedPlusCode.code);
2828
```d
2929
import openlocationcode;
3030
31-
// get geo coordinates from plus code
31+
// get geo coordinates from plus code string
3232
string input = "8FVC2222+22GCCCC";
3333
if (!input.isValidCode)
3434
return error;
@@ -39,7 +39,7 @@ if (!plusCode.isFull)
3939
OpenLocationCodeArea area = plusCode.decodeTrustedFull();
4040
printf("area around %d, %d", area.centerLatitude, area.centerLongitude);
4141
42-
// get plus code from geo coordinates
42+
// get plus code string from geo coordinates
4343
ubyte[maxOLCLength] buffer;
4444
scope ubyte[] generatedPlusCodeString = OpenLocationCode.encode(buffer, lat, lon);
4545
printf("%s", cast(char[])generatedPlusCodeString);

dub.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{
22
"name": "d-open-location-code",
3+
"description": "port of google's open-location-code (also known as Plus+Codes)",
34
"license": "Apache-2.0",
45
"targetType": "library",
56
"configurations": [

0 commit comments

Comments
 (0)