From fc2d5447d2ea96dd9537d98abfada82674522d78 Mon Sep 17 00:00:00 2001 From: meri Date: Thu, 27 Mar 2014 21:29:28 +0100 Subject: [PATCH] Renamed files #22 --- ...tringsEvaluator.java => EmbeddedLessGenerator.java} | 4 ++-- ...ddedScripting.java => EmbeddedScriptGenerator.java} | 2 +- .../java/com/github/sommeri/less4j/LessCompiler.java | 6 +++--- .../core/compiler/expressions/ExpressionEvaluator.java | 8 ++++---- .../expressions/strings/StringInterpolator.java | 10 +++++----- 5 files changed, 15 insertions(+), 15 deletions(-) rename src/main/java/com/github/sommeri/less4j/{LessStringsEvaluator.java => EmbeddedLessGenerator.java} (80%) rename src/main/java/com/github/sommeri/less4j/{EmbeddedScripting.java => EmbeddedScriptGenerator.java} (80%) diff --git a/src/main/java/com/github/sommeri/less4j/LessStringsEvaluator.java b/src/main/java/com/github/sommeri/less4j/EmbeddedLessGenerator.java similarity index 80% rename from src/main/java/com/github/sommeri/less4j/LessStringsEvaluator.java rename to src/main/java/com/github/sommeri/less4j/EmbeddedLessGenerator.java index 607d53c3..c0d9f3c3 100644 --- a/src/main/java/com/github/sommeri/less4j/LessStringsEvaluator.java +++ b/src/main/java/com/github/sommeri/less4j/EmbeddedLessGenerator.java @@ -3,9 +3,9 @@ import com.github.sommeri.less4j.core.ast.Expression; import com.github.sommeri.less4j.utils.InStringCssPrinter; -public class LessStringsEvaluator implements EmbeddedScripting { +public class EmbeddedLessGenerator implements EmbeddedScriptGenerator { - public LessStringsEvaluator() { + public EmbeddedLessGenerator() { super(); } diff --git a/src/main/java/com/github/sommeri/less4j/EmbeddedScripting.java b/src/main/java/com/github/sommeri/less4j/EmbeddedScriptGenerator.java similarity index 80% rename from src/main/java/com/github/sommeri/less4j/EmbeddedScripting.java rename to src/main/java/com/github/sommeri/less4j/EmbeddedScriptGenerator.java index d87938f6..c0eb3b59 100644 --- a/src/main/java/com/github/sommeri/less4j/EmbeddedScripting.java +++ b/src/main/java/com/github/sommeri/less4j/EmbeddedScriptGenerator.java @@ -2,7 +2,7 @@ import com.github.sommeri.less4j.core.ast.Expression; -public interface EmbeddedScripting { +public interface EmbeddedScriptGenerator { String toScriptExpression(Expression value, LessProblems problemsHandler); diff --git a/src/main/java/com/github/sommeri/less4j/LessCompiler.java b/src/main/java/com/github/sommeri/less4j/LessCompiler.java index 5269aca5..ef925e4d 100644 --- a/src/main/java/com/github/sommeri/less4j/LessCompiler.java +++ b/src/main/java/com/github/sommeri/less4j/LessCompiler.java @@ -32,7 +32,7 @@ public class Configuration { private LessSource cssResultLocation; private boolean linkSourceMap = true; private List functionPackages = new ArrayList(); - private EmbeddedScripting embeddedScripting; + private EmbeddedScriptGenerator embeddedScripting; /** * This is needed in for source map. @@ -70,11 +70,11 @@ public void addCustomFunction(LessFunction functionPackage) { this.functionPackages.add(functionPackage); } - public EmbeddedScripting getEmbeddedScripting() { + public EmbeddedScriptGenerator getEmbeddedScripting() { return embeddedScripting; } - public void setEmbeddedScripting(EmbeddedScripting embeddedScripting) { + public void setEmbeddedScripting(EmbeddedScriptGenerator embeddedScripting) { this.embeddedScripting = embeddedScripting; } diff --git a/src/main/java/com/github/sommeri/less4j/core/compiler/expressions/ExpressionEvaluator.java b/src/main/java/com/github/sommeri/less4j/core/compiler/expressions/ExpressionEvaluator.java index 605acd68..0119cf16 100644 --- a/src/main/java/com/github/sommeri/less4j/core/compiler/expressions/ExpressionEvaluator.java +++ b/src/main/java/com/github/sommeri/less4j/core/compiler/expressions/ExpressionEvaluator.java @@ -6,9 +6,9 @@ import java.util.Iterator; import java.util.List; -import com.github.sommeri.less4j.EmbeddedScripting; +import com.github.sommeri.less4j.EmbeddedScriptGenerator; import com.github.sommeri.less4j.LessCompiler.Configuration; -import com.github.sommeri.less4j.LessStringsEvaluator; +import com.github.sommeri.less4j.EmbeddedLessGenerator; import com.github.sommeri.less4j.core.ast.ASTCssNode; import com.github.sommeri.less4j.core.ast.ASTCssNodeType; import com.github.sommeri.less4j.core.ast.AbstractVariableDeclaration; @@ -59,7 +59,7 @@ public class ExpressionEvaluator { private List functions = new ArrayList(); private StringInterpolator stringInterpolator; private StringInterpolator embeddedScriptInterpolator; - private EmbeddedScripting embeddedScripting; + private EmbeddedScriptGenerator embeddedScripting; public ExpressionEvaluator(ProblemsHandler problemsHandler, Configuration configuration) { this(new NullScope(), problemsHandler, configuration); @@ -71,7 +71,7 @@ public ExpressionEvaluator(IScope scope, ProblemsHandler problemsHandler, Config this.problemsHandler = problemsHandler; arithmeticCalculator = new ArithmeticCalculator(problemsHandler); colorsCalculator = new ColorsCalculator(problemsHandler); - embeddedScripting = configuration.getEmbeddedScripting() == null ? new LessStringsEvaluator() : configuration.getEmbeddedScripting(); + embeddedScripting = configuration.getEmbeddedScripting() == null ? new EmbeddedLessGenerator() : configuration.getEmbeddedScripting(); stringInterpolator = new StringInterpolator(problemsHandler); embeddedScriptInterpolator = new StringInterpolator(embeddedScripting, problemsHandler); diff --git a/src/main/java/com/github/sommeri/less4j/core/compiler/expressions/strings/StringInterpolator.java b/src/main/java/com/github/sommeri/less4j/core/compiler/expressions/strings/StringInterpolator.java index 9f275b05..46c119f7 100644 --- a/src/main/java/com/github/sommeri/less4j/core/compiler/expressions/strings/StringInterpolator.java +++ b/src/main/java/com/github/sommeri/less4j/core/compiler/expressions/strings/StringInterpolator.java @@ -2,8 +2,8 @@ import java.util.regex.Pattern; -import com.github.sommeri.less4j.EmbeddedScripting; -import com.github.sommeri.less4j.LessStringsEvaluator; +import com.github.sommeri.less4j.EmbeddedScriptGenerator; +import com.github.sommeri.less4j.EmbeddedLessGenerator; import com.github.sommeri.less4j.core.ast.Expression; import com.github.sommeri.less4j.core.ast.Variable; import com.github.sommeri.less4j.core.compiler.expressions.ExpressionEvaluator; @@ -13,14 +13,14 @@ public class StringInterpolator extends AbstractStringReplacer { private static final Pattern STR_INTERPOLATION = Pattern.compile("@\\{([^\\{\\}@])*\\}"); - private final EmbeddedScripting embeddedScriptEvaluator; + private final EmbeddedScriptGenerator embeddedScriptEvaluator; private final ProblemsHandler problemsHandler; public StringInterpolator(ProblemsHandler problemsHandler) { - this(new LessStringsEvaluator(), problemsHandler); + this(new EmbeddedLessGenerator(), problemsHandler); } - public StringInterpolator(EmbeddedScripting embeddedScriptEvaluator, ProblemsHandler problemsHandler) { + public StringInterpolator(EmbeddedScriptGenerator embeddedScriptEvaluator, ProblemsHandler problemsHandler) { this.embeddedScriptEvaluator = embeddedScriptEvaluator; this.problemsHandler = problemsHandler; }