@@ -306,7 +306,6 @@ public String toString() {
306306
307307  // Cached State 
308308  private  final  Map <String , Object > estimatedData ;
309-   private  final  Map <String , Boolean > dataAvailability ;
310309  private  final  Map <Object , ParseJSONCacheItem > hashedObjects ; // For mutable containers 
311310
312311  private  String  localId ;
@@ -385,7 +384,6 @@ public ParseObject(String theClassName) {
385384    operationSetQueue .add (new  ParseOperationSet ());
386385    estimatedData  = new  HashMap <>();
387386    hashedObjects  = new  IdentityHashMap <>();
388-     dataAvailability  = new  HashMap <>();
389387
390388    State .Init <?> builder  = newStateBuilder (theClassName );
391389    // When called from new, assume hasData for the whole object is true. 
@@ -754,7 +752,6 @@ private void setState(State newState, boolean notifyIfObjectIdChanges) {
754752      }
755753
756754      rebuildEstimatedData ();
757-       rebuildDataAvailability ();
758755      checkpointAllMutableContainers ();
759756    }
760757  }
@@ -843,7 +840,6 @@ public Set<String> keySet() {
843840    synchronized  (mutex ) {
844841      currentOperations ().remove (key );
845842      rebuildEstimatedData ();
846-       rebuildDataAvailability ();
847843      checkpointAllMutableContainers ();
848844    }
849845  }
@@ -856,7 +852,6 @@ public Set<String> keySet() {
856852    synchronized  (mutex ) {
857853      currentOperations ().clear ();
858854      rebuildEstimatedData ();
859-       rebuildDataAvailability ();
860855      checkpointAllMutableContainers ();
861856    }
862857  }
@@ -2959,18 +2954,6 @@ private void rebuildEstimatedData() {
29592954    }
29602955  }
29612956
2962-   /** 
2963-    * Regenerates the dataAvailability map from the serverData. 
2964-    */ 
2965-   private  void  rebuildDataAvailability () {
2966-     synchronized  (mutex ) {
2967-       dataAvailability .clear ();
2968-       for  (String  key  : state .keySet ()) {
2969-         dataAvailability .put (key , true );
2970-       }
2971-     }
2972-   }
2973- 
29742957  /** 
29752958   * performOperation() is like {@link #put(String, Object)} but instead of just taking a new value, 
29762959   * it takes a ParseFieldOperation that modifies the value. 
@@ -2990,7 +2973,6 @@ private void rebuildDataAvailability() {
29902973      currentOperations ().put (key , newOperation );
29912974
29922975      checkpointMutableContainer (key , newValue );
2993-       dataAvailability .put (key , Boolean .TRUE );
29942976    }
29952977  }
29962978
@@ -3546,8 +3528,7 @@ public boolean isDataAvailable() {
35463528
35473529  private  boolean  isDataAvailable (String  key ) {
35483530    synchronized  (mutex ) {
3549-       return  isDataAvailable ()
3550-           || (dataAvailability .containsKey (key ) ? dataAvailability .get (key ) : false );
3531+       return  isDataAvailable () || estimatedData .containsKey (key );
35513532    }
35523533  }
35533534
0 commit comments