Lab2/src/main/java/AtomicIntegerFix/IntegerObj.java
/**
     * this method used to increment object variable
     * @return nothing
     */
this method used to increment object variable
@return nothing
this method used to increment object variable @return nothing
public void inc() {
        int oldValue,newValue;
        boolean pass = false;
        while(!pass) {
             oldValue = this.counter.get();
             newValue = oldValue + 1;
            pass = counter.compareAndSet(oldValue, newValue);
            this.value = counter.get();
        }
    }
public void inc ( ) { int oldValue , newValue ; boolean pass = false ; while ( ! pass ) { oldValue = this . counter . get ( ) ; newValue = oldValue + 1 ; pass = counter . compareAndSet ( oldValue , newValue ) ; this . value = counter . get ( ) ; } }
this method used to increment object variable
 @return nothing
this method used to increment object variable @return nothing