List of usage examples for com.google.gwt.core.ext.linker ConfigurationProperty getName
String getName();
From source file:com.arcbees.chosen.rebind.VersionInspectorLinker.java
License:Apache License
private boolean isTest(LinkerContext context) { boolean isTest = false; for (ConfigurationProperty property : context.getConfigurationProperties()) { String name = property.getName(); List<String> values = property.getValues(); if ("junit.moduleName".equals(name) && !values.isEmpty() && !values.get(0).isEmpty()) { isTest = true;//from ww w. j a v a 2 s. co m break; } } return isTest; }
From source file:com.arcbees.chosen.rebind.VersionInspectorLinker.java
License:Apache License
private boolean canVerifyNewerVersion(LinkerContext context) { boolean verifyNewerVersion = true; for (ConfigurationProperty property : context.getConfigurationProperties()) { if (PROPERTY_VERIFY_NEWER_VERSION.equals(property.getName())) { List<String> values = property.getValues(); verifyNewerVersion = !(!values.isEmpty() && "false".equals(values.get(0))); break; }/*w ww . j a va2s. co m*/ } return verifyNewerVersion; }
From source file:com.gwtplatform.mvp.rebind.linker.FormFactorPropertyGenerator.java
License:Apache License
private String getQueryParamName(SortedSet<ConfigurationProperty> configProperties) { String queryParam = DEFAULT_QUERY_PARAM_NAME; for (ConfigurationProperty configProperty : configProperties) { if (configProperty.getName().equals(QUERY_PARAM_CONFIGURATION)) { queryParam = configProperty.getValues().get(0); break; }//from w w w .j av a2s .c o m } return queryParam; }
From source file:org.cesiumjs.linker.CesiumScriptInjector.java
License:Apache License
private static String getPageRelativeModulePath(LinkerContext context) { String moduleName = context.getModuleName(); List<String> pathBindings = null; for (ConfigurationProperty property : context.getConfigurationProperties()) { if (PAGE_RELATIVE_MODULE_PATH.equals(property.getName())) { pathBindings = property.getValues(); }//from w ww.j ava 2s.co m } if (pathBindings == null) return moduleName; for (String binding : pathBindings) { String[] parts = binding.split("="); if (parts.length == 2 && moduleName.equals(parts[0])) { System.out.println(" Setting page-relative module path for module '" + moduleName + "' using gwt.xml config"); return parts[1]; } } return moduleName; }
From source file:org.gwtbootstrap3.extras.cachemanifest.Offline.java
License:Apache License
@Override public ArtifactSet link(final TreeLogger logger, final LinkerContext context, final ArtifactSet artifacts) throws UnableToCompleteException { final ArtifactSet artifactset = new ArtifactSet(artifacts); final HashSet<String> resources = new HashSet<String>(); for (final EmittedArtifact emitted : artifacts.find(EmittedArtifact.class)) { if (skipArtifact(emitted)) continue; resources.add(emitted.getPartialPath()); }//from w w w. ja v a 2 s . c o m final SortedSet<ConfigurationProperty> staticFileProperties = context.getConfigurationProperties(); for (final ConfigurationProperty configurationProperty : staticFileProperties) { final String name = configurationProperty.getName(); if (CACHEMANIFEST_STATIC_FILES_PROPERTY.equals(name)) { for (final String value : configurationProperty.getValues()) { resources.add(value); } } } final String manifestString = buildManifestContents(resources); if (manifestString != null) { final EmittedArtifact manifest = emitString(logger, manifestString, "appcache.manifest"); artifactset.add(manifest); } return artifactset; }