@SuppressWarnings("unchecked")
	public static void read(String fileName) throws FileNotFoundException {

		// prepare to read file
		FileInputStream fin = new FileInputStream("plugins/" + Main.pluginName + "/" + fileName);
		ObjectInputStream ois;

		try {
			// attempt to read file
			ois = new ObjectInputStream(fin);
			try {
				// attempt to save data from file to object.
				StaticVariables.setRegions((List<RegionData>) ois.readObject());
				Main.sendDebugInfo("Region data accessed successfully!");

			} catch (ClassNotFoundException e) {

				// if class wasn't found send error msg to console
				Main.sendSevereInfo("A problem occurred attempting to read from the region data file : ClassNotFoundException");
				e.printStackTrace();

			} catch (IOException e) {

				// if IOexception send error msg to console
				Main.sendSevereInfo("A problem occurred attempting to read from the region data file : IOException");
				e.printStackTrace();
			}
		} catch (IOException e) {

			// if IOexception send error msg to console
			Main.sendSevereInfo("A problem occurred attempting to read from the region data file : IOException");
			e.printStackTrace();
		}
		try {

			// attempt to close input stream
			fin.close();

		} catch (IOException e) {

			// if IOexception send error msg to console
			Main.sendSevereInfo("A problem occurred attempting to read from the region data file : IOException");
			e.printStackTrace();

		}
	}