Example #1
0
 public static Dataset toDataset(INavigationElement<?> element) {
   CategorizedDescriptor descriptor = null;
   if (element instanceof CategoryElement) {
     descriptor = Descriptors.toDescriptor(((CategoryElement) element).getContent());
   } else if (element instanceof ModelElement) descriptor = ((ModelElement) element).getContent();
   if (descriptor == null) return null;
   Category category = null;
   if (element.getParent() instanceof CategoryElement)
     category = ((CategoryElement) element.getParent()).getContent();
   return toDataset(descriptor, category);
 }
Example #2
0
 public static void closeEditor(CategorizedEntity entity) {
   BaseDescriptor descriptor = Descriptors.toDescriptor(entity);
   closeEditor(descriptor);
 }
Example #3
0
 public static void openEditor(CategorizedEntity model) {
   openEditor(Descriptors.toDescriptor(model));
 }
Example #4
0
 public static String getFullPath(Category category) {
   return getFullPath(Descriptors.toDescriptor(category), category.getCategory());
 }
Example #5
0
 public static Dataset toDataset(CategorizedEntity entity) {
   CategorizedDescriptor descriptor = Descriptors.toDescriptor(entity);
   Category category = entity.getCategory();
   return toDataset(descriptor, category);
 }