src/main/java/de/digitalcollections/iiif/model/sharedcanvas/Resource.java
public void setViewingHints(List<ViewingHint> viewingHints) throws IllegalArgumentException {
    for (ViewingHint hint : viewingHints) {
      boolean supportsHint = (hint.getType() == ViewingHint.Type.OTHER
                              || this.getSupportedViewingHintTypes().contains(hint.getType()));
      if (!supportsHint) {
        throw new IllegalArgumentException(String.format(
            "Resources of type '%s' do not support the '%s' viewing hint.",
            this.getType(), hint.toString()));
      }
    }
    this.viewingHints = viewingHints;
  }
public void setViewingHints(List<ViewingHint> viewingHints) throws IllegalArgumentException {
    for (ViewingHint hint : viewingHints) {
      boolean supportsHint = (hint.getType() == ViewingHint.Type.OTHER
                              || this.getSupportedViewingHintTypes().contains(hint.getType()));
      if (!supportsHint) {
        throw new IllegalArgumentException(String.format(
            "Resources of type '%s' do not support the '%s' viewing hint.",
            this.getType(), hint.toString()));
      }
    }
    this.viewingHints = viewingHints;
  }
public void setViewingHints ( List < ViewingHint > viewingHints ) throws IllegalArgumentException { for ( ViewingHint hint : viewingHints ) { boolean supportsHint = ( hint . getType ( ) == ViewingHint . Type . OTHER || this . getSupportedViewingHintTypes ( ) . contains ( hint . getType ( ) ) ) ; if ( ! supportsHint ) { throw new IllegalArgumentException ( String . format ( "Resources of type '%s' do not support the '%s' viewing hint." , this . getType ( ) , hint . toString ( ) ) ) ; } } this . viewingHints = viewingHints ; }
Set the viewing hints for this resource.

@param viewingHints list of viewing hints
@throws IllegalArgumentException if the resources not not support one of the viewing hints.
Set the viewing hints for this resource .