.class public HoldIntegerSync

.super java/lang/Object

.field private protected sharedInt I
.field private protected writeable Z
.field private protected f Ljoos/lib/JoosIO;

.method public <init>()V
  .limit locals 1
  .limit stack 3
  aload_0
  invokenonvirtual java/lang/Object/<init>()V
  aload_0
  iconst_1
  putfield HoldIntegerSync/writeable Z
  new joos/lib/JoosIO
  dup
  invokenonvirtual joos/lib/JoosIO/<init>()V
  aload_0
  swap
  putfield HoldIntegerSync/f Ljoos/lib/JoosIO;
  return
.end method

.method public synchronized setSharedInt(I)V
  .limit locals 2
  .limit stack 3
  start_0:
  aload_0
  getfield HoldIntegerSync/writeable Z
  ifeq true_2
  iconst_0
  goto stop_3
  true_2:
  iconst_1
  stop_3:
  ifeq stop_1
  new joos/lib/JoosObject
  dup
  aload_0
  invokenonvirtual joos/lib/JoosObject/<init>(Ljava/lang/Object;)V
  iconst_0
  invokevirtual joos/lib/JoosObject/wait(I)Z
  ifeq stop_4
  aload_0
  getfield HoldIntegerSync/f Ljoos/lib/JoosIO;
  ldc "Interruption of setSharedInt"
  invokevirtual joos/lib/JoosIO/println(Ljava/lang/String;)V
  stop_4:
  goto start_0
  stop_1:
  aload_0
  iload_1
  putfield HoldIntegerSync/sharedInt I
  aload_0
  iconst_0
  putfield HoldIntegerSync/writeable Z
  aload_0
  invokevirtual java/lang/Object/notify()V
  return
.end method

.method public synchronized getSharedInt()I
  .limit locals 1
  .limit stack 3
  start_0:
  aload_0
  getfield HoldIntegerSync/writeable Z
  ifeq stop_1
  new joos/lib/JoosObject
  dup
  aload_0
  invokenonvirtual joos/lib/JoosObject/<init>(Ljava/lang/Object;)V
  iconst_0
  invokevirtual joos/lib/JoosObject/wait(I)Z
  ifeq stop_2
  aload_0
  getfield HoldIntegerSync/f Ljoos/lib/JoosIO;
  ldc "Interruption of getSharedInt"
  invokevirtual joos/lib/JoosIO/println(Ljava/lang/String;)V
  stop_2:
  goto start_0
  stop_1:
  aload_0
  iconst_1
  putfield HoldIntegerSync/writeable Z
  aload_0
  invokevirtual java/lang/Object/notify()V
  aload_0
  getfield HoldIntegerSync/sharedInt I
  ireturn
.end method

