summaryrefslogtreecommitdiffstats
path: root/tdejava/koala/org/trinitydesktop/koala/Observer.java
diff options
context:
space:
mode:
Diffstat (limited to 'tdejava/koala/org/trinitydesktop/koala/Observer.java')
-rw-r--r--tdejava/koala/org/trinitydesktop/koala/Observer.java365
1 files changed, 365 insertions, 0 deletions
diff --git a/tdejava/koala/org/trinitydesktop/koala/Observer.java b/tdejava/koala/org/trinitydesktop/koala/Observer.java
new file mode 100644
index 00000000..0acfe926
--- /dev/null
+++ b/tdejava/koala/org/trinitydesktop/koala/Observer.java
@@ -0,0 +1,365 @@
+//Auto-generated by kalyptus. DO NOT EDIT.
+package org.trinitydesktop.koala;
+
+import org.trinitydesktop.qt.Qt;
+import org.trinitydesktop.qt.TQMetaObject;
+import org.trinitydesktop.qt.QtSupport;
+import org.trinitydesktop.qt.TQObject;
+import java.util.ArrayList;
+import org.trinitydesktop.qt.TQObject;
+
+/**
+
+ Observer for TDEIO.Job progress information.
+ This class, of which there is always only one instance,
+ "observes" what jobs do and forwards this information
+ to the progress-info server.
+ It is a DCOP object so that the UI server can call the
+ kill method when the user presses Cancel.
+ Usually jobs are automatically registered by the
+ TDEIO.Scheduler, so you do not have to care about that.
+ @author David Faure <faure@kde.org>
+
+ @short Observer for TDEIO.Job progress information.
+
+*/
+public class Observer extends TQObject implements DCOPObjectInterface {
+ protected Observer(Class dummy){super((Class) null);}
+ public native TQMetaObject metaObject();
+ public native String className();
+ /**
+ Called by the job constructor, to signal its presence to the
+ UI Server.
+ @param job the new job
+ @param showProgress true to show progress, false otherwise
+ @return the progress ID assigned by the UI Server to the Job.
+
+ @short Called by the job constructor, to signal its presence to the UI Server.
+ */
+ public native int newJob(Job job, boolean showProgress);
+ /**
+ Called by the job destructor, to tell the UI Server that
+ the job ended.
+ @param progressId the progress ID of the job, as returned by newJob()
+ @short Called by the job destructor, to tell the UI Server that the job ended.
+ */
+ public native void jobFinished(int progressId);
+ /**
+ Opens a password dialog.
+ @param info the authentication information
+ @return true if successful ("ok" clicked), false otherwise
+
+ @short Opens a password dialog.
+ */
+ public native boolean openPassDlg(AuthInfo info);
+ /**
+ See renamedlg.h
+ @short
+ */
+ public native int open_RenameDlg(Job job, String caption, String src, String dest, int mode, StringBuffer newDest, long sizeSrc, long sizeDest, int ctimeSrc, int ctimeDest, int mtimeSrc, int mtimeDest);
+ public native int open_RenameDlg(Job job, String caption, String src, String dest, int mode, StringBuffer newDest, long sizeSrc, long sizeDest, int ctimeSrc, int ctimeDest, int mtimeSrc);
+ public native int open_RenameDlg(Job job, String caption, String src, String dest, int mode, StringBuffer newDest, long sizeSrc, long sizeDest, int ctimeSrc, int ctimeDest);
+ public native int open_RenameDlg(Job job, String caption, String src, String dest, int mode, StringBuffer newDest, long sizeSrc, long sizeDest, int ctimeSrc);
+ public native int open_RenameDlg(Job job, String caption, String src, String dest, int mode, StringBuffer newDest, long sizeSrc, long sizeDest);
+ public native int open_RenameDlg(Job job, String caption, String src, String dest, int mode, StringBuffer newDest, long sizeSrc);
+ public native int open_RenameDlg(Job job, String caption, String src, String dest, int mode, StringBuffer newDest);
+ /**
+ See skipdlg.h
+ @short
+ */
+ public native int open_SkipDlg(Job job, boolean multi, String error_text);
+ public native void stating(Job arg1, KURL url);
+ public native void mounting(Job arg1, String dev, String point);
+ public native void unmounting(Job arg1, String point);
+ public native void slotTotalSize(Job arg1, long size);
+ public native void slotTotalFiles(Job arg1, long files);
+ public native void slotTotalDirs(Job arg1, long dirs);
+ public native void slotProcessedSize(Job arg1, long size);
+ public native void slotProcessedFiles(Job arg1, long files);
+ public native void slotProcessedDirs(Job arg1, long dirs);
+ public native void slotSpeed(Job arg1, long speed);
+ public native void slotPercent(Job arg1, long percent);
+ public native void slotInfoMessage(Job arg1, String msg);
+ public native void slotCopying(Job arg1, KURL from, KURL to);
+ public native void slotMoving(Job arg1, KURL from, KURL to);
+ public native void slotDeleting(Job arg1, KURL url);
+ public native void slotTransferring(Job arg1, KURL url);
+ public native void slotCreatingDir(Job arg1, KURL dir);
+ public native void slotCanResume(Job arg1, long offset);
+ /**
+ Called by the UI Server (using DCOP) if the user presses cancel.
+ @param progressId the progress ID of the job, as returned by newJob()
+ @short Called by the UI Server (using DCOP) if the user presses cancel.
+ */
+ // void killJob(int arg1); >>>> NOT CONVERTED
+ /**
+ Called by the UI Server (using DCOP) to get all the metadata of the job
+ @param progressId the progress IDof the job, as returned by newJob()
+ @short Called by the UI Server (using DCOP) to get all the metadata of the job
+ */
+ // TDEIO::MetaData metadata(int arg1); >>>> NOT CONVERTED
+ /**
+ Returns the unique observer object.
+ @return the observer object
+
+ @short Returns the unique observer object.
+ */
+ public static native Observer self();
+ /**
+ Popup a message box. See TDEIO.SlaveBase.
+ This doesn't use DCOP anymore, it shows the dialog in the application's process.
+ Otherwise, other apps would block when trying to communicate with UIServer.
+ @param progressId the progress ID of the job, as returned by newJob()
+ @param type the type of the message box
+ @param text the text to show
+ @param caption the window caption
+ @param buttonYes the text of the "Yes" button
+ @param buttonNo the text of the "No button
+ @short Popup a message box.
+ */
+ public static native int messageBox(int progressId, int type, String text, String caption, String buttonYes, String buttonNo);
+ /**
+ Popup a message box. See TDEIO.SlaveBase.
+ This doesn't use DCOP anymore, it shows the dialog in the application's process.
+ Otherwise, other apps would block when trying to communicate with UIServer.
+ @param progressId the progress ID of the job, as returned by newJob()
+ @param type the type of the message box
+ @param text the text to show
+ @param caption the window caption
+ @param buttonYes the text of the "Yes" button
+ @param buttonNo the text of the "No button
+ @param dontAskAgainName A checkbox is added with which further confirmation can be turned off.
+ The string is used to lookup and store the setting in tdeioslaverc.
+ @short Popup a message box.
+ */
+ public static native int messageBox(int progressId, int type, String text, String caption, String buttonYes, String buttonNo, String dontAskAgainName);
+ public Observer() {
+ super((Class) null);
+ newObserver();
+ }
+ private native void newObserver();
+ /**
+ Returns the object id of the DCOPObject.
+ @return the object's id
+
+ @short Returns the object id of the DCOPObject.
+ */
+ public native String objId();
+ /**
+ Renames a dcop object, if no other with the same name exists
+ Use with care, all dcop signals are disconnected
+ @param objId the new object id
+ @short Renames a dcop object, if no other with the same name exists Use with care, all dcop signals are disconnected
+ */
+ public native boolean setObjId(String objId);
+ /**
+ Dispatches a message.
+ Usually you want to use an IDL
+ compiler to automatically generate an implementation for
+ this function.
+ If this function returns false, then processDynamic()
+ is called.
+ Note to implementators: remember to call the baseclasses
+ implementation. It handles the functions "functions()" and
+ "interfaces()" which return the lists of supported functions
+ and interfaces, respectively.
+ @param fun is the normalized function signature.
+ Such a signature usually looks like
+ foobar(String,int). The return type,
+ qualifiers like "const" etc. are not part of
+ the signature.
+ @param data the received data
+ @param replyType write the reply type in this string
+ @param replyData write the reply data in this array
+ @return true if successful, false otherwise. The default implementation
+ returns false for all <code>fun</code> except "functions()" and
+ "interfaces()".
+
+ @short Dispatches a message.
+ @see DCOPClient#normalizeFunctionSignature
+ @see #functions
+ @see DCOPClient#process
+ */
+ public native boolean process(String fun, byte[] data, StringBuffer replyType, byte[] replyData);
+ /**
+ This function is of interest when you used an IDL compiler
+ to generate the implementation for process() but
+ you still want to dispatch some functions dynamically.
+ Dynamically means that methods may appear and vanish
+ during runtime.
+ @param fun is the normalized function signature.
+ Such a signature usually looks like
+ foobar(String,int). The return type,
+ qualifiers like "const" etc. are not part of
+ the signature.
+ @param data the received data
+ @param replyType write the reply type in this string
+ @param replyData write the reply data in this array
+ @return true if successful, false otherwise. The default implementation
+ returns always false.
+
+ @short This function is of interest when you used an IDL compiler to generate the implementation for process() but you still want to dispatch some functions dynamically.
+ @see #process
+ @see DCOPClient#normalizeFunctionSignature
+ @see #functions
+ @see DCOPClient#process
+ */
+ public native boolean processDynamic(String fun, byte[] data, StringBuffer replyType, byte[] replyData);
+ /**
+ This function is of interest when you used an IDL compiler
+ to generate the implementation for functions() but
+ you still want to list some functions dynamically.
+ Dynamically means that the methods may appear and vanish
+ during runtime.
+ @return A list of the additional functions, default is an empty list.
+
+ @short This function is of interest when you used an IDL compiler to generate the implementation for functions() but you still want to list some functions dynamically.
+ @see #functions
+ */
+ public native ArrayList functionsDynamic();
+ /**
+ This function is of interest when you used an IDL compiler
+ to generate the implementation for interfaces() but
+ you still want to list some interfaces dynamically.
+ Dynamically means that they may appear and vanish
+ during runtime.
+ @return A list of the additional interfaces, default is an empty list.
+
+ @short This function is of interest when you used an IDL compiler to generate the implementation for interfaces() but you still want to list some interfaces dynamically.
+ @see #interfaces
+ */
+ public native ArrayList interfacesDynamic();
+ /**
+ Returns the names of the interfaces, specific ones last. The
+ functions gets reimplemented by the IDL compiler. If you don't
+ use the IDL compiler, consider implementing this function
+ manually if you want your object to be easily explorable.
+ @return a list of interfaces
+
+ @short Returns the names of the interfaces, specific ones last.
+ @see #functions
+ */
+ public native ArrayList interfaces();
+ /**
+ Returns the list of functions understood by the object. It gets
+ reimplemented by the IDL compiler. If you don't use the IDL
+ compiler, consider implementing this function manually if you
+ want your object to be easily scriptable.
+ Rationale: functions() allows an interpreter to do client-side
+ type-casting properly.
+ Note to implementators: remember to call the baseclasses
+ implementation.
+ @return a list of functions
+
+ @short Returns the list of functions understood by the object.
+ @see #interfaces
+ @see #process
+ @see #processDynamic
+ @see DCOPClient#normalizeFunctionSignature
+ */
+ public native ArrayList functions();
+ /**
+ Emit <code>signal</code> as DCOP signal from this object with <code>data</code> as
+ arguments
+ @param signal the signal to emit
+ @param data the data to send
+ @short Emit <code>signal</code> as DCOP signal from this object with <code>data</code> as arguments
+ */
+ public native void emitDCOPSignal(String signal, byte[] data);
+ /**
+ Connects to a DCOP signal.
+ @param sender the name of the client that emits the signal. When empty
+ the signal will be passed from any client.
+ @param senderObj the name of the sending object that emits the signal.
+ @param signal the name of the signal. The arguments should match with slot.
+ @param slot The name of the slot to call. Its arguments should match with signal.
+ @param Volatile If true, the connection will not be reestablished when
+ <code>sender</code> unregisters and reregisters with DCOP. In this case the <code>sender</code>
+ must be registered when the connection is made.
+ If false, the connection will be reestablished when <code>sender</code> reregisters.
+ In this case the connection can be made even if <code>sender</code> is not registered
+ at that time.
+
+ <li>
+ <code>Volatile</code> is true and <code>sender</code> does not exist.
+ </li>
+
+ <li>
+ <code>signal</code> and <code>slot</code> do not have matching arguments.
+
+ </li> @return false if a connection could not be established.
+ This will be the case when
+
+ @short Connects to a DCOP signal.
+ */
+ public native boolean connectDCOPSignal(String sender, String senderObj, String signal, String slot, boolean Volatile);
+ /**
+ Disconnects a DCOP signal.
+ A special case is when both <code>sender</code> & <code>signal</code> are empty. In this
+ case all connections related to this object in the current client
+ are disconnected. (Both connections from as well as to this object!)
+ @param sender the name of the client that emits the signal.
+ @param senderObj the name of the object that emits the signal.
+ If empty all objects will be disconnected.
+ @param signal the name of the signal. The arguments should match with slot.
+ If empty all objects will be disconnected.
+ @param slot The name of the slot the signal is connected to.
+ If empty all slots will be disconnected.
+ @return false if no connection(s) where removed.
+
+ @short Disconnects a DCOP signal.
+ */
+ public native boolean disconnectDCOPSignal(String sender, String senderObj, String signal, String slot);
+ /**
+ Returns the DCOPClient responsible for making the call.
+ Only call this function while you are handling a DCOP call.
+ @return the DCOPClient responsible for making the call.
+ This information is only guaranteed to be correct when
+ entering your DCOP function.
+
+ @short Returns the DCOPClient responsible for making the call.
+ */
+ public native DCOPClient callingDcopClient();
+ /**
+ @short
+ */
+ public native void setCallingDcopClient(DCOPClient arg1);
+ /**
+ Checks whether an object with the given id is known in this process.
+ DCOPObjectProxy
+ @return true if an object with the questionable <code>objId</code> is
+ known in this process. This query does not ask proxies.
+
+ @short Checks whether an object with the given id is known in this process.
+ */
+ public static native boolean hasObject(String objId);
+ /**
+ Try to find a dcop object with the given id.
+ This function does not query the DCOPObjectProxy.
+ @param objId the object id to search
+ @return the DCOPObject for the id <code>objId.</code>
+
+ @short Try to find a dcop object with the given id.
+ */
+ public static native DCOPObjectInterface find(String objId);
+ /**
+ Tries to find an object using a partial object id.
+ This function is used for multicasting a DCOP message to
+ several objects inside a single process.
+ @param partialId the partial object id to search for
+ @return a list of DCOPObjects beginning with the string
+ contained in <code>partialId.</code>
+
+ @short Tries to find an object using a partial object id.
+ */
+ // TQPtrList<DCOPObject> match(const TQCString& arg1); >>>> NOT CONVERTED
+ /**
+ Creates an object id for the TQObject <code>obj.</code> This is done
+ using the TQObject.name() function.
+ @param obj the object whose name will be used
+ @return the created object id
+
+ @short Creates an object id for the TQObject <code>obj.</code>
+ */
+ public static native String objectName(TQObject arg1);
+}