CryptoGateway 综合文本
文境: [Commercial][Archymeta Information Technologies]
[Technologies][White Paper for the File System Database]
File System Database
3) Polymorphism and Specialization
last-scan: Sat, 01 Dec 2012 02:35:31 GMT (e4738812c1587449...)

The operating system provides meta-properties of all files inside the corresponding file system. These meta-properties can be extracted and added into the virtual database to be queried, sorted against by the user. Although it gives the maximum common denominator for all files, it contains far too little information about the data contained inside a file system.

last-scan: Sat, 01 Dec 2012 02:35:31 GMT (64b8731408c02f1b...)

A file in a file system can contains any possible data types, most likely these data types contain further meta-properties and/or extended structure that can be parsed and added into the virtual database to be further queried and/or sorted against, giving a user much increased understanding of the data he/she has. Creating a virtual table for each one of these sub-types would create a maintenance nightmare, causing significant code redundancy (and thus potential for error), harder conceptual representation on the user interfaces, and other undesirable effects.

last-scan: Sat, 01 Dec 2012 02:35:31 GMT (7c9542bb41c56ef8...)

Fig. 4: File family used in the current version of the system. The root starts with the node “File Node”, all its specializations inherit its meta-properties. The same is true for the next generation of a specialization one.

OO polymorphism can be used to represent the “IS A” relationship, which is made possible by using our technologies. By using OO polymorphism, a piece of data in a file is first of all a file, which means that a user can query the meta-properties of file supported by the operation system. When needed, a user can specialize to a certain type of data, say images, and query against those meta-properties that are special to images, like the pixel-size of the image, the author, the title, etc., of the image. Images have more sub-classification, for example, those images that are taken by a modern camera contains the time it was take, the place (GPS coordinate) it was take, the information about the camera, etc.. These further details can only be revealed by further specialization inside the query expression. Figure 5 shows the file family (classification) used by the current version of the system.

last-scan: Sat, 01 Dec 2012 02:35:31 GMT (cb3c6174fc66f1d5...)

In addition to querying and sorting, specialization make it easier to bind corresponding handlers of the data contained inside the file, like previewer, editor, player, consumer, etc., which are different from one type of data to another.