* @param id component id to be replaced with the fragment content.
* @param objectTO connector object TO.
* @return fragment.
*/
private Fragment getStatusIcon(final String id, final ConnObjectTO objectTO) {
final Image image;
final String alt, title;
switch (statusUtils.getRemoteStatus(objectTO).getStatus()) {
case ACTIVE:
image = new Image("status", "statuses/active.png");
alt = "active icon";
title = "Enabled";
break;
case SUSPENDED:
image = new Image("status", "statuses/inactive.png");
alt = "inactive icon";
title = "Disabled";
break;
default:
image = null;
alt = null;
title = null;
}
final Fragment frag;
if (image != null) {
image.add(new Behavior() {
private static final long serialVersionUID = 1469628524240283489L;
@Override
public void onComponentTag(final Component component, final ComponentTag tag) {