Search:

Type: Posts; User: helloworld922

Search: Search took 0.19 seconds.

  1. Replies
    4
    Views
    2,218

    Re: synchronised

    The static refers to a class state, not a specific instanced object. So, any static methods are locked to the static synchronized method, but all instance methods are left unlocked. See Instrinsic...
  2. Replies
    4
    Views
    2,218

    Re: synchronised

    Here's how your program flow is going:
    1. main thread
    start thread 2 and thread 3
    2. t1 thread
    print out text, wait 5 seconds
    3. t2 thread
    print out text

    Because thread 2 and 3 are running...
Results 1 to 2 of 2