@Override
public boolean afterOthers(WebFragmentEntry entry) {
WebFragment webFragment = entry.getWebFragment();
if (webFragment.getOrdering() != null) {
OrderingOrdering after = webFragment.getOrdering().getAfter();
if (after != null) {
return after.getOthers() != null;
}
}
return false;
}
@Override
public boolean beforeOthers(WebFragmentEntry entry) {
WebFragment webFragment = entry.getWebFragment();
if (webFragment.getOrdering() != null) {
OrderingOrdering before = webFragment.getOrdering().getBefore();
if (before != null) {
return before.getOthers() != null;
}
}
return false;
}
@Override
public List<String> getAfterNames(WebFragmentEntry entry) {
WebFragment webFragment = entry.getWebFragment();
if (webFragment.getOrdering() != null) {
OrderingOrdering after = webFragment.getOrdering().getAfter();
if (after != null) {
return after.getName() == null ? Collections.<String> emptyList() : after.getName();
}
}
return Collections.emptyList();
}
@Override
public List<String> getBeforeNames(WebFragmentEntry entry) {
WebFragment webFragment = entry.getWebFragment();
if (webFragment.getOrdering() != null) {
OrderingOrdering before = webFragment.getOrdering().getBefore();
if (before != null) {
return before.getName() == null ? Collections.<String> emptyList() : before.getName();
}
}
return Collections.emptyList();
}