Skip to content
Snippets Groups Projects
Commit 49aefc4d authored by Simon Barner's avatar Simon Barner
Browse files

GREEN

parent 76a45425
No related branches found
No related tags found
1 merge request!863907
......@@ -3,7 +3,7 @@ IContextMenuContributor.java 0f09c76662c154cf52ddab61b417e82a42854162 GREEN
IContextMenuMultiSelectionContributor.java 125b31dd38009bc2095b7e6bc860e946e39f58c4 GREEN
IEditPartFactory.java 5729715847f553d95a5bad4a9211c7e6f458badd GREEN
IModelEditor.java 962d7f7758abc88bbc6064c8b4eb32da00abf8e8 GREEN
IModelEditorBinding.java 844865d93252b6c4a648c23ff28bb28fd42c17aa YELLOW
IModelEditorBinding.java 844865d93252b6c4a648c23ff28bb28fd42c17aa GREEN
IModelElementHandler.java 86a8ec88b9679bbe7f53cfa8d1592bd862873f80 GREEN
ITutorialStepUI.java b8aee2b95857484ab6ad9ecd55b5de9f0ea158e5 GREEN
ITutorialUIProvider.java aa0ff5db4d7ba0953e34edeb99f3e8279567e18f GREEN
......
......@@ -7,7 +7,7 @@ EditorBase.java 9c09fff92945256bb8680992ae7bb2c78f47b150 GREEN
FXEditorBase.java 545085c3270f09d69b609f328792e904ebda23ff GREEN
IListPropertySection.java 8bb00fe7959583e794ff9437b7a77404c9a9e70f GREEN
LWFXEFEditorBase.java f6b160b700a0287021402b5702beb2bfdce3dc2e GREEN
ModelEditorBindingBase.java b9b1a1c5a48a6e677d1f57ad55a6126d9703c4b5 YELLOW
ModelEditorBindingBase.java b9b1a1c5a48a6e677d1f57ad55a6126d9703c4b5 GREEN
ModelElementHandlerBase.java d08583ffdf78938a14caeb46124eda4ce5cac3e4 GREEN
MultiEObjectActionBase.java 9e237d8ea640c4194e4877af4a9cfce88698e543 GREEN
NamedCommentedModelElementHandlerBase.java 681b98b50b362f01abb7a36f108f4f11b9e51829 GREEN
......
DelegatingControllerFactory.java be19395684645d79d892e5caed079d4b7f5cb5b0 YELLOW
DelegatingControllerFactory.java 50b2a5057794d6df22649e267d282ca3aa16797c GREEN
DelegatingFactoryBase.java f421742267610f41bb6196346026d2f239d90ed0 GREEN
DelegatingModelFactory.java f94ca989a5b97ad3f073040bb46b9c0a87e35d6d YELLOW
DelegatingVisualFactory.java 8bb82e9d48b2577655e577e7e807629c6fd6f2db YELLOW
DelegatingModelFactory.java 09919cf0cdd95ce500ffc1083899d29b89efb5b2 GREEN
DelegatingVisualFactory.java 17bd4a6bbd3b9f9f8f9104d8cd9b239ef4bac759 GREEN
......@@ -28,9 +28,10 @@ import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.ILinkMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IMVCBundle;
/**
* Delegates the creational calls to concrete {@link IControllerFactory}s. The first non-null
* element returned by the factories of the initially given list is returned. If no element is
* created (all delegates returned null), this factory throws a {@link RuntimeException}.
* Delegates the creational calls to concrete {@link IControllerFactory}s. The first
* non-{@code null} element returned by the factories of the initially given list is returned. If no
* element is created (all delegates returned {@code null}), this factory throws a
* {@link RuntimeException}.
*
* @author hoelzl
* @author diewald
......
......@@ -15,6 +15,7 @@
+--------------------------------------------------------------------------*/
package org.fortiss.tooling.kernel.ui.extension.base.factory;
import static java.util.Optional.empty;
import static java.util.stream.Collectors.toList;
import static org.apache.commons.lang3.reflect.ConstructorUtils.getMatchingAccessibleConstructor;
import static org.conqat.lib.commons.collections.CollectionUtils.isNullOrEmpty;
......@@ -32,9 +33,9 @@ import org.fortiss.tooling.common.ui.javafx.lwfxef.model.IModelFactory;
import org.fortiss.tooling.kernel.ui.ToolingKernelUIActivator;
/**
* Delegates the creational and getter calls to concrete {@link IModelFactory}s. The first non-null
* element returned by the factories of the initially given list is returned. If no element is
* created (all delegates returned null), this factory also returns null.
* Delegates the creational and getter calls to concrete {@link IModelFactory}s. The first
* non-{@code null} element returned by the factories of the initially given list is returned. If no
* element is created (all delegates returned {@code null}), this factory also returns {@code null}.
* <p>
* Only the root model must be identical for all delegate factories. Hence, the root element of the
* first delegate is returned.
......@@ -65,7 +66,7 @@ public class DelegatingModelFactory extends DelegatingFactoryBase<IModelFactory>
InvocationTargetException e) {
error(ToolingKernelUIActivator.getDefault(), "Failed to instantiate the factory " +
delegateFactory.getSimpleName() + ".");
return Optional.empty();
return empty();
}
} catch(NullPointerException | SecurityException e1) {
error(ToolingKernelUIActivator.getDefault(), "The factory " +
......@@ -73,7 +74,7 @@ public class DelegatingModelFactory extends DelegatingFactoryBase<IModelFactory>
" is missing a single argument Constructor accepting the edited model." +
" Only such constructors are allowed for " +
IModelFactory.class.getSimpleName() + "s.");
return Optional.empty();
return empty();
}
}
......
......@@ -32,9 +32,9 @@ import org.fortiss.tooling.kernel.ui.extension.base.LWFXEFEditorBase;
/**
* Base class for {@link IVisualFactory}s of extendable {@link LWFXEFEditorBase}
* {@link IEditorPart}s.The first non-null element returned by the factories of the initially given
* list is returned. If no element is
* created (all delegates returned null), this factory also returns null.
* {@link IEditorPart}s.The first non-{@code null} element returned by the factories of the
* initially given list is returned. If no element is created (all delegates returned null), this
* factory also returns {@code null}.
* <P>
* This class uses the {@link ITransformationService} to find a delegate visual factory for the
* model elements in question.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment