Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
suliangchun
dbeaver
提交
22cd42d3
D
dbeaver
项目概览
suliangchun
/
dbeaver
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dbeaver
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
22cd42d3
编写于
5月 05, 2018
作者:
S
serge-rider
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Debug core - launch config and shortcut
上级
bee6d449
变更
18
隐藏空白更改
内联
并排
Showing
18 changed file
with
237 addition
and
63 deletion
+237
-63
plugins/org.jkiss.dbeaver.debug.core/src/org/jkiss/dbeaver/debug/DBGDebugObject.java
...ebug.core/src/org/jkiss/dbeaver/debug/DBGDebugObject.java
+27
-0
plugins/org.jkiss.dbeaver.debug.ui/OSGI-INF/l10n/bundle.properties
...rg.jkiss.dbeaver.debug.ui/OSGI-INF/l10n/bundle.properties
+5
-0
plugins/org.jkiss.dbeaver.debug.ui/plugin.xml
plugins/org.jkiss.dbeaver.debug.ui/plugin.xml
+36
-0
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/DatabaseDebugConfigurationTab.java
...jkiss/dbeaver/debug/ui/DatabaseDebugConfigurationTab.java
+3
-6
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/DatabaseLaunchContributionItem.java
...kiss/dbeaver/debug/ui/DatabaseLaunchContributionItem.java
+1
-1
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/DatabaseLaunchShortcut.java
...rc/org/jkiss/dbeaver/debug/ui/DatabaseLaunchShortcut.java
+2
-6
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/details/DatabaseDetailPaneFactory.java
...s/dbeaver/debug/ui/details/DatabaseDetailPaneFactory.java
+1
-1
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/details/DatabaseStandardBreakpointPane.java
...aver/debug/ui/details/DatabaseStandardBreakpointPane.java
+1
-1
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/internal/DatabaseDebugLaunchShortcut.java
...beaver/debug/ui/internal/DatabaseDebugLaunchShortcut.java
+47
-0
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/internal/DebugConfigurationPanelDescriptor.java
.../debug/ui/internal/DebugConfigurationPanelDescriptor.java
+1
-1
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/internal/DebugConfigurationPanelRegistry.java
...er/debug/ui/internal/DebugConfigurationPanelRegistry.java
+1
-1
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/internal/DebugUIInternals.java
...org/jkiss/dbeaver/debug/ui/internal/DebugUIInternals.java
+1
-1
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/internal/DebugUIMessages.java
.../org/jkiss/dbeaver/debug/ui/internal/DebugUIMessages.java
+2
-2
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/internal/DebugUIMessages.properties
...kiss/dbeaver/debug/ui/internal/DebugUIMessages.properties
+0
-0
plugins/org.jkiss.dbeaver.ext.postgresql.debug.ui/OSGI-INF/l10n/bundle.properties
...r.ext.postgresql.debug.ui/OSGI-INF/l10n/bundle.properties
+0
-9
plugins/org.jkiss.dbeaver.ext.postgresql.debug.ui/plugin.xml
plugins/org.jkiss.dbeaver.ext.postgresql.debug.ui/plugin.xml
+46
-33
plugins/org.jkiss.dbeaver.ext.postgresql.debug.ui/src/org/jkiss/dbeaver/ext/postgresql/debug/ui/internal/PostgreDebugObjectAdapterFactory.java
...l/debug/ui/internal/PostgreDebugObjectAdapterFactory.java
+60
-0
plugins/org.jkiss.dbeaver.ext.postgresql/META-INF/MANIFEST.MF
...ins/org.jkiss.dbeaver.ext.postgresql/META-INF/MANIFEST.MF
+3
-1
未找到文件。
plugins/org.jkiss.dbeaver.debug.core/src/org/jkiss/dbeaver/debug/DBGDebugObject.java
0 → 100644
浏览文件 @
22cd42d3
/*
* DBeaver - Universal Database Manager
* Copyright (C) 2010-2018 Serge Rider (serge@jkiss.org)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
org.jkiss.dbeaver.debug
;
import
org.jkiss.dbeaver.model.DBPObject
;
/**
* Object which can be debugged
*/
public
interface
DBGDebugObject
extends
DBPObject
{
}
plugins/org.jkiss.dbeaver.debug.ui/OSGI-INF/l10n/bundle.properties
浏览文件 @
22cd42d3
...
...
@@ -24,3 +24,8 @@ command.ToggleBreakpoint.label = Toggle Breakpoint
launchConfigurationTabGroup.description
=
Settings of database debug launch
launchConfigurationTabGroup.launchMode.description
=
Create a configuration to debug database code
launchGroups.launchGroup.label
=
Database Debug
launchGroups.launchGroup.title
=
Select or configure database object debugger
launchShortcuts.shortcut.label
=
Database Debug
launchShortcuts.shortcut.description
=
Database object debugger
plugins/org.jkiss.dbeaver.debug.ui/plugin.xml
浏览文件 @
22cd42d3
...
...
@@ -39,6 +39,41 @@
</launchConfigurationTabGroup>
</extension>
<extension
point=
"org.eclipse.debug.ui.launchGroups"
>
<launchGroup
bannerImage=
"platform:/plugin/org.jkiss.dbeaver.core/$nl$/icons/database.png"
id=
"org.jkiss.dbeaver.debug.launchGroup"
image=
"platform:/plugin/org.jkiss.dbeaver.core/$nl$/icons/database.png"
label=
"%launchGroups.launchGroup.label"
mode=
"debug"
title=
"%launchGroups.launchGroup.title"
>
</launchGroup>
</extension>
<extension
point=
"org.eclipse.debug.ui.launchShortcuts"
>
<shortcut
id=
"org.jkiss.dbeaver.debug.ui.shortcut"
label=
"%launchShortcuts.shortcut.label"
description=
"%launchShortcuts.shortcut.description"
class=
"org.jkiss.dbeaver.debug.ui.internal.DatabaseDebugLaunchShortcut"
icon=
"platform:/plugin/org.jkiss.dbeaver.core/$nl$/icons/database.png"
modes=
"debug"
>
<configurationType
id=
"org.jkiss.dbeaver.debug.ui.configuration"
/>
<contextualLaunch>
<contextLabel
label=
"%launchShortcuts.shortcut.label"
mode=
"debug"
>
</contextLabel>
<enablement>
<with
variable=
"selection"
>
<count
value=
"1"
/>
<iterate
ifEmpty=
"false"
operator=
"and"
>
<adapt
type=
"org.jkiss.dbeaver.debug.DBGDebugObject"
/>
</iterate>
</with>
</enablement>
</contextualLaunch>
</shortcut>
</extension>
<extension
point=
"org.eclipse.core.runtime.adapters"
>
<factory
adaptableType=
"org.jkiss.dbeaver.ui.editors.entity.EntityEditor"
class=
"org.jkiss.dbeaver.debug.ui.actions.DebugActionAdapterFactory"
>
...
...
@@ -86,6 +121,7 @@
style=
"push"
/>
</menuContribution>
</extension>
<extension
point=
"org.eclipse.ui.commands"
>
<category
description=
"Debug Procedure commands"
id=
"org.jkiss.dbeaver.debug.ui.commands.category.procedure"
name=
"Debug Procedure"
/>
...
...
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/DatabaseDebugConfigurationTab.java
浏览文件 @
22cd42d3
...
...
@@ -33,17 +33,14 @@ import org.eclipse.swt.widgets.*;
import
org.eclipse.ui.PlatformUI
;
import
org.jkiss.dbeaver.DBException
;
import
org.jkiss.dbeaver.debug.DBGConstants
;
import
org.jkiss.dbeaver.debug.internal.DebugConfigurationPanelDescriptor
;
import
org.jkiss.dbeaver.debug.internal.DebugConfigurationPanelRegistry
;
import
org.jkiss.dbeaver.debug.
internal.ui
.DebugUIMessages
;
import
org.jkiss.dbeaver.debug.
ui.
internal.DebugConfigurationPanelDescriptor
;
import
org.jkiss.dbeaver.debug.
ui.
internal.DebugConfigurationPanelRegistry
;
import
org.jkiss.dbeaver.debug.
ui.internal
.DebugUIMessages
;
import
org.jkiss.dbeaver.model.DBIcon
;
import
org.jkiss.dbeaver.model.DBPDataSourceContainer
;
import
org.jkiss.dbeaver.model.DBPImage
;
import
org.jkiss.dbeaver.model.runtime.DBRRunnableContext
;
import
org.jkiss.dbeaver.registry.DataSourceDescriptor
;
import
org.jkiss.dbeaver.registry.DataSourceProviderRegistry
;
import
org.jkiss.dbeaver.registry.DataSourceRegistry
;
import
org.jkiss.dbeaver.registry.driver.DriverDescriptor
;
import
org.jkiss.dbeaver.runtime.RunnableContextDelegate
;
import
org.jkiss.dbeaver.runtime.ui.DBUserInterface
;
import
org.jkiss.dbeaver.ui.DBeaverIcons
;
...
...
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/DatabaseLaunchContributionItem.java
浏览文件 @
22cd42d3
...
...
@@ -44,7 +44,7 @@ import org.eclipse.ui.IEditorPart;
import
org.eclipse.ui.IWorkbenchPage
;
import
org.eclipse.ui.IWorkbenchWindow
;
import
org.eclipse.ui.PlatformUI
;
import
org.jkiss.dbeaver.debug.
internal.ui
.DebugUIInternals
;
import
org.jkiss.dbeaver.debug.
ui.internal
.DebugUIInternals
;
import
org.jkiss.dbeaver.model.struct.DBSObject
;
public
class
DatabaseLaunchContributionItem
extends
ContributionItem
{
...
...
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/DatabaseLaunchShortcut.java
浏览文件 @
22cd42d3
...
...
@@ -43,7 +43,7 @@ import org.eclipse.ui.model.WorkbenchLabelProvider;
import
org.jkiss.dbeaver.Log
;
import
org.jkiss.dbeaver.debug.DBGConstants
;
import
org.jkiss.dbeaver.debug.core.DebugCore
;
import
org.jkiss.dbeaver.debug.
internal.ui
.DebugUIMessages
;
import
org.jkiss.dbeaver.debug.
ui.internal
.DebugUIMessages
;
import
org.jkiss.dbeaver.model.struct.DBSObject
;
import
org.jkiss.dbeaver.runtime.ui.DBUserInterface
;
import
org.jkiss.utils.CommonUtils
;
...
...
@@ -237,11 +237,7 @@ public abstract class DatabaseLaunchShortcut implements ILaunchShortcut2 {
try
{
String
dsId
=
config
.
getAttribute
(
DBGConstants
.
ATTR_DATASOURCE_ID
,
(
String
)
null
);
if
(!
CommonUtils
.
equalObjects
(
dsId
,
launchable
.
getDataSource
().
getContainer
().
getId
()))
{
return
false
;
}
return
true
;
return
CommonUtils
.
equalObjects
(
dsId
,
launchable
.
getDataSource
().
getContainer
().
getId
());
}
catch
(
CoreException
e
)
{
return
false
;
}
...
...
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/details/DatabaseDetailPaneFactory.java
浏览文件 @
22cd42d3
...
...
@@ -28,7 +28,7 @@ import org.eclipse.debug.ui.IDetailPane;
import
org.eclipse.debug.ui.IDetailPaneFactory
;
import
org.eclipse.jface.viewers.IStructuredSelection
;
import
org.jkiss.dbeaver.debug.DBGConstants
;
import
org.jkiss.dbeaver.debug.
internal.ui
.DebugUIMessages
;
import
org.jkiss.dbeaver.debug.
ui.internal
.DebugUIMessages
;
public
class
DatabaseDetailPaneFactory
implements
IDetailPaneFactory
{
...
...
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/details/DatabaseStandardBreakpointPane.java
浏览文件 @
22cd42d3
...
...
@@ -19,7 +19,7 @@
package
org.jkiss.dbeaver.debug.ui.details
;
import
org.eclipse.swt.widgets.Composite
;
import
org.jkiss.dbeaver.debug.
internal.ui
.DebugUIMessages
;
import
org.jkiss.dbeaver.debug.
ui.internal
.DebugUIMessages
;
import
org.jkiss.dbeaver.debug.ui.DebugUI
;
public
class
DatabaseStandardBreakpointPane
extends
DatabaseDebugDetailPane
<
DatabaseBreakpointEditor
>
{
...
...
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/ui/internal/DatabaseDebugLaunchShortcut.java
0 → 100644
浏览文件 @
22cd42d3
/*
* DBeaver - Universal Database Manager
* Copyright (C) 2010-2018 Serge Rider (serge@jkiss.org)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
org.jkiss.dbeaver.debug.ui.internal
;
import
org.eclipse.core.runtime.CoreException
;
import
org.eclipse.debug.core.*
;
import
org.jkiss.dbeaver.debug.ui.DatabaseLaunchShortcut
;
import
org.jkiss.dbeaver.model.struct.DBSObject
;
import
java.util.Map
;
public
class
DatabaseDebugLaunchShortcut
extends
DatabaseLaunchShortcut
{
private
static
final
String
CONFIG_TYPE
=
"org.jkiss.dbeaver.debug.launchConfiguration"
;
public
DatabaseDebugLaunchShortcut
()
{
super
(
CONFIG_TYPE
,
"Database Debug"
);
}
@Override
protected
ILaunchConfiguration
createConfiguration
(
DBSObject
launchable
)
throws
CoreException
{
ILaunchManager
manager
=
DebugPlugin
.
getDefault
().
getLaunchManager
();
ILaunchConfigurationType
type
=
manager
.
getLaunchConfigurationType
(
CONFIG_TYPE
);
ILaunchConfigurationWorkingCopy
workingCopy
=
type
.
newInstance
(
null
,
"Database debug configuration"
);
return
workingCopy
;
}
@Override
protected
boolean
isCandidate
(
ILaunchConfiguration
config
,
DBSObject
launchable
,
Map
<
String
,
Object
>
databaseContext
)
{
return
super
.
isCandidate
(
config
,
launchable
,
databaseContext
);
}
}
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/internal/DebugConfigurationPanelDescriptor.java
→
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/
ui/
internal/DebugConfigurationPanelDescriptor.java
浏览文件 @
22cd42d3
...
...
@@ -14,7 +14,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
org.jkiss.dbeaver.debug.internal
;
package
org.jkiss.dbeaver.debug.
ui.
internal
;
import
org.eclipse.core.runtime.IConfigurationElement
;
import
org.jkiss.code.NotNull
;
...
...
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/internal/DebugConfigurationPanelRegistry.java
→
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/
ui/
internal/DebugConfigurationPanelRegistry.java
浏览文件 @
22cd42d3
...
...
@@ -14,7 +14,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
org.jkiss.dbeaver.debug.internal
;
package
org.jkiss.dbeaver.debug.
ui.
internal
;
import
org.eclipse.core.runtime.IConfigurationElement
;
import
org.eclipse.core.runtime.IExtensionRegistry
;
...
...
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/
internal/ui
/DebugUIInternals.java
→
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/
ui/internal
/DebugUIInternals.java
浏览文件 @
22cd42d3
...
...
@@ -16,7 +16,7 @@
* limitations under the License.
*/
package
org.jkiss.dbeaver.debug.
internal.ui
;
package
org.jkiss.dbeaver.debug.
ui.internal
;
import
java.util.ArrayList
;
import
java.util.Arrays
;
...
...
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/
internal/ui
/DebugUIMessages.java
→
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/
ui/internal
/DebugUIMessages.java
浏览文件 @
22cd42d3
...
...
@@ -16,13 +16,13 @@
* limitations under the License.
*/
package
org.jkiss.dbeaver.debug.
internal.ui
;
package
org.jkiss.dbeaver.debug.
ui.internal
;
import
org.eclipse.osgi.util.NLS
;
public
class
DebugUIMessages
extends
NLS
{
private
static
final
String
BUNDLE_NAME
=
"org.jkiss.dbeaver.debug.
internal.ui
.DebugUIMessages"
;
//$NON-NLS-1$
private
static
final
String
BUNDLE_NAME
=
"org.jkiss.dbeaver.debug.
ui.internal
.DebugUIMessages"
;
//$NON-NLS-1$
public
static
String
DatabaseStandardBreakpointPane_description
;
public
static
String
DatabaseStandardBreakpointPane_name
;
...
...
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/
internal/ui
/DebugUIMessages.properties
→
plugins/org.jkiss.dbeaver.debug.ui/src/org/jkiss/dbeaver/debug/
ui/internal
/DebugUIMessages.properties
浏览文件 @
22cd42d3
文件已移动
plugins/org.jkiss.dbeaver.ext.postgresql.debug.ui/OSGI-INF/l10n/bundle.properties
浏览文件 @
22cd42d3
...
...
@@ -19,15 +19,6 @@
Bundle-Vendor
=
JKISS
Bundle-Name
=
DBeaver PostgreSQL Debug UI
launchShortcuts.shortcut.pgSQL.global.label
=
PL/pgSQL (Global)
launchShortcuts.shortcut.pgSQL.global.description
=
PL/pgSQL global debug for PostgreSQL procedures
launchShortcuts.shortcut.pgSQL.local.label
=
PL/pgSQL (Local)
launchShortcuts.shortcut.pgSQL.local.description
=
PL/pgSQL local debug for PostgreSQL procedures
launchGroups.launchGroup.pgSQL.label
=
PL/pgSQL Debug
launchGroups.launchGroup.pgSQL.title
=
Select or configure PL/pgSQL procedure to debug
actions.ManageBreakpointRulerAction.label
=
Toggle &Breakpoint
actionSets.actionSet.pgSQL.label
=
PL/pgSQL Debug
...
...
plugins/org.jkiss.dbeaver.ext.postgresql.debug.ui/plugin.xml
浏览文件 @
22cd42d3
...
...
@@ -33,6 +33,7 @@
</panel>
</extension>
<!--
<extension point="org.eclipse.debug.ui.launchShortcuts">
<shortcut
category="org.jkiss.dbeaver.ext.postgresql.debug.ui.pgSQL"
...
...
@@ -82,7 +83,9 @@
</contextualLaunch>
</shortcut>
</extension>
-->
<!--
<extension point="org.eclipse.debug.ui.launchGroups">
<launchGroup
bannerImage="platform:/plugin/org.jkiss.dbeaver.ext.postgresql/$nl$/icons/postgresql_icon.png"
...
...
@@ -94,6 +97,7 @@
title="%launchGroups.launchGroup.pgSQL.title">
</launchGroup>
</extension>
-->
<extension
point=
"org.eclipse.core.runtime.adapters"
>
<factory
adaptableType=
"org.jkiss.dbeaver.ext.postgresql.ui.editors.PostgreSourceViewEditor"
class=
"org.jkiss.dbeaver.debug.ui.actions.DebugActionAdapterFactory"
>
...
...
@@ -102,9 +106,16 @@
<factory
adaptableType=
"org.jkiss.dbeaver.model.DBPDataSourceContainer"
class=
"org.jkiss.dbeaver.ext.postgresql.debug.ui.internal.PostgreDebugUIAdapterFactory"
>
<adapter
type=
"org.jkiss.dbeaver.debug.ui.DBGEditorAdvisor"
/>
</factory>
<factory
adaptableType=
"java.lang.Object"
class=
"org.jkiss.dbeaver.ext.postgresql.debug.ui.internal.PostgreDebugObjectAdapterFactory"
>
<adapter
type=
"org.jkiss.dbeaver.debug.DBGDebugObject"
/>
</factory>
</extension>
<extension
point=
"org.eclipse.ui.editorActions"
>
<!--
Breakpoin toggle contribution.
TODO: move to core debug. Dunno how because we need specific targetID
-->
<editorContribution
id=
"org.jkiss.dbeaver.debug.ui.editorContribution"
targetID=
"postgresql.source.view"
>
<action
actionID=
"RulerDoubleClick"
...
...
@@ -128,39 +139,40 @@
</extension>
-->
<extension
point=
"org.eclipse.ui.actionSets"
>
<actionSet
label=
"%actionSets.actionSet.pgSQL.label"
visible=
"true"
id=
"org.jkiss.dbeaver.ext.postgresql.debug.ui.actionSets.actionSet.pgSQL"
>
<menu
label=
"%actionSets.actionSet.menu.debug.label"
path=
"additions"
id=
"org.eclipse.ui.debug"
>
<separator
name=
"pgSQLGroup"
/>
</menu>
<!--
<action
label="%actionSets.action.pgSQLMenu.label"
style="pulldown"
icon="platform:/plugin/org.jkiss.dbeaver.ext.postgresql/$nl$/icons/postgresql_icon.png"
class="org.jkiss.dbeaver.ext.postgresql.debug.ui.internal.PgSqlMenuDelegate"
menubarPath="org.eclipse.ui.debug/pgSQLGroup"
id="org.jkiss.dbeaver.ext.postgresql.debug.ui.actionSets.action.pgSQLMenu">
</action>
<action
definitionId="org.jkiss.dbeaver.ext.postgresql.debug.ui.commands.command.pgSQLMenuDelegateToolbar"
label="%actionSets.action.pgSQLToolbar.label"
style="pulldown"
icon="platform:/plugin/org.jkiss.dbeaver.ext.postgresql/$nl$/icons/postgresql_icon.png"
tooltip="%actionSets.action.pgSQLToolbar.tooltip"
class="org.jkiss.dbeaver.ext.postgresql.debug.ui.internal.PgSqlMenuDelegate"
toolbarPath="org.eclipse.debug.ui.launchActionSet/debug"
id="org.jkiss.dbeaver.ext.postgresql.debug.ui.actionSets.action.pgSQLToolbar">
</action>
-->
<action
definitionId=
"org.jkiss.dbeaver.ext.postgresql.debug.ui.commands.command.pgSQLConfigurations"
label=
"%actionSets.action.pgSQLConfigurations.label"
class=
"org.jkiss.dbeaver.ext.postgresql.debug.ui.internal.PgSqlOpenLaunchDialogAction"
id=
"org.jkiss.dbeaver.ext.postgresql.debug.ui.actionSets.action.pgSQLConfigurations"
>
</action>
</actionSet>
</extension>
<!--
<extension point="org.eclipse.ui.actionSets">
<actionSet label="%actionSets.actionSet.pgSQL.label" visible="true" id="org.jkiss.dbeaver.ext.postgresql.debug.ui.actionSets.actionSet.pgSQL">
<menu label="%actionSets.actionSet.menu.debug.label" path="additions" id="org.eclipse.ui.debug">
<separator name="pgSQLGroup"/>
</menu>
<action
label="%actionSets.action.pgSQLMenu.label"
style="pulldown"
icon="platform:/plugin/org.jkiss.dbeaver.ext.postgresql/$nl$/icons/postgresql_icon.png"
class="org.jkiss.dbeaver.ext.postgresql.debug.ui.internal.PgSqlMenuDelegate"
menubarPath="org.eclipse.ui.debug/pgSQLGroup"
id="org.jkiss.dbeaver.ext.postgresql.debug.ui.actionSets.action.pgSQLMenu">
</action>
<action
definitionId="org.jkiss.dbeaver.ext.postgresql.debug.ui.commands.command.pgSQLMenuDelegateToolbar"
label="%actionSets.action.pgSQLToolbar.label"
style="pulldown"
icon="platform:/plugin/org.jkiss.dbeaver.ext.postgresql/$nl$/icons/postgresql_icon.png"
tooltip="%actionSets.action.pgSQLToolbar.tooltip"
class="org.jkiss.dbeaver.ext.postgresql.debug.ui.internal.PgSqlMenuDelegate"
toolbarPath="org.eclipse.debug.ui.launchActionSet/debug"
id="org.jkiss.dbeaver.ext.postgresql.debug.ui.actionSets.action.pgSQLToolbar">
</action>
<action
definitionId="org.jkiss.dbeaver.ext.postgresql.debug.ui.commands.command.pgSQLConfigurations"
label="%actionSets.action.pgSQLConfigurations.label"
class="org.jkiss.dbeaver.ext.postgresql.debug.ui.internal.PgSqlOpenLaunchDialogAction"
id="org.jkiss.dbeaver.ext.postgresql.debug.ui.actionSets.action.pgSQLConfigurations">
</action>
</actionSet>
</extension>
<extension point="org.eclipse.ui.commands">
<command
...
...
@@ -176,5 +188,6 @@
id="org.jkiss.dbeaver.ext.postgresql.debug.ui.commands.command.pgSQLConfigurations">
</command>
</extension>
-->
</plugin>
plugins/org.jkiss.dbeaver.ext.postgresql.debug.ui/src/org/jkiss/dbeaver/ext/postgresql/debug/ui/internal/PostgreDebugObjectAdapterFactory.java
0 → 100644
浏览文件 @
22cd42d3
/*
* DBeaver - Universal Database Manager
* Copyright (C) 2010-2018 Serge Rider (serge@jkiss.org)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
org.jkiss.dbeaver.ext.postgresql.debug.ui.internal
;
import
org.eclipse.core.runtime.IAdapterFactory
;
import
org.jkiss.dbeaver.debug.DBGDebugObject
;
import
org.jkiss.dbeaver.ext.postgresql.model.PostgreProcedure
;
import
org.jkiss.dbeaver.ext.postgresql.ui.editors.PostgreSourceViewEditor
;
import
org.jkiss.dbeaver.model.navigator.DBNDatabaseNode
;
import
org.jkiss.dbeaver.ui.editors.IDatabaseEditorInput
;
public
class
PostgreDebugObjectAdapterFactory
implements
IAdapterFactory
{
private
static
final
Class
<?>[]
CLASSES
=
new
Class
[]
{
DBGDebugObject
.
class
};
private
static
final
DBGDebugObject
DEBUG_OBJECT
=
new
DBGDebugObject
()
{
};
@Override
public
<
T
>
T
getAdapter
(
Object
adaptableObject
,
Class
<
T
>
adapterType
)
{
if
(
adapterType
==
DBGDebugObject
.
class
)
{
if
(
adaptableObject
instanceof
PostgreSourceViewEditor
&&
((
PostgreSourceViewEditor
)
adaptableObject
).
getSourceObject
()
instanceof
PostgreProcedure
)
{
return
adapterType
.
cast
(
DEBUG_OBJECT
);
}
if
(
adaptableObject
instanceof
IDatabaseEditorInput
&&
((
IDatabaseEditorInput
)
adaptableObject
).
getDatabaseObject
()
instanceof
PostgreProcedure
)
{
return
adapterType
.
cast
(
DEBUG_OBJECT
);
}
if
(
adaptableObject
instanceof
DBNDatabaseNode
&&
((
DBNDatabaseNode
)
adaptableObject
).
getObject
()
instanceof
PostgreProcedure
)
{
return
adapterType
.
cast
(
DEBUG_OBJECT
);
}
}
return
null
;
}
@Override
public
Class
<?>[]
getAdapterList
()
{
return
CLASSES
;
}
}
plugins/org.jkiss.dbeaver.ext.postgresql/META-INF/MANIFEST.MF
浏览文件 @
22cd42d3
...
...
@@ -27,6 +27,8 @@ Bundle-Vendor: %Bundle-Vendor
Bundle-ClassPath: .
Bundle-Activator: org.jkiss.dbeaver.ext.postgresql.PostgreActivator
Export-Package: org.jkiss.dbeaver.ext.postgresql,
org.jkiss.dbeaver.ext.postgresql.model
org.jkiss.dbeaver.ext.postgresql.model,
org.jkiss.dbeaver.ext.postgresql.ui,
org.jkiss.dbeaver.ext.postgresql.ui.editors
Bundle-Localization: OSGI-INF/l10n/bundle
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录