neil 9 years ago
parent
commit
32d7b1f949
  1. 3
      designer/src/com/fr/design/actions/utils/DeprecatedActionManager.java
  2. 3
      designer/src/com/fr/design/condition/HighLightConditionAttributesPane.java
  3. 2
      designer/src/com/fr/design/condition/PaddingPane.java
  4. 3
      designer/src/com/fr/design/mainframe/ElementCasePane.java
  5. 6
      designer/src/com/fr/design/mainframe/JWorkBook.java
  6. 2
      designer/src/com/fr/design/mainframe/cell/CellElementEditPane.java
  7. 13
      designer/src/com/fr/design/module/DesignerModule.java
  8. 3
      designer/src/com/fr/design/present/PresentPane.java
  9. 5
      designer/src/com/fr/design/report/ReportExportAttrPane.java
  10. 2
      designer/src/com/fr/design/report/VerifierListPane.java
  11. 4
      designer/src/com/fr/design/webattr/EditToolBar.java
  12. 2
      designer/src/com/fr/design/widget/WidgetPane.java
  13. 15
      designer/src/com/fr/design/write/submit/SubmitVisitorListPane.java
  14. 920
      designer_base/src/com/fr/design/ExtraDesignClassManager.java
  15. 4
      designer_base/src/com/fr/design/data/datapane/TableDataCreatorProducer.java
  16. 2
      designer_base/src/com/fr/design/data/datapane/TableDataTreePane.java
  17. 14
      designer_base/src/com/fr/design/data/datapane/connect/ConnectionListPane.java
  18. 2
      designer_base/src/com/fr/design/data/tabledata/tabledatapane/TableDataManagerPane.java
  19. 4
      designer_base/src/com/fr/design/data/tabledata/wrapper/TableDataFactory.java
  20. 2
      designer_base/src/com/fr/design/formula/FormulaFactory.java
  21. 3
      designer_base/src/com/fr/design/fun/BackgroundQuickUIProvider.java
  22. 5
      designer_base/src/com/fr/design/fun/BackgroundUIProvider.java
  23. 4
      designer_base/src/com/fr/design/fun/CellAttributeProvider.java
  24. 2
      designer_base/src/com/fr/design/fun/CellWidgetOptionProvider.java
  25. 4
      designer_base/src/com/fr/design/fun/ConnectionProvider.java
  26. 4
      designer_base/src/com/fr/design/fun/DesignerEnvProcessor.java
  27. 4
      designer_base/src/com/fr/design/fun/ElementUIProvider.java
  28. 4
      designer_base/src/com/fr/design/fun/ExportAttrTabProvider.java
  29. 4
      designer_base/src/com/fr/design/fun/ExportToolBarProvider.java
  30. 4
      designer_base/src/com/fr/design/fun/FormElementCaseEditorProcessor.java
  31. 4
      designer_base/src/com/fr/design/fun/FormWidgetOptionProvider.java
  32. 4
      designer_base/src/com/fr/design/fun/GlobalListenerProvider.java
  33. 3
      designer_base/src/com/fr/design/fun/HighlightProvider.java
  34. 3
      designer_base/src/com/fr/design/fun/HyperlinkProvider.java
  35. 4
      designer_base/src/com/fr/design/fun/IndentationUnitProcessor.java
  36. 4
      designer_base/src/com/fr/design/fun/JavaScriptActionProvider.java
  37. 4
      designer_base/src/com/fr/design/fun/MenuHandler.java
  38. 4
      designer_base/src/com/fr/design/fun/ParameterWidgetOptionProvider.java
  39. 4
      designer_base/src/com/fr/design/fun/PresentKindProvider.java
  40. 4
      designer_base/src/com/fr/design/fun/PreviewProvider.java
  41. 4
      designer_base/src/com/fr/design/fun/SubmitProvider.java
  42. 5
      designer_base/src/com/fr/design/fun/TableDataDefineProvider.java
  43. 4
      designer_base/src/com/fr/design/fun/TableDataPaneProcessor.java
  44. 4
      designer_base/src/com/fr/design/fun/TitlePlaceProcessor.java
  45. 4
      designer_base/src/com/fr/design/fun/ToolbarItemProvider.java
  46. 4
      designer_base/src/com/fr/design/fun/UIFormulaProcessor.java
  47. 5
      designer_base/src/com/fr/design/fun/VerifyDefineProvider.java
  48. 4
      designer_base/src/com/fr/design/fun/WidgetDesignHandler.java
  49. 4
      designer_base/src/com/fr/design/fun/WidgetPropertyUIProvider.java
  50. 2
      designer_base/src/com/fr/design/fun/impl/AbstractBackgroundQuickUIProvider.java
  51. 2
      designer_base/src/com/fr/design/fun/impl/AbstractBackgroundUIProvider.java
  52. 2
      designer_base/src/com/fr/design/fun/impl/AbstractCellAttributeProvider.java
  53. 10
      designer_base/src/com/fr/design/fun/impl/AbstractCellWidgetOptionProvider.java
  54. 10
      designer_base/src/com/fr/design/fun/impl/AbstractConnectionProvider.java
  55. 2
      designer_base/src/com/fr/design/fun/impl/AbstractDesignerEnvProcessor.java
  56. 2
      designer_base/src/com/fr/design/fun/impl/AbstractElementUIProvider.java
  57. 2
      designer_base/src/com/fr/design/fun/impl/AbstractExportAttrTabProvider.java
  58. 2
      designer_base/src/com/fr/design/fun/impl/AbstractFormElementCaseEditorProcessor.java
  59. 9
      designer_base/src/com/fr/design/fun/impl/AbstractFormWidgetOptionProvider.java
  60. 10
      designer_base/src/com/fr/design/fun/impl/AbstractGlobalListenerProvider.java
  61. 9
      designer_base/src/com/fr/design/fun/impl/AbstractHighlightProvider.java
  62. 9
      designer_base/src/com/fr/design/fun/impl/AbstractHyperlinkProvider.java
  63. 2
      designer_base/src/com/fr/design/fun/impl/AbstractIndentationUnitProcessor.java
  64. 9
      designer_base/src/com/fr/design/fun/impl/AbstractJavaScriptActionProvider.java
  65. 2
      designer_base/src/com/fr/design/fun/impl/AbstractMenuHandler.java
  66. 9
      designer_base/src/com/fr/design/fun/impl/AbstractParameterWidgetOptionProvider.java
  67. 10
      designer_base/src/com/fr/design/fun/impl/AbstractPresentKindProvider.java
  68. 9
      designer_base/src/com/fr/design/fun/impl/AbstractPreviewProvider.java
  69. 29
      designer_base/src/com/fr/design/fun/impl/AbstractServerTableDataDefineProvider.java
  70. 10
      designer_base/src/com/fr/design/fun/impl/AbstractSubmitProvider.java
  71. 2
      designer_base/src/com/fr/design/fun/impl/AbstractTDPaneProcessor.java
  72. 25
      designer_base/src/com/fr/design/fun/impl/AbstractTableDataDefineProvider.java
  73. 2
      designer_base/src/com/fr/design/fun/impl/AbstractTitleProcessor.java
  74. 9
      designer_base/src/com/fr/design/fun/impl/AbstractToolbarItem.java
  75. 2
      designer_base/src/com/fr/design/fun/impl/AbstractUIFormulaProcessor.java
  76. 2
      designer_base/src/com/fr/design/fun/impl/AbstractVerifyDefineProvider.java
  77. 7
      designer_base/src/com/fr/design/fun/impl/AbstractWidgetDesignHandler.java
  78. 2
      designer_base/src/com/fr/design/fun/impl/AbstractWidgetPropertyUIProvider.java
  79. 5
      designer_base/src/com/fr/design/gui/frpane/HyperlinkGroupPane.java
  80. 2
      designer_base/src/com/fr/design/gui/style/AlignmentPane.java
  81. 3
      designer_base/src/com/fr/design/gui/style/BackgroundPane.java
  82. 3
      designer_base/src/com/fr/design/javascript/JavaScriptActionPane.java
  83. 15
      designer_base/src/com/fr/design/mainframe/AbstractAppProvider.java
  84. 5
      designer_base/src/com/fr/design/mainframe/App.java
  85. 2
      designer_base/src/com/fr/design/mainframe/DesignerFrame.java
  86. 3
      designer_base/src/com/fr/design/mainframe/DesignerFrameFileDealerPane.java
  87. 17
      designer_base/src/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java
  88. 16
      designer_base/src/com/fr/design/menu/ShortCut.java
  89. 5
      designer_base/src/com/fr/design/module/DesignModule.java
  90. 4
      designer_base/src/com/fr/design/style/background/BackgroundFactory.java
  91. 2
      designer_base/src/com/fr/design/utils/DesignUtils.java
  92. 2
      designer_base/src/com/fr/env/RemoteEnv.java
  93. 9
      designer_base/src/com/fr/start/BaseDesigner.java
  94. 2
      designer_form/src/com/fr/design/designer/creator/XElementCase.java
  95. 5
      designer_form/src/com/fr/design/mainframe/WidgetPropertyPane.java

3
designer/src/com/fr/design/actions/utils/DeprecatedActionManager.java

