org.eclipse.xtext.builder.impl.QueuedBuildData Java Examples
The following examples show how to use
org.eclipse.xtext.builder.impl.QueuedBuildData.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: N4JSBuildTypeTrackingBuilder.java From n4js with Eclipse Public License 1.0 | 6 votes |
private void superDoBuild(ToBeBuilt toBeBuilt, Set<String> removedProjects, IProgressMonitor monitor, BuildType type) { // return early if there's nothing to do. // we reuse the isEmpty() impl from BuildData assuming that it doesnT access the ResourceSet which is still null // and would be expensive to create. boolean indexingOnly = type == BuildType.RECOVERY; QueuedBuildData queuedBuildData = getQueuedBuildData(); if (isNoop(toBeBuilt, queuedBuildData, indexingOnly)) return; SubMonitor progress = toBuilderMonitor(monitor, 1); IProject project = getProject(); ResourceSet resourceSet = createResourceSet(project); BuildData buildData = new BuildData(getProject().getName(), resourceSet, toBeBuilt, queuedBuildData, indexingOnly, this::needRebuild, removedProjects); getBuilderState().update(buildData, progress.split(1, SubMonitor.SUPPRESS_NONE)); if (!indexingOnly) { try { project.getWorkspace().checkpoint(false); } catch (NoClassDefFoundError e) { // guard against broken Eclipse installations / bogus project // configuration throw new RuntimeException(e); } } }
Example #2
Source File: AbstractQueuedBuildDataTest.java From xtext-xtend with Eclipse Public License 2.0 | 5 votes |
@Override public void setUp() throws Exception { super.setUp(); JdtQueuedBuildData _jdtQueuedBuildData = new JdtQueuedBuildData(); this.queuedBuildDataContribution = _jdtQueuedBuildData; QueuedBuildData _queuedBuildData = new QueuedBuildData(this.mapper, this.queuedBuildDataContribution); this.queuedBuildData = _queuedBuildData; JavaChangeQueueFiller _javaChangeQueueFiller = new JavaChangeQueueFiller(this.queuedBuildData, this.converter); this.queueFiller = _javaChangeQueueFiller; JavaCore.addElementChangedListener(this.queueFiller, ElementChangedEvent.POST_CHANGE); }
Example #3
Source File: N4JSBuildTypeTrackingBuilder.java From n4js with Eclipse Public License 1.0 | 4 votes |
private QueuedBuildData getQueuedBuildData() { return optimisticGet("queuedBuildData"); }
Example #4
Source File: N4JSBuildTypeTrackingBuilder.java From n4js with Eclipse Public License 1.0 | 4 votes |
private boolean isNoop(ToBeBuilt toBeBuilt, QueuedBuildData queuedBuildData, boolean indexingOnly) { return new BuildData(getProject().getName(), null, toBeBuilt, queuedBuildData, indexingOnly, this::needRebuild) .isEmpty(); }
Example #5
Source File: Bug349445Test.java From xtext-eclipse with Eclipse Public License 2.0 | 4 votes |
@Test public void testUpdate() { testMe.update(new BuildData(null, null, new ToBeBuilt(), new QueuedBuildData(null)), null); assertEquals(1, loadCalled); }
Example #6
Source File: Access.java From xtext-eclipse with Eclipse Public License 2.0 | 4 votes |
/** * @since 2.5 */ public static Provider<QueuedBuildData> getQueuedBuildData() { return Access.<QueuedBuildData>provider(QueuedBuildData.class); }
Example #7
Source File: SharedStateModule.java From xtext-eclipse with Eclipse Public License 2.0 | 4 votes |
/** * @since 2.5 */ public Provider<QueuedBuildData> provideQueuedBuildData() { return Access.getQueuedBuildData(); }
Example #8
Source File: JavaChangeQueueFiller.java From xtext-eclipse with Eclipse Public License 2.0 | 4 votes |
@Inject public JavaChangeQueueFiller(QueuedBuildData queue, BuilderDeltaConverter deltaConverter) { this.queue = queue; this.deltaConverter = deltaConverter; }