Source code static analysis tools

Code writing is not rigorous. It often leads to many unpredictable errors in your software, and these errors are sometimes random, which makes it difficult for you to analyze and locate problems. We can use some excellent static source code analysis

About full screen and untitle bar

Remove the title bar: the first method: [java] requestWindowFeature (Window. FEATURE_NO_TITLE); // remove the title bar note that this sentence must be written before the setContentView () method. Otherwise, the second error will be reported: In

Struts2 & lt; s: iterator/& gt; how to obtain a cyclic Index

, # L. index, which is a list index. L is an IteratorStatus Object List . The User object contains the name and password attributes. Of course, you can also write it as: ,

Use of JAVA serialization to read and write objects in IO

Serialization is a mechanism for processing object streams. Object streams are called object streams that stream object content. You can perform read and write operations on Streaming objects, or transfer streaming objects between networks.

Common sorting algorithms for interview questions

The default sorting effect of the following sorting sequence is from small to large. The sequence to be sorted: 3,4, 63,4,-9, 0,-21. basic Idea of Bubble Sorting: Exchange adjacent two elements in sequence, so that big data is sunk (or small data is

Java Singleton Mode Analysis

(1)/* thread security, but efficiency is relatively low. At the beginning, we need to load a class new object. This is a hunger Singleton1 mode */public class Singleton1 {private Singleton1 () {} private static final Singleton1 instance = new

Join in Java

You have thread T1, T2 and T3, how will you ensure that thread T2 run after T1 and thread T3 run after T2? You have three threads T1, T2, and T3. How can you run T2. after T1. after T2. after T2? The following is a possible implementation

Comparison of objects in java

Let's take a look at this Code: Public class IntergerError {public static void main (String [] args) {// TODO Auto-generated method stubInteger num1 = new Integer (100); Integer num2 = new Integer (100 ); system. out. println (compare (num1, num2);}

Design Pattern (3) Proxy pattern

Today I learned the Proxy mode. The proxy mode is used to access an existing object in proxy mode when it is difficult or inconvenient to operate on an existing object. The Proxy implementation method must be consistent with the Proxy object. For

A usage of constructing and traversing two-digit Arrays

Refer to some shell Array Operations and usage to construct and traverse a two-dimensional array, as shown below: # Sites = ("www.a.com www. B .com www.c.com www.d.com" "www.e.cn www.f.cn") separated by Spaces ") n_sites =$ {# sites [*]} # obtain

General Enumeration type

Write an interface [java] public interface DisplayEnum {public String getDisplay ();} then write the enumeration [java]/*** Gender */public enum SexType implements DisplayEnum {MEN ("M"), FELMEN ("F"); private String value; private SexType (String

Eclipse generates javadoc

There are three main methods to generate a document (javadoc) using eclipse: 1. Right-click the project list, select Export (Export), and select javadoc under java in the Export (Export) dialog box, submit to the next step. In the Javadoc Generation

Java Binary Search Algorithm

The beauty of programming lies in the beauty of algorithms. Let's first look at the binary search algorithm: The Hidden condition: binary search must be ordered, from small to large, or binary search can be performed only after sorting from large to

Mahout algorithm source code analysis: Itembased Collaborative Filtering (3) RowSimilari

Mahout version: 0.7, hadoop version: 1.0.4, jdk: 1.7.0 _ 25 64bit. This article analyzes whether the analysis in the previous article is correct, mainly writing the reading of the output file in the previous article and adding log information to

SpringMVC + EasyUI asynchronous tree

Asynchronous tree has been used before: Struct2 + JQuery Ztree. For the latest project, SpringMVC + EasyUI must be used to generate an asynchronous tree. After a while, we will report the solution as follows: first, use EasyUI Tree components,

Java Semaphore usage

The semaphore of the operating system is a very important concept and has been applied in Process Control. The Semaphore of the Java concurrent library can easily control semaphores. Semaphore can control the number of resources that can be accessed

Java Socket: Java-NIO-Selector

The appearance of Selector greatly improves the efficiency of multiple Java sockets. When there is no NIO, multiple polling sockets are completed through read blocking. Even in non-blocking mode, we still need to use the system call when polling

Count and Say @ LeetCode

The question is not intuitive, here the description is better some http://www.careercup.com/question? Id = 4425679 "Count and Say problem" Write a code to do following: n String to print 0 1 1 1 1 2 2 1 3 1 2 1 1... base case: n = 0 print "1" for n =

Java thread Implementation Method

Multithreading has always been a very difficult feeling for everyone. In fact, after understanding it, you will find that it is not as profound as you think. Next, I will share with you my experience in multithreading, next, we will briefly

Application of Animation on Activity Login

If an account logon error is displayed in the pop-up box, it will be ugly and unfriendly. Of course, Toast is also a good choice. Here we provide an Animation effect of Animation to indicate an input error. When the user name or password is

Total Pages: 6206 1 .... 6149 6150 6151 6152 6153 .... 6206 Go to: GO

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.