Search in sources :

Example 1 with ScreenSectionItems

use of org.applause.lang.applauseDsl.ScreenSectionItems in project applause by applause.

the class DefaultListScreenClassExtensions method configurations.

public Iterable<UIComponentMemberConfiguration> configurations(final Screen it) {
    EList<ScreenSection> _sections = it.getSections();
    final Function1<ScreenSection, ScreenSectionItems> _function = new Function1<ScreenSection, ScreenSectionItems>() {

        public ScreenSectionItems apply(final ScreenSection it) {
            ScreenSectionItems _items = it.getItems();
            return _items;
        }
    };
    List<ScreenSectionItems> _map = ListExtensions.<ScreenSection, ScreenSectionItems>map(_sections, _function);
    final Function1<ScreenSectionItems, EList<ScreenListItemCell>> _function_1 = new Function1<ScreenSectionItems, EList<ScreenListItemCell>>() {

        public EList<ScreenListItemCell> apply(final ScreenSectionItems it) {
            EList<ScreenListItemCell> _items = it.getItems();
            return _items;
        }
    };
    List<EList<ScreenListItemCell>> _map_1 = ListExtensions.<ScreenSectionItems, EList<ScreenListItemCell>>map(_map, _function_1);
    Iterable<ScreenListItemCell> _flatten = Iterables.<ScreenListItemCell>concat(_map_1);
    final Function1<ScreenListItemCell, EList<UIComponentMemberConfiguration>> _function_2 = new Function1<ScreenListItemCell, EList<UIComponentMemberConfiguration>>() {

        public EList<UIComponentMemberConfiguration> apply(final ScreenListItemCell it) {
            EList<UIComponentMemberConfiguration> _configurations = it.getConfigurations();
            return _configurations;
        }
    };
    Iterable<EList<UIComponentMemberConfiguration>> _map_2 = IterableExtensions.<ScreenListItemCell, EList<UIComponentMemberConfiguration>>map(_flatten, _function_2);
    Iterable<UIComponentMemberConfiguration> _flatten_1 = Iterables.<UIComponentMemberConfiguration>concat(_map_2);
    return _flatten_1;
}
Also used : ScreenListItemCell(org.applause.lang.applauseDsl.ScreenListItemCell) Function1(org.eclipse.xtext.xbase.lib.Functions.Function1) ScreenSectionItems(org.applause.lang.applauseDsl.ScreenSectionItems) ScreenSection(org.applause.lang.applauseDsl.ScreenSection) EList(org.eclipse.emf.common.util.EList) UIComponentMemberConfiguration(org.applause.lang.applauseDsl.UIComponentMemberConfiguration)

Example 2 with ScreenSectionItems

use of org.applause.lang.applauseDsl.ScreenSectionItems in project applause by applause.

the class DefaultListScreenClassExtensions method defaultCell.

public ScreenListItemCell defaultCell(final Screen it) {
    EList<ScreenSection> _sections = it.getSections();
    final Function1<ScreenSection, ScreenSectionItems> _function = new Function1<ScreenSection, ScreenSectionItems>() {

        public ScreenSectionItems apply(final ScreenSection it) {
            ScreenSectionItems _items = it.getItems();
            return _items;
        }
    };
    List<ScreenSectionItems> _map = ListExtensions.<ScreenSection, ScreenSectionItems>map(_sections, _function);
    final Function1<ScreenSectionItems, EList<ScreenListItemCell>> _function_1 = new Function1<ScreenSectionItems, EList<ScreenListItemCell>>() {

        public EList<ScreenListItemCell> apply(final ScreenSectionItems it) {
            EList<ScreenListItemCell> _items = it.getItems();
            return _items;
        }
    };
    List<EList<ScreenListItemCell>> _map_1 = ListExtensions.<ScreenSectionItems, EList<ScreenListItemCell>>map(_map, _function_1);
    Iterable<ScreenListItemCell> _flatten = Iterables.<ScreenListItemCell>concat(_map_1);
    ScreenListItemCell _head = IterableExtensions.<ScreenListItemCell>head(_flatten);
    return _head;
}
Also used : ScreenSection(org.applause.lang.applauseDsl.ScreenSection) ScreenListItemCell(org.applause.lang.applauseDsl.ScreenListItemCell) EList(org.eclipse.emf.common.util.EList) Function1(org.eclipse.xtext.xbase.lib.Functions.Function1) ScreenSectionItems(org.applause.lang.applauseDsl.ScreenSectionItems)

Example 3 with ScreenSectionItems

use of org.applause.lang.applauseDsl.ScreenSectionItems in project applause by applause.

the class DefaultDetailsScreenModuleFileCompiler method cells.

public Iterable<ScreenListItemCell> cells(final Screen it) {
    EList<ScreenSection> _sections = it.getSections();
    final Function1<ScreenSection, ScreenSectionItems> _function = new Function1<ScreenSection, ScreenSectionItems>() {

        public ScreenSectionItems apply(final ScreenSection it) {
            ScreenSectionItems _items = it.getItems();
            return _items;
        }
    };
    List<ScreenSectionItems> _map = ListExtensions.<ScreenSection, ScreenSectionItems>map(_sections, _function);
    final Function1<ScreenSectionItems, EList<ScreenListItemCell>> _function_1 = new Function1<ScreenSectionItems, EList<ScreenListItemCell>>() {

        public EList<ScreenListItemCell> apply(final ScreenSectionItems it) {
            EList<ScreenListItemCell> _items = it.getItems();
            return _items;
        }
    };
    List<EList<ScreenListItemCell>> _map_1 = ListExtensions.<ScreenSectionItems, EList<ScreenListItemCell>>map(_map, _function_1);
    Iterable<ScreenListItemCell> _flatten = Iterables.<ScreenListItemCell>concat(_map_1);
    return _flatten;
}
Also used : ScreenSection(org.applause.lang.applauseDsl.ScreenSection) ScreenListItemCell(org.applause.lang.applauseDsl.ScreenListItemCell) EList(org.eclipse.emf.common.util.EList) Function1(org.eclipse.xtext.xbase.lib.Functions.Function1) ScreenSectionItems(org.applause.lang.applauseDsl.ScreenSectionItems)

