2D-Information File Format
Users' data programs are based on the open 2D-information file format, which is designed to implement 2D-info navigation functionality.
All modules are written in the portable JavaTM computer language.
There are two main types of the data programs:
- full description of the information space, element by element
(see example);
- script of changes, describing only differences in comparison with another data program
(see example).
Any 2D-information program is a subclass of the main InfoEngine module, - InfoProcessor,
which in turn consists of the whole set of classes:
Viewer, Editor, and InfoObject.
All of them are located in knowledge2D.world package.
To use these classes, each data program must contain the following line:
import knowledge2D.world.*;
While data programs of type (1) are direct subclasses of the InfoProcessor
(this is implemented by using extends keyword in their class declaration),
programs of type (2) usually inherit the ones of type (1). In the latter case,
it is possible to inherit the whole chain of programs, provided they inherit
each other and InfoProcessor is their original parent class.
Programs of type (1)
start with mentioning some general info variables: data title, owner,
version, default coordinates for entering the InfoPage, etc.
Then, main data variables are described:
For each Unit, the following data is given.
-
META information.
The only requirement is that parameter 1 (type of content) must be present for
any valid element. Although number of the parameters can be arbitrary,
the InfoExplorer is limited by processing the first five ones
(see types).
-
Actual content.
Ideally, the data should be present for each abstraction Level.
It can contain plain text. However, more effective way is to store
there compact links to texts located somewhere on the net.
Next step is in forming elements for each Instance.
Finally, all the Units are assembled into the resulting 2D-info structure:
Each Unit consists of a set of its Instances, where in turn, each Instance
is represented by a set of different Levels of abstraction.
In addition, there can be description of bookmarks, if any.
All this code is located inside the LoadContent() method,
which executes during loading the InfoPage.
Programs of type (2)
reflect all the changes made to the data during working
session.
Current version of the InfoExplorer provides recording of using
such editor's functions as "Select", "Connect", "Modify",
Add/Insert/Remove Unit, managing Bookmarks and META
information.
For example, if viewing the fifth Instance of the second Unit user
clicks Navigator's button "Select", the following line will be added into
the program:
select (2, 5);
Starting this program has the same effect as if the user goes to the same
location and clicks the "Select" as described above.
Using such programs results in executing all recorded functions in the order they were made. This creates exact copy of the information environment that existed at specific time.
All this code is located inside the LoadProgrammedContent() method,
which executes during loading the InfoPage.
Towards a new Data Description Language
All 2D-information compatible documents are extensions to the InfoProcessor.
To work with these documents, processing programs can call InfoProcessor's functions.
For example, from the beginning a program imports the Test_Data and initializes the data file by executing
Test_Data ip = new Test_Data();
As all InfoProcessor's methods are a part of the data program already,
there is no need to write their implementation code. Programs can call them directly by their names,
e.g., ip.forward(); ip.down(); etc.
We can continue the subclassing (e.g., MyData extends Test_Data, etc.),
and use any InfoProcessor's methods in the inherited programs.
Complete list of the available methods is specified by the infoObject interface.
Normally, a 2D-information program runs by executing one InfoProcessor's method after another.
However, this flow of execution may be changed. As InfoProcessor is written in Java, 2D-information programmers can use any Java flow control statements:
if.. else..; for.., while.. loops, etc.
See example on how some Java statements might be used in a 2D-information program.
InfoProcessor's methods can be used both as sentences in users' data programs, and as commands in external computer programs. For example, the 2D-infoExplorer's code is built mostly on the top of the InfoProcessor.
Also, see the InfoWorld format, which allows assembling 2D-information programs into manageable blocks, e.g., books or manuals.
This Web site is not and in no way is affiliated to official site of the
InfoSpace, Inc.
The term "2D-info Space" is not affiliated with trademarks of the
InfoSpace, Inc.
Copyright(C) S. Beloy