master
hanxueqing 5 years ago
parent a8a1b75333
commit fd9237301d

14
.gitignore vendored

@ -0,0 +1,14 @@
*.iml
.gradle
/local.properties
/.idea/caches
/.idea/libraries
/.idea/modules.xml
/.idea/workspace.xml
/.idea/navEditor.xml
/.idea/assetWizardSettings.xml
.DS_Store
/build
/captures
.externalNativeBuild
.cxx

@ -0,0 +1 @@
CMKnowledgeGraph

@ -0,0 +1,116 @@
<component name="ProjectCodeStyleConfiguration">
<code_scheme name="Project" version="173">
<codeStyleSettings language="XML">
<indentOptions>
<option name="CONTINUATION_INDENT_SIZE" value="4" />
</indentOptions>
<arrangement>
<rules>
<section>
<rule>
<match>
<AND>
<NAME>xmlns:android</NAME>
<XML_ATTRIBUTE />
<XML_NAMESPACE>^$</XML_NAMESPACE>
</AND>
</match>
</rule>
</section>
<section>
<rule>
<match>
<AND>
<NAME>xmlns:.*</NAME>
<XML_ATTRIBUTE />
<XML_NAMESPACE>^$</XML_NAMESPACE>
</AND>
</match>
<order>BY_NAME</order>
</rule>
</section>
<section>
<rule>
<match>
<AND>
<NAME>.*:id</NAME>
<XML_ATTRIBUTE />
<XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
</AND>
</match>
</rule>
</section>
<section>
<rule>
<match>
<AND>
<NAME>.*:name</NAME>
<XML_ATTRIBUTE />
<XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
</AND>
</match>
</rule>
</section>
<section>
<rule>
<match>
<AND>
<NAME>name</NAME>
<XML_ATTRIBUTE />
<XML_NAMESPACE>^$</XML_NAMESPACE>
</AND>
</match>
</rule>
</section>
<section>
<rule>
<match>
<AND>
<NAME>style</NAME>
<XML_ATTRIBUTE />
<XML_NAMESPACE>^$</XML_NAMESPACE>
</AND>
</match>
</rule>
</section>
<section>
<rule>
<match>
<AND>
<NAME>.*</NAME>
<XML_ATTRIBUTE />
<XML_NAMESPACE>^$</XML_NAMESPACE>
</AND>
</match>
<order>BY_NAME</order>
</rule>
</section>
<section>
<rule>
<match>
<AND>
<NAME>.*</NAME>
<XML_ATTRIBUTE />
<XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
</AND>
</match>
<order>ANDROID_ATTRIBUTE_ORDER</order>
</rule>
</section>
<section>
<rule>
<match>
<AND>
<NAME>.*</NAME>
<XML_ATTRIBUTE />
<XML_NAMESPACE>.*</XML_NAMESPACE>
</AND>
</match>
<order>BY_NAME</order>
</rule>
</section>
</rules>
</arrangement>
</codeStyleSettings>
</code_scheme>
</component>

@ -0,0 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="Encoding" addBOMForNewFiles="with NO BOM" />
</project>

@ -0,0 +1,19 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="GradleSettings">
<option name="linkedExternalProjectsSettings">
<GradleProjectSettings>
<option name="distributionType" value="DEFAULT_WRAPPED" />
<option name="externalProjectPath" value="$PROJECT_DIR$" />
<option name="modules">
<set>
<option value="$PROJECT_DIR$" />
<option value="$PROJECT_DIR$/app" />
</set>
</option>
<option name="resolveModulePerSourceSet" value="false" />
<option name="testRunner" value="PLATFORM" />
</GradleProjectSettings>
</option>
</component>
</project>

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/build/classes" />
</component>
<component name="ProjectType">
<option name="id" value="Android" />
</component>
</project>

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="RenderSettings">
<option name="showDecorations" value="true" />
</component>
</project>

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="RunConfigurationProducerService">
<option name="ignoredProducers">
<set>
<option value="org.jetbrains.plugins.gradle.execution.test.runner.AllInPackageGradleConfigurationProducer" />
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestClassGradleConfigurationProducer" />
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestMethodGradleConfigurationProducer" />
</set>
</option>
</component>
</project>

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" />
</component>
</project>

@ -0,0 +1 @@
CMKnowledgeGraph

1
app/.gitignore vendored

@ -0,0 +1 @@
/build

@ -0,0 +1,45 @@
apply plugin: 'com.android.application'
android {
compileSdkVersion 29
buildToolsVersion "29.0.2"
defaultConfig {
applicationId "com.example.cmknowledgegraph"
minSdkVersion 15
targetSdkVersion 29
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.appcompat:appcompat:1.0.2'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'androidx.test.ext:junit:1.1.0'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1'
api 'com.hankcs:hanlp:portable-1.7.2'
implementation 'com.google.android.material:material:1.0.0'
// implementation 'androidx.appcompat:appcompat:1.1.0'
// implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
// testImplementation 'junit:junit:4.12'
// androidTestImplementation 'androidx.test.ext:junit:1.1.0'
// androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1'
// api 'com.hankcs:hanlp:portable-1.7.2'
// implementation 'com.google.android.material:material:1.0.0'
// androidTestImplementation 'androidx.test.ext:junit:1.1.1'
// androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
// implementation fileTree(dir: 'libs', include: ['*.aar', '*.jar'], exclude: [])
}

@ -0,0 +1,21 @@
# Add project specific ProGuard rules here.
# You can control the set of applied configuration files using the
# proguardFiles setting in build.gradle.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html
# If your project uses WebView with JS, uncomment the following
# and specify the fully qualified class name to the JavaScript interface
# class:
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
# public *;
#}
# Uncomment this to preserve the line number information for
# debugging stack traces.
#-keepattributes SourceFile,LineNumberTable
# If you keep the line number information, uncomment this to
# hide the original source file name.
#-renamesourcefileattribute SourceFile

@ -0,0 +1,27 @@
package com.example.cmknowledgegraph;
import android.content.Context;
import androidx.test.platform.app.InstrumentationRegistry;
import androidx.test.ext.junit.runners.AndroidJUnit4;
import org.junit.Test;
import org.junit.runner.RunWith;
import static org.junit.Assert.*;
/**
* Instrumented test, which will execute on an Android device.
*
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
*/
@RunWith(AndroidJUnit4.class)
public class ExampleInstrumentedTest {
@Test
public void useAppContext() {
// Context of the app under test.
Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
assertEquals("com.example.cmknowledgegraph", appContext.getPackageName());
}
}

@ -0,0 +1,30 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.cmknowledgegraph">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:networkSecurityConfig="@xml/network_security_config"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme">
<activity android:name=".SearchEntryActivity"></activity>
<activity android:name=".PersonalityCenterActivity" />
<activity android:name=".LoginActivity"></activity>
<activity android:name=".RegisterActivity" />
<activity android:name=".MainActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>

@ -0,0 +1,27 @@
package com.example.PersonalCenter;
import android.util.Log;
public class Login {
private String password;
private String phonenumber;
public Login(String phonenumber,String password){
this.password = password;
this.phonenumber = phonenumber;
}
public String connUser(){
String infoString = WebServiceGet.executeHttpGet(phonenumber,password,"/Login");
// if(infoString.equals("false")){
// Log.i("Login","+++++++++++fail"+infoString);
// }else {
// Log.i("Login","+++++++++++successs"+infoString);
// }
//登录成功后返回用户名
while(infoString==null){}
Log.i("sucesss",infoString+"ha");
return infoString;
}
}

@ -0,0 +1,20 @@
package com.example.PersonalCenter;
public class Register {
String phonenumber;
String username;
String password;
public Register(String phonenumber, String username, String password){
this.phonenumber = phonenumber;
this.username = username;
this.password = password;
}
public boolean regist(){
String regRet = WebServicePost.execuHttpPost(username, phonenumber, password,"/Register");
if(regRet.equals("true")){
return true;
}else {
return false;
}
}
}

@ -0,0 +1,47 @@
package com.example.PersonalCenter;
import android.util.Log;
import com.hankcs.hanlp.HanLP;
import java.lang.reflect.Array;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
public class Search {
public String sickname;
public Search(String sickname){
this.sickname = sickname;
}
public List<Set<String>> search(){
Log.i("search","sick执行了");
//找出对应的8个关键字
List<String> keywordList = HanLP.extractKeyword(sickname,8);
//针对每一个sickname来查找一下能不能够找到相应的名字
Set<String> mediciesSet = new HashSet<String>();
Set<String> reasonsSet = new HashSet<String>();
for(String i: keywordList){
Log.i("关键词提取",i+"ha");
String resq = SearchServiceGet.executeSearchGet(i,"/Search");
if(!resq.equals("fail")) {
String[] me_rea = resq.split("-");
String[] medicines = me_rea[0].split("\\|");
for(String j: medicines) mediciesSet.add(j);
String[] reasons = me_rea[1].split("\\|");
for(String j: reasons) reasonsSet.add(j);
}
}
List<Set<String>> a = new ArrayList<Set<String>>();
a.add(mediciesSet);
a.add(reasonsSet);
return a;
}
}

@ -0,0 +1,63 @@
package com.example.PersonalCenter;
import android.util.Log;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.net.HttpURLConnection;
import java.net.MalformedURLException;
import java.net.ProtocolException;
import java.net.URL;
public class SearchServiceGet {
public static String executeSearchGet(String sickname,String address){
HttpURLConnection connection = null;
InputStream in = null;
String Url = "http://106.54.210.208:8080/ChineseM"+address;
String path = Url + "?sickname="+sickname;
URL url = null;
try {
url = new URL(path);
connection = (HttpURLConnection)url.openConnection();
connection.setRequestMethod("GET");
connection.setConnectTimeout(100000);//建立连接超时
connection.setReadTimeout(80000);//传输数据超时
in = connection.getInputStream();
BufferedReader reader = null;//输入流
String line = "";//读取返回的每一行
StringBuilder response = new StringBuilder();
try {
reader = new BufferedReader(new InputStreamReader(in));
while((line = reader.readLine()) != null) {
response.append(line);
}
//这时候response就是一个连续字符串了吧
Log.i("response+++++",response+"返回值");
return response.toString();
//
} catch (IOException e) {
e.printStackTrace();
}finally {
if(reader!=null){
try {
reader.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
} catch (MalformedURLException e) {
e.printStackTrace();
} catch (ProtocolException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
return "";
}
}

@ -0,0 +1,72 @@
package com.example.PersonalCenter;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.net.HttpURLConnection;
import java.net.MalformedURLException;
import java.net.URL;
public class WebServiceGet {
public static String executeHttpGet(String phonenumber,String password,String address){
HttpURLConnection connection = null;
InputStream in = null;
String Url = "http://106.54.210.208:8080/ChineseM"+address;
String path = Url+"?phonenumber=" + phonenumber + "&password=" + password;
URL url = null;
try {
url = new URL(path);
} catch (MalformedURLException e) {
e.printStackTrace();
}
try {
connection = (HttpURLConnection)url.openConnection();
connection.setRequestMethod("GET");
connection.setConnectTimeout(100000);//建立连接超时
connection.setReadTimeout(80000);//传输数据超时
in = connection.getInputStream();
return parseInfo(in);
} catch (IOException e) {
e.printStackTrace();
}finally {
if(connection != null){
connection.disconnect();
}
if(in != null){
try {
in.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
return null;
}
//将字节流转换成String
public static String parseInfo(InputStream inputStream){
BufferedReader reader = null;
String line = "";
StringBuilder response = new StringBuilder();
try {
reader = new BufferedReader(new InputStreamReader(inputStream));
while((line = reader.readLine()) != null) {
response.append(line);
}
return response.toString();
} catch (IOException e) {
e.printStackTrace();
}finally {
if(reader!=null){
try {
reader.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
return null;
}
}

@ -0,0 +1,91 @@
package com.example.PersonalCenter;
import android.util.Log;
import java.io.BufferedReader;
import java.io.DataOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.net.HttpURLConnection;
import java.net.MalformedURLException;
import java.net.URL;
import java.net.URLEncoder;
public class WebServicePost {
public static String execuHttpPost(String username,String phonenumber,String password,String address){
HttpURLConnection connection = null;
InputStream in = null;
String path = "http://106.54.210.208:8080/ChineseM/"+address;
URL url = null;
try {
url = new URL(path);
} catch (MalformedURLException e) {
e.printStackTrace();
}
try {
connection = (HttpURLConnection) url.openConnection();
connection.setDoInput(true);
connection.setDoOutput(true);
connection.setRequestMethod("POST");
connection.setReadTimeout(8000);
connection.setUseCaches(false);
connection.setRequestProperty("Content-Type","application/x-www-form-urlencoded");
connection.connect();
DataOutputStream out = new DataOutputStream(connection.getOutputStream());
String data = "username="+ URLEncoder.encode(username,"UTF-8")+"&phonenumber="+URLEncoder.encode(phonenumber,"UTF-8")+"&password="+URLEncoder.encode(password,"UTF-8");
out.writeBytes(data);
out.flush();
out.close();
int resultCode = connection.getResponseCode();
if(HttpURLConnection.HTTP_OK == resultCode){
in = connection.getInputStream();
return parseInfo(in);
}
return null;
} catch (IOException e) {
e.printStackTrace();
}finally {
if(connection != null){
connection.disconnect();
}
if(in != null){
try {
in.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
return null;
}
public static String parseInfo(InputStream inputStream){
BufferedReader reader = null;
String line = "";
StringBuilder response = new StringBuilder();
reader = new BufferedReader(new InputStreamReader(inputStream));
try {
while((line = reader.readLine())!=null){
Log.d("RegisterActivity",line);
response.append(line);
}
Log.d("RegisterActivity","response.toSring:"+response.toString());
return response.toString();
} catch (IOException e) {
e.printStackTrace();
}finally {
if(reader != null){
try {
reader.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
return null;
}
}

@ -0,0 +1,35 @@
package com.example.cmknowledgegraph;
import com.hankcs.hanlp.HanLP;
import java.util.List;
import java.util.Scanner;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
public class HanlpSearch {
public static void main(String[] args) {
Scanner content = new Scanner(System.in);
String key = content.nextLine();
if(key.indexOf("吃")==-1) {
List result = HanLP.segment(key);
System.out.println(result);
for(int i=0;i<result.size();i++) {
String pattern = "(.*?)/[n|a]$";
Pattern template = Pattern.compile(pattern);
Matcher mc = template.matcher(String.valueOf(result.get(i)));
if (mc.find()) {
String[] splitstr = mc.group().split("\\/");
System.out.println(splitstr[0]);
} else {
result = HanLP.extractKeyword(key, 1);
System.out.println(result.get(0));
}
}
}
else{
List<String> result = HanLP.extractKeyword(key,2);
System.out.println(result.get(0));
}
}
}

@ -0,0 +1,113 @@
package com.example.cmknowledgegraph;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;
import androidx.appcompat.app.AlertDialog;
import androidx.appcompat.app.AppCompatActivity;
import com.example.PersonalCenter.Login;
public class LoginActivity extends AppCompatActivity {
public static String username;
public static int usersuccess = 0;
public static boolean isLogin=false;//登录属性true登陆成功false未登录
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_login);
final EditText tel_edit=findViewById(R.id.id_edit);
final EditText password_edit=findViewById(R.id.password_edit);
/**
* (int)(string)
*/
LayoutInflater inflater = getLayoutInflater();
View layout = inflater.inflate(R.layout.activity_personality_center, null);
final Button welcom_btn= layout.findViewById(R.id.welcom_btn);
final Button login_btn=findViewById(R.id.login_btn);
login_btn.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
if(tel_edit==null||tel_edit.getText().toString().equals("")){
AlertDialog.Builder builder = new AlertDialog.Builder(LoginActivity.this);
builder.setTitle("登录失败");// 设置标题
builder.setMessage("请输入电话号码");// 为对话框设置内容
builder.create().show();// 使用show()方法显示对话框
}else if(password_edit==null||password_edit.getText().toString().equals("")){
AlertDialog.Builder builder = new AlertDialog.Builder(LoginActivity.this);
builder.setTitle("登录失败");// 设置标题
builder.setMessage("请输入密码");// 为对话框设置内容
builder.create().show();// 使用show()方法显示对话框
}else {
//获取手机号和密码
String tel = tel_edit.getText().toString().trim();
String password = password_edit.getText().toString();
//调用数据库类中的方法进行登录
// boolean isLogin= OperaSchema.longin(tel,password);//原来的数据库
final Login login = new Login(tel, password);
new Thread(new Runnable() {
@Override
public void run() {
LoginActivity.username = login.connUser();
LoginActivity.usersuccess = 1;
Log.i("登录", "登录有没有问题" + username + "oooo");
}
}).start();
/**
*
*
*/
while (LoginActivity.usersuccess == 0) {
Log.i("suersuer======", "dkie" + LoginActivity.usersuccess);
}
if (!LoginActivity.username.equals("")) {
//改变个人中心的登录状态,
isLogin=true;
finish();//返回个人中心Activity
//刷新个人中心Activity
Log.i("成功", "成功了");
} else {//登陆失败提醒
AlertDialog.Builder builder = new AlertDialog.Builder(LoginActivity.this);
builder.setTitle("登陆提醒");// 设置标题
builder.setMessage("登陆失败");// 为对话框设置内容
builder.create().show();// 使用show()方法显示对话框
Log.i("失败", "失败了");
}
LoginActivity.username = "";
LoginActivity.usersuccess = 0;
}
}
});
//TextView注册跳转
TextView register_text=findViewById(R.id.register_text);
register_text.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
//跳转到注册页面
Intent intent=new Intent();
intent.setClass(LoginActivity.this,RegisterActivity.class);
startActivity(intent);
}
});
}
}

@ -0,0 +1,75 @@
package com.example.cmknowledgegraph;
import android.os.Bundle;
import com.example.cmknowledgegraph.MainContent;
import com.example.cmknowledgegraph.R;
import com.example.cmknowledgegraph.SearchContent;
import com.google.android.material.bottomnavigation.BottomNavigationView;
import com.hankcs.hanlp.HanLP;
import androidx.appcompat.app.AppCompatActivity;
import androidx.annotation.NonNull;
import androidx.fragment.app.FragmentManager;
import androidx.fragment.app.FragmentTransaction;
import android.view.MenuItem;
import android.widget.TextView;
import java.util.List;
public class MainActivity extends AppCompatActivity {
private TextView mTextMessage;
private FragmentTransaction transaction;
private FragmentManager fragmentManager;
private BottomNavigationView.OnNavigationItemSelectedListener mOnNavigationItemSelectedListener
= new BottomNavigationView.OnNavigationItemSelectedListener() {
@Override
public boolean onNavigationItemSelected(MenuItem item) {
fragmentManager = getSupportFragmentManager(); //使用fragmentmanager和transaction来实现切换效果
transaction = fragmentManager.beginTransaction();
switch (item.getItemId()) {
case R.id.home:
transaction.replace(R.id.content,new MainContent()); //对应的java class
transaction.commit(); //一定不要忘记commit否则不会显示
return true;
case R.id.search:
transaction.replace(R.id.content,new SearchContent()); //对应的java class
transaction.commit(); //一定不要忘记commit否则不会显示
return true;
case R.id.chat:
return true;
case R.id.person:
transaction.replace(R.id.content,new PersonContent()); //对应的java class
transaction.commit(); //一定不要忘记commit否则不会显示
return true;
}
return false;
}
};
// 设置默认进来是tab 显示的页面
private void setDefaultFragment(){
fragmentManager = getSupportFragmentManager();
transaction = fragmentManager.beginTransaction();
transaction.replace(R.id.content,new MainContent());
transaction.commit();
}
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
setDefaultFragment(); //上面写的那个函数
BottomNavigationView navView = findViewById(R.id.nav_view);
mTextMessage = findViewById(R.id.message);
navView.setOnNavigationItemSelectedListener(mOnNavigationItemSelectedListener);
}
}

@ -0,0 +1,19 @@
package com.example.cmknowledgegraph;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import androidx.fragment.app.Fragment;
public class MainContent extends Fragment {
//创建视图
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
// Inflate the layout for this fragment
return inflater.inflate( R.layout.activity_home, container, false ); //要加载的layout文件
}
}

@ -0,0 +1,48 @@
package com.example.cmknowledgegraph;
import android.content.Intent;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Button;
import android.widget.ImageButton;
import androidx.fragment.app.Fragment;
public class PersonContent extends Fragment {
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
// Inflate the layout for this fragment
return inflater.inflate( R.layout.activity_personality_center, container, false ); //要加载的layout文件
}
public void onActivityCreated(Bundle savedInstanceState) {
// TODO Auto-generated method stub
super.onActivityCreated(savedInstanceState);
Button login_pc_btn = (Button) getActivity().findViewById(R.id.login_pc_button);
login_pc_btn.setOnClickListener(new View.OnClickListener() {
public void onClick(View v) {
//跳转到LoginActivity
if(!LoginActivity.isLogin){
Intent intent=new Intent();
intent.setClass(getActivity(),LoginActivity.class);
startActivity(intent);
}
}
});
}
@Override
public void onResume() {
super.onResume();
if(LoginActivity.isLogin){
Button longin_pc_btn=(Button) getActivity().findViewById(R.id.login_pc_button);
longin_pc_btn.setText("Hello"+LoginActivity.username);
}
//高血压
}
}

@ -0,0 +1,22 @@
package com.example.cmknowledgegraph;
import androidx.appcompat.app.AppCompatActivity;
import android.annotation.SuppressLint;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.Button;
public class PersonalityCenterActivity extends AppCompatActivity {
@SuppressLint("LongLogTag")
@Override
protected void onCreate(Bundle savedInstanceState) {
Log.i("PersonalityCenterActivity","个人中心");
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_personality_center);
}
}

@ -0,0 +1,102 @@
package com.example.cmknowledgegraph;
import android.content.DialogInterface;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import androidx.appcompat.app.AlertDialog;
import androidx.appcompat.app.AppCompatActivity;
import com.example.PersonalCenter.Register;
public class RegisterActivity extends AppCompatActivity {
public static int regester = 0;
public static boolean isRegister;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_register);
final EditText tel_edit=findViewById(R.id.tel_register_edit);
final EditText password_edit=findViewById(R.id.password_register_edit);
final EditText nickname_edit=findViewById(R.id.nickname_register_edit);
/**
* int(string)(string)
*/
Button register =findViewById(R.id.register_btn);
register.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
if(tel_edit==null||tel_edit.getText().toString().equals("")){
AlertDialog.Builder builder = new AlertDialog.Builder(RegisterActivity.this);
builder.setTitle("注册失败");// 设置标题
builder.setMessage("请输入电话号码");// 为对话框设置内容
builder.create().show();// 使用show()方法显示对话框
}else if (password_edit==null||password_edit.getText().toString().equals("")){
AlertDialog.Builder builder = new AlertDialog.Builder(RegisterActivity.this);
builder.setTitle("注册失败");// 设置标题
builder.setMessage("请输入密码");// 为对话框设置内容
builder.create().show();// 使用show()方法显示对话框
}else if(nickname_edit==null||nickname_edit.getText().toString().equals("")){
AlertDialog.Builder builder = new AlertDialog.Builder(RegisterActivity.this);
builder.setTitle("注册失败");// 设置标题
builder.setMessage("请输入用户名");// 为对话框设置内容
builder.create().show();// 使用show()方法显示对话框
}else {
//获取手机号,密码,昵称
String tel = tel_edit.getText().toString().trim();
String password = password_edit.getText().toString();
String NickName = nickname_edit.getText().toString();
//调用数据库类方法进行注册
// boolean isRegister= OperaSchema.register(tel,NickName,password);//原来的数据连接
final Register register = new Register(tel, NickName, password);
new Thread(new Runnable() {
@Override
public void run() {
RegisterActivity.isRegister = register.regist();
Log.i("hahaaha", "注册成功了吗" + isRegister);
RegisterActivity.regester = 1;
}
}).start();
while (RegisterActivity.regester == 0) {
Log.i("rererer======", "dsd" + RegisterActivity.regester);
}
if (RegisterActivity.isRegister) {
//注册成功,对话框提醒
AlertDialog.Builder builder = new AlertDialog.Builder(RegisterActivity.this);
builder.setTitle("注册提醒");// 设置标题
// builder.setIcon(R.drawable.ic_launcher);//设置图标
builder.setMessage("注册成功");// 为对话框设置内容
builder.setPositiveButton("确定", new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface arg0, int arg1) {
// TODO Auto-generated method stub
//返回登录页面
finish();
}
});
builder.create().show();// 使用show()方法显示对话框
} else {//注册失败
//注册失败提醒
Log.i("zh==-----==--==", "kidoosloe");
AlertDialog.Builder builder = new AlertDialog.Builder(RegisterActivity.this);
builder.setTitle("注册提醒");// 设置标题
// builder.setIcon(R.drawable.ic_launcher);//设置图标
builder.setMessage("注册失败");// 为对话框设置内容
builder.create().show();
}
RegisterActivity.regester = 0;
RegisterActivity.isRegister = false;
}
}
});
}
}

