Example usage for com.google.gwt.core.ext.linker.impl PropertiesMappingArtifact PropertiesMappingArtifact

List of usage examples for com.google.gwt.core.ext.linker.impl PropertiesMappingArtifact PropertiesMappingArtifact

Introduction

In this page you can find the example usage for com.google.gwt.core.ext.linker.impl PropertiesMappingArtifact PropertiesMappingArtifact.

Prototype

public PropertiesMappingArtifact(Class<? extends Linker> linker,
            Map<PermutationId, List<Map<String, String>>> mappings) 

Source Link

Usage

From source file:cc.alcina.framework.gwt.appcache.linker.PermutationInfoLinker.java

License:Apache License

protected void maybeOutputPropertyMap(TreeLogger logger, LinkerContext context, ArtifactSet toReturn) {
    if (permutationsUtil.getPermutationsMap() == null || permutationsUtil.getPermutationsMap().isEmpty()) {
        return;/*  ww w .j av a  2  s  .c o m*/
    }
    PropertiesMappingArtifact mappingArtifact = new PropertiesMappingArtifact(CrossSiteIframeLinker.class,
            permutationsUtil.getPermutationsMap());
    toReturn.add(mappingArtifact);
    EmittedArtifact serializedMap;
    try {
        String mappings = mappingArtifact.getSerialized();
        serializedMap = emitString(logger, mappings, "compilation-mappings.txt");
        // TODO(unnurg): make this Deploy
        serializedMap.setVisibility(Visibility.Public);
        toReturn.add(serializedMap);
    } catch (UnableToCompleteException e) {
        e.printStackTrace();
    }
}