<LocusAlreadyExists> error message and the object
that already exists is actually of type Site, the use the <Site> format for printing the
error message. If the actual type of the object is a generic Locus (not a Site), use
the <Locus> format.
The same applies to <Track> which may be of type <OneWayTrack> or <TwoWayTrack>.
This should be a fairly easy task in JAVA if you set up your classes properly. (Hint: overload the toString() method).
<Locus>:=<LocusType>: <LocusName> at (<longitude>,<latitude>) <Radius>
<Radius>:=<ZeroRadius>|<NonZeroRadius>
<ZeroRadius>:= with radius 0
<NonZeroRadius>:=with radius <radius>
<LocusType>:=<SiteType>|interesting place|junction|MASH unit|pantry and supplies|
shelter|weapons|unassigned
<SiteType>:=air unit|military base|civilian territory|ground unit|hospital
<LocusName>:=<name>
<StartName>:=<LocusName>
<DestinationName>:=<LocusName>
<StartLocus>:=<Locus>
<DestinationLocus>:=<Locus>
<LocusList>:=<Locus><nl><LocusList>|<Locus><nl>
<FindInSiteLocusList>:=<Locus> at distance: <double><nl><FindInSiteLocusList>|
<Locus> at distance: <double><nl>
<Track>:= (<StartName><Direction> <DestinationName>)
<Direction>:=<OneWay>|<TwoWay>
<OneWay>:= ==>
<TwoWay>:= <=>
<ListTracks>:=Follow <Track><nl><ListTracks>|Follow <Track><nl>
<Route>:=<ListTracks><nl>Total length: <double><nl>
<LocusDoesNotExist>:=Error: <LocusName>, does not exist<nl>
<UnableToDeleteLocus>:=Error: <Locus> cannot be deleted because it is mapped<nl>
<LocusNotMapped>:=Error: The locus <Locus> has not been mapped<nl>
<LocusInUse>:=Error: The locus <Locus> cannot be unmapped while any tracks use it
as a start or destination<nl>
<LocusAlreadyMapped>:=Error: The locus <Locus> has already been mapped
at those coordinates<nl>
<LocusAlreadyExists>:=Error: The specified locus cannot be created because
<Locus> already exists<nl>
<TrackAlreadyExists>:=Error: The specified track cannot be created because
<Track> already exists<nl>
<StartAndDestinationSame>:=Error: Start locus and destination locus
must be different<nl>
<SpatialIntersection>:=Error: Spacial intersection<nl>
<NoRouteExists>:=Error: No route could be found from <StartLocus> to
<DestinationLocus><nl>
<NoLociEntered>:=No loci entered<nl>
<BPTreeOrderAlreadyInitialized>:=Error: B+ tree already initialized<nl>
<InvalidBPTreeOrder>:=Error: B+ tree order must be greater than or equal to three (3)<nl>
<BPTreeOrderNotYetInitialized>:=Error: B+ tree has yet to be initialized<nl>
<InvalidLocusType>:=Error: Invalid locus type<nl>
<SiteWithZeroRadius>:=Error: Sites must have non-zero radii<nl>
<NotSitePosRadius>:=Error: Only Sites may have non-zero radii<nl>
<SiteNameIsLocus>:=Error: Cannot perform operation on a Locus<nl>
<LocusNameIsSite>:=Error: Cannot perform operation on a Site<nl>