code: public ModelNode resolveModelAttribute(final ExpressionResolver resolver, final ModelNode model) throws OperationFailedException {
          final ModelNode node = new ModelNode();
          if(model.has(name)) {
              node.set(model.get(name));
          }
          return resolveValue(resolver, node);
      }
docs: Finds a value in the given {@code model} whose key matches this attribute's {@link #getName() name},
  uses the given {@code resolver} to {@link ExpressionResolver#resolveExpressions(org.jboss.dmr.ModelNode)} resolve}
  it and validates it using this attribute's {@link #getValidator() validator}. If the value is
  undefined and a {@link #getDefaultValue() default value} is available, the default value is used.
  
  @param resolver the expression resolver
  @param model model node of type {@link ModelType#OBJECT}, typically representing a model resource
  
  @return the resolved value, possibly the default value if the model does not have a defined value matching
  this attribute's name
  @throws OperationFailedException if the value is not valid