Here you can find the source of getBufferedImageType(String encodeType)
public static int getBufferedImageType(String encodeType)
//package com.java2s; /*/*from w w w . ja va 2s. com*/ * Copyright 2000-2013 Enonic AS * http://www.enonic.com/license */ import java.awt.image.BufferedImage; public class Main { public static int getBufferedImageType(String encodeType) { if (encodeType.equals("png")) { return BufferedImage.TYPE_INT_ARGB; } else { return BufferedImage.TYPE_INT_RGB; } } }