Example 4 with ScreenSectionItems

use of org.applause.lang.applauseDsl.ScreenSectionItems in project applause by applause.

the class DefaultDetailsScreenModuleFileCompiler method configurations.

public Iterable<UIComponentMemberConfiguration> configurations(final Screen it) {
    EList<ScreenSection> _sections = it.getSections();
    final Function1<ScreenSection, ScreenSectionItems> _function = new Function1<ScreenSection, ScreenSectionItems>() {

        public ScreenSectionItems apply(final ScreenSection it) {
            ScreenSectionItems _items = it.getItems();
            return _items;
        }
    };
    List<ScreenSectionItems> _map = ListExtensions.<ScreenSection, ScreenSectionItems>map(_sections, _function);
    final Function1<ScreenSectionItems, EList<ScreenListItemCell>> _function_1 = new Function1<ScreenSectionItems, EList<ScreenListItemCell>>() {

        public EList<ScreenListItemCell> apply(final ScreenSectionItems it) {
            EList<ScreenListItemCell> _items = it.getItems();
            return _items;
        }
    };
    List<EList<ScreenListItemCell>> _map_1 = ListExtensions.<ScreenSectionItems, EList<ScreenListItemCell>>map(_map, _function_1);
    Iterable<ScreenListItemCell> _flatten = Iterables.<ScreenListItemCell>concat(_map_1);
    final Function1<ScreenListItemCell, EList<UIComponentMemberConfiguration>> _function_2 = new Function1<ScreenListItemCell, EList<UIComponentMemberConfiguration>>() {

        public EList<UIComponentMemberConfiguration> apply(final ScreenListItemCell it) {
            EList<UIComponentMemberConfiguration> _configurations = it.getConfigurations();
            return _configurations;
        }
    };
    Iterable<EList<UIComponentMemberConfiguration>> _map_2 = IterableExtensions.<ScreenListItemCell, EList<UIComponentMemberConfiguration>>map(_flatten, _function_2);
    Iterable<UIComponentMemberConfiguration> _flatten_1 = Iterables.<UIComponentMemberConfiguration>concat(_map_2);
    return _flatten_1;
}
Also used : ScreenListItemCell(org.applause.lang.applauseDsl.ScreenListItemCell) Function1(org.eclipse.xtext.xbase.lib.Functions.Function1) ScreenSectionItems(org.applause.lang.applauseDsl.ScreenSectionItems) ScreenSection(org.applause.lang.applauseDsl.ScreenSection) EList(org.eclipse.emf.common.util.EList) UIComponentMemberConfiguration(org.applause.lang.applauseDsl.UIComponentMemberConfiguration)

Example 5 with ScreenSectionItems

use of org.applause.lang.applauseDsl.ScreenSectionItems in project applause by applause.

the class DefaultDetailsScreenModuleFileCompiler method defaultCell.

public ScreenListItemCell defaultCell(final Screen it) {
    EList<ScreenSection> _sections = it.getSections();
    final Function1<ScreenSection, ScreenSectionItems> _function = new Function1<ScreenSection, ScreenSectionItems>() {

        public ScreenSectionItems apply(final ScreenSection it) {
            ScreenSectionItems _items = it.getItems();
            return _items;
        }
    };
    List<ScreenSectionItems> _map = ListExtensions.<ScreenSection, ScreenSectionItems>map(_sections, _function);
    final Function1<ScreenSectionItems, EList<ScreenListItemCell>> _function_1 = new Function1<ScreenSectionItems, EList<ScreenListItemCell>>() {

        public EList<ScreenListItemCell> apply(final ScreenSectionItems it) {
            EList<ScreenListItemCell> _items = it.getItems();
            return _items;
        }
    };
    List<EList<ScreenListItemCell>> _map_1 = ListExtensions.<ScreenSectionItems, EList<ScreenListItemCell>>map(_map, _function_1);
    Iterable<ScreenListItemCell> _flatten = Iterables.<ScreenListItemCell>concat(_map_1);
    ScreenListItemCell _head = IterableExtensions.<ScreenListItemCell>head(_flatten);
    return _head;
}
Also used : ScreenSection(org.applause.lang.applauseDsl.ScreenSection) ScreenListItemCell(org.applause.lang.applauseDsl.ScreenListItemCell) EList(org.eclipse.emf.common.util.EList) Function1(org.eclipse.xtext.xbase.lib.Functions.Function1) ScreenSectionItems(org.applause.lang.applauseDsl.ScreenSectionItems)

Aggregations

ScreenSectionItems (org.applause.lang.applauseDsl.ScreenSectionItems)6 ScreenListItemCell (org.applause.lang.applauseDsl.ScreenListItemCell)5 ScreenSection (org.applause.lang.applauseDsl.ScreenSection)5 EList (org.eclipse.emf.common.util.EList)5 Function1 (org.eclipse.xtext.xbase.lib.Functions.Function1)5 UIComponentMemberConfiguration (org.applause.lang.applauseDsl.UIComponentMemberConfiguration)2 ENotificationImpl (org.eclipse.emf.ecore.impl.ENotificationImpl)1