The purpose of this file is to define a standard way of storing rally courses, allowing programs to exchange their courses with other programs,
even if those other programs are on a different platform or operating system.
This page defines how such XML files are to be formatted.
Files for these courses should be named with an extension of .ref (for Rally Event File).
A .ref file that includes any logos or non-standard accessories must include those image files in the same folder or a sub-folder of the .ref file.
This is usually an issue when sharing course files.
Let's begin with the definition of the outermost field within the file, the RALLY_EVENT element.
Exactly one such element is required.
The NAME attribute is optional.
In general, the NAME attribute should reflect the overall theme of the courses within the file.
The file is called an Event file because it can contain all of the courses for a given event.
For example, the event could be a set of courses for a trial.
But it could just as easily contain a semester's worth of training classes, or all the courses a dog ran to get it's Rally Championship title.
Courses within a single Event file need not be of the same registry, rule set, or course level.
<?xml version="1.0" encoding="ISO-8859-1"?>
<RALLY_EVENT NAME="SLKC - January 1, 2012">
.
.
.
</RALLY_EVENT>
|
Within the RALLY_EVENT element, the following elements may exist.
<?xml version="1.0" encoding="ISO-8859-1"?>
<RALLY_EVENT NAME="SLKC - January 31, 2012">
<CREATED_ON>01/31/2012</CREATED_ON>
<DESCRIPTION>08:00AM</DESCRIPTION>
<COURSES>see below</COURSES>
</RALLY_EVENT>
|
Let's look at these attributes and elements in more detail.
- CREATED_ON: The date the course was created, MM/DD/YYYY
- DESCRIPTION: Whatever else needs to be recorded regarding this event.
Within the COURSES element, one or more COURSE elements may exist.
<COURSE REGISTRY="Anybody's Kennel Club (AKC)" LEVEL="Beginners" TYPE="Regular">
<COURSE_TYPE>Trial</COURSE_TYPE>
<VENUE>Outdoor</VENUE>
<CLASSES>A/B</CLASSES>
<RING_WIDTH>45</RING_WIDTH>
<RING_HEIGHT>50</RING_HEIGHT>
<HOST_NAME>A Local Kennel Club</HOST_NAME>
<HOST_ABBREVIATION>ALKC</HOST_ABBREVIATION>
<HOST_URL>ALKC</HOST_URL>
<LOGO1>images/alkc_logo.jpg</LOGO1>
<LOGO2>images/alkc_logo.jpg</LOGO2>
<AUTHOR>The Honorable James Jonah Jameson</AUTHOR>
<JUDGE>The Honorable James Jonah Jameson</RING_HEIGHT>
<COPYRIGHT>2012, The Honorable James Jonah Jameson</COPYRIGHT>
<COMMENTS>My inspiration for this course was the jughandles of New Jersey.</COMMENTS>
<ATTACHMENT>videos/fidosTitle.mp4</ATTACHMENT>
<STATIONS>See below</STATIONS>
<LINKS>See below</LINKS>
<RING_GATES>See below</RING_GATES>
<ACCESSORIES>See below</ACCESSORIES>
</COURSE>
|
Let's look at these attributes and elements in more detail.
- REGISTRY (attribute): The Name of the Registry, followed by a space and an opening parenthesis, followed by the Initials of the Registry, followed by a closing parenthesis.
If the Registry has no Initials, just use the Name of the Registry.
- LEVEL (attribute): The name that defines the level of difficulty of the course.
- TYPE (attribute): Registries may have their own definition of these, but an example is Regular/Non-Regular. (Optional)
- COURSE_TYPE: The purpose for creating the course. The possible values are:
Trial | Official |
Match | Official |
Show and Go | Official |
Class | Unofficial |
Clinic | Unofficial |
Practice | Unofficial |
Seminar | Unofficial |
Workshop | Unofficial |
Separating Official and Unofficial Courses allows the user agent to present feedback that is different between the two types.
- CLASSES: Registries may have their own definition of these, but an example is "A/B". (Optional)
- RING_WIDTH: An integer value representing the actual ring width, using units defined for the course's Registry.
- RING_HEIGHT: An integer value representing the actual ring height, using units defined for the course's Registry.
Courses should be constructed with their height greater than their width.
- HOST_NAME: The name of the club hosting the event or activity.
- HOST_ABBREVIATION: The abbreviation of the club hosting the event or activity.
- HOST_URL: The website of the club hosting the event or activity.
- LOGO1: An image that will be included on the course map print-out.
Generally, use the logo of the club hosting the event or activity here.
- LOGO1: An second image that will be included on the course map print-out.
Generally, use the logo of the course's registry here.
- AUTHOR: The person who created the course. (optional)
- JUDGE: The name of the judge for trial and match courses.
Alternately, an INSTRUCTOR tag may be used for unofficial. (optional)
- COPYRIGHT: Programs should allow copyrights to be appended to courses.
When opening a copyrighted course that does not belong to the owner of the program,
the program should allow the course to be read, displayed and printed as is,
but it should prevent the course from being edited or saved as another course. (optional)
- COMMENTS: Comments about the course from the author or judge. (optional)
- ATTACHMENT: Relative path or URL to an image, audio or video file associated with the course. (optional)
Within the STATIONS element, multiple STATION elements must exist.
<STATIONS>
.
.
.
<STATION NUMBER=12>
<SIGN>1</SIGN>
<X>10</X>
<Y>15</Y>
<ROTATION>0</ROTATION>
<INCOMING_CONNECTION_POINT>SW</INCOMING_CONNECTION_POINT>
<OUTGOING_CONNECTION_POINT>NW</OUTGOING_CONNECTION_POINT>
<REQUIRED>NW</OUTGOING_CONNECTION_POINT>
<START>NW</OUTGOING_CONNECTION_POINT>
<FINISH>NW</OUTGOING_CONNECTION_POINT>
<HONOR>NW</OUTGOING_CONNECTION_POINT>
<BONUS>NW</OUTGOING_CONNECTION_POINT>
</STATION>
.
.
.
</STATIONS>
|
- NUMBER: Station number, numeric only.
- SIGN: The NUMBER of the sign to be used at this station.
- X: The distance from the left side of the course map drawing.
- Y: The distance from the bottom of the course map drawing.
- ROTATION: Angle of rotation of the sign, in degrees.
Zero degrees means the sign points north.
The rotation goes clockwise.
- INCOMING_ATTACHMENT_POINT: Position on the sign where the arrow coming into it from the previous sign on the course will attach.
- OUTGOING_ATTACHMENT_POINT: Position on the sign where the arrow leaving it to the subsequent sign on the course will attach.
- REQUIRED: Either TRUE or FALSE, if the sign is required for this course.
All courses require one Start and one Finish sign.
- START: Either TRUE or FALSE, if the sign is the Start sign for this course.
- FINISH: Either TRUE or FALSE, if the sign is the Finish sign for this course.
- FINISH: Either TRUE or FALSE, if the sign is the Finish sign for this course.
- HONOR: Either TRUE or FALSE, if the sign is an Honor sign for this course.
Honor signs may only be placed after the Finish sign.
- BONUS: Either TRUE or FALSE, if the sign is an Bonus sign for this course.
Bonus signs may only be placed after the Finish sign.
Within the LINKS element, multiple LINK elements must exist.
<LINKS>
.
.
.
<LINK NUMBER=12>
<FROM>12.NW</FROM>
<TO>13.S</TO>
</LINK>
.
.
.
</LINKS>
|
- NUMBER (attribute): Sequential number, numeric only.
- FROM: The NUMBER of the station, followed by a period, followed by the corner designation of the point from which the arrow will originate.
- TO: The NUMBER of the station, followed by a period, followed by the corner designation of the point to which the arrow will terminate.
Within the RING_GATES element, multiple RING_GATE elements may exist.
<RING_GATES>
<RING_GATE SIDE="E" LOCATION="10">IN</RING_GATE>
.
.
.
<RING_GATES>
|
- SIDE (attribute): N, S, E, or W, defines the side to which this ring gate is attached.
- LOCATION (attribute): If the gate is on the E or W sides, then this is how far up the side the ring gate will be located (center of gate).
If the gate is on the N or S sides, then this is how far from the left the ring gate will be located (center of gate).
- Text: Either IN, OUT, or BOTH, this describes the direction of ring gate.
Within the ACCESSORIES element, multiple ACCESSORY elements may exist.
<ACCESSORIES>
<ACCESSORY TYPE="Cone">
<X>12</X>
<Y>29.4</Y>
<WIDTH>60</WIDTH>
<HEIGHT>80</HEIGHT>
<ANGLE>0</ANGLE>
</ACCESSORY>
<ACCESSORIES>
<ACCESSORY TYPE="IMG" SRC="images/dog.jpg">
<X>26.3</X>
<Y>13</Y>
<WIDTH>60</WIDTH>
<HEIGHT>60</HEIGHT>
<ROTATION>0</ROTATION>
</ACCESSORY>
.
.
.
</ACCESSORIES>
|
- TYPE (attribute): One of the standard set of accessories or a user-supplied image.
- Cone
- Food Bowl
- Chair
- Bar Jump
- Broad Jump
- High Jump
- IMG
- SRC: Path to the file to insert onto the course, only if TYPE is IMG.
- X, Y: The horizontal and vertical location of the center of the object.
- ROTATION: The rotation of the object, in clockwise degrees.