Class ImageApiProfile
- java.lang.Object
-
- de.digitalcollections.iiif.model.Profile
-
- de.digitalcollections.iiif.model.image.ImageApiProfile
-
public class ImageApiProfile extends Profile
An Image API profile.Can be either a simple pre-defined profile (e.g.
LEVEL_ZERO) or a complex profile describing the available features of a given IIIF image.See http://iiif.io/api/image/2.1/#profile-description for an overview of all available properties and features and http://iiif.io/api/image/2.1/compliance/ for an overview of the available compliance levels.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImageApiProfile.Featurestatic classImageApiProfile.Formatstatic classImageApiProfile.Quality
-
Field Summary
Fields Modifier and Type Field Description static StringCONTEXTstatic ImageApiProfileLEVEL_ONEstatic ImageApiProfileLEVEL_TWOstatic ImageApiProfileLEVEL_ZEROstatic StringTYPEstatic Set<String>V1_PROFILES
-
Constructor Summary
Constructors Constructor Description ImageApiProfile()
-
Method Summary
-
Methods inherited from class de.digitalcollections.iiif.model.Profile
getIdentifier
-
-
-
-
Field Detail
-
LEVEL_ZERO
public static final ImageApiProfile LEVEL_ZERO
-
LEVEL_ONE
public static final ImageApiProfile LEVEL_ONE
-
LEVEL_TWO
public static final ImageApiProfile LEVEL_TWO
-
CONTEXT
public static final String CONTEXT
- See Also:
- Constant Field Values
-
TYPE
public static final String TYPE
- See Also:
- Constant Field Values
-
-
Method Detail
-
fromUrl
public static ImageApiProfile fromUrl(String url)
-
getFormats
public Set<ImageApiProfile.Format> getFormats()
-
setFormats
public void setFormats(Set<ImageApiProfile.Format> formats)
-
addFormat
public ImageApiProfile addFormat(ImageApiProfile.Format first, ImageApiProfile.Format... rest)
-
getQualities
public Set<ImageApiProfile.Quality> getQualities()
-
setQualities
public void setQualities(Set<ImageApiProfile.Quality> qualities)
-
addQuality
public ImageApiProfile addQuality(ImageApiProfile.Quality first, ImageApiProfile.Quality... rest)
-
getFeatures
public Set<ImageApiProfile.Feature> getFeatures()
-
setFeatures
public void setFeatures(Set<ImageApiProfile.Feature> features)
-
addFeature
public ImageApiProfile addFeature(ImageApiProfile.Feature first, ImageApiProfile.Feature... rest)
-
getMaxArea
public Long getMaxArea()
-
setMaxArea
public void setMaxArea(Long maxArea)
-
getMaxHeight
public Integer getMaxHeight()
-
setMaxHeight
public void setMaxHeight(Integer maxHeight)
-
getMaxWidth
public Integer getMaxWidth()
-
setMaxWidth
public void setMaxWidth(Integer maxWidth)
-
merge
public static ImageApiProfile merge(List<Profile> profiles)
Merge multiple profiles into one. Useful for image servers that want to consolidate the limits given in a info.json.- Parameters:
profiles- profiles to be merged- Returns:
- merged profile
-
merge
public ImageApiProfile merge(ImageApiProfile other)
Merge two profiles.- Parameters:
other- profile to be merged- Returns:
- merged profile
-
-