提交 05a49242 编写于 作者: S serge-rider

dbeaver/dbeaver#342 RSV: extra settings

上级 bf3604f6
......@@ -193,6 +193,8 @@ public interface IResultSetController extends IDataController, DBPContextProvide
void setDataFilter(final DBDDataFilter dataFilter, boolean refreshData);
void setSegmentFetchSize(Integer segmentFetchSize);
/**
* Enable/disable viewer actions. May be used by editors to "lock" RSV actions like navigation, edit, etc.
* Actions will be locked until lockedBy will be disposed
......
......@@ -200,6 +200,8 @@ public class ResultSetViewer extends Viewer
// Mode
private boolean recordMode;
private Integer segmentFetchSize;
private final List<IResultSetListener> listeners = new ArrayList<>();
private final List<ResultSetJobDataRead> dataPumpJobQueue = new ArrayList<>();
......@@ -582,6 +584,11 @@ public class ResultSetViewer extends Viewer
}
}
@Override
public void setSegmentFetchSize(Integer segmentFetchSize) {
this.segmentFetchSize = segmentFetchSize;
}
////////////////////////////////////////////////////////////
// Misc
......@@ -3485,6 +3492,9 @@ public class ResultSetViewer extends Viewer
if (getDataContainer() == null) {
return 0;
}
if (segmentFetchSize != null && segmentFetchSize > 0) {
return segmentFetchSize;
}
return getPreferenceStore().getInt(ModelPreferences.RESULT_SET_MAX_ROWS);
}
......
......@@ -175,6 +175,14 @@ public class SpreadsheetPresentation extends AbstractPresentation implements IRe
this.showOddRows = showOddRows;
}
public boolean isAutoFetchSegments() {
return autoFetchSegments;
}
public void setAutoFetchSegments(boolean autoFetchSegments) {
this.autoFetchSegments = autoFetchSegments;
}
@Nullable
DBPDataSource getDataSource() {
DBSDataContainer dataContainer = controller.getDataContainer();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册