public static object dosearch(RubyModule /*!*/ self, [NotNull] RubyArray /*!*/ arSourcesR, [NotNull] String /*!*/ from, [NotNull] String /*!*/ strParams, [NotNull] bool /*!*/ bSearchSyncChanges, [NotNull] int /*!*/ nProgressStep, String /*!*/ strCallback, String /*!*/ strCallbackParams) { object res = null; try { SyncThread.stopSync(); if (strCallback != null && strCallback.Length > 0) { SyncThread.getSyncEngine().getNotify().setSearchNotification(strCallback, strCallbackParams); } Vector <String> arSources = RhoRuby.makeVectorStringFromArray(arSourcesR); SyncThread.getInstance().addQueueCommand(new SyncThread.SyncSearchCommand(from, strParams, arSources, bSearchSyncChanges, nProgressStep)); res = SyncThread.getInstance().getRetValue(); } catch (Exception ex) { Exception rubyEx = self.Context.CurrentException; if (rubyEx == null) { rubyEx = RubyExceptionData.InitializeException(new RuntimeError(ex.Message.ToString()), ex.Message); } LOG.ERROR("dosearch", ex); throw rubyEx; } return(res); }
public static void set_syncserver(RubyModule /*!*/ self, [NotNull] String /*!*/ syncserver) { try { SyncThread.stopSync(); SyncThread.getSyncEngine().setSyncServer(syncserver); if (syncserver != null && syncserver.length() > 0) { SyncThread.getInstance().start(SyncThread.epLow); if (ClientRegister.getInstance() != null) { ClientRegister.getInstance().startUp(); } } } catch (Exception ex) { Exception rubyEx = self.Context.CurrentException; if (rubyEx == null) { rubyEx = RubyExceptionData.InitializeException(new RuntimeError(ex.Message.ToString()), ex.Message); } LOG.ERROR("set_syncserver", ex); throw rubyEx; } }
public static bool is_syncing(RubyModule /*!*/ self) { try { return(SyncThread.getSyncEngine().isSyncing()); } catch (Exception ex) { LOG.HandleRubyException(ex, RhoRuby.rubyContext.CurrentException, "is_syncing"); return(false); } }
public static void set_syncserver(RubyModule /*!*/ self, [NotNull] String /*!*/ syncserver) { SyncThread.stopSync(); SyncThread.getSyncEngine().setSyncServer(syncserver); if (syncserver != null && syncserver.length() > 0) { SyncThread.getInstance().start(SyncThread.epLow); if (ClientRegister.getInstance() != null) { ClientRegister.getInstance().startUp(); } } }
public static object dosearch(RubyModule /*!*/ self, [NotNull] RubyArray /*!*/ arSourcesR, [NotNull] String /*!*/ from, [NotNull] String /*!*/ strParams, [NotNull] bool /*!*/ bSearchSyncChanges, [NotNull] int /*!*/ nProgressStep, String /*!*/ strCallback, String /*!*/ strCallbackParams) { SyncThread.stopSync(); if (strCallback != null && strCallback.Length > 0) { SyncThread.getSyncEngine().getNotify().setSearchNotification(strCallback, strCallbackParams); } Vector <String> arSources = RhoRuby.makeVectorStringFromArray(arSourcesR); SyncThread.getInstance().addQueueCommand(new SyncThread.SyncSearchCommand(from, strParams, arSources, bSearchSyncChanges, nProgressStep)); return(SyncThread.getInstance().getRetValue()); }
public static void add_objectnotify(RubyModule /*!*/ self, [NotNull] int /*!*/ nSrcID, [NotNull] string /*!*/ strObject) { try { SyncThread.getSyncEngine().getNotify().addObjectNotify(nSrcID, strObject); } catch (Exception ex) { Exception rubyEx = self.Context.CurrentException; if (rubyEx == null) { rubyEx = RubyExceptionData.InitializeException(new RuntimeError(ex.Message.ToString()), ex.Message); } LOG.ERROR("add_objectnotify", ex); throw rubyEx; } }
public static void enable_status_popup(RubyModule /*!*/ self, bool /*!*/ bEnable) { try { SyncThread.getSyncEngine().getNotify().enableStatusPopup(bEnable); } catch (Exception ex) { Exception rubyEx = self.Context.CurrentException; if (rubyEx == null) { rubyEx = RubyExceptionData.InitializeException(new RuntimeError(ex.Message.ToString()), ex.Message); } LOG.ERROR("enable_status_popup", ex); throw rubyEx; } }
public static void clean_objectnotify(RubyModule /*!*/ self) { try { SyncThread.getSyncEngine().getNotify().cleanObjectNotifications(); } catch (Exception ex) { Exception rubyEx = self.Context.CurrentException; if (rubyEx == null) { rubyEx = RubyExceptionData.InitializeException(new RuntimeError(ex.Message.ToString()), ex.Message); } LOG.ERROR("clean_objectnotify", ex); throw rubyEx; } }
public static void set_threaded_mode(RubyModule /*!*/ self, [NotNull] bool /*!*/ bThreadMode) { try { SyncThread.getInstance().setNonThreadedMode(!bThreadMode); SyncThread.getSyncEngine().setNonThreadedMode(!bThreadMode); } catch (Exception ex) { Exception rubyEx = self.Context.CurrentException; if (rubyEx == null) { rubyEx = RubyExceptionData.InitializeException(new RuntimeError(ex.Message.ToString()), ex.Message); } LOG.ERROR("set_threaded_mode", ex); throw rubyEx; } }
public static void set_notification(RubyModule /*!*/ self, [NotNull] int /*!*/ nSrcID, [NotNull] String /*!*/ url, string /*!*/ callback_param) { try { SyncThread.getSyncEngine().getNotify().setSyncNotification(nSrcID, new SyncNotify.SyncNotification(url, callback_param != null ? callback_param : "", nSrcID != -1)); } catch (Exception ex) { Exception rubyEx = self.Context.CurrentException; if (rubyEx == null) { rubyEx = RubyExceptionData.InitializeException(new RuntimeError(ex.Message.ToString()), ex.Message); } LOG.ERROR("set_notification", ex); throw rubyEx; } }
public static void logout(RubyModule /*!*/ self) { try { SyncThread.stopSync(); SyncThread.getSyncEngine().logout_int(); } catch (Exception ex) { Exception rubyEx = self.Context.CurrentException; if (rubyEx == null) { rubyEx = RubyExceptionData.InitializeException(new RuntimeError(ex.Message.ToString()), ex.Message); } LOG.ERROR("logout", ex); throw rubyEx; } }
public static int logged_in(RubyModule /*!*/ self) { int res = 0; try { res = SyncThread.getSyncEngine().isLoggedIn() ? 1 : 0; } catch (Exception ex) { Exception rubyEx = self.Context.CurrentException; if (rubyEx == null) { rubyEx = RubyExceptionData.InitializeException(new RuntimeError(ex.Message.ToString()), ex.Message); } LOG.ERROR("logged_in", ex); throw rubyEx; } return(res); }
public static void logout(RubyModule /*!*/ self) { SyncThread.stopSync(); SyncThread.getSyncEngine().stopSyncByUser(); SyncThread.getSyncEngine().logout(); }
public static void set_threaded_mode(RubyModule /*!*/ self, [NotNull] bool /*!*/ bThreadMode) { SyncThread.getInstance().setNonThreadedMode(!bThreadMode); SyncThread.getSyncEngine().setNonThreadedMode(!bThreadMode); }
public static void enable_status_popup(RubyModule /*!*/ self, bool /*!*/ bEnable) { SyncThread.getSyncEngine().getNotify().enableStatusPopup(bEnable); }
public static void set_notification(RubyModule /*!*/ self, [NotNull] int /*!*/ nSrcID, [NotNull] String /*!*/ url, string /*!*/ callback_param) { SyncThread.getSyncEngine().getNotify().setSyncNotification(nSrcID, new SyncNotify.SyncNotification(url, callback_param != null ? callback_param : "", nSrcID != -1)); }
public static void clean_objectnotify(RubyModule /*!*/ self) { SyncThread.getSyncEngine().getNotify().cleanObjectNotifications(); }
public static int logged_in(RubyModule /*!*/ self) { return(SyncThread.getSyncEngine().isLoggedIn() ? 1 : 0); }
public static void add_objectnotify(RubyModule /*!*/ self, [NotNull] int /*!*/ nSrcID, [NotNull] string /*!*/ strObject) { SyncThread.getSyncEngine().getNotify().addObjectNotify(nSrcID, strObject); }