public class VKPhotoSizes extends VKList<VKApiPhotoSize> implements android.os.Parcelable
photo_sizes=1 parameter is used in methods,
response contains an info about original photo
copies with different sizes in sizes array with objects,
each of them contains following fields: VKList.Parser<D>, VKList.ReflectParser<D extends VKApiModel>| Modifier and Type | Field and Description |
|---|---|
static android.os.Parcelable.Creator<VKPhotoSizes> |
CREATOR |
fields| Constructor and Description |
|---|
VKPhotoSizes()
Creates empty list of photo sizes.
|
VKPhotoSizes(org.json.JSONArray from)
Creates and fills list of photo sizes.
|
| Modifier and Type | Method and Description |
|---|---|
int |
describeContents() |
void |
fill(org.json.JSONArray from)
Fill list according with given data.
|
void |
fill(org.json.JSONArray from,
int width,
int height)
Creates list of photo sizes which fill with according data.
|
java.lang.String |
getByType(char type)
Return image according with given type of thumb.
|
java.lang.String |
getImageForDimension(int width,
int height)
Finds an image that fits perfectly into the specified dimensions.
|
void |
setOriginalDimension(int width,
int height)
Sets original image dimensions.
|
static void |
setQuality(float quality)
Sets the quality modifier for sampling algorithm of image resolution.
|
void |
sort()
Sorts thumbs according to their width.
|
void |
writeToParcel(android.os.Parcel dest,
int flags) |
add, add, addAfter, addAll, addAll, addBefore, clear, contains, containsAll, equals, fill, fill, fill, fill, get, getById, getCount, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, parse, remove, remove, removeAll, retainAll, search, set, size, subList, toArray, toArraygetTag, getTag, setTag, setTagpublic static android.os.Parcelable.Creator<VKPhotoSizes> CREATOR
public VKPhotoSizes()
public VKPhotoSizes(org.json.JSONArray from)
public static void setQuality(float quality)
quality - positive number between 0.0f and 1.0f.public void fill(org.json.JSONArray from,
int width,
int height)
from - array of photo sizes returned by VK.width - original photo width in pixels.height - original photo height in pixels.public void fill(org.json.JSONArray from)
from - array of photo sizes returned by VK.public java.lang.String getByType(char type)
public void setOriginalDimension(int width,
int height)
width - original photo width in pixels.height - original photo height in pixels.public void sort()
public java.lang.String getImageForDimension(int width,
int height)
width - required minimum width of image in pixels.height - required minimum height of image in pixels.public int describeContents()
describeContents in interface android.os.ParcelabledescribeContents in class VKList<VKApiPhotoSize>public void writeToParcel(android.os.Parcel dest,
int flags)
writeToParcel in interface android.os.ParcelablewriteToParcel in class VKList<VKApiPhotoSize>