public Object getValue(Object target, Class<?> type, long fieldOffset) {

		if (type == int.class)
			return unsafe.getInt(target, fieldOffset);
		else if (type == long.class)
			return unsafe.getLong(target, fieldOffset);
		else if (type == short.class)
			return unsafe.getShort(target, fieldOffset);
		else if (type == boolean.class)
			return unsafe.getBoolean(target, fieldOffset);
		else if (type == char.class)
			return unsafe.getChar(target, fieldOffset);
		else if (type == double.class)
			return unsafe.getDouble(target, fieldOffset);
		else if (type == byte.class)
			return unsafe.getByte(target, fieldOffset);
		else if (type == float.class)
			return unsafe.getFloat(target, fieldOffset);
		else
			return unsafe.getObject(target, fieldOffset);

	}