Coexistence of Kotlin and Java, calling kotlin code in -Java

Call of kotlin data class Call of object simple profit mode class in Kotlin Calling file class in Kotlin Flexible transfer of parameters by calling jvm annotation String string null call Call of kotlin data class kotlin Code: package com.tianfu.kotlin /** * age Member annotations cannot have get and ...

Posted on Wed, 08 Jul 2020 12:02:49 -0400 by gareh

Access other nodes through a jumper using the JSCH framework

A set of code for remotely accessing ssh has been developed. Recently, there is a need for a jumper to access the target service.After searching the web for half a day, I didn't find a good example, so I browsed the API of JSCH myself.But look in the clouds.Imagine if port forwarding works by mapping the target node ip:port to localhost:port an ...

Posted on Sun, 05 Jul 2020 11:04:53 -0400 by n8w

Access other nodes through a jumper using the JSCH framework

A set of code for remotely accessing ssh has been developed. Recently, there is a need for a jumper to access the target service.After searching the web for half a day, I didn't find a good example, so I browsed the API of JSCH myself.But look in the clouds.Imagine if port forwarding works by mapping the target node ip:port to localhost:port an ...

Posted on Sun, 05 Jul 2020 11:05:19 -0400 by golden_water

Principle and java implementation of inserting red and black trees

A red-black tree is a binary balanced lookup tree in which each node has a storage bit to represent the color of the node, either RED or BLACK.Red-black trees have the following properties: (1) Each node is red or black (2) The root node is black (3) If a node is red, both of its sons are black (4) For each node, all paths from that node to its ...

Posted on Sun, 05 Jul 2020 10:56:44 -0400 by dallasx

Update DownloadManager usage with android system

The results are as follows: added in API level 9. Package path:java.lang.Object    ↳ android.app.DownloadManager Download Manager is a system service that handles long-running HTTP downloads. Applications requested to download through this API should be ACTION_NOTIFICATION_CLICKED registers a broadcast receiver so t ...

Posted on Sat, 04 Jul 2020 11:06:01 -0400 by Citizen

Update DownloadManager usage with android system

The results are as follows: added in API level 9. Package path:java.lang.Object    ↳ android.app.DownloadManager Download Manager is a system service that handles long-running HTTP downloads. Applications requested to download through this API should be ACTION_NOTIFICATION_CLICKED registers a broadcast receiver so t ...

Posted on Sat, 04 Jul 2020 11:05:39 -0400 by micknic

Array lookup algorithm, array, a + b = c

subject Given an unordered array, such as int[] arr={3, 5, 8, 9, 12, 21, 27}, list all sets that meet the criteria: A set contains two values a, b(a and B are in the array, and a is not equal to b) a+b=c,c also in the array Reflection Sort first. Use the index of a and B to do nested loops, a main loop, B sub-loop, iterate out all combinatio ...

Posted on Sat, 04 Jul 2020 10:36:57 -0400 by mpunn

100% Perfect Friend Sharing

Step 1: go Federation Official Website Register an account to create an application (the application name matches the project name), a detailed step you can refer to Friends QQ Login Skipping this time, text Import jar package add permission <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> <uses-p ...

Posted on Fri, 03 Jul 2020 11:10:27 -0400 by fire_cracker

jquery, js knowledge

jquery selector Jquery selector requires two backslashes to escape special characters when fetching elements For example: var orgName=$("#whir$t3198_f4972").val(); A minor question: <div style="WIDTH: 100%" id="whir$t3198-whir$t3198_f4972"> <div class="cls-ui cls-ui-ui207 cls-ui-readonly cls-ui-1003131 ...

Posted on Thu, 02 Jul 2020 10:44:13 -0400 by Tchelo

Separation of dynamic and static state by Nginx+Tomcat

Add group groupadd www Add user WWW: useradd - G www under www group Modify configuration file nginx.conf : user www www; worker_processes 2; events{ worker_connections 1024; } http{ #Set the default type to binary stream default_type application/octet-stream; server_names_hash_bucket_size 128; #Specify the hea ...

Posted on Wed, 01 Jul 2020 11:01:33 -0400 by dinno2