Trace:
Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
jvx:reference [2020/06/15 08:55] cduncan [DataBooks] |
jvx:reference [2020/06/15 09:49] cduncan [The Simplest JVx Application: Just the GUI] |
||
---|---|---|---|
Line 624: | Line 624: | ||
columnDefinition.setNullable(false); | columnDefinition.setNullable(false); | ||
</code> | </code> | ||
- | ==== MetaData ==== | + | ==== Meta Data ==== |
Most of the column definition is additional information about the column, like if it is nullable, the label of the column, default values, allowed values, and similar information. | Most of the column definition is additional information about the column, like if it is nullable, the label of the column, default values, allowed values, and similar information. | ||
Line 667: | Line 667: | ||
===== Usage Example ===== | ===== Usage Example ===== | ||
- | Here is a simple example of a ''%%MemDataBook%%'', an ''%%IDataBook%%'' implementation which only operates in memory: | + | Here is a simple example of a ''%%MemDataBook%%'', an ''%%IDataBook%%'' implementation that only operates in memory: |
<code java> | <code java> | ||
Line 716: | Line 716: | ||
* Binary Data | * Binary Data | ||
- | Text and binary data are both objects (arrays of primitives are objects after all) and numbers are either primitives or objects. Most of the time, if we deal with numbers inside a database, we want them to be of arbitrary precision, which means we must represent them as ''%%BigDecimal%%''. Supporting ''%%double%%'' or ''%%float%%'' in these cases would be dangerous because one might write a ''%%float%%'' into the database [[https://en.wikipedia.org/wiki/Floating-point_arithmetic|which might or might not end up with the correct value]] in the database. To completely eliminate such problems, we only support objects, which means that one is “limited” to the usage of number extensions like ''%%BigLong%%'' and ''%%BigDecimal%%'', which do not suffer from such problems. | + | Text and binary data are both objects (arrays of primitives are objects after all) and numbers are either primitives or objects. Most of the time, if we deal with numbers inside a database, we want them to be of arbitrary precision, which means we must represent them as ''%%BigDecimal%%''. Supporting ''%%double%%'' or ''%%float%%'' in these cases would be dangerous because one might write a ''%%float%%'' into the database [[https://en.wikipedia.org/wiki/Floating-point_arithmetic|, which might or might not end up with the correct value]] in the database. To completely eliminate such problems, we only support objects, which means that one is “limited” to the usage of number extensions like ''%%BigLong%%'' and ''%%BigDecimal%%'', which do not suffer from such problems. |
==== Where Are the Data Pages? ==== | ==== Where Are the Data Pages? ==== | ||
Line 786: | Line 786: | ||
====== Application Basics ====== | ====== Application Basics ====== | ||
- | Let’s talk about the basics, how a [[https://sourceforge.net/projects/jvx/|JVx]] application starts, works and how the connection strings together the client and server side. | + | Let’s talk about the basics: how a [[https://sourceforge.net/projects/jvx/|JVx]] application starts, how it works, and how the connection strings together the client and server side. |
===== Multitier Architecture ===== | ===== Multitier Architecture ===== | ||
Line 817: | Line 817: | ||
frame.eventWindowClosed().addListener(() -> System.exit(0)); | frame.eventWindowClosed().addListener(() -> System.exit(0)); | ||
</code> | </code> | ||
- | We can start to create and manipulate the GUI. In this case we are building a simple window with a label inside. Last but not least, we make sure that the JVM will exit when the window is closed. | + | We can start to create and manipulate the GUI. In this case, we are building a simple window with a label inside. Lastly, we make sure that the JVM will exit when the window is closed. |
A very good example and showcase for that is the [[https://github.com/sibvisions/jvx.kitchensink|JVx Kitchensink]]. | A very good example and showcase for that is the [[https://github.com/sibvisions/jvx.kitchensink|JVx Kitchensink]]. | ||
- | That’s it. That is the most simple way to start a [[https://sourceforge.net/projects/jvx/|JVx]] application. We can use all controls, and we can use ''%%MemDataBook%%''s without any problem or limitation. Best of all, we can simply switch to another technology by using another factory. | + | That’s it! That is the most simple way to start a [[https://sourceforge.net/projects/jvx/|JVx]] application. We can use all controls, and we can use ''%%MemDataBook%%''s without any problem or limitation. Best of all, we can simply switch to another technology by using another factory. |
===== Anatomy of a remote JVx application ===== | ===== Anatomy of a remote JVx application ===== |