int i = 0;
i = 0;
	public int setFileName(String pathInfoFileName) throws GalleryException	{		String s = pathInfoFileName.startsWith("/") ? pathInfoFileName				.substring(1) : pathInfoFileName;		String s1;		int n = 0;		if (s.startsWith("index"))		{			// GalleryException			if (s.equals("index." + configData.urlExtention))			{				indexNum = 1;			}			else			{				int i = 0;				s1 = s.substring("index".length(), s.indexOf('.'));				try				{					i = Integer.parseInt(s1);				}				catch (NumberFormatException e)				{					throw new GalleryNotFoundException("URL not found", e);				}				indexNum = 1 + i;				if (indexNum > totalIndexes)				{					throw new GalleryNotFoundException("URL not found");				}			}			int maxImagesPerIndex = cols * rows;			imageNum = 1 + (indexNum - 1) * maxImagesPerIndex;			if (indexNum < totalIndexes)			{				currentCols = cols;				currentRows = rows;			}			else			{				int r = totalImages % maxImagesPerIndex;				currentRows = r / cols;				if (r % cols > 0)					currentRows++;				currentCols = Math.min(r, cols);			}			n = INDEX;		}		else		// a slide page		{			s1 = s.substring(0, s.indexOf('.'));			Integer theImage = (Integer) images.get(s1);			if (null == theImage)			{				throw new GalleryNotFoundException("URL not found");			}			imageNum = theImage.intValue();			indexNum = calculateIndexNum(imageNum);			image = getImage(imageNum);			n = SLIDE;		}		return n;	}