Android source code analysis (14) -- how to save data with SharedPreferences
1: How to use SharedPreference s
This article only provides a way to save data. Please adjust the specific use scenarios according to the needs.
EditText add save data click event to save data.
diff --git a/res/layout/activity_voicemail_settings.xml b/res/layout/activity_voicemail_settings.xml
index cd7af05..57526f2 10075 ...
Posted by amarafzal on Thu, 02 Jan 2020 11:34:43 +0100
Paging with mybatis PageHelper
frame address: https://github.com/pagehelper/Mybatis-PageHelper/blob/master/wikis/zh/HowToUse.md
Reference documents address: https://blog.csdn.net/she_lock/article/details/79975907
pom dependence
<dependency>
<groupId>com.github.pagehelper</groupId>
<artifactId>pagehelper-spring-boot-starter</a ...
Posted by madsosterby on Thu, 02 Jan 2020 10:47:17 +0100
Android verification code -- dry goods
I. directory
1, effect
2, source code
3, use
4. Please give me a good comment
I. Effect
Note: the number of digits of the verification code can be modified (shown here as four digits), the number of digits and letters can be mixed, the size of the font can be modified, and the number of confusion lines can be ...
Posted by vyb3 on Thu, 02 Jan 2020 07:28:24 +0100
Message push using the Alliance
Integrate:
1: first, go to his official website to register an account of the alliance.
Transfer gate: Official website of the Alliance
Then use it now to create a new app: the name of the app you created is the same as the name on your project.
Be sure to write the package name correctly. The package name is the packag ...
Posted by sbarros on Thu, 02 Jan 2020 03:12:23 +0100
Android custom control ---- inherit ViewGroup sideslip menu 3, common sideslip menu, add menu switch button (end)
Project structure:
Train of thought: How to open and close a menu this.smoothScrollTo(0, 0) when opened; the slide menu displays This.smoothscrollto (mmmenuwidth, 0) when closed; menu hidden Write a button outside and click the event to call the toggle method
Specific code:
In the custom control SlidingMenu
package c ...
Posted by WiseGuy on Thu, 02 Jan 2020 02:12:47 +0100
superMap uses javascript to load WMTS service layer
First download the SuperMap ABCD iclient ABCD 8C (2017) abcdsp1 ABCD for ABCD JavaScript,
Download address: http://support.supermap.com.cn/DownloadCenter/DownloadPage.aspx?id=666
Create GettingStarted.html in the root directory as follows:
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title ...
Posted by dewen on Thu, 02 Jan 2020 01:28:02 +0100
The layout and simple application of activity& intent
Creation of activity
First, a myactivity is automatically generated,
Mainactivity inherits the class of Activity
Override the onCreat method,
Call the setContentView method again in the OnCreate method
Set the layout to be displayed in the activity through setContentView
This creates an activity
Use of activity
However, be ...
Posted by 0p3n_p0rT on Wed, 01 Jan 2020 19:53:07 +0100
Mybatis generator: a plug-in for mybatis to automatically generate entity code
To use the Mybatis plug-in in maven project to automatically produce entity classes and mapping files, the following steps are required:
1. Create generatorConfig.xml file
(1) create plug-in file
(2) configure the path of relevant production files and the configuration of relevant parameters
2. Configure pom.xml
(1) add re ...
Posted by cupboy on Wed, 01 Jan 2020 14:09:45 +0100
Android self implementation percentage layout
In development, component layout is the work that everyone must face in daily development. For Android, there are five common layouts, namely:
LinearLayout (linear layout)
Tablelayout (table layout)
Relativelayout
Absolute layout
FrameLayout (frame layout)
However, if we can layout the interface in a percentage way in th ...
Posted by goatboy on Wed, 01 Jan 2020 11:32:06 +0100
Layout Android interface with linear layout manager
In the layout file activity > main.xml, add two nested < LinearLayout > in the vertical linear layout manager < LinearLayout > added by default, then set the first < LinearLayout > arrangement as horizontal arrangement, add four horizontally side-by-side TextView components, set the text alignment of TextVi ...
Posted by alex2046 on Wed, 01 Jan 2020 08:16:04 +0100