Loading docs/html/guide/topics/data/backup.jd +0 −8 Original line number Original line Diff line number Diff line Loading @@ -708,14 +708,6 @@ you must use synchronized statements each time you perform a read or write. For in any Activity where you read and write the file, you need an object to use as the intrinsic in any Activity where you read and write the file, you need an object to use as the intrinsic lock for the synchronized statements:</p> lock for the synchronized statements:</p> <div class="sidebox-wrapper"> <div class="sidebox"> <p><strong>Interesting Fact:</strong></p> <p>A zero-length array is lighter-weight than a normal Object, so it's great for an intrinsic lock.</p> </div> </div> <pre> <pre> // Object for intrinsic lock // Object for intrinsic lock static final Object[] sDataLock = new Object[0]; static final Object[] sDataLock = new Object[0]; Loading Loading
docs/html/guide/topics/data/backup.jd +0 −8 Original line number Original line Diff line number Diff line Loading @@ -708,14 +708,6 @@ you must use synchronized statements each time you perform a read or write. For in any Activity where you read and write the file, you need an object to use as the intrinsic in any Activity where you read and write the file, you need an object to use as the intrinsic lock for the synchronized statements:</p> lock for the synchronized statements:</p> <div class="sidebox-wrapper"> <div class="sidebox"> <p><strong>Interesting Fact:</strong></p> <p>A zero-length array is lighter-weight than a normal Object, so it's great for an intrinsic lock.</p> </div> </div> <pre> <pre> // Object for intrinsic lock // Object for intrinsic lock static final Object[] sDataLock = new Object[0]; static final Object[] sDataLock = new Object[0]; Loading