/** Create the immutable {@link Request} object. */
public Request build() {
if (centerInside && centerCrop) {
throw new IllegalStateException("Center crop and center inside can not be used together.");
}
if (centerCrop && targetWidth == 0) {
throw new IllegalStateException("Center crop requires calling resize.");
}
if (centerInside && targetWidth == 0) {
throw new IllegalStateException("Center inside requires calling resize.");
}
if (priority == null) {
priority = Priority.NORMAL;
}
return new Request(uri, resourceId, transformations, targetWidth, targetHeight, centerCrop,
centerInside, rotationDegrees, rotationPivotX, rotationPivotY, hasRotationPivot, config,
priority);
}
Request.java 文件源码
java
阅读 34
收藏 0
点赞 0
评论 0
项目:picasso
作者:
评论列表
文章目录