예제 #1
0
 public boolean doNeedRebuild(final IProject it) {
   boolean _xblockexpression = false;
   {
     String _name = it.getName();
     final JavaBuilderState oldState = this.javaBuildState.get(_name);
     final JavaBuilderState newState = JavaBuilderState.getLastBuiltState(it);
     Procedure1<Delta> _xifexpression = null;
     boolean _or = false;
     boolean _equals = Objects.equal(oldState, null);
     if (_equals) {
       _or = true;
     } else {
       Long _lastStructuralBuildTime = oldState.getLastStructuralBuildTime();
       Long _lastStructuralBuildTime_1 = newState.getLastStructuralBuildTime();
       boolean _notEquals = (!Objects.equal(_lastStructuralBuildTime, _lastStructuralBuildTime_1));
       _or = (_equals || _notEquals);
     }
     if (_or) {
       final Procedure1<Delta> _function =
           new Procedure1<Delta>() {
             public void apply(final Delta it) {
               final Set<QualifiedName> structurallyChangedTypes =
                   newState.getStructurallyChangedTypes();
               boolean _or = false;
               IResourceDescription _new = it.getNew();
               boolean _namesIntersect =
                   JdtQueuedBuildData.this.namesIntersect(_new, structurallyChangedTypes);
               if (_namesIntersect) {
                 _or = true;
               } else {
                 IResourceDescription _old = it.getOld();
                 boolean _namesIntersect_1 =
                     JdtQueuedBuildData.this.namesIntersect(_old, structurallyChangedTypes);
                 _or = (_namesIntersect || _namesIntersect_1);
               }
               if (_or) {
                 Collection<Delta> _deltas = JdtQueuedBuildData.this.getDeltas();
                 _deltas.add(it);
               }
             }
           };
       _xifexpression = _function;
     } else {
       _xifexpression = null;
     }
     boolean _doNeedRebuild = this.doNeedRebuild(newState, _xifexpression);
     _xblockexpression = (_doNeedRebuild);
   }
   return _xblockexpression;
 }
예제 #2
0
 public void doQueueChanges(final Collection<Delta> queuedDeltas) {
   boolean _or = false;
   boolean _equals = Objects.equal(queuedDeltas, null);
   if (_equals) {
     _or = true;
   } else {
     int _size = queuedDeltas.size();
     boolean _equals_1 = (_size == 0);
     _or = (_equals || _equals_1);
   }
   if (_or) {
     return;
   }
   for (final Delta delta : queuedDeltas) {
     boolean _matched = false;
     if (!_matched) {
       if (delta instanceof UnconfirmedStructuralChangesDelta) {
         _matched = true;
         final IProject project = ((UnconfirmedStructuralChangesDelta) delta).getProject();
         JavaBuilderState state = this.javaBuildState.get(project);
         boolean _equals_2 = Objects.equal(state, null);
         if (_equals_2) {
           String _name = project.getName();
           JavaBuilderState _lastBuiltState = JavaBuilderState.getLastBuiltState(project);
           JavaBuilderState _state = state = _lastBuiltState;
           this.javaBuildState.put(_name, _state);
         }
         Integer _buildNumber = state.getBuildNumber();
         ((UnconfirmedStructuralChangesDelta) delta).setBuildNumber((_buildNumber).intValue());
         this.unconfirmedDeltas.add(((UnconfirmedStructuralChangesDelta) delta));
       }
     }
     if (!_matched) {
       Collection<Delta> _deltas = this.getDeltas();
       _deltas.add(delta);
     }
   }
 }