Skip to content
Snippets Groups Projects
Commit bf2af0f5 authored by Tiziano Munaro's avatar Tiziano Munaro
Browse files

GREEN (with minor changes)


Issue-Ref: 4221
Issue-Url: af3#4221

Signed-off-by: default avatarTiziano Munaro <munaro@fortiss.org>
parent 438115f7
No related branches found
No related tags found
1 merge request!2024221: Add priority system to prototype categories including sorting
Pipeline #38413 failed
PrototypeProvider.java 211a74ae6a54cdc703fe293f839889ad01967453 YELLOW
PrototypeProvider.java 8396bb14c2ae9d820b822c43a9a9ab52cb8e8a93 GREEN
......@@ -61,12 +61,12 @@ public final class PrototypeProvider extends PrototypeProviderBase {
// Library categories should have a lower priority than standard prototype
// categories (like "Behavioral Specification" elements).
try {
setPrototypeCategory(categoryName, -10);
setPrototypeCategoryPriority(categoryName, -10);
} catch (IllegalArgumentException e) {
// only in case someone changes registerPrimaryPrototype()
// Only in case someone changes registerPrimaryPrototype().
error(getDefault(),
"Error during setting the category priority for the reuse library '" + categoryName + "'", e);
showError("Cannot set category priortiy for '" + categoryName + "'");
"Error setting the category priority for the reuse library '" + categoryName + "'.", e);
showError("Cannot set category priortiy for '" + categoryName + "'.");
}
EList<EObject> reuseElementList = library.getReuseElementList();
......
......@@ -3,6 +3,6 @@ ConstraintViolationBase.java ec66973ab2183623f0cd4a85c59c886dddad6cf6 GREEN
DialogMessage.java 8420640e999e4fb15fa644333e5d71e1d16c2559 GREEN
ElementCompositorBase.java 7a445e5adde11878fe0515baca8b915287149b28 GREEN
MultiViolationConstraintCheckerBase.java 30886a94c99cf8948f64401b1db821abe06e1e6c GREEN
PrototypeProviderBase.java 8052145154f8b3b15f45dc84d31afdea5560c716 YELLOW
PrototypeProviderBase.java 4625d5ed40d3bcadfc6dda3ed4cc1f3873a23307 GREEN
TransformationContextChainBase.java 1ef37880ab275778c563928e80ba378fec964cb6 GREEN
TransformationProviderBase.java 9e91100cc1f2c8fbd8d41af55aedfea34e02ff71 GREEN
......@@ -128,7 +128,7 @@ public abstract class PrototypeProviderBase implements IPrototypeProvider {
* {@link IllegalArgumentException} is thrown. Only needed if the category should be sorted
* based on the new priority and not by name.
*/
protected void setPrototypeCategory(String category, int priority)
protected void setPrototypeCategoryPriority(String category, int priority)
throws IllegalArgumentException {
PrototypeCategory cat = categories.get(category);
if(cat == null) {
......
......@@ -7,7 +7,7 @@ ElementCompositorService.java b1924b5b349118a70149cfac5b48544897d26e9e GREEN
LoggingService.java da784259f7b456b54bf75c41ec268f64919ce78d GREEN
MigrationService.java 017c8438262065f663427a998536035bc7732fe1 GREEN
PersistencyService.java f33993962d83b08df767da501cb11c14d37a7c19 GREEN
PrototypeService.java 565b62d0738ccff8ec3e856484fe7f1b7caee12f YELLOW
PrototypeService.java 4b82fd438f26fafaf225b35c734c2976b738e512 YELLOW
ToolingKernelInternal.java afbd2ccb5277ffdaa5e8d6b901dc10b61ef4a36d GREEN
TransformationService.java 64ee4fb5ccc623f8acfba20866fc2b0944c4adab GREEN
TutorialService.java 675d3f365ce062869f86baa3779d50687674bda0 GREEN
......@@ -276,7 +276,7 @@ public class PrototypeService implements IPrototypeService, IIntrospectiveKernel
* of identical priorities, is lexicographically AFTER category2). Otherwise, a positive integer
* is returned, except both categories have identical priorities AND identical names, in which
* case zero is returned.
* Note: the lexicographically order is reversed (<A,B> = "A greater than B" = positive int).
* Note: The lexicographical order is reversed (<A,B> = "A greater than B" = positive integer).
*/
static class PrototypeCategoryComparator implements Comparator<PrototypeCategory> {
......
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