@ -0,0 +1,33 @@
package com.example.cmknowledgegraph;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ImageButton;
import androidx.appcompat.app.AppCompatActivity;
import com.example.PersonalCenter.Search;
public class SearchActivity extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_search);
EditText search_edit_frame = findViewById(R.id.search_edit);
ImageButton search_btn = findViewById(R.id.search_btn);
String sickname = search_edit_frame.getText().toString();
search_btn.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
// Search search = new Search(sickname);
// search.search();
}
});
}
}

@ -0,0 +1,71 @@
package com.example.cmknowledgegraph;
import android.os.Bundle;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ArrayAdapter;
import android.widget.EditText;
import android.widget.ImageButton;
import android.widget.ListView;
import androidx.fragment.app.Fragment;
import com.example.PersonalCenter.Search;
import com.hankcs.hanlp.seg.common.Term;
import com.hankcs.hanlp.tokenizer.StandardTokenizer;
import java.util.List;
import java.util.Set;
//
public class SearchContent extends Fragment {
public static List<Set<String>> a;
public static int k=0;
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
// Inflate the layout for this fragment
return inflater.inflate( R.layout.activity_search, container, false ); //要加载的layout文件
}
public void onActivityCreated(Bundle savedInstanceState) {
// TODO Auto-generated method stub
super.onActivityCreated(savedInstanceState);
EditText search_edit = getActivity().findViewById(R.id.search_edit);
ImageButton search_btn = (ImageButton) getActivity().findViewById(R.id.search_btn);
search_btn.setOnClickListener(new View.OnClickListener() {
public void onClick(View v) {
Log.i("haha","=======Oncli");
//查找逻辑
List<Term> termList = StandardTokenizer.segment("什么是糖尿病");
System.out.println(termList);
String sickname = search_edit.getText().toString();
Search search = new Search(sickname);
new Thread(new Runnable() {
@Override
public void run() {
SearchContent.a = search.search();
SearchContent.k = 1;
}
}).start();
while(SearchContent.k==0) {Log.i("i","i");}
if(SearchContent.a!=null){
String[] medicines = a.get(0).toArray(new String[0]);
String[] reasons = a.get(1).toArray(new String[0]);
ListView lv = getActivity().findViewById(R.id.listView1);
ArrayAdapter<String> adapter = new ArrayAdapter<String>(getActivity(),android.R.layout.simple_list_item_1,medicines);
lv.setAdapter(adapter);
}
SearchContent.k=0;
SearchContent.a=null;
}
});
}
}

