Class
MGRSUtils
public class MGRSUtils
- Military Grid Reference System utilities
Methods
validateZoneNumber(_:)
public static func validateZoneNumber(_ number: Int)
- Validate the zone number
- @param number
-
zone number
validateBandLetter(_:)
public static func validateBandLetter(_ letter: Character)
- Validate the band letter
- @param letter
-
band letter
nextBandLetter(_:)
public static func nextBandLetter(_ letter: Character) -> Character
- Get the next band letter
- @param letter
-
band letter
- @return next band letter, 'Y' (MGRSConstants.MAX_BAND_LETTER + 1)
-
if no next bands
previousBandLetter(_:)
public static func previousBandLetter(_ letter: Character) -> Character
- Get the previous band letter
- @param letter
-
band letter
- @return previous band letter, 'B' (MGRSConstants.MIN_BAND_LETTER
-
- 1) if no previous bands
labelName(_:_:)
public static func labelName(_ zoneNumber: Int, _ bandLetter: Character) -> String
- Get the label name
- @param zoneNumber
-
zone number
- @param bandLetter
-
band letter
- @return name
hemisphere(_:)
public static func hemisphere(_ bandLetter: Character) -> Hemisphere
- Get the hemisphere from the band letter
- @param bandLetter
-
band letter
- @return hemisphere