Painting an Android robot with Canvas and Paint in Android

scene In Android, the brush uses the Paint class, and the Canvas uses the Canvas class to represent it. Basic steps of drawing First, write a custom view class inherited from view, then rewrite its onDraw method, and finally add the custom view to actvity. Effect     Note: Blog: https://blog.csdn.net/badao_liumang_qizhi Pay attention to the ...

Posted on Fri, 10 Jan 2020 12:38:58 -0500 by smc

MyBatis details

1. Typealias (alias) It refers to replacing the full name of a class with a short name in the configuration file. Aliases are divided into system aliases and custom aliases, regardless of case First add the configuration in config.xml <typeAliases> <typeAlias type="com.kgc.mybatis.pojo.Person" alias="Perso ...

Posted on Fri, 10 Jan 2020 12:01:00 -0500 by avvishnu

SSH simple integration

Understand: struts to implement the interaction between browser and server; spring completes object creation, object dependency and transaction processing hibernate completes data access Difficult points: 1. By accessing the browser, spring can create an action without creating it by itself 2. Set c3p0 in spring to improv ...

Posted on Fri, 10 Jan 2020 11:07:04 -0500 by bfinucan

Logback logs cannot be generated by day

Problem Description: when I checked the server log of this project recently, I found that if the project is not restarted, no new log file will be generated, and all logs will be printed to the log file of the day when the project starts to run. Problematic profile <?xml version="1.0" encoding="UTF-8"?> <configuration> <!--Th ...

Posted on Fri, 10 Jan 2020 10:46:30 -0500 by ratass2002

Setting alarm clock with AlarmManager in Android

scene set alarm     Alarm reminder     Note: Blog: https://blog.csdn.net/badao_liumang_qizhi Pay attention to the public address Domineering procedural ape Get programming related ebooks, tutorials and free downloads. Realization Create a new MainActivity, add a time selector and a Button to its layout file <?xml version="1.0" encoding ...

Posted on Fri, 10 Jan 2020 10:16:26 -0500 by justinchrono

About the switch between the official version and the test version of Android app

Some time ago, there was a problem with the app. The server link on the app was actually the link to the test server, which embarrassed me. Because every formal and test server switch is manually replaced, this problem arises. Then I wonder if I can switch formal and test server links according to release and debug. Finally, th ...

Posted on Thu, 09 Jan 2020 14:47:56 -0500 by itsinmyhead

12.mybatis dynamic splicing sql

1. Demand: query users by gender and name Query sql:   SELECT id, username, birthday, sex, address FROM `user` WHERE sex = 1 AND username LIKE '%Zhang%' 2. Use if tag Modify UserMapper.xml as follows: <!-- Query users by criteria --> <select id="queryUserByWhere" parameterType="user" resultType="user"> SELECT ...

Posted on Thu, 09 Jan 2020 14:08:42 -0500 by refiking

Application principle of BaseServlet

Application principle of BaseServlet BaseServlet can call the corresponding method through reflection according to the method parameter, and then judge whether to forward or redirect to the corresponding page according to the result generated by the method. Combine web.xml with TestServlet to explain the processing of request ...

Posted on Thu, 09 Jan 2020 14:05:42 -0500 by kestasjk

Hive embedded mode installation (based on Hadoop)

Download and extract to the specified directory (1) Configure environment variable / etc/profile export HIVE_HOME=/usr/local/hive/ export PATH=$PATH:$HIVE_HOME/bin (2) Modify hive configuration file hive-env.sh Add hadoop path, hive path, lib path of hive #HADOOP_HOME=${bin}/../../hadoop HADOOP_HOME=/usr/local/hadoop ...

Posted on Thu, 09 Jan 2020 12:33:59 -0500 by ksimpkins

Introduction to RocketMQ driven by Spring Cloud Stream message

Spring cloudstream currently supports RabbitMQ, Kafka middleware, and RocketMQ, which I am learning recently. Here are my notes To learn Spring cloud Stream, you can learn about Spring Messaging and Spring Integration, Let's take a look at the model of Spring Message The corresponding model of Messaging includes a message body Payload and a m ...

Posted on Thu, 09 Jan 2020 10:10:25 -0500 by Fuzzy Wobble