gpt4 book ai didi

com.atlassian.maven.plugins.amps.util.minifier.YUIErrorReporter类的使用及代码示例

转载 作者:知者 更新时间:2024-03-20 12:44:31 32 4
gpt4 key购买 nike

本文整理了Java中com.atlassian.maven.plugins.amps.util.minifier.YUIErrorReporter类的一些代码示例,展示了YUIErrorReporter类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YUIErrorReporter类的具体详情如下:
包路径:com.atlassian.maven.plugins.amps.util.minifier.YUIErrorReporter
类名称:YUIErrorReporter

YUIErrorReporter介绍

暂无

代码示例

代码示例来源:origin: com.atlassian.maven.plugins/amps-maven-plugin

@Override
public void warning(String message, String sourceName, int line, String lineSource, int lineOffset)
{
  log.warn(getMessage(message,sourceName,line,lineSource,lineOffset));
}

代码示例来源:origin: com.atlassian.maven.plugins/amps-maven-plugin

@Override
public EvaluatorException runtimeError(String message, String sourceName, int line, String lineSource, int lineOffset)
{
  error(message,sourceName,line,lineSource,lineOffset);
  throw new EvaluatorException(message,sourceName,line,lineSource,lineOffset);
}

代码示例来源:origin: com.atlassian.maven.plugins/amps-maven-plugin

private void yuiJsCompile(File sourceFile, File destFile, Log log, Charset cs) throws MojoExecutionException
{
  try
  {
    FileUtils.forceMkdir(destFile.getParentFile());
    try (InputStreamReader in = new InputStreamReader(new FileInputStream(sourceFile), cs);
       OutputStreamWriter out = new OutputStreamWriter(new FileOutputStream(destFile), cs))
    {
      JavaScriptCompressor yui = new JavaScriptCompressor(in, new YUIErrorReporter(log));
      yui.compress(out, -1, true, false, false, false);
    }
  }
  catch (IOException e)
  {
    throw new MojoExecutionException("IOException when compiling JS", e);
  }
}

代码示例来源:origin: com.atlassian.maven.plugins/maven-amps-plugin

@Override
public EvaluatorException runtimeError(String message, String sourceName, int line, String lineSource, int lineOffset)
{
  error(message,sourceName,line,lineSource,lineOffset);
  throw new EvaluatorException(message,sourceName,line,lineSource,lineOffset);
}

代码示例来源:origin: com.atlassian.maven.plugins/maven-amps-plugin

private void yuiJsCompile(File sourceFile, File destFile, Log log, Charset cs) throws MojoExecutionException
{
  InputStreamReader in = null;
  OutputStreamWriter out = null;
  try
  {
    FileUtils.forceMkdir(destFile.getParentFile());
    in = new InputStreamReader(new FileInputStream(sourceFile), cs);
    out = new OutputStreamWriter(new FileOutputStream(destFile), cs);
    
    JavaScriptCompressor yui = new JavaScriptCompressor(in,new YUIErrorReporter(log));
    yui.compress(out,-1,true,false,false,false);
  }
  catch (IOException e)
  {
    throw new MojoExecutionException("IOException when compiling JS", e);
  }
  finally {
    IOUtils.closeQuietly(in);
    IOUtils.closeQuietly(out);
  }
}

代码示例来源:origin: com.atlassian.maven.plugins/maven-amps-plugin

@Override
public void warning(String message, String sourceName, int line, String lineSource, int lineOffset)
{
  log.warn(getMessage(message,sourceName,line,lineSource,lineOffset));
}

代码示例来源:origin: com.atlassian.maven.plugins/maven-amps-plugin

@Override
public void error(String message, String sourceName, int line, String lineSource, int lineOffset)
{
  log.error(getMessage(message,sourceName,line,lineSource,lineOffset));
}

代码示例来源:origin: com.atlassian.maven.plugins/amps-maven-plugin

@Override
public void error(String message, String sourceName, int line, String lineSource, int lineOffset)
{
  log.error(getMessage(message,sourceName,line,lineSource,lineOffset));
}

32 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com