@ -0,0 +1,14 @@
package com.example.cmknowledgegraph;
import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;
public class SearchEntryActivity extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_search_entry);
}
}

@ -0,0 +1,44 @@
package com.example.cmknowledgegraph;
import com.hankcs.hanlp.HanLP;
import com.hankcs.hanlp.suggest.Suggester;
import java.util.List;
public class test {
public void init(){
/**
*
* + ++ +
*
*
*
*/
String content = "我的胃不舒服";
List<String> keywordList = HanLP.extractKeyword(content, 5);
System.out.println(keywordList);
//关键词联想
Suggester suggester = new Suggester();
String[] titleArray =
(
"威廉王子发表演说 呼吁保护野生动物\n" +
"《时代》年度人物最终入围名单出炉 普京马云入选\n" +
"“黑格比”横扫菲:菲吸取“海燕”经验及早疏散\n" +
"日本保密法将正式生效 日媒指其损害国民知情权\n" +
"英报告说空气污染带来“公共健康危机”"
).split("\\n");
for (String title : titleArray)
{
suggester.addSentence(title);
}
System.out.println(suggester.suggest("发言", 1)); // 语义
System.out.println(suggester.suggest("危机公共", 1)); // 字符
System.out.println(suggester.suggest("mayun", 1)); // 拼音
}
}

