}
@Managed
@ManagedOperation(name = OperationNames.UPDATE_RESOURCE, description = "Updates the navigation")
public ModelObject updateNavigation(@ManagedContext OperationContext context, @ManagedContext ModelObject navModel) {
ModelNumber priority = get(navModel, ModelNumber.class, "priority");
if (priority.isDefined()) {
navigation.setPriority(priority.getInt());
}
Node node = getNode(NodePath.root(), true, Nodes.visitChildren());
return populateNavigationModel(node, 0, context);
}