use of org.eclipse.scout.rt.platform.Order in project scout.rt by eclipse.
the class AbstractComposerField method execResolveAttributePath.
/**
* see {@link #execResolveEntityPathForEntityExport(EntityNode)}, {@link AttributePath} for more details
* <p>
* The path in the composer tree is prefixed with
* {@link #interceptResolveRootPathForTopLevelAttribute(IDataModelAttribute, List)}
*/
@ConfigOperation
@Order(99)
protected AttributePath execResolveAttributePath(AttributeNode node) {
LinkedList<IDataModelEntity> list = new LinkedList<IDataModelEntity>();
if (node == null) {
return null;
}
EntityNode tmp = node.getAncestorNode(EntityNode.class);
while (tmp != null) {
if (tmp.getEntity() != null) {
list.add(0, tmp.getEntity());
}
// next
tmp = tmp.getAncestorNode(EntityNode.class);
}
if (list.size() > 0) {
interceptResolveRootPathForTopLevelEntity(list.get(0), list);
} else {
interceptResolveRootPathForTopLevelAttribute(node.getAttribute(), list);
}
return new AttributePath(list, node.getAttribute());
}
use of org.eclipse.scout.rt.platform.Order in project scout.rt by eclipse.
the class AbstractClipboardField method execDropRequest.
@ConfigOperation
@Order(80)
protected void execDropRequest(TransferObject transferObject) {
if (transferObject instanceof ResourceListTransferObject) {
ResourceListTransferObject resourceListTransferObject = (ResourceListTransferObject) transferObject;
setValue(resourceListTransferObject.getResources());
}
}
use of org.eclipse.scout.rt.platform.Order in project scout.rt by eclipse.
the class AbstractWizardStep method calculateViewOrder.
/**
* Calculates the column's view order, e.g. if the @Order annotation is set to 30.0, the method will return 30.0. If
* no {@link Order} annotation is set, the method checks its super classes for an @Order annotation.
*
* @since 3.10.0-M4
*/
@SuppressWarnings("squid:S1244")
protected double calculateViewOrder() {
double viewOrder = getConfiguredViewOrder();
Class<?> cls = getClass();
if (viewOrder == IOrdered.DEFAULT_ORDER) {
while (cls != null && IWizardStep.class.isAssignableFrom(cls)) {
if (cls.isAnnotationPresent(Order.class)) {
Order order = (Order) cls.getAnnotation(Order.class);
return order.value();
}
cls = cls.getSuperclass();
}
}
return viewOrder;
}
use of org.eclipse.scout.rt.platform.Order in project scout.rt by eclipse.
the class AbstractDataModelAttribute method calculateViewOrder.
/**
* Calculates the column's view order, e.g. if the @Order annotation is set to 30.0, the method will return 30.0. If
* no {@link Order} annotation is set, the method checks its super classes for an @Order annotation.
*
* @since 3.10.0-M4
*/
@SuppressWarnings("squid:S1244")
protected double calculateViewOrder() {
double viewOrder = getConfiguredViewOrder();
Class<?> cls = getClass();
if (viewOrder == IOrdered.DEFAULT_ORDER) {
while (cls != null && IDataModelAttribute.class.isAssignableFrom(cls)) {
if (cls.isAnnotationPresent(Order.class)) {
Order order = (Order) cls.getAnnotation(Order.class);
return order.value();
}
cls = cls.getSuperclass();
}
}
return viewOrder;
}
use of org.eclipse.scout.rt.platform.Order in project scout.rt by eclipse.
the class AbstractListBox method execLoadTableData.
@ConfigOperation
@Order(230)
protected List<? extends ILookupRow<KEY>> execLoadTableData() {
List<? extends ILookupRow<KEY>> data;
// (1) get data by service
if (getLookupCall() != null) {
ILookupCall<KEY> call = BEANS.get(ILookupCallProvisioningService.class).newClonedInstance(getLookupCall(), new FormFieldProvisioningContext(AbstractListBox.this));
prepareLookupCall(call);
data = call.getDataByAll();
data = filterLookupResult(call, data);
} else // (b) get data direct
{
data = filterLookupResult(null, null);
}
return data;
}
Aggregations