@ -0,0 +1,34 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt"
android:width="108dp"
android:height="108dp"
android:viewportWidth="108"
android:viewportHeight="108">
<path
android:fillType="evenOdd"
android:pathData="M32,64C32,64 38.39,52.99 44.13,50.95C51.37,48.37 70.14,49.57 70.14,49.57L108.26,87.69L108,109.01L75.97,107.97L32,64Z"
android:strokeWidth="1"
android:strokeColor="#00000000">
<aapt:attr name="android:fillColor">
<gradient
android:endX="78.5885"
android:endY="90.9159"
android:startX="48.7653"
android:startY="61.0927"
android:type="linear">
<item
android:color="#44000000"
android:offset="0.0" />
<item
android:color="#00000000"
android:offset="1.0" />
</gradient>
</aapt:attr>
</path>
<path
android:fillColor="#FFFFFF"
android:fillType="nonZero"
android:pathData="M66.94,46.02L66.94,46.02C72.44,50.07 76,56.61 76,64L32,64C32,56.61 35.56,50.11 40.98,46.06L36.18,41.19C35.45,40.45 35.45,39.3 36.18,38.56C36.91,37.81 38.05,37.81 38.78,38.56L44.25,44.05C47.18,42.57 50.48,41.71 54,41.71C57.48,41.71 60.78,42.57 63.68,44.05L69.11,38.56C69.84,37.81 70.98,37.81 71.71,38.56C72.44,39.3 72.44,40.45 71.71,41.19L66.94,46.02ZM62.94,56.92C64.08,56.92 65,56.01 65,54.88C65,53.76 64.08,52.85 62.94,52.85C61.8,52.85 60.88,53.76 60.88,54.88C60.88,56.01 61.8,56.92 62.94,56.92ZM45.06,56.92C46.2,56.92 47.13,56.01 47.13,54.88C47.13,53.76 46.2,52.85 45.06,52.85C43.92,52.85 43,53.76 43,54.88C43,56.01 43.92,56.92 45.06,56.92Z"
android:strokeWidth="1"
android:strokeColor="#00000000" />
</vector>

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 111 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

@ -0,0 +1,9 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24.0"
android:viewportHeight="24.0">
<path
android:fillColor="#FF000000"
android:pathData="M3,13h8L11,3L3,3v10zM3,21h8v-6L3,15v6zM13,21h8L21,11h-8v10zM13,3v6h8L21,3h-8z" />
</vector>

@ -0,0 +1,9 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24.0"
android:viewportHeight="24.0">
<path
android:fillColor="#FF000000"
android:pathData="M10,20v-6h4v6h5v-8h3L12,3 2,12h3v8z" />
</vector>

