Locators
 

Locators are used to uniquely identify a file or other object in the DMNSion Exchange system. A locator string is composed of phrases preceeded by and delimited by the slash / character. An example of a locator string is:

/winklerlaw/Dunham, Mark/Reports/Dr. Jones/Final Exam.pdf:2t

Lets break it down:

Account

The first phrase is the account name where the object resides. The account name is assigned by DMNSion to each account in the system.

Root

The second phrase is the root, typically the account's client name, but defined by the account.

Folders

After the root phrase, any number of phrases can be defined to specify the sub-folder within the root folder where the file or object is found. All are defined by the account.

File

The last phrase in the locator string is the file name. Note that there is an optional ending to the file name, which is the page number and/or type. The page number and/or type are preceeeded by a colon : character.

 

Locators for each types of object

Account

The account locator string is the smallest locator string that can be found:

/winklerlaw/

Note that the ending slash is required.

This locator string can only be used with a GET operation and it returns a listing of the root folders (clients) for the account.

Client

The client string adds the client name to the account locator:

/winklerlaw/Dunham, Mark/

Note that the ending slash is required.

This locator string can only be used with a GET operation and it returns a listing of the folders and files in the root directory of the client.

... Note

The client note adds the note page type to the client locator:

/winklerlaw/Dunham, Mark/:n

The client note can be read and written to. It is a text string.

... Data

The client data adds the data page type to the client locator:

/winklerlaw/Dunham, Mark/:d

The client data can be read and written to. It is a JSON object.

Folder

The folder string adds the folder name to the client locator:

/winklerlaw/Dunham, Mark/Reports/

Note that the ending slash is required.

This locator string can only be used with a GET operation and it returns a listing of the folders and files in the folder.

... Note

The folder note adds the note page type to the folder locator:

/winklerlaw/Dunham, Mark/Reports/:n

The folder note can be read and written to. It is a text string.

... Data

The folder data adds the data page type to the folder locator:

/winklerlaw/Dunham, Mark/Reports/:d

The folder data can be read and written to. It is a JSON object.

File

The file string adds the file name to a folder or client locator:

/winklerlaw/Dunham, Mark/Reports/Dr. Jones/Final Exam.pdf

... Note

The file note adds the note page type to the file locator:

/winklerlaw/Dunham, Mark/Reports/Dr. Jones/Final Exam.pdf:n

The file note can be read and written to. It is a text string.

... Thumbnail

The file thumbnail adds the thumbnail page type to the file locator:

/winklerlaw/Dunham, Mark/Reports/Dr. Jones/Final Exam.pdf:t

The file thumbnail can only be read. It is a JPEG image.

... PDF

The file pdf adds the pdf page type to the file locator:

/winklerlaw/Dunham, Mark/Reports/Dr. Jones/Final Exam.doc:p

The file pdf can only be read. Note that we changed the file from a pdf in the other examples to MS Word. You can obtain the PDF representation of many types of files.

... Page

The file page adds the page number to the file locator:

/winklerlaw/Dunham, Mark/Reports/Dr. Jones/Final Exam.pdf:3

The file page can only be read. It is a JPEG image created from the PDF representation of the file, if available.

... Page Thumbnail

The file thumbnail adds the page number thumbnail page type to the file locator:

/winklerlaw/Dunham, Mark/Reports/Dr. Jones/Final Exam.pdf:3t

The file page thumbnail can only be read. It is a JPEG image crated from the page, if available.

 

Format of a listing

When a listing is returned from a GET operation, it has a format similar to the return of an FTP LIST command. Each folder and/or file is detailed in a single text row with the following formats:

Folder

drwxrwxrwx 0 nobody nobody 0 Oct 09 06:40 Smith, Mary

The first word indicates that the entry is a folder by starting with the character d. Next a zero is always returned, followed by the creator and owner names which default to nobody.

The next word is the size of the folder and a zero is always returned.

The date of creatinon is returned next, in the format of MMM dd hh:mm or MMM dd yyyy. Notice the absence of a year if the date is within one year.

Last the name of the folder is returned. Note that there may be blanks in the folder name.

File

-rwxrwxrwx 1 ec@ecandidus ec@ecandidus 1602535 Nov 16 01:24 Lower Back.JPG

The first word indicates that the entry is a file by starting with the character -. Next the number of page thumbnails available is returned, followed by the creator and modifier handlers. Any spaces in the handler names are replaced by the underscore _ character.

The file size is returned next, folowed by the last modified date in the same format as described above. Ending it is the file name.

 

Next: Handlers