@ -34,6 +34,7 @@ import com.fr.report.cell.cellattr.BarcodePresent;
import com.fr.report.cell.cellattr.CurrencyLinePresent;
import javax.swing.*;
import java.util.Set;
/**
* peter: 这个方法只是临时放在这边的, 等插件系统全部完善后,立刻删除.
@ -131,7 +132,7 @@ public class DeprecatedActionManager {
presentMenu.addShortCut(barcodeAction);
presentMenu.addShortCut(currencyLineAction);
PresentKindProvider[] providers = ExtraDesignClassManager.getInstance().getPresentKindProviders();
Set<PresentKindProvider> providers = ExtraDesignClassManager.getInstance().getArray(PresentKindProvider.MARK_STRING);
for (PresentKindProvider provider : providers) {
NewPresentAction action = new NewPresentAction(ePane, provider.title(), provider.kindOfPresent().getName());
action.setMnemonic(provider.mnemonic());

3
designer/src/com/fr/design/condition/HighLightConditionAttributesPane.java

@ -9,6 +9,7 @@ import com.fr.report.cell.cellattr.highlight.*;
import javax.swing.*;
import java.awt.*;
import java.util.Iterator;
import java.util.Set;
public class HighLightConditionAttributesPane extends ConditionAttributesPane<DefaultHighlight> {
@ -48,7 +49,7 @@ public class HighLightConditionAttributesPane extends ConditionAttributesPane<De
classPaneMap.put(BorderHighlightAction.class, new BorderHighlightPane(this));
classPaneMap.put(WidgetHighlightAction.class, new WidgetHighlightPane(this));
classPaneMap.put(ValueHighlightAction.class, new NewRealValuePane(this));
HighlightProvider[] providers = ExtraDesignClassManager.getInstance().getHighlightProviders();
Set<HighlightProvider> providers = ExtraDesignClassManager.getInstance().getArray(HighlightProvider.MARK_STRING);
for (HighlightProvider provider : providers) {
classPaneMap.put(provider.classForHighlightAction(), provider.appearanceForCondition(this));
}

2
designer/src/com/fr/design/condition/PaddingPane.java

@ -46,7 +46,7 @@ public class PaddingPane extends ConditionAttrSingleConditionPane<HighlightActio
this.paddingLeftSpinner.setValue(new Integer(0));
this.paddingRightSpinner.setValue(new Integer(0));
this.indentationUnitProcessor = ExtraDesignClassManager.getInstance().getIndentationUnitEditor();
this.indentationUnitProcessor = ExtraDesignClassManager.getInstance().getSingle(IndentationUnitProcessor.MARK_STRING);
if (null == this.indentationUnitProcessor) {
this.indentationUnitProcessor = new DefaultIndentationUnitProcessor();
}

3
designer/src/com/fr/design/mainframe/ElementCasePane.java

@ -18,6 +18,7 @@ import java.awt.event.KeyEvent;
import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;
import java.lang.reflect.Constructor;
import java.util.Set;
import javax.swing.AbstractAction;
import javax.swing.ActionMap;
@ -384,7 +385,7 @@ public abstract class ElementCasePane<T extends TemplateElementCase> extends Tar
}
private void addExtraCellEditor(Grid grid) {
ElementUIProvider[] providers = ExtraDesignClassManager.getInstance().getElementUIProviders();
Set<ElementUIProvider> providers = ExtraDesignClassManager.getInstance().getArray(ElementUIProvider.MARK_STRING);
for (ElementUIProvider provider : providers) {
CellEditor editor = null;
Class<?> clazz = provider.targetCellEditorClass();

6
designer/src/com/fr/design/mainframe/JWorkBook.java

@ -69,6 +69,7 @@ import java.io.FileOutputStream;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.Set;
/**
* JWorkBook used to edit WorkBook.
@ -660,9 +661,10 @@ public class JWorkBook extends JTemplate<WorkBook, WorkBookUndoState> {
*
*/
public PreviewProvider[] supportPreview() {
return (PreviewProvider[])ArrayUtils.addAll(new PreviewProvider[]{
Set<PreviewProvider> set = ExtraDesignClassManager.getInstance().getArray(PreviewProvider.MARK_STRING);
return ArrayUtils.addAll(new PreviewProvider[]{
new PagePreview(), new WritePreview(), new ViewPreview()
}, ExtraDesignClassManager.getInstance().getPreviewProviders());
}, set.toArray(new PreviewProvider[set.size()]));
}
/**

2
designer/src/com/fr/design/mainframe/cell/CellElementEditPane.java

@ -180,7 +180,7 @@ public class CellElementEditPane extends BasicPane {
paneList.add(new CellPresentPane());
paneList.add(new CellOtherSetPane());
cellAttributeProvider = ExtraDesignClassManager.getInstance().getCelllAttributeProvider();
cellAttributeProvider = ExtraDesignClassManager.getInstance().getSingle(CellAttributeProvider.MARK_STRING);
if (cellAttributeProvider != null){
paneList.add((AbstractCellAttrPane) cellAttributeProvider.createCellAttributePane());
}

13
designer/src/com/fr/design/module/DesignerModule.java

@ -71,6 +71,7 @@ import java.awt.event.ActionListener;
import java.awt.image.BufferedImage;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.Set;
public class DesignerModule extends DesignModule {
@ -120,7 +121,7 @@ public class DesignerModule extends DesignModule {
ActionFactory.registerChartCellEditorInEditor(ChartQuickEditor.getInstance());
ElementUIProvider[] providers = ExtraDesignClassManager.getInstance().getElementUIProviders();
Set<ElementUIProvider> providers = ExtraDesignClassManager.getInstance().getArray(ElementUIProvider.MARK_STRING);
for (ElementUIProvider provider : providers) {
ActionFactory.registerCellEditor(provider.targetObjectClass(), provider.quickEditor());
}
@ -224,6 +225,16 @@ public class DesignerModule extends DesignModule {
public JTemplate<WorkBook, ?> openTemplate(FILE tplFile) {
return new JWorkBook(asIOFile(tplFile), tplFile);
}
@Override
public String mark4Provider() {
return getClass().getName();
}
@Override
public void process() {
}
}
@Override

3
designer/src/com/fr/design/present/PresentPane.java

@ -16,6 +16,7 @@ import com.fr.report.cell.cellattr.CurrencyLinePresent;
import java.awt.event.ItemListener;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
/**
* @author zhou
@ -86,7 +87,7 @@ public class PresentPane extends UIComboBoxPane<Present> {
keys.add(CurrencyLinePresent.class.getName());
displays.add(currency.title4PopupWindow());
PresentKindProvider[] providers = ExtraDesignClassManager.getInstance().getPresentKindProviders();
Set<PresentKindProvider> providers = ExtraDesignClassManager.getInstance().getArray(PresentKindProvider.MARK_STRING);
for (PresentKindProvider provider : providers) {
FurtherBasicBeanPane<? extends Present> extra = provider.appearanceForPresent();
paneList.add(extra);

5
designer/src/com/fr/design/report/ReportExportAttrPane.java

@ -11,6 +11,7 @@ import com.fr.io.attr.ReportExportAttr;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
public class ReportExportAttrPane extends BasicPane {
@ -29,8 +30,8 @@ public class ReportExportAttrPane extends BasicPane {
uiTabbedPane.addTab("PDF", pdfExportPane);
wordExportPane = new WordExportPane();
uiTabbedPane.addTab("Word", wordExportPane);
ExportAttrTabProvider[] providers = ExtraDesignClassManager.getInstance().getExportAttrTabProviders();
paneList = new ArrayList<AbstractExportPane>();
Set<ExportAttrTabProvider> providers = ExtraDesignClassManager.getInstance().getArray(ExportAttrTabProvider.XML_TAG);
paneList = new ArrayList<>();
for (ExportAttrTabProvider provider : providers) {
uiTabbedPane.addTab(provider.title(), provider.toSwingComponent());
paneList.add(provider.toExportPane());

2
designer/src/com/fr/design/report/VerifierListPane.java

@ -1 +1 @@
package com.fr.design.report; import com.fr.data.Verifier; import com.fr.design.ExtraDesignClassManager; import com.fr.design.fun.VerifyDefineProvider; import com.fr.design.gui.controlpane.NameObjectCreator; import com.fr.design.gui.controlpane.NameableCreator; import com.fr.design.gui.controlpane.ObjectJControlPane; import com.fr.design.mainframe.ElementCasePane; import com.fr.general.Inter; import com.fr.general.NameObject; import com.fr.report.write.ReportWriteAttr; import com.fr.report.write.ValueVerifier; import com.fr.report.write.WClassVerifier; import com.fr.stable.ArrayUtils; import com.fr.stable.Nameable; import java.util.ArrayList; /** * 校验列表 */ public class VerifierListPane extends ObjectJControlPane { public VerifierListPane(ElementCasePane ePane) { super(ePane); } /** * 创建选项 * * @return 选项 */ public NameableCreator[] createNameableCreators() { NameableCreator[] creators = new NameableCreator[]{ new NameObjectCreator(Inter.getLocText(new String[]{"BuildIn", "Verify"}), "/com/fr/web/images/reportlet.png", ValueVerifier.class, BuildInVerifierPane.class) }; for (VerifyDefineProvider provider : ExtraDesignClassManager.getInstance().getVerifyDefineProviders()) { creators = ArrayUtils.add(creators, new NameObjectCreator( provider.nameForVerifier(), provider.iconPath(), provider.classForVerifier(), provider.appearanceForVerifier() ) { }); } creators = ArrayUtils.add(creators, new NameObjectCreator( Inter.getLocText(new String[]{"Custom", "Verify"}), "/com/fr/web/images/reportlet.png", WClassVerifier.class, CustomVerifierPane.class)); return creators; } @Override protected String title4PopupWindow() { return "Verify Collections"; } public void populate(ReportWriteAttr reportWriteAttr) { if (reportWriteAttr == null) { return; } java.util.List<NameObject> nameObjectList = new ArrayList<>(); int verifierCount = reportWriteAttr.getVerifierCount(); for (int i = 0; i < verifierCount; i++) { Verifier verifier = reportWriteAttr.getVerifier(i); nameObjectList.add(new NameObject(verifier.getName(), verifier)); } this.populate(nameObjectList.toArray(new NameObject[nameObjectList.size()])); } public void updateReportWriteAttr(ReportWriteAttr reportWriteAttr) { // Nameable[]居然不能强转成NameObject[],一定要这么写... Nameable[] res = this.update(); NameObject[] res_array = new NameObject[res.length]; java.util.Arrays.asList(res).toArray(res_array); reportWriteAttr.clearVerifiers(); for (int i = 0; i < res_array.length; i++) { NameObject nameObject = res_array[i]; if (nameObject.getObject() instanceof Verifier) { Verifier verifier = (Verifier) nameObject.getObject(); verifier.setName(nameObject.getName()); reportWriteAttr.addVerifier(verifier); } } } }
package com.fr.design.report; import com.fr.data.Verifier; import com.fr.design.ExtraDesignClassManager; import com.fr.design.fun.VerifyDefineProvider; import com.fr.design.gui.controlpane.NameObjectCreator; import com.fr.design.gui.controlpane.NameableCreator; import com.fr.design.gui.controlpane.ObjectJControlPane; import com.fr.design.mainframe.ElementCasePane; import com.fr.general.Inter; import com.fr.general.NameObject; import com.fr.report.write.ReportWriteAttr; import com.fr.report.write.ValueVerifier; import com.fr.report.write.WClassVerifier; import com.fr.stable.ArrayUtils; import com.fr.stable.Nameable; import java.util.ArrayList; import java.util.Set; /** * 校验列表 */ public class VerifierListPane extends ObjectJControlPane { public VerifierListPane(ElementCasePane ePane) { super(ePane); } /** * 创建选项 * * @return 选项 */ public NameableCreator[] createNameableCreators() { NameableCreator[] creators = new NameableCreator[]{ new NameObjectCreator(Inter.getLocText(new String[]{"BuildIn", "Verify"}), "/com/fr/web/images/reportlet.png", ValueVerifier.class, BuildInVerifierPane.class) }; Set<VerifyDefineProvider> set = ExtraDesignClassManager.getInstance().getArray(VerifyDefineProvider.MARK_STRING); for (VerifyDefineProvider provider : set) { creators = ArrayUtils.add(creators, new NameObjectCreator( provider.nameForVerifier(), provider.iconPath(), provider.classForVerifier(), provider.appearanceForVerifier() ) { }); } creators = ArrayUtils.add(creators, new NameObjectCreator( Inter.getLocText(new String[]{"Custom", "Verify"}), "/com/fr/web/images/reportlet.png", WClassVerifier.class, CustomVerifierPane.class)); return creators; } @Override protected String title4PopupWindow() { return "Verify Collections"; } public void populate(ReportWriteAttr reportWriteAttr) { if (reportWriteAttr == null) { return; } java.util.List<NameObject> nameObjectList = new ArrayList<>(); int verifierCount = reportWriteAttr.getVerifierCount(); for (int i = 0; i < verifierCount; i++) { Verifier verifier = reportWriteAttr.getVerifier(i); nameObjectList.add(new NameObject(verifier.getName(), verifier)); } this.populate(nameObjectList.toArray(new NameObject[nameObjectList.size()])); } public void updateReportWriteAttr(ReportWriteAttr reportWriteAttr) { // Nameable[]居然不能强转成NameObject[],一定要这么写... Nameable[] res = this.update(); NameObject[] res_array = new NameObject[res.length]; java.util.Arrays.asList(res).toArray(res_array); reportWriteAttr.clearVerifiers(); for (int i = 0; i < res_array.length; i++) { NameObject nameObject = res_array[i]; if (nameObject.getObject() instanceof Verifier) { Verifier verifier = (Verifier) nameObject.getObject(); verifier.setName(nameObject.getName()); reportWriteAttr.addVerifier(verifier); } } } }

4
designer/src/com/fr/design/webattr/EditToolBar.java

@ -47,6 +47,7 @@ import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
public class EditToolBar extends BasicPane {
@ -354,7 +355,8 @@ public class EditToolBar extends BasicPane {
* 初始化元素
*/
public void initComponents() {
exportToolBarProviders = ExtraDesignClassManager.getInstance().getExportToolBarProviders();
Set<ExportToolBarProvider> set = ExtraDesignClassManager.getInstance().getArray(ExportToolBarProvider.XML_TAG);
exportToolBarProviders = set.toArray(new ExportToolBarProvider[set.size()]);
this.setLayout(FRGUIPaneFactory.createBorderLayout());
JPanel north = FRGUIPaneFactory.createBorderLayout_S_Pane();
icon = new UICheckBox(Inter.getLocText("FR-Designer_Show_Icon"));

2
designer/src/com/fr/design/widget/WidgetPane.java

@ -69,7 +69,7 @@ public class WidgetPane extends BasicPane implements ItemListener {
if (e.getStateChange() == ItemEvent.SELECTED) {
Widget oldWidget = update();
Widget selectedItem = editorTypeComboBox.getCellWidget();
WidgetDesignHandler handler = ExtraDesignClassManager.getInstance().getWidgetDesignHandler();
WidgetDesignHandler handler = ExtraDesignClassManager.getInstance().getSingle(WidgetDesignHandler.XML_TAG);
if (handler != null) {
handler.transferWidgetProperties(oldWidget, selectedItem);
}

15
designer/src/com/fr/design/write/submit/SubmitVisitorListPane.java

@ -21,7 +21,6 @@ import com.fr.report.write.BuiltInSQLSubmiter;
import com.fr.report.write.ReportWriteAttr;
import com.fr.report.write.SubmitVisitor;
import com.fr.report.write.WClassSubmiter;
import com.fr.stable.ArrayUtils;
import com.fr.stable.Nameable;
import com.fr.write.BuiltInSQLSubmiterProvider;
import com.fr.write.DBManipulation;
@ -31,10 +30,8 @@ import javax.swing.*;
import java.awt.*;
import java.awt.event.ItemEvent;
import java.awt.event.ItemListener;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.*;
import java.util.List;
import java.util.Map;
public class SubmitVisitorListPane extends ObjectJControlPane {
@ -172,17 +169,17 @@ public class SubmitVisitorListPane extends ObjectJControlPane {
public CustomPane() {
this.setLayout(FRGUIPaneFactory.createBorderLayout());
customCardPane = FRGUIPaneFactory.createCardLayout_S_Pane();
customSubmitPanes = new HashMap<String, BasicBeanPane>();
comboItemsMap = new HashMap<String, String>();
customSubmitPanes = new HashMap<>();
comboItemsMap = new HashMap<>();
SubmitProvider[] providers = ExtraDesignClassManager.getInstance().getSubmitProviders();
providers = (SubmitProvider[]) ArrayUtils.add(providers, new DefaultSubmit());
Set<SubmitProvider> providers = ExtraDesignClassManager.getInstance().getArray(SubmitProvider.MARK_STRING);
providers.add(new DefaultSubmit());
for (SubmitProvider provider : providers) {
customSubmitPanes.put(provider.keyForSubmit(), provider.appearanceForSubmit());
comboItemsMap.put(provider.keyForSubmit(), provider.dataForSubmit());
}
configTypes = new ArrayList<String>();
configTypes = new ArrayList<>();
for (Map.Entry<String, BasicBeanPane> entry : customSubmitPanes.entrySet()) {
String key = entry.getKey();
configTypes.add(comboItemsMap.get(key));

920
designer_base/src/com/fr/design/ExtraDesignClassManager.java

File diff suppressed because it is too large Load Diff

4
designer_base/src/com/fr/design/data/datapane/TableDataCreatorProducer.java

@ -100,10 +100,6 @@ public class TableDataCreatorProducer {
TableDataNameObjectCreator[] creators = new TableDataNameObjectCreator[]{dataBase, ds_Class, table, fileTable, storeProcedure, multiTable, treeTable};
TableDataCreatorProvider creatorProvider = ExtraDesignClassManager.getInstance().getTableDataCreatorProvider();
if (creatorProvider != null) {
return creatorProvider.produceServerTableDataCreator(creators);
}
return merge(creators, ExtraDesignClassManager.getInstance().getServerTableDataCreators());
}

2
designer_base/src/com/fr/design/data/datapane/TableDataTreePane.java

@ -47,7 +47,7 @@ public class TableDataTreePane extends BasicTableDataTreePane {
public synchronized static BasicTableDataTreePane getInstance(DesignModelAdapter<?, ?> tc) {
TableDataPaneProcessor treePaneProcessor = ExtraDesignClassManager.getInstance().getTableDataPaneProcessor();
TableDataPaneProcessor treePaneProcessor = ExtraDesignClassManager.getInstance().getSingle(TableDataPaneProcessor.XML_TAG);
if (treePaneProcessor != null) {
return treePaneProcessor.createTableDataTreePane(tc);
}

14
designer_base/src/com/fr/design/data/datapane/connect/ConnectionListPane.java

@ -4,6 +4,7 @@ import com.fr.data.impl.Connection;
import com.fr.data.impl.JDBCDatabaseConnection;
import com.fr.data.impl.JNDIDatabaseConnection;
import com.fr.design.ExtraDesignClassManager;
import com.fr.design.fun.ConnectionProvider;
import com.fr.design.gui.controlpane.JListControlPane;
import com.fr.design.gui.controlpane.NameObjectCreator;
import com.fr.design.gui.controlpane.NameableCreator;
@ -107,9 +108,18 @@ public class ConnectionListPane extends JListControlPane {
JNDIDatabaseConnection.class,
DatabaseConnectionPane.JNDI.class
)};
NameObjectCreator[] pluginCreators = ExtraDesignClassManager.getInstance().getConnections();
Set<ConnectionProvider> pluginCreators = ExtraDesignClassManager.getInstance().getArray(ConnectionProvider.XML_TAG);
for (ConnectionProvider provider : pluginCreators) {
NameObjectCreator creator = new NameObjectCreator(
provider.nameForConnection(),
provider.iconPathForConnection(),
provider.classForConnection(),
provider.appearanceForConnection()
);
creators = ArrayUtils.add(creators, creator);
}
return (NameableCreator[]) ArrayUtils.addAll(creators, pluginCreators);
return creators;
}
@Override

2
designer_base/src/com/fr/design/data/tabledata/tabledatapane/TableDataManagerPane.java

@ -40,7 +40,7 @@ public class TableDataManagerPane extends LoadingBasicPane {
this.tableDataTextField = new UITextField();
tableDataPathPane.add(tableDataTextField, BorderLayout.CENTER);
this.tableDataTextField.setEditable(false);
TableDataPaneProcessor paneProcessor = ExtraDesignClassManager.getInstance().getTableDataPaneProcessor();
TableDataPaneProcessor paneProcessor = ExtraDesignClassManager.getInstance().getSingle(TableDataPaneProcessor.XML_TAG);
TableDataPaneController pane = null;
if (paneProcessor != null) {
pane = paneProcessor.createServerTableDataPane(DesignModelAdapter.getCurrentModelAdapter()

4
designer_base/src/com/fr/design/data/tabledata/wrapper/TableDataFactory.java

@ -59,10 +59,6 @@ public abstract class TableDataFactory {
}
private static TableDataNameObjectCreator getTableDataNameObjectCreator(TableData tabledata) {
TableDataCreatorProvider creatorProvider = ExtraDesignClassManager.getInstance().getTableDataCreatorProvider();
if (creatorProvider != null) {
map.putAll(creatorProvider.registerMap());
}
TableDataNameObjectCreator tableDataNameObjectCreator = map.get(tabledata.getClass().getName());
if (tableDataNameObjectCreator == null) {
tableDataNameObjectCreator = map.get(tabledata.getClass().getSuperclass().getName());

2
designer_base/src/com/fr/design/formula/FormulaFactory.java

@ -20,7 +20,7 @@ public class FormulaFactory {
}
private static UIFormulaProcessor get() {
UIFormulaProcessor processor = ExtraDesignClassManager.getInstance().getUIFormulaProcessor();
UIFormulaProcessor processor = ExtraDesignClassManager.getInstance().getSingle(UIFormulaProcessor.MARK_STRING);
if (processor == null) {
processor = new DefaultUIFormulaProcessor();
}

3
designer_base/src/com/fr/design/fun/BackgroundQuickUIProvider.java

@ -3,12 +3,13 @@ package com.fr.design.fun;
import com.fr.design.mainframe.backgroundpane.BackgroundQuickPane;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.Provider;
import com.fr.stable.fun.mark.Mutable;
/**
* Created by richie on 16/5/18.
* 背景设置界面接口,用于扩展设置更多类型的背景
*/
public interface BackgroundQuickUIProvider extends Level, Provider {
public interface BackgroundQuickUIProvider extends Mutable {
String MARK_STRING = "BackgroundQuickUIProvider";

5
designer_base/src/com/fr/design/fun/BackgroundUIProvider.java

@ -2,13 +2,12 @@ package com.fr.design.fun;
import com.fr.design.style.background.BackgroundDetailPane;
import com.fr.general.Background;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.Provider;
import com.fr.stable.fun.mark.Mutable;
/**
* Created by richie on 16/5/18.
*/
public interface BackgroundUIProvider extends Level, Provider {
public interface BackgroundUIProvider extends Mutable {
String MARK_STRING = "BackgroundUIProvider";

4
designer_base/src/com/fr/design/fun/CellAttributeProvider.java

@ -1,12 +1,12 @@
package com.fr.design.fun;
import com.fr.design.gui.frpane.AbstractAttrNoScrollPane;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Immutable;
/**
* Created by zhouping on 2015/11/11.
*/
public interface CellAttributeProvider extends Level{
public interface CellAttributeProvider extends Immutable{
String MARK_STRING = "CellAttributeProvider";
int CURRENT_LEVEL = 1;

2
designer_base/src/com/fr/design/fun/CellWidgetOptionProvider.java

@ -10,7 +10,7 @@ import com.fr.stable.fun.Level;
* @since 8.0
* 格子中的自定义控件接口
*/
public interface CellWidgetOptionProvider extends ParameterWidgetOptionProvider, Level {
public interface CellWidgetOptionProvider extends ParameterWidgetOptionProvider {
String XML_TAG = "CellWidgetOptionProvider";

4
designer_base/src/com/fr/design/fun/ConnectionProvider.java

@ -2,13 +2,13 @@ package com.fr.design.fun;
import com.fr.data.impl.Connection;
import com.fr.design.beans.BasicBeanPane;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
/**
* @author : richie
* @since : 8.0
*/
public interface ConnectionProvider extends Level {
public interface ConnectionProvider extends Mutable {
public static final String XML_TAG = "ConnectionProvider";

4
designer_base/src/com/fr/design/fun/DesignerEnvProcessor.java

@ -1,6 +1,6 @@
package com.fr.design.fun;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Immutable;
/**
* 在env加载之前, 修改env参数的接口
@ -9,7 +9,7 @@ import com.fr.stable.fun.Level;
*
* Created by Administrator on 2016/3/31/0031.
*/
public interface DesignerEnvProcessor extends Level{
public interface DesignerEnvProcessor extends Immutable{
String XML_TAG = "DesignerEnvProcessor";
int CURRENT_LEVEL = 1;

4
designer_base/src/com/fr/design/fun/ElementUIProvider.java

@ -2,14 +2,14 @@ package com.fr.design.fun;
import com.fr.design.actions.UpdateAction;
import com.fr.design.selection.QuickEditor;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
/**
* Created by richie on 16/4/25.
* 单元格元素和悬浮元素扩展,通过实现这个接口,可以在单元格中添加更多类型的元素.
*/
public interface ElementUIProvider extends Level {
public interface ElementUIProvider extends Mutable {
String MARK_STRING = "ElementUIProvider";

4
designer_base/src/com/fr/design/fun/ExportAttrTabProvider.java

@ -1,7 +1,7 @@
package com.fr.design.fun;
import com.fr.design.report.AbstractExportPane;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
import javax.swing.*;
@ -12,7 +12,7 @@ import javax.swing.*;
/**
* 导出属性Tab页的接口
*/
public interface ExportAttrTabProvider extends Level{
public interface ExportAttrTabProvider extends Mutable {
String XML_TAG = "ExportAttrTabProvider";
int CURRENT_LEVEL = 1;

4
designer_base/src/com/fr/design/fun/ExportToolBarProvider.java

@ -1,13 +1,13 @@
package com.fr.design.fun;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
import javax.swing.*;
/**
* 导出菜单设计器端拓展用于控制该菜单是否在web端显示
*/
public interface ExportToolBarProvider extends Level{
public interface ExportToolBarProvider extends Mutable{
String XML_TAG = "ExportToolBarProvider";

4
designer_base/src/com/fr/design/fun/FormElementCaseEditorProcessor.java

@ -1,14 +1,14 @@
package com.fr.design.fun;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.ReportFitAttrProvider;
import com.fr.stable.fun.mark.Immutable;
import java.beans.PropertyDescriptor;
/**
* Created by zhouping on 2015/9/10.
*/
public interface FormElementCaseEditorProcessor extends Level{
public interface FormElementCaseEditorProcessor extends Immutable {
String MARK_STRING = "PropertyEditor";

4
designer_base/src/com/fr/design/fun/FormWidgetOptionProvider.java

@ -1,14 +1,12 @@
package com.fr.design.fun;
import com.fr.stable.fun.Level;
/**
* @author richie
* @date 2015-03-23
* @since 8.0
* 表单控件
*/
public interface FormWidgetOptionProvider extends ParameterWidgetOptionProvider, Level {
public interface FormWidgetOptionProvider extends ParameterWidgetOptionProvider {
String XML_TAG = "FormWidgetOptionProvider";

4
designer_base/src/com/fr/design/fun/GlobalListenerProvider.java

@ -1,7 +1,7 @@
package com.fr.design.fun;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
import java.awt.event.AWTEventListener;
@ -9,7 +9,7 @@ import java.awt.event.AWTEventListener;
* Created by zack on 2015/8/17.
* 全局事件监听
*/
public interface GlobalListenerProvider extends Level{
public interface GlobalListenerProvider extends Mutable{
String XML_TAG = "GlobalListenerProvider";

3
designer_base/src/com/fr/design/fun/HighlightProvider.java

@ -3,11 +3,12 @@ package com.fr.design.fun;
import com.fr.design.condition.ConditionAttrSingleConditionPane;
import com.fr.design.condition.ConditionAttributesPane;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
/**
* 条件属性界面设计接口
*/
public interface HighlightProvider extends Level{
public interface HighlightProvider extends Mutable{
String MARK_STRING = "HighlightProvider";

3
designer_base/src/com/fr/design/fun/HyperlinkProvider.java

@ -2,11 +2,12 @@ package com.fr.design.fun;
import com.fr.design.gui.controlpane.NameableCreator;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
/**
* Created by zack on 2016/1/20.
*/
public interface HyperlinkProvider extends Level{
public interface HyperlinkProvider extends Mutable {
String XML_TAG = "HyperlinkProvider";
int CURRENT_LEVEL = 1;

4
designer_base/src/com/fr/design/fun/IndentationUnitProcessor.java

@ -1,11 +1,11 @@
package com.fr.design.fun;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Immutable;
/**
* Created by zhouping on 2015/9/20.
*/
public interface IndentationUnitProcessor extends Level{
public interface IndentationUnitProcessor extends Immutable {
String MARK_STRING = "IndentationProcessor";
int CURRENT_LEVEL = 1;

4
designer_base/src/com/fr/design/fun/JavaScriptActionProvider.java

@ -2,12 +2,12 @@ package com.fr.design.fun;
import com.fr.design.beans.FurtherBasicBeanPane;
import com.fr.js.JavaScript;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
/**
* Created by zack on 2015/8/14.
*/
public interface JavaScriptActionProvider extends Level{
public interface JavaScriptActionProvider extends Mutable{
String XML_TAG = "JavaScriptActionProvider";

4
designer_base/src/com/fr/design/fun/MenuHandler.java

@ -2,7 +2,7 @@ package com.fr.design.fun;
import com.fr.design.mainframe.toolbar.ToolBarMenuDockPlus;
import com.fr.design.menu.ShortCut;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
/**
* @author richie
@ -10,7 +10,7 @@ import com.fr.stable.fun.Level;
* @since 8.0
* 设计器菜单栏插件接口
*/
public interface MenuHandler extends Level {
public interface MenuHandler extends Mutable {
String MARK_STRING = "MenuHandler";

4
designer_base/src/com/fr/design/fun/ParameterWidgetOptionProvider.java

@ -1,14 +1,14 @@
package com.fr.design.fun;
import com.fr.form.ui.Widget;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
/**
* @author : richie
* @since : 8.0
* 自定义参数界面控件
*/
public interface ParameterWidgetOptionProvider extends Level{
public interface ParameterWidgetOptionProvider extends Mutable {
String XML_TAG = "ParameterWidgetOptionProvider";

4
designer_base/src/com/fr/design/fun/PresentKindProvider.java

@ -2,7 +2,7 @@ package com.fr.design.fun;
import com.fr.base.present.Present;
import com.fr.design.beans.FurtherBasicBeanPane;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
/**
* @author richie
@ -10,7 +10,7 @@ import com.fr.stable.fun.Level;
* @since 8.0
* 形态类型接口
*/
public interface PresentKindProvider extends Level{
public interface PresentKindProvider extends Mutable{
int CURRENT_LEVEL = 1;

4
designer_base/src/com/fr/design/fun/PreviewProvider.java

@ -1,7 +1,7 @@
package com.fr.design.fun;
import com.fr.design.mainframe.JTemplate;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
import java.util.Map;
@ -11,7 +11,7 @@ import java.util.Map;
* @since 8.0
* 自定义预览方式接口
*/
public interface PreviewProvider extends Level{
public interface PreviewProvider extends Mutable{
String MARK_STRING = "PreviewProvider";

4
designer_base/src/com/fr/design/fun/SubmitProvider.java

@ -1,12 +1,12 @@
package com.fr.design.fun;
import com.fr.design.beans.BasicBeanPane;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
/**
* 自定义提交接口
*/
public interface SubmitProvider extends Level{
public interface SubmitProvider extends Mutable{
String MARK_STRING = "SubmitProvider";

5
designer_base/src/com/fr/design/fun/TableDataDefineProvider.java

@ -2,14 +2,15 @@ package com.fr.design.fun;
import com.fr.base.TableData;
import com.fr.design.data.tabledata.tabledatapane.AbstractTableDataPane;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
import com.fr.stable.fun.mark.Aftermath;
/**
* @author : richie
* @since : 7.1.1
* 自定义报表数据集界面接口单独存在的一个个数据集
*/
public interface TableDataDefineProvider extends Level {
public interface TableDataDefineProvider extends Mutable, Aftermath {
String XML_TAG = "TableDataDefineProvider";

4
designer_base/src/com/fr/design/fun/TableDataPaneProcessor.java

@ -4,7 +4,7 @@ import com.fr.design.DesignModelAdapter;
import com.fr.design.data.BasicTableDataTreePane;
import com.fr.design.data.datapane.TableDataPaneController;
import com.fr.design.menu.ShortCut;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Immutable;
/**
* 自定义的模板服务器数据集的树样式接口 el:分组样式
@ -12,7 +12,7 @@ import com.fr.stable.fun.Level;
* Date: 2016/4/18
* Time: 9:04
*/
public interface TableDataPaneProcessor extends Level {
public interface TableDataPaneProcessor extends Immutable {
String XML_TAG = "TableDataPaneProcessor";
int CURRENT_LEVEL = 1;

4
designer_base/src/com/fr/design/fun/TitlePlaceProcessor.java

@ -1,10 +1,10 @@
package com.fr.design.fun;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Immutable;
import java.awt.*;
public interface TitlePlaceProcessor extends Level{
public interface TitlePlaceProcessor extends Immutable {
String MARK_STRING = "TitlePlaceProcessor";

4
designer_base/src/com/fr/design/fun/ToolbarItemProvider.java

@ -1,14 +1,14 @@
package com.fr.design.fun;
import com.fr.form.ui.Widget;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
/**
* @author : focus
* @since : 8.0
* 自定义web工具栏菜单
*/
public interface ToolbarItemProvider extends Level{
public interface ToolbarItemProvider extends Mutable {
String XML_TAG = "ToolbarItemProvider";

4
designer_base/src/com/fr/design/fun/UIFormulaProcessor.java

@ -1,7 +1,7 @@
package com.fr.design.fun;
import com.fr.design.formula.UIFormula;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Immutable;
/**
* @author richie
@ -9,7 +9,7 @@ import com.fr.stable.fun.Level;
* @since 8.0
* 公式编辑器界面处理接口
*/
public interface UIFormulaProcessor extends Level{
public interface UIFormulaProcessor extends Immutable{
String MARK_STRING = "UIFormulaProcessor";
int CURRENT_LEVEL = 1;

5
designer_base/src/com/fr/design/fun/VerifyDefineProvider.java

@ -2,13 +2,12 @@ package com.fr.design.fun;
import com.fr.data.Verifier;
import com.fr.design.beans.BasicBeanPane;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.Provider;
import com.fr.stable.fun.mark.Mutable;
/**
* Created by richie on 16/6/8.
*/
public interface VerifyDefineProvider extends Level, Provider {
public interface VerifyDefineProvider extends Mutable {
String MARK_STRING = "VerifyDefineProvider";

4
designer_base/src/com/fr/design/fun/WidgetDesignHandler.java

@ -1,14 +1,14 @@
package com.fr.design.fun;
import com.fr.form.ui.Widget;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Immutable;
/**
* Coder: zack
* Date: 2016/5/12
* Time: 10:37
*/
public interface WidgetDesignHandler extends Level {
public interface WidgetDesignHandler extends Immutable {
String XML_TAG = "WidgetDesignHandler";
int CURRENT_LEVEL = 1;

4
designer_base/src/com/fr/design/fun/WidgetPropertyUIProvider.java

@ -1,13 +1,13 @@
package com.fr.design.fun;
import com.fr.design.gui.itable.AbstractPropertyTable;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
/**
* Created by vito on 16/4/27.
*/
public interface WidgetPropertyUIProvider extends Level {
public interface WidgetPropertyUIProvider extends Mutable {
String XML_TAG = "WidgetPropertyUIProvider";
int CURRENT_LEVEL = 1;

2
designer_base/src/com/fr/design/fun/impl/AbstractBackgroundQuickUIProvider.java

@ -2,10 +2,12 @@ package com.fr.design.fun.impl;
import com.fr.design.fun.BackgroundQuickUIProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by richie on 16/5/18.
*/
@API(level = BackgroundQuickUIProvider.CURRENT_LEVEL)
public abstract class AbstractBackgroundQuickUIProvider extends AbstractProvider implements BackgroundQuickUIProvider {
@Override

2
designer_base/src/com/fr/design/fun/impl/AbstractBackgroundUIProvider.java

@ -2,10 +2,12 @@ package com.fr.design.fun.impl;
import com.fr.design.fun.BackgroundUIProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by richie on 16/5/18.
*/
@API(level = BackgroundUIProvider.CURRENT_LEVEL)
public abstract class AbstractBackgroundUIProvider extends AbstractProvider implements BackgroundUIProvider {
@Override

2
designer_base/src/com/fr/design/fun/impl/AbstractCellAttributeProvider.java

@ -1,10 +1,12 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.CellAttributeProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by zhouping on 2015/11/11.
*/
@API(level = CellAttributeProvider.CURRENT_LEVEL)
public abstract class AbstractCellAttributeProvider implements CellAttributeProvider {
public int currentAPILevel() {

10
designer_base/src/com/fr/design/fun/impl/AbstractCellWidgetOptionProvider.java

@ -1,17 +1,23 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.CellWidgetOptionProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* @author richie
* @date 2015-05-13
* @since 8.0
*/
public abstract class AbstractCellWidgetOptionProvider implements CellWidgetOptionProvider {
@API(level = CellWidgetOptionProvider.CURRENT_LEVEL)
public abstract class AbstractCellWidgetOptionProvider extends AbstractProvider implements CellWidgetOptionProvider {
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
}

10
designer_base/src/com/fr/design/fun/impl/AbstractConnectionProvider.java

@ -1,16 +1,24 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.ConnectionProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* @author richie
* @date 2015-05-13
* @since 8.0
*/
public abstract class AbstractConnectionProvider implements ConnectionProvider {
@API(level = ConnectionProvider.CURRENT_LEVEL)
public abstract class AbstractConnectionProvider extends AbstractProvider implements ConnectionProvider {
@Override
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
}

2
designer_base/src/com/fr/design/fun/impl/AbstractDesignerEnvProcessor.java

@ -1,10 +1,12 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.DesignerEnvProcessor;
import com.fr.stable.fun.mark.API;
/**
* Created by Administrator on 2016/3/31/0031.
*/
@API(level = DesignerEnvProcessor.CURRENT_LEVEL)
public abstract class AbstractDesignerEnvProcessor implements DesignerEnvProcessor {
public int currentAPILevel() {

2
designer_base/src/com/fr/design/fun/impl/AbstractElementUIProvider.java

@ -2,10 +2,12 @@ package com.fr.design.fun.impl;
import com.fr.design.fun.ElementUIProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by richie on 16/4/25.
*/
@API(level = ElementUIProvider.CURRENT_LEVEL)
public abstract class AbstractElementUIProvider extends AbstractProvider implements ElementUIProvider {
@Override

2
designer_base/src/com/fr/design/fun/impl/AbstractExportAttrTabProvider.java

@ -2,10 +2,12 @@ package com.fr.design.fun.impl;
import com.fr.design.fun.ExportAttrTabProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by vito on 16/5/5.
*/
@API(level = ExportAttrTabProvider.CURRENT_LEVEL)
public abstract class AbstractExportAttrTabProvider extends AbstractProvider implements ExportAttrTabProvider {
@Override
public int currentAPILevel() {

2
designer_base/src/com/fr/design/fun/impl/AbstractFormElementCaseEditorProcessor.java

@ -2,12 +2,14 @@ package com.fr.design.fun.impl;
import com.fr.design.fun.FormElementCaseEditorProcessor;
import com.fr.stable.fun.ReportFitAttrProvider;
import com.fr.stable.fun.mark.API;
import java.beans.PropertyDescriptor;
/**
* Created by zhouping on 2015/9/10.
*/
@API(level = FormElementCaseEditorProcessor.CURRENT_LEVEL)
public abstract class AbstractFormElementCaseEditorProcessor implements FormElementCaseEditorProcessor {
public int currentAPILevel() {

9
designer_base/src/com/fr/design/fun/impl/AbstractFormWidgetOptionProvider.java

@ -1,18 +1,25 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.FormWidgetOptionProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* @author richie
* @date 2015-05-13
* @since 8.0
*/
public abstract class AbstractFormWidgetOptionProvider implements FormWidgetOptionProvider {
@API(level = FormWidgetOptionProvider.CURRENT_LEVEL)
public abstract class AbstractFormWidgetOptionProvider extends AbstractProvider implements FormWidgetOptionProvider {
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
@Override
public boolean isContainer() {

10
designer_base/src/com/fr/design/fun/impl/AbstractGlobalListenerProvider.java

@ -1,15 +1,21 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.GlobalListenerProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by zack on 2015/8/17.
*/
public abstract class AbstractGlobalListenerProvider implements GlobalListenerProvider {
@API(level = GlobalListenerProvider.CURRENT_LEVEL)
public abstract class AbstractGlobalListenerProvider extends AbstractProvider implements GlobalListenerProvider {
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
}

9
designer_base/src/com/fr/design/fun/impl/AbstractHighlightProvider.java

@ -1,16 +1,23 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.HighlightProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* @author richie
* @date 2015-05-13
* @since 8.0
*/
public abstract class AbstractHighlightProvider implements HighlightProvider {
@API(level = HighlightProvider.CURRENT_LEVEL)
public abstract class AbstractHighlightProvider extends AbstractProvider implements HighlightProvider {
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
}

9
designer_base/src/com/fr/design/fun/impl/AbstractHyperlinkProvider.java

@ -1,14 +1,21 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.HyperlinkProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by zack on 2016/1/18.
*/
public abstract class AbstractHyperlinkProvider implements HyperlinkProvider {
@API(level = HyperlinkProvider.CURRENT_LEVEL)
public abstract class AbstractHyperlinkProvider extends AbstractProvider implements HyperlinkProvider {
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
}

2
designer_base/src/com/fr/design/fun/impl/AbstractIndentationUnitProcessor.java

@ -1,10 +1,12 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.IndentationUnitProcessor;
import com.fr.stable.fun.mark.API;
/**
* Created by zhouping on 2015/9/20.
*/
@API(level = IndentationUnitProcessor.CURRENT_LEVEL)
public class AbstractIndentationUnitProcessor implements IndentationUnitProcessor {
private int indentationUnit = 1;

9
designer_base/src/com/fr/design/fun/impl/AbstractJavaScriptActionProvider.java

@ -1,14 +1,21 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.JavaScriptActionProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by zack on 2015/8/20.
*/
public abstract class AbstractJavaScriptActionProvider implements JavaScriptActionProvider {
@API(level = JavaScriptActionProvider.CURRENT_LEVEL)
public abstract class AbstractJavaScriptActionProvider extends AbstractProvider implements JavaScriptActionProvider {
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
}

2
designer_base/src/com/fr/design/fun/impl/AbstractMenuHandler.java

@ -4,12 +4,14 @@ import com.fr.design.fun.MenuHandler;
import com.fr.design.mainframe.toolbar.ToolBarMenuDockPlus;
import com.fr.design.menu.ShortCut;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* @author richie
* @date 2015-05-13
* @since 8.0
*/
@API(level = MenuHandler.CURRENT_LEVEL)
public abstract class AbstractMenuHandler extends AbstractProvider implements MenuHandler {
public int currentAPILevel() {

9
designer_base/src/com/fr/design/fun/impl/AbstractParameterWidgetOptionProvider.java

@ -1,16 +1,23 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.ParameterWidgetOptionProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* @author richie
* @date 2015-05-13
* @since 8.0
*/
public abstract class AbstractParameterWidgetOptionProvider implements ParameterWidgetOptionProvider {
@API(level = ParameterWidgetOptionProvider.CURRENT_LEVEL)
public abstract class AbstractParameterWidgetOptionProvider extends AbstractProvider implements ParameterWidgetOptionProvider {
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
}

10
designer_base/src/com/fr/design/fun/impl/AbstractPresentKindProvider.java

@ -1,17 +1,23 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.PresentKindProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* @author richie
* @date 2015-05-22
* @since 8.0
*/
public abstract class AbstractPresentKindProvider implements PresentKindProvider {
@API(level = PresentKindProvider.CURRENT_LEVEL)
public abstract class AbstractPresentKindProvider extends AbstractProvider implements PresentKindProvider {
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
}

9
designer_base/src/com/fr/design/fun/impl/AbstractPreviewProvider.java

@ -3,6 +3,8 @@ package com.fr.design.fun.impl;
import com.fr.design.fun.PreviewProvider;
import com.fr.design.mainframe.JTemplate;
import com.fr.general.ComparatorUtils;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
import java.util.Collections;
import java.util.Map;
@ -12,12 +14,17 @@ import java.util.Map;
* @date 2015-05-13
* @since 8.0
*/
public abstract class AbstractPreviewProvider implements PreviewProvider {
@API(level = PreviewProvider.CURRENT_LEVEL)
public abstract class AbstractPreviewProvider extends AbstractProvider implements PreviewProvider {
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
@Override
public void onClick(JTemplate<?, ?> jt) {

29
designer_base/src/com/fr/design/fun/impl/AbstractServerTableDataDefineProvider.java

@ -1,12 +1,39 @@
package com.fr.design.fun.impl;
import com.fr.design.data.datapane.TableDataNameObjectCreator;
import com.fr.design.data.tabledata.wrapper.TableDataFactory;
import com.fr.design.fun.ServerTableDataDefineProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* @author richie
* @date 2015-05-13
* @since 8.0
*/
public abstract class AbstractServerTableDataDefineProvider implements ServerTableDataDefineProvider {
@API(level = ServerTableDataDefineProvider.CURRENT_LEVEL)
public abstract class AbstractServerTableDataDefineProvider extends AbstractProvider implements ServerTableDataDefineProvider {
@Override
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
@Override
public void process() {
TableDataNameObjectCreator creator = new TableDataNameObjectCreator(
nameForTableData(),
prefixForTableData(),
iconPathForTableData(),
classForTableData(),
classForInitTableData(),
appearanceForTableData()
);
TableDataFactory.register(classForTableData(), creator);
}
}

10
designer_base/src/com/fr/design/fun/impl/AbstractSubmitProvider.java

@ -1,12 +1,18 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.SubmitProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
public abstract class AbstractSubmitProvider implements SubmitProvider {
@API(level = SubmitProvider.CURRENT_LEVEL)
public abstract class AbstractSubmitProvider extends AbstractProvider implements SubmitProvider {
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
}

2
designer_base/src/com/fr/design/fun/impl/AbstractTDPaneProcessor.java

@ -1,12 +1,14 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.TableDataPaneProcessor;
import com.fr.stable.fun.mark.API;
/**
* Coder: zack
* Date: 2016/4/18
* Time: 10:30
*/
@API(level = TableDataPaneProcessor.CURRENT_LEVEL)
public abstract class AbstractTDPaneProcessor implements TableDataPaneProcessor {
@Override
public int currentAPILevel() {

25
designer_base/src/com/fr/design/fun/impl/AbstractTableDataDefineProvider.java

@ -1,16 +1,39 @@
package com.fr.design.fun.impl;
import com.fr.design.data.datapane.TableDataNameObjectCreator;
import com.fr.design.data.tabledata.wrapper.TableDataFactory;
import com.fr.design.fun.TableDataDefineProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* @author richie
* @date 2015-05-13
* @since 8.0
*/
public abstract class AbstractTableDataDefineProvider implements TableDataDefineProvider {
@API(level = TableDataDefineProvider.CURRENT_LEVEL)
public abstract class AbstractTableDataDefineProvider extends AbstractProvider implements TableDataDefineProvider {
@Override
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
@Override
public void process() {
TableDataNameObjectCreator creator = new TableDataNameObjectCreator(
nameForTableData(),
prefixForTableData(),
iconPathForTableData(),
classForTableData(),
classForInitTableData(),
appearanceForTableData()
);
TableDataFactory.register(classForTableData(), creator);
}
}

2
designer_base/src/com/fr/design/fun/impl/AbstractTitleProcessor.java

@ -1,7 +1,9 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.TitlePlaceProcessor;
import com.fr.stable.fun.mark.API;
@API(level = TitlePlaceProcessor.CURRENT_LEVEL)
public abstract class AbstractTitleProcessor implements TitlePlaceProcessor {
public int currentAPILevel() {

9
designer_base/src/com/fr/design/fun/impl/AbstractToolbarItem.java

@ -1,14 +1,21 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.ToolbarItemProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by richie on 15/12/1.
*/
public abstract class AbstractToolbarItem implements ToolbarItemProvider {
@API(level = ToolbarItemProvider.CURRENT_LEVEL)
public abstract class AbstractToolbarItem extends AbstractProvider implements ToolbarItemProvider {
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
}

2
designer_base/src/com/fr/design/fun/impl/AbstractUIFormulaProcessor.java

@ -1,12 +1,14 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.UIFormulaProcessor;
import com.fr.stable.fun.mark.API;
/**
* @author richie
* @date 2015-05-13
* @since 8.0
*/
@API(level = UIFormulaProcessor.CURRENT_LEVEL)
public abstract class AbstractUIFormulaProcessor implements UIFormulaProcessor {
public int currentAPILevel() {

2
designer_base/src/com/fr/design/fun/impl/AbstractVerifyDefineProvider.java

@ -2,10 +2,12 @@ package com.fr.design.fun.impl;
import com.fr.design.fun.VerifyDefineProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by richie on 16/6/8.
*/
@API(level = VerifyDefineProvider.CURRENT_LEVEL)
public abstract class AbstractVerifyDefineProvider extends AbstractProvider implements VerifyDefineProvider {
@Override

7
designer_base/src/com/fr/design/fun/impl/AbstractWidgetDesignHandler.java

@ -1,11 +1,18 @@
package com.fr.design.fun.impl;
import com.fr.design.fun.WidgetDesignHandler;
import com.fr.stable.fun.mark.API;
/**
* Coder: zack
* Date: 2016/5/12
* Time: 10:41
*/
@API(level = WidgetDesignHandler.CURRENT_LEVEL)
public abstract class AbstractWidgetDesignHandler implements WidgetDesignHandler {
@Override
public int currentAPILevel() {
return CURRENT_LEVEL;
}
}

2
designer_base/src/com/fr/design/fun/impl/AbstractWidgetPropertyUIProvider.java

@ -2,11 +2,13 @@ package com.fr.design.fun.impl;
import com.fr.design.fun.WidgetPropertyUIProvider;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by vito on 16/4/27.
*/
@API(level = WidgetPropertyUIProvider.CURRENT_LEVEL)
public abstract class AbstractWidgetPropertyUIProvider extends AbstractProvider implements WidgetPropertyUIProvider {
@Override

5
designer_base/src/com/fr/design/gui/frpane/HyperlinkGroupPane.java

@ -18,6 +18,7 @@ import com.fr.stable.Nameable;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
/**
* 超级链接 界面.
@ -43,13 +44,13 @@ public class HyperlinkGroupPane extends JListControlPane {
for (int i = 0; i < templateArrayLisy.size(); i++) {
pluginCreators[i] = ((HyperlinkPluginAction) templateArrayLisy.get(i)).getHyperlinkCreator();
}
HyperlinkProvider[] providers = ExtraDesignClassManager.getInstance().getHyperlinkProvider();
Set<HyperlinkProvider> providers = ExtraDesignClassManager.getInstance().getArray(HyperlinkProvider.XML_TAG);
List<NameableCreator> creatorList = new ArrayList<NameableCreator>();
for (HyperlinkProvider provider : providers) {
NameableCreator nc = provider.createHyperlinkCreator();
creatorList.add(nc);
}
return (NameableCreator[]) ArrayUtils.addAll(creatorList.toArray(new NameableCreator[creatorList.size()]), ArrayUtils.addAll(creators, pluginCreators));
return ArrayUtils.addAll(creatorList.toArray(new NameableCreator[creatorList.size()]), ArrayUtils.addAll(creators, pluginCreators));
}
/**

2
designer_base/src/com/fr/design/gui/style/AlignmentPane.java

@ -95,7 +95,7 @@ public class AlignmentPane extends AbstractBasicStylePane implements GlobalNameO
initOtherComponent();
initAllNames();
indentationUnitProcessor = ExtraDesignClassManager.getInstance().getIndentationUnitEditor();
indentationUnitProcessor = ExtraDesignClassManager.getInstance().getSingle(IndentationUnitProcessor.MARK_STRING);
if (null == indentationUnitProcessor){
indentationUnitProcessor = new DefaultIndentationUnitProcessor();
}

3
designer_base/src/com/fr/design/gui/style/BackgroundPane.java

@ -15,6 +15,7 @@ import java.awt.*;
import java.awt.event.ItemEvent;
import java.awt.event.ItemListener;
import java.util.ArrayList;
import java.util.Set;
/**
* @author zhou
@ -68,7 +69,7 @@ public class BackgroundPane extends AbstractBasicStylePane {
kinds.add(new PatternBackgroundQuickPane());
kinds.add(new ImageBackgroundQuickPane());
kinds.add(new GradientBackgroundQuickPane());
BackgroundQuickUIProvider[] providers = ExtraDesignClassManager.getInstance().getBackgroundQuickUIProviders();
Set<BackgroundQuickUIProvider> providers = ExtraDesignClassManager.getInstance().getArray(BackgroundQuickUIProvider.MARK_STRING);
for (BackgroundQuickUIProvider provider : providers) {
kinds.add(provider.appearanceForBackground());

3
designer_base/src/com/fr/design/javascript/JavaScriptActionPane.java

@ -21,6 +21,7 @@ import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
public abstract class JavaScriptActionPane extends UIComboBoxPane<JavaScript> {
@ -52,7 +53,7 @@ public abstract class JavaScriptActionPane extends UIComboBoxPane<JavaScript> {
}
);
paneList.add(initEmaiPane());
List<JavaScriptActionProvider> javaScriptActionProviders = ExtraDesignClassManager.getInstance().getJavaScriptActionProvider();
Set<JavaScriptActionProvider> javaScriptActionProviders = ExtraDesignClassManager.getInstance().getArray(JavaScriptActionProvider.XML_TAG);
if (javaScriptActionProviders != null) {
for (JavaScriptActionProvider jsp : javaScriptActionProviders) {
paneList.add(jsp.getJavaScriptActionPane());

15
designer_base/src/com/fr/design/mainframe/AbstractAppProvider.java

@ -1,13 +1,26 @@
package com.fr.design.mainframe;
import com.fr.base.io.IOFile;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
/**
* Created by Administrator on 2016/3/17/0017.
*/
public abstract class AbstractAppProvider<T extends IOFile> implements App{
@API(level = App.CURRENT_LEVEL)
public abstract class AbstractAppProvider<T extends IOFile> extends AbstractProvider implements App{
public int currentAPILevel() {
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
@Override
public void process() {
DesignerFrame.registApp(this);
}
}

5
designer_base/src/com/fr/design/mainframe/App.java

@ -2,12 +2,13 @@ package com.fr.design.mainframe;
import com.fr.base.io.IOFile;
import com.fr.file.FILE;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.mark.Mutable;
import com.fr.stable.fun.mark.Aftermath;
/**
* Created by Administrator on 2016/3/17/0017.
*/
public interface App<T extends IOFile> extends Level{
public interface App<T extends IOFile> extends Mutable, Aftermath {
String MARK_STRING = "DesignerApp";

2
designer_base/src/com/fr/design/mainframe/DesignerFrame.java

@ -263,7 +263,7 @@ public class DesignerFrame extends JFrame implements JTemplateActionListener, Ta
GeneralContext.addPluginReadListener(new PluginReadListener() {
@Override
public void success() {
TitlePlaceProcessor processor = ExtraDesignClassManager.getInstance().getTitlePlaceProcessor();
TitlePlaceProcessor processor = ExtraDesignClassManager.getInstance().getSingle(TitlePlaceProcessor.MARK_STRING);
if (processor == null) {
processor = new DefaultTitlePlace();
}

3
designer_base/src/com/fr/design/mainframe/DesignerFrameFileDealerPane.java

@ -43,6 +43,7 @@ import java.awt.event.KeyEvent;
import java.io.File;
import java.util.HashMap;
import java.util.Map;
import java.util.Set;
public class DesignerFrameFileDealerPane extends JPanel implements FileToolbarStateChangeListener, ResponseDataSourceChange {
private static final String FILE = "file";
@ -127,7 +128,7 @@ public class DesignerFrameFileDealerPane extends JPanel implements FileToolbarSt
toolbarDef.addShortCut(openFolderAction, renameAction);
}
toolbarDef.addShortCut(delFileAction);
ShortCut[] extraShortCuts = ExtraDesignClassManager.getInstance().getTemplateTreeShortCutProviders();
Set<ShortCut> extraShortCuts = ExtraDesignClassManager.getInstance().getArray(ShortCut.TEMPLATE_TREE);
for (ShortCut shortCut : extraShortCuts){
toolbarDef.addShortCut(shortCut);
}

17
designer_base/src/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java

@ -55,9 +55,7 @@ import com.fr.stable.ProductConstants;
import javax.swing.*;
import java.awt.*;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Locale;
import java.util.*;
/**
* @author richer
@ -299,7 +297,7 @@ public abstract class ToolBarMenuDock {
}
private ShortCut createGlobalTDAction() {
TableDataPaneProcessor processor = ExtraDesignClassManager.getInstance().getTableDataPaneProcessor();
TableDataPaneProcessor processor = ExtraDesignClassManager.getInstance().getSingle(TableDataPaneProcessor.XML_TAG);
return processor == null ? new GlobalTableDataAction() : processor.createServerTDAction();
}
@ -528,8 +526,15 @@ public abstract class ToolBarMenuDock {
protected void insertMenu(MenuDef menuDef, String anchor, ShortCutMethodAction action) {
// 下面是插件接口接入点
MenuHandler[] menuHandlers = ExtraDesignClassManager.getInstance().getMenuHandlers(anchor);
for (MenuHandler handler : menuHandlers) {
Set<MenuHandler> set = ExtraDesignClassManager.getInstance().getArray(MenuHandler.MARK_STRING);
java.util.List<MenuHandler> target = new ArrayList<>();
for (MenuHandler handler : set) {
if (ComparatorUtils.equals(handler.category(), anchor)) {
target.add(handler);
}
}
for (MenuHandler handler : target) {
int insertPosition = handler.insertPosition(menuDef.getShortCutCount());
ShortCut shortCut = action.methodAction(handler);
if (shortCut == null){

16
designer_base/src/com/fr/design/menu/ShortCut.java

@ -1,16 +1,20 @@
package com.fr.design.menu;
import com.fr.stable.fun.Level;
import com.fr.stable.fun.impl.AbstractProvider;
import com.fr.stable.fun.mark.API;
import com.fr.stable.fun.mark.Mutable;
import javax.swing.JPopupMenu;
import javax.swing.JToolBar;
import javax.swing.*;
/**
* 用来往MenuDef或是ToolBarDef里面加东西时用的接口
* august:ShortCut没有必要序列化和XMLabled
* 原来那么多Menudef都提供持久化操作太浪费资源
*/
public abstract class ShortCut implements Level{
@API(level = ShortCut.CURRENT_LEVEL)
public abstract class ShortCut extends AbstractProvider implements Mutable {
public static final String TEMPLATE_TREE = "TemplateTreeShortCut";
public static final int CURRENT_LEVEL = 1;
@ -18,6 +22,10 @@ public abstract class ShortCut implements Level{
return CURRENT_LEVEL;
}
@Override
public String mark4Provider() {
return getClass().getName();
}
private MenuKeySet menuKeySet = null;

5
designer_base/src/com/fr/design/module/DesignModule.java

@ -22,6 +22,7 @@ import com.fr.stable.plugin.ExtraDesignClassManagerProvider;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
/**
* Created by IntelliJ IDEA.
@ -66,7 +67,7 @@ public abstract class DesignModule extends TopModule {
public Class<?>[] actionsForInsertCellElement() {
List<Class<?>> classes = new ArrayList<>();
ElementUIProvider[] providers = ExtraDesignClassManager.getInstance().getElementUIProviders();
Set<ElementUIProvider> providers = ExtraDesignClassManager.getInstance().getArray(ElementUIProvider.MARK_STRING);
for (ElementUIProvider provider : providers) {
classes.add(provider.actionForInsertCellElement());
}
@ -75,7 +76,7 @@ public abstract class DesignModule extends TopModule {
public Class<?>[] actionsForInsertFloatElement() {
List<Class<?>> classes = new ArrayList<>();
ElementUIProvider[] providers = ExtraDesignClassManager.getInstance().getElementUIProviders();
Set<ElementUIProvider> providers = ExtraDesignClassManager.getInstance().getArray(ElementUIProvider.MARK_STRING);
for (ElementUIProvider provider : providers) {
classes.add(provider.actionForInsertFloatElement());
}

4
designer_base/src/com/fr/design/style/background/BackgroundFactory.java

@ -3,6 +3,7 @@ package com.fr.design.style.background;
import com.fr.base.background.*;
import com.fr.design.ExtraDesignClassManager;
import com.fr.design.fun.BackgroundQuickUIProvider;
import com.fr.design.fun.BackgroundUIProvider;
import com.fr.design.style.background.gradient.GradientBackgroundPane;
import com.fr.design.style.background.impl.*;
@ -54,7 +55,8 @@ public class BackgroundFactory {
}
private static void registerExtra(Map<Class<? extends Background>, BackgroundUIWrapper> map) {
for (BackgroundUIProvider provider : ExtraDesignClassManager.getInstance().getBackgroundUIProviders()) {
Set<BackgroundUIProvider> set = ExtraDesignClassManager.getInstance().getArray(BackgroundUIProvider.MARK_STRING);
for (BackgroundUIProvider provider : set) {
map.put(provider.targetClass(), BackgroundUIWrapper.create()
.setType(provider.targetUIClass()).setTitle(provider.targetTitle()));
}

2
designer_base/src/com/fr/design/utils/DesignUtils.java

@ -324,7 +324,7 @@ public class DesignUtils {
private static String getWebBrowserPath() {
String urlPath = FRContext.getCurrentEnv().getPath();
DesignerEnvProcessor processor = ExtraDesignClassManager.getInstance().getEnvProcessor();
DesignerEnvProcessor processor = ExtraDesignClassManager.getInstance().getSingle(DesignerEnvProcessor.XML_TAG);
if (processor != null) {
//cas访问的时候, url要处理下.
urlPath = processor.getWebBrowserURL(urlPath);

2
designer_base/src/com/fr/env/RemoteEnv.java vendored

@ -388,7 +388,7 @@ public class RemoteEnv implements Env {
private void extraChangeEnvPara() {
//在env连接之前, 加载一下不依赖env的插件. 看看需不需要改变参数.
PluginLoader.init();
DesignerEnvProcessor envProcessor = ExtraDesignClassManager.getInstance().getEnvProcessor();
DesignerEnvProcessor envProcessor = ExtraDesignClassManager.getInstance().getSingle(DesignerEnvProcessor.XML_TAG);
if (envProcessor != null) {
this.path = envProcessor.changeEnvPathBeforeConnect(user, password, path);
}

9
designer_base/src/com/fr/start/BaseDesigner.java

@ -39,6 +39,7 @@ import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import java.io.File;
import java.lang.reflect.Method;
import java.util.Set;
/**
* The main class of Report Designer.
@ -113,11 +114,9 @@ public abstract class BaseDesigner extends ToolBarMenuDock {
}
private void bindGlobalListener() {
GlobalListenerProvider[] providers = ExtraDesignClassManager.getInstance().getGlobalListenerProvider();
if (ArrayUtils.isNotEmpty(providers)) {
for (GlobalListenerProvider provider : providers) {
Toolkit.getDefaultToolkit().addAWTEventListener(provider.listener(), AWTEvent.KEY_EVENT_MASK);
}
Set<GlobalListenerProvider> providers = ExtraDesignClassManager.getInstance().getArray(GlobalListenerProvider.XML_TAG);
for (GlobalListenerProvider provider : providers) {
Toolkit.getDefaultToolkit().addAWTEventListener(provider.listener(), AWTEvent.KEY_EVENT_MASK);
}
}

2
designer_form/src/com/fr/design/designer/creator/XElementCase.java

@ -86,7 +86,7 @@ public class XElementCase extends XBorderStyleWidgetCreator implements FormEleme
};
FormElementCaseEditorProcessor processor = ExtraDesignClassManager.getInstance().getPropertyTableEditor();
FormElementCaseEditorProcessor processor = ExtraDesignClassManager.getInstance().getSingle(FormElementCaseEditorProcessor.MARK_STRING);
if (processor == null) {
return propertyTableEditor;
}

5
designer_form/src/com/fr/design/mainframe/WidgetPropertyPane.java

@ -18,6 +18,7 @@ import javax.swing.*;
import java.awt.*;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
/**
* 控件属性表Docking
@ -120,8 +121,8 @@ public class WidgetPropertyPane extends FormDockView implements BaseWidgetProper
if (selection != null && selection.getSelectedCreator() != null) {
embeddedPropertyUIProviders = selection.getSelectedCreator().getWidgetPropertyUIProviders();
}
WidgetPropertyUIProvider[] widgetAttrProviders = ExtraDesignClassManager.getInstance().getWidgetAttrProviders();
widgetAttrProviders = (WidgetPropertyUIProvider[]) ArrayUtils.addAll(embeddedPropertyUIProviders, widgetAttrProviders);
Set<WidgetPropertyUIProvider> set = ExtraDesignClassManager.getInstance().getArray(WidgetPropertyUIProvider.XML_TAG);
WidgetPropertyUIProvider[] widgetAttrProviders = ArrayUtils.addAll(embeddedPropertyUIProviders, set.toArray(new WidgetPropertyUIProvider[set.size()]));
return widgetAttrProviders;
}

Loading…
Cancel
Save