code: private void validateIntent() {
      if (entityMetadata.isProjectedEntity() && !intent.isValidOnProjectedEntities()) {
        String message = String.format("Operation %s is not allowed for ProjectedEntity %s", intent,
            entity.getClass().getName());
        throw new EntityManagerException(message);
      }
    }
docs: Validates if the Intent is legal for the entity being marshalled.
  
  @throws EntityManagerException
  if the Intent is not valid for the entity being marshalled