The members of a class are divided into two classes, static members (static member), and instance members (instance member). A static member belongs to a class and an instance member is an instance of an object, that is, a class.
A brief discussion of whether static fields and static methods are used in a class is a thread-safe issue.
We are aware that the call to static field and static method is called through the class. Static methods do not operate on specific instances, only static members. Instance methods can operate on specific instances, access static members, and access instance members.
So, is the static method used in multi-threading a thread-safe issue? This depends on whether static methods are used in static methods to see if static members are employed.
Because, when using the same static method in multi-threading, each thread uses a copy of its own instance field (instance field) and shares a static field. So, if the static method does not manipulate a static member, only the instance fields (instance field) are used inside the method, which does not cause security problems. However, if the static method operates on a static field, it needs to be handled securely in a static method with mutually exclusive access.
http://blog.csdn.net/scucj/article/details/1394523