diff options
Diffstat (limited to 'kdejava/koala/org/kde/koala/KTipDatabase.java')
-rw-r--r-- | kdejava/koala/org/kde/koala/KTipDatabase.java | 74 |
1 files changed, 74 insertions, 0 deletions
diff --git a/kdejava/koala/org/kde/koala/KTipDatabase.java b/kdejava/koala/org/kde/koala/KTipDatabase.java new file mode 100644 index 00000000..56087877 --- /dev/null +++ b/kdejava/koala/org/kde/koala/KTipDatabase.java @@ -0,0 +1,74 @@ +//Auto-generated by kalyptus. DO NOT EDIT. +package org.kde.koala; + +import org.kde.qt.Qt; +import org.kde.qt.QtSupport; + +/** + + A database for tips-of-the-day. + This class provides convenient access to a database containing + tips of the day. The database is stored in a XML file and parsed + when a KTipDatabase object is created. + Once the file is read in, you can access the tips to display + them in the tip of the day dialog. + The state of the tipdialog is saved to the applications's config file + in the group "TipOfDay" with a boolean entry "RunOnStart". Check this value + if you want to allow the user to enable/disable the tipdialog in the + application's configuration dialog. + @author Matthias Hoelzer-Kluepfel <mhk@kde.org> + + @short A database for tips-of-the-day. + +*/ +public class KTipDatabase implements QtSupport { + private long _qt; + private boolean _allocatedInJavaWorld = true; + protected KTipDatabase(Class dummy){} + + /** + This constructor reads in the tips from a file with the given name. If + no name is given, a file called 'application-name/tips' will be loaded. + @param tipFile The absolute path to the tips file. + @short This constructor reads in the tips from a file with the given name. + */ + public KTipDatabase(String tipFile) { + newKTipDatabase(tipFile); + } + private native void newKTipDatabase(String tipFile); + public KTipDatabase() { + newKTipDatabase(); + } + private native void newKTipDatabase(); + /** + This constructor takes a list of files that will be merged. This constructor + essentially behaves like the one above. It returns when tipFiles is empty. + @param tipFiles A list of absolute paths to the tips file + @short This constructor takes a list of files that will be merged. + */ + public KTipDatabase(String[] tipFiles) { + newKTipDatabase(tipFiles); + } + private native void newKTipDatabase(String[] tipFiles); + /** + Returns the current tip. + @short Returns the current tip. + */ + public native String tip(); + /** + The next tip will become the current one. + @short The next tip will become the current one. + */ + public native void nextTip(); + /** + The previous tip will become the current one. + @short The previous tip will become the current one. + */ + public native void prevTip(); + /** Deletes the wrapped C++ instance */ + protected native void finalize() throws InternalError; + /** Delete the wrapped C++ instance ahead of finalize() */ + public native void dispose(); + /** Has the wrapped C++ instance been deleted? */ + public native boolean isDisposed(); +} |