@ -0,0 +1,170 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="108dp"
android:height="108dp"
android:viewportWidth="108"
android:viewportHeight="108">
<path
android:fillColor="#008577"
android:pathData="M0,0h108v108h-108z" />
<path
android:fillColor="#00000000"
android:pathData="M9,0L9,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,0L19,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M29,0L29,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M39,0L39,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M49,0L49,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M59,0L59,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M69,0L69,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M79,0L79,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M89,0L89,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M99,0L99,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,9L108,9"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,19L108,19"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,29L108,29"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,39L108,39"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,49L108,49"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,59L108,59"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,69L108,69"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,79L108,79"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,89L108,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,99L108,99"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,29L89,29"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,39L89,39"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,49L89,49"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,59L89,59"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,69L89,69"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,79L89,79"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M29,19L29,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M39,19L39,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M49,19L49,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M59,19L59,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M69,19L69,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M79,19L79,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
</vector>

@ -0,0 +1,9 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24.0"
android:viewportHeight="24.0">
<path
android:fillColor="#FF000000"
android:pathData="M12,22c1.1,0 2,-0.9 2,-2h-4c0,1.1 0.89,2 2,2zM18,16v-5c0,-3.07 -1.64,-5.64 -4.5,-6.32L13.5,4c0,-0.83 -0.67,-1.5 -1.5,-1.5s-1.5,0.67 -1.5,1.5v0.68C7.63,5.36 6,7.92 6,11v5l-2,2v1h16v-1l-2,-2z" />
</vector>

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/home_back_1"
tools:context=".MainActivity">
</LinearLayout>

@ -0,0 +1,91 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
tools:context=".LoginActivity">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="80dp"
android:layout_marginLeft="60dp">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="账号"
android:layout_marginTop="10dp"
android:layout_marginLeft="10dp"
android:textSize="20dp"
android:textColor="#35302D"/>
<EditText
android:id="@+id/id_edit"
android:layout_width="250dp"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:layout_marginLeft="10dp"
android:inputType="number"/>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:layout_marginLeft="60dp">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="密码"
android:layout_marginTop="10dp"
android:layout_marginLeft="10dp"
android:textSize="20dp"
android:textColor="#8B4513"/>
<EditText
android:id="@+id/password_edit"
android:layout_width="250dp"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:layout_marginLeft="10dp"
android:inputType="textPassword"/>
</LinearLayout>
<Button
android:id="@+id/login_btn"
android:layout_width="300dp"
android:layout_height="wrap_content"
android:text="登录"
android:textSize="20dp"
android:background="#FFDAB9"
android:layout_marginTop="30dp"
android:layout_marginLeft="70dp"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="忘记密码?"
android:textSize="15dp"
android:layout_marginTop="10dp"
android:layout_marginLeft="70dp"
android:textColor="#8B4513"/>
<TextView
android:id="@+id/register_text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="注册"
android:textSize="17dp"
android:layout_marginTop="10dp"
android:layout_marginLeft="180dp"
android:textColor="#8B4513"/>
</LinearLayout>
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@mipmap/login_pic"/>
</LinearLayout>

@ -0,0 +1,29 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/container"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity">
<FrameLayout
android:id="@+id/content"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
tools:ignore="MissingConstraints" />
<com.google.android.material.bottomnavigation.BottomNavigationView
android:id="@+id/nav_view"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="0dp"
android:layout_marginEnd="0dp"
android:background="?android:attr/windowBackground"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:menu="@menu/bottom_nav_menu" />
</androidx.constraintlayout.widget.ConstraintLayout>

@ -0,0 +1,212 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".PersonalityCenterActivity">
<ImageView
android:id="@+id/head_picture"
android:layout_width="110dp"
android:layout_height="110dp"
android:layout_marginTop="20dp"
android:layout_marginLeft="150dp"
android:layout_centerInParent="true"
android:src="@mipmap/picture"/>
<Button
android:id="@+id/login_pc_button"
android:layout_width="100dp"
android:layout_height="50dp"
android:text="登录"
android:textSize="20sp"
android:background="#FFDAB9"
android:layout_marginLeft="157dp"
android:visibility="visible"/>
<Button
android:id="@+id/welcom_btn"
android:layout_width="100dp"
android:layout_height="50dp"
android:text="欢迎"
android:textSize="20sp"
android:background="#FFDAB9"
android:layout_marginLeft="157dp"
android:visibility="gone"/>
<View
android:layout_marginTop="20dp"
android:layout_height="1px"
android:background="#000000"
android:layout_width="fill_parent"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageView
android:id="@+id/yellow_star1"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_marginLeft="2dp"
android:src="@mipmap/star"/>
<TextView
android:id="@+id/personal"
android:layout_width="100dp"
android:layout_height="40dp"
android:text="个性推荐"
android:textSize="18sp"
android:layout_marginTop="12dp"
android:layout_marginLeft="16dp"/>
</LinearLayout>
<View
android:layout_height="1px"
android:background="#000000"
android:layout_width="fill_parent"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageView
android:id="@+id/yellow_star2"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_marginLeft="2dp"
android:src="@mipmap/star"/>
<TextView
android:id="@+id/diet_hobby"
android:layout_width="100dp"
android:layout_height="40dp"
android:text="饮食爱好"
android:textSize="18sp"
android:layout_marginTop="12dp"
android:layout_marginLeft="16dp"/>
</LinearLayout>
<View
android:layout_height="1px"
android:background="#000000"
android:layout_width="fill_parent"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageView
android:id="@+id/yellow_star3"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_marginLeft="2dp"
android:src="@mipmap/star"/>
<TextView
android:id="@+id/regimen"
android:layout_width="100dp"
android:layout_height="40dp"
android:text="养生方案"
android:textSize="18sp"
android:layout_marginTop="12dp"
android:layout_marginLeft="16dp"/>
</LinearLayout>
<View
android:layout_height="1px"
android:background="#000000"
android:layout_width="fill_parent"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageView
android:id="@+id/yellow_star4"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_marginLeft="2dp"
android:src="@mipmap/star"/>
<TextView
android:id="@+id/history"
android:layout_width="100dp"
android:layout_height="40dp"
android:text="浏览记录"
android:textSize="18sp"
android:layout_marginTop="12dp"
android:layout_marginLeft="16dp"/>
</LinearLayout>
<View
android:layout_height="1px"
android:background="#000000"
android:layout_width="fill_parent"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageView
android:id="@+id/yellow_star5"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_marginLeft="2dp"
android:src="@mipmap/star"/>
<TextView
android:id="@+id/message"
android:layout_width="100dp"
android:layout_height="40dp"
android:text="消息通知"
android:textSize="18sp"
android:layout_marginTop="12dp"
android:layout_marginLeft="16dp"/>
</LinearLayout>
<View
android:layout_height="1px"
android:background="#000000"
android:layout_width="fill_parent"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageView
android:id="@+id/yellow_star6"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_marginLeft="2dp"
android:src="@mipmap/star"/>
<TextView
android:id="@+id/setting"
android:layout_width="100dp"
android:layout_height="40dp"
android:text="设置"
android:textSize="18sp"
android:layout_marginTop="12dp"
android:layout_marginLeft="16dp"/>
</LinearLayout>
<View
android:layout_height="1px"
android:background="#000000"
android:layout_width="fill_parent"/>
</LinearLayout>

@ -0,0 +1,76 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
tools:context=".RegisterActivity">
<GridLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:rowCount="3"
android:columnCount="2"
android:layout_marginTop="80dp"
android:layout_marginLeft="60dp"
>
<TextView
android:text="手机号"
android:layout_marginTop="10dp"
android:layout_marginLeft="10dp"
android:textSize="20dp"
android:textColor="#D2691E"
/>
<EditText
android:id="@+id/tel_register_edit"
android:layout_width="200dp"
android:layout_height="wrap_content"
android:layout_marginLeft="10dp"
android:layout_marginTop="10dp"/>
<TextView
android:text="昵称"
android:layout_marginTop="25dp"
android:layout_marginLeft="20dp"
android:textSize="20dp"
android:textColor="#D2691E"
/>
<EditText
android:id="@+id/nickname_register_edit"
android:layout_width="200dp"
android:layout_height="wrap_content"
android:layout_marginLeft="15dp"
android:layout_marginTop="20dp"/>
<TextView
android:text="密 码"
android:layout_marginTop="25dp"
android:layout_marginLeft="10dp"
android:textSize="20dp"
android:textColor="#D2691E"
/>
<EditText
android:id="@+id/password_register_edit"
android:layout_width="200dp"
android:layout_height="wrap_content"
android:layout_marginLeft="15dp"
android:layout_marginTop="20dp"
android:inputType="textPassword"
/>
</GridLayout>
<Button
android:id="@+id/register_btn"
android:layout_width="250dp"
android:layout_height="wrap_content"
android:layout_marginTop="80dp"
android:layout_marginStart="100dp"
android:background="#FFE4C4"
android:layout_marginLeft="5dp"
android:text="注册"
android:textSize="20dp"/>
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@mipmap/register_pic"
android:layout_marginLeft="150dp"
android:layout_marginTop="60dp"/>
</LinearLayout>

@ -0,0 +1,97 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
tools:context=".SearchActivity">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="101dp">
<EditText
android:id="@+id/search_edit"
android:layout_width="250dp"
android:layout_height="wrap_content"
android:layout_marginLeft="80dp"
android:layout_marginTop="10dp"
android:paddingBottom="15dp"
android:text="糖尿病怎么办"
android:textColor="#C0C0C0"
android:textSize="40px"
/>
<ImageButton
android:id="@+id/search_btn"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_marginLeft="10dp"
android:src="@mipmap/search"/>
</LinearLayout>
<GridLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="30dp"
android:layout_marginLeft="50dp"
android:columnCount="3"
android:rowCount="2"
android:orientation="horizontal">
<Button
android:id="@+id/btn1"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginLeft="10dp"
android:text="食欲不振"
android:background="#FFDEAD"
/>
<Button
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginLeft="10dp"
android:text="糖尿病"
android:background="#FFDEAD"/>
<Button
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginLeft="10dp"
android:text="头晕"
android:background="#FFDEAD"/>
<Button
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="15dp"
android:layout_marginLeft="10dp"
android:text="熬夜掉发"
android:background="#FFDEAD"/>
<Button
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="15dp"
android:layout_marginLeft="10dp"
android:text="感冒发烧"
android:background="#FFDEAD"/>
<Button
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="15dp"
android:layout_marginLeft="10dp"
android:text="感冒发烧"
android:background="#FFDEAD"/>
</GridLayout>
<!-- <ImageView-->
<!-- android:layout_width="wrap_content"-->
<!-- android:layout_height="wrap_content"-->
<!-- android:src="@drawable/search_back"/>-->
<ListView
android:id="@+id/listView1"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
</LinearLayout>

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".SearchEntryActivity">
</androidx.constraintlayout.widget.ConstraintLayout>

@ -0,0 +1,24 @@
<?xml version="1.0" encoding="utf-8"?>
<menu xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:id="@+id/home"
android:icon="@drawable/ic_home_black_24dp"
android:title="Home" />
<item
android:id="@+id/search"
android:icon="@drawable/ic_dashboard_black_24dp"
android:title="Search" />
<item
android:id="@+id/chat"
android:icon="@drawable/ic_notifications_black_24dp"
android:title="Chat" />
<item
android:id="@+id/person"
android:icon="@drawable/person"
android:title="Per" />
</menu>

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@drawable/ic_launcher_background" />
<foreground android:drawable="@drawable/ic_launcher_foreground" />
</adaptive-icon>

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@drawable/ic_launcher_background" />
<foreground android:drawable="@drawable/ic_launcher_foreground" />
</adaptive-icon>

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="colorPrimary">#008577</color>
<color name="colorPrimaryDark">#00574B</color>
<color name="colorAccent">#D81B60</color>
</resources>

@ -0,0 +1,3 @@
<resources>
<string name="app_name">CMKnowledgeGraph</string>
</resources>

@ -0,0 +1,11 @@
<resources>
<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
</style>
</resources>

@ -0,0 +1,11 @@
<network-security-config>
<base-config cleartextTrafficPermitted="true"/>
<domain-config>
<domain includeSubdomains="true">example.com</domain>
<pin-set expiration="2018-01-01">
<pin digest="SHA-256">7HIpactkIAq2Y49orFOOQKurWxmmSFZhBCoQYcRhJ3Y=</pin>
<!-- backup pin -->
<pin digest="SHA-256">fwza0LRMXouZHRC8Ei+4PyuldPDcf3UKgO/04cDM1oE=</pin>
</pin-set>
</domain-config>
</network-security-config>

@ -0,0 +1,17 @@
package com.example.cmknowledgegraph;
import org.junit.Test;
import static org.junit.Assert.*;
/**
* Example local unit test, which will execute on the development machine (host).
*
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
*/
public class ExampleUnitTest {
@Test
public void addition_isCorrect() {
assertEquals(4, 2 + 2);
}
}

@ -0,0 +1,27 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.5.2'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
repositories {
google()
jcenter()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}

@ -0,0 +1,20 @@
# Project-wide Gradle settings.
# IDE (e.g. Android Studio) users:
# Gradle settings configured through the IDE *will override*
# any settings specified in this file.
# For more details on how to configure your build environment visit
# http://www.gradle.org/docs/current/userguide/build_environment.html
# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
org.gradle.jvmargs=-Xmx1536m
# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
# AndroidX package structure to make it clearer which packages are bundled with the
# Android operating system, and which are packaged with your app's APK
# https://developer.android.com/topic/libraries/support-library/androidx-rn
android.useAndroidX=true
# Automatically convert third-party libraries to use AndroidX
android.enableJetifier=true

Binary file not shown.

@ -0,0 +1,6 @@
#Wed Oct 23 10:48:58 CST 2019
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-all.zip

172
gradlew vendored

@ -0,0 +1,172 @@
#!/usr/bin/env sh
##############################################################################
##
## Gradle start up script for UN*X
##
##############################################################################
# Attempt to set APP_HOME
# Resolve links: $0 may be a link
PRG="$0"
# Need this for relative symlinks.
while [ -h "$PRG" ] ; do
ls=`ls -ld "$PRG"`
link=`expr "$ls" : '.*-> \(.*\)$'`
if expr "$link" : '/.*' > /dev/null; then
PRG="$link"
else
PRG=`dirname "$PRG"`"/$link"
fi
done
SAVED="`pwd`"
cd "`dirname \"$PRG\"`/" >/dev/null
APP_HOME="`pwd -P`"
cd "$SAVED" >/dev/null
APP_NAME="Gradle"
APP_BASE_NAME=`basename "$0"`
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS=""
# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD="maximum"
warn () {
echo "$*"
}
die () {
echo
echo "$*"
echo
exit 1
}
# OS specific support (must be 'true' or 'false').
cygwin=false
msys=false
darwin=false
nonstop=false
case "`uname`" in
CYGWIN* )
cygwin=true
;;
Darwin* )
darwin=true
;;
MINGW* )
msys=true
;;
NONSTOP* )
nonstop=true
;;
esac
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
# Determine the Java command to use to start the JVM.
if [ -n "$JAVA_HOME" ] ; then
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
# IBM's JDK on AIX uses strange locations for the executables
JAVACMD="$JAVA_HOME/jre/sh/java"
else
JAVACMD="$JAVA_HOME/bin/java"
fi
if [ ! -x "$JAVACMD" ] ; then
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
else
JAVACMD="java"
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
# Increase the maximum file descriptors if we can.
if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
MAX_FD_LIMIT=`ulimit -H -n`
if [ $? -eq 0 ] ; then
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
MAX_FD="$MAX_FD_LIMIT"
fi
ulimit -n $MAX_FD
if [ $? -ne 0 ] ; then
warn "Could not set maximum file descriptor limit: $MAX_FD"
fi
else
warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
fi
fi
# For Darwin, add options to specify how the application appears in the dock
if $darwin; then
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
fi
# For Cygwin, switch paths to Windows format before running java
if $cygwin ; then
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
JAVACMD=`cygpath --unix "$JAVACMD"`
# We build the pattern for arguments to be converted via cygpath
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
SEP=""
for dir in $ROOTDIRSRAW ; do
ROOTDIRS="$ROOTDIRS$SEP$dir"
SEP="|"
done
OURCYGPATTERN="(^($ROOTDIRS))"
# Add a user-defined pattern to the cygpath arguments
if [ "$GRADLE_CYGPATTERN" != "" ] ; then
OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
fi
# Now convert the arguments - kludge to limit ourselves to /bin/sh
i=0
for arg in "$@" ; do
CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
else
eval `echo args$i`="\"$arg\""
fi
i=$((i+1))
done
case $i in
(0) set -- ;;
(1) set -- "$args0" ;;
(2) set -- "$args0" "$args1" ;;
(3) set -- "$args0" "$args1" "$args2" ;;
(4) set -- "$args0" "$args1" "$args2" "$args3" ;;
(5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
(6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
(7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
(8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
(9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
esac
fi
# Escape application args
save () {
for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
echo " "
}
APP_ARGS=$(save "$@")
# Collect all arguments for the java command, following the shell quoting and substitution rules
eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong
if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
cd "$(dirname "$0")"
fi
exec "$JAVACMD" "$@"

84
gradlew.bat vendored

@ -0,0 +1,84 @@
@if "%DEBUG%" == "" @echo off
@rem ##########################################################################
@rem
@rem Gradle startup script for Windows
@rem
@rem ##########################################################################
@rem Set local scope for the variables with windows NT shell
if "%OS%"=="Windows_NT" setlocal
set DIRNAME=%~dp0
if "%DIRNAME%" == "" set DIRNAME=.
set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS=
@rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome
set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
if "%ERRORLEVEL%" == "0" goto init
echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
goto fail
:findJavaFromJavaHome
set JAVA_HOME=%JAVA_HOME:"=%
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
if exist "%JAVA_EXE%" goto init
echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
goto fail
:init
@rem Get command-line arguments, handling Windows variants
if not "%OS%" == "Windows_NT" goto win9xME_args
:win9xME_args
@rem Slurp the command line arguments.
set CMD_LINE_ARGS=
set _SKIP=2
:win9xME_args_slurp
if "x%~1" == "x" goto execute
set CMD_LINE_ARGS=%*
:execute
@rem Setup the command line
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
:end
@rem End local scope for the variables with windows NT shell
if "%ERRORLEVEL%"=="0" goto mainEnd
:fail
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
rem the _cmd.exe /c_ return code!
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
exit /b 1
:mainEnd
if "%OS%"=="Windows_NT" endlocal
:omega

@ -0,0 +1,2 @@
include ':app'
rootProject.name='CMKnowledgeGraph'
Loading…
Cancel
Save