package com.epson.cameracopy.device;

import android.hardware.Camera;
import java.util.Iterator;
import java.util.List;

public class CameraSizeList implements Iterable<SizeWrapper> {
    List<Camera.Size> mCameraSizeList;

    public static class CameraSizeWarpper implements SizeWrapper {
        static final /* synthetic */ boolean $assertionsDisabled = false;
        Camera.Size mCameraSize;

        static {
            Class<CameraSizeList> cls = CameraSizeList.class;
        }

        public CameraSizeWarpper(Camera.Size size) {
            this.mCameraSize = size;
        }

        public int getWidth() {
            return this.mCameraSize.width;
        }

        public int getHeight() {
            return this.mCameraSize.height;
        }
    }

    public CameraSizeList(List<Camera.Size> list) {
        this.mCameraSizeList = list;
    }

    public Iterator<SizeWrapper> iterator() {
        return new Iterator<SizeWrapper>() {
            int mIndex = 0;

            public void remove() {
            }

            public boolean hasNext() {
                return this.mIndex < CameraSizeList.this.mCameraSizeList.size();
            }

            public SizeWrapper next() {
                if (this.mIndex >= CameraSizeList.this.mCameraSizeList.size()) {
                    return null;
                }
                this.mIndex++;
                return new CameraSizeWarpper(CameraSizeList.this.mCameraSizeList.get(this.mIndex));
            }
        };
    }
}
