大家好!我是岛上程序猿,感谢您阅读本文,欢迎一键三连哦。
💞当前专栏:安卓app毕业设计
精彩专栏推荐👇🏻👇🏻👇🏻
🎀Java毕业设计
🌎微信小程序毕业设计
目录
- 一、项目简介
- 二、系统核心功能模块部分截图
- 2.1用户登陆的设计与实现
- 2.2单词学习
- 2.3单词复习
- 2.4 单词浏览
- 三、部分核心代码
- 4.1 登录部分
- 4.2照片部分
- 四、论文目录
- 获取源码或论文
一、项目简介
英语在国内目前属于各类的考试的必修课程,中考、高考、考研、出国,几乎贯穿所有学习阶段。而单词作为英语学习的基础,有着异常重要的作用。传统单词书笨重、不易携带和查询。随着智能手机的普及,人们获取信息的方式已经发生了巨大的转变。智能手机正在逐步融入我们的生活,并影响和改变着我们的生活。因此,基于 Android系统设计一款记单词软件,方便人们随时随地记忆单词,合理利用碎片化时间。
二、系统核心功能模块部分截图
2.1用户登陆的设计与实现
2.2单词学习
本模块是本App的核心功能模块,支持单词搜索查询,并有已背单词和未背单词提示,具体实现效果如下图:
2.3单词复习
复习模块提供两种复习模式:随机从已背单词本选单词,然后随机空出几个字母,进行单词填空,写错则将该单词从已背单词本删除,并加入陌生单词本;或者随机中文释义(按字母排序显示)和发音,提供3个单词选项,选对了则将该单词加入已背单词本,选错了则加入陌生单词本。
具体实现效果如下图:
2.4 单词浏览
本模块可以选择查看词库或者已背单词本或者陌生单词本的单词(按字母排序),并提供添加按钮,便于用户根据实际情况选择单词添加如合适的词库。具体实现效果如下图:
三、部分核心代码
4.1 登录部分
package com.batman.baselibrary.utils;import android.util.Log;import java.security.MessageDigest;
import java.util.logging.Logger;import javax.crypto.Mac;
import javax.crypto.spec.SecretKeySpec;public class SignUtil {private static final String DEFAULT_CHARSET = "UTF-8";private static final char[] DIGITS;public static String hmacSha256(String key, String data) {try {Mac mac = Mac.getInstance("HmacSHA256");SecretKeySpec signingKey = new SecretKeySpec(key.getBytes(), mac.getAlgorithm());mac.init(signingKey);return encodeHex(mac.doFinal(data.getBytes()));} catch (Exception e) {Log.e("hmacSHA256 error",e.toString());}return null;}public static String md5(String data, String charset) {try {byte[] msg = data.getBytes(charset);MessageDigest md = MessageDigest.getInstance("MD5");return encodeHex(md.digest(msg));} catch (Exception e) {Log.e("execute MD5 error",e.toString());}return null;}public static String sha256(String data, String charset) {try {byte[] msg = data.getBytes(charset);MessageDigest md = MessageDigest.getInstance("SHA-256");return encodeHex(md.digest(msg));} catch (Exception e) {Log.e("execute SHA-256 error",e.toString());}return null;}public static String sha1(String data, String charset) {try {byte[] msg = data.getBytes(charset);MessageDigest md = MessageDigest.getInstance("SHA1");return encodeHex(md.digest(msg));} catch (Exception e) {Log.e("execute SHA1 error",e.toString());}return null;}public static String sha1(String data) {return sha1(data, DEFAULT_CHARSET);}private static String encodeHex(byte[] data) {int l = data.length;char[] out = new char[l << 1];int i = 0;for (int j = 0; i < l; ++i) {out[j++] = DIGITS[(240 & data[i]) >>> 4];out[j++] = DIGITS[15 & data[i]];}return new String(out);}static {DIGITS =new char[] {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd','e', 'f'};}
}
4.2照片部分
package com.batman.baselibrary.utils;import android.app.Activity;
import android.content.ContentUris;
import android.content.Context;
import android.content.Intent;
import android.database.Cursor;
import android.net.Uri;
import android.os.Build;
import android.os.Environment;
import android.provider.DocumentsContract;
import android.provider.MediaStore;import com.batman.baselibrary.Constant;import java.io.File;import androidx.core.content.FileProvider;public class CameraUtils {public static final int RC_CAMERA_PERM = 123;public static final int TAKE_PICTURE_FROM_CAMERA = 100;public static final int TAKE_PICTURE_FROM_GALLERY = 200;public static final int TAKE_PICTURE_PREVIEW = 300;public static File showCameraAction(Activity context) {File file = FileUtils.getDiskCachePicture(context);showCameraAction(context, file);return file;}public static File showCameraAction(Activity context, String temporaryFileName) {File file = FileUtils.getDiskCachePicture(context, temporaryFileName);showCameraAction(context, file);return file;}/*** 在onActivityResult中 可以通过key得到一个返回值,即 Bitmap imageBitmap = (Bitmap) extras.get("data");此返回值是* 拍摄照片的缩略图,但是一般不这样做,我们需要的是全尺寸的照片,所以我们通过filename保存拍摄的照片** @param context* @param temporaryFile* @return*/public static Uri showCameraAction(Activity context, File temporaryFile) {return showCameraAction(context, temporaryFile, TAKE_PICTURE_FROM_CAMERA);}public static Uri showCameraAction(Activity context, File temporaryFile, int requestCode) {// 跳转到系统照相机Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);Uri uri = null;if (intent.resolveActivity(context.getPackageManager()) != null) {if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) {//步骤二:Android 7.0及以上获取文件 Uriuri = FileProvider.getUriForFile(context, Constant.FILE_PROVIDER, temporaryFile);intent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION | Intent.FLAG_GRANT_WRITE_URI_PERMISSION);} else {//步骤三:获取文件Uriuri = Uri.fromFile(temporaryFile);}intent.putExtra(MediaStore.EXTRA_OUTPUT, uri);context.startActivityForResult(intent, requestCode);} else {//相机出现异常}return uri;}public static void showPicAction(Activity context) {// 跳转到相册Intent intent = new Intent(Intent.ACTION_PICK, MediaStore.Images.Media.EXTERNAL_CONTENT_URI);if (intent.resolveActivity(context.getPackageManager()) != null) {context.startActivityForResult(intent, TAKE_PICTURE_FROM_GALLERY);} else {}}public static String getAbsolutePath(final Context context, final Uri uri) {// DocumentProviderif (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT && DocumentsContract.isDocumentUri(context, uri)) {// ExternalStorageProviderif (isExternalStorageDocument(uri)) {final String docId = DocumentsContract.getDocumentId(uri);final String[] split = docId.split(":");final String type = split[0];if ("primary".equalsIgnoreCase(type)) {return Environment.getExternalStorageDirectory() + "/" + split[1];}// TODO handle non-primary volumes}// DownloadsProviderelse if (isDownloadsDocument(uri)) {final String id = DocumentsContract.getDocumentId(uri);final Uri contentUri = ContentUris.withAppendedId(Uri.parse("content://downloads/public_downloads"), Long.valueOf(id));return getDataColumn(context, contentUri, null, null);}// MediaProviderelse if (isMediaDocument(uri)) {final String docId = DocumentsContract.getDocumentId(uri);final String[] split = docId.split(":");final String type = split[0];Uri contentUri = null;if ("image".equals(type)) {contentUri = MediaStore.Images.Media.EXTERNAL_CONTENT_URI;} else if ("video".equals(type)) {contentUri = MediaStore.Video.Media.EXTERNAL_CONTENT_URI;} else if ("audio".equals(type)) {contentUri = MediaStore.Audio.Media.EXTERNAL_CONTENT_URI;}final String selection = "_id=?";final String[] selectionArgs = new String[]{split[1]};return getDataColumn(context, contentUri, selection, selectionArgs);}}// MediaStore (and general)else if ("content".equalsIgnoreCase(uri.getScheme())) {return getDataColumn(context, uri, null, null);}// Fileelse if ("file".equalsIgnoreCase(uri.getScheme())) {return uri.getPath();}return null;}/*** Get the value of the data column for this Uri. This is useful for* MediaStore Uris, and other file-based ContentProviders.** @param context The context.* @param uri The Uri to query.* @param selection (Optional) Filter used in the query.* @param selectionArgs (Optional) Selection arguments used in the query.* @return The value of the _data column, which is typically a file path.*/public static String getDataColumn(Context context, Uri uri, String selection, String[] selectionArgs) {Cursor cursor = null;final String column = "_data";final String[] projection = {column};try {cursor = context.getContentResolver().query(uri, projection, selection, selectionArgs,null);if (cursor != null && cursor.moveToFirst()) {final int column_index = cursor.getColumnIndexOrThrow(column);return cursor.getString(column_index);}} finally {if (cursor != null)cursor.close();}return null;}/*** @param uri The Uri to check.* @return Whether the Uri authority is ExternalStorageProvider.*/public static boolean isExternalStorageDocument(Uri uri) {return "com.android.externalstorage.documents".equals(uri.getAuthority());}/*** @param uri The Uri to check.* @return Whether the Uri authority is DownloadsProvider.*/public static boolean isDownloadsDocument(Uri uri) {return "com.android.providers.downloads.documents".equals(uri.getAuthority());}/*** @param uri The Uri to check.* @return Whether the Uri authority is MediaProvider.*/public static boolean isMediaDocument(Uri uri) {return "com.android.providers.media.documents".equals(uri.getAuthority());}}
四、论文目录
1.绪论 6
1.1研究背景和意义 6
1.2论文结构 7
2. 需求分析及设计目标 8
2.1 需求分析 8
2.1 设计目标 9
3.相关技术简介 9
3.1后台系统技术 10
3.1.1 Java语言 10
3.1.2 J2EE平台 12
3.1.3 MySQL数据库 15
3.2基于Android的前台技术 16
4.系统设计实现 19
4.1 系统功能设计 19
4.1.1 核心功能模块设计 19
4.1.2 其它功能要求 20
4.2数据库页表设计 21
4.3系统详细实现 23
4.3.1 用户登陆的设计与实现 24
4.3.2 单词搜索 25
4.3.3 单词记忆 25
4.3.4 单词复习 26
4.3.4 单词浏览: 26
4.3.4 个人中心 26
5.软件测试 27
5.1软件测试的目的和方法 27
5.1.1 软件测试的目的 27
5.1.2 软件测试基本方式 28
5.2测试用例 29
5.3测试结果 30
6.总结与展望 31
6.1 研究总结 31
6.2 展望 31
参考文献 33
致 谢 34
获取源码或论文
如嘘对应的源码或论文,可以斯wo。