only:minor header fix
This commit is contained in:
parent
5e9cb08a7c
commit
8f627887b7
|
@ -1,10 +1,8 @@
|
|||
package com.rusefi.output;
|
||||
|
||||
import com.rusefi.ConfigField;
|
||||
import com.rusefi.ConfigFieldImpl;
|
||||
import com.rusefi.ReaderState;
|
||||
import com.rusefi.TypesHelper;
|
||||
import com.rusefi.core.Tuple;
|
||||
import com.rusefi.output.variables.VariableRecord;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
@ -29,10 +27,12 @@ import static com.rusefi.output.GetOutputValueConsumer.wrapSwitchStatement;
|
|||
public class GetConfigValueConsumer implements ConfigurationConsumer {
|
||||
private static final String CONFIG_ENGINE_CONFIGURATION = "config->engineConfiguration.";
|
||||
private static final String ENGINE_CONFIGURATION = "engineConfiguration.";
|
||||
static final String FILE_HEADER =
|
||||
"// generated by " + GetConfigValueConsumer.class.getSimpleName() + ".java\n" +
|
||||
"#include \"pch.h\"\n" +
|
||||
"#include \"value_lookup.h\"\n";
|
||||
|
||||
public static String getHeader(Class clazz) {
|
||||
return "// generated by " + clazz.getSimpleName() + ".java\n" +
|
||||
"#include \"pch.h\"\n" +
|
||||
"#include \"value_lookup.h\"\n";
|
||||
}
|
||||
|
||||
private static final String GET_METHOD_HEADER =
|
||||
"float getConfigValueByName(const char *name) {\n";
|
||||
|
@ -118,7 +118,7 @@ public class GetConfigValueConsumer implements ConfigurationConsumer {
|
|||
}
|
||||
|
||||
public String getHeaderAndGetter() {
|
||||
return FILE_HEADER +
|
||||
return GetConfigValueConsumer.getHeader(getClass()) +
|
||||
getCompleteGetterBody();
|
||||
}
|
||||
|
||||
|
|
|
@ -3,7 +3,6 @@ package com.rusefi.output;
|
|||
import com.rusefi.ConfigField;
|
||||
import com.rusefi.ReaderState;
|
||||
import com.rusefi.TypesHelper;
|
||||
import com.rusefi.core.Pair;
|
||||
import com.rusefi.output.variables.VariableRecord;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
|
@ -15,7 +14,6 @@ import java.util.concurrent.atomic.AtomicInteger;
|
|||
|
||||
import static com.rusefi.output.ConfigStructureImpl.ALIGNMENT_FILL_AT;
|
||||
import static com.rusefi.output.DataLogConsumer.UNUSED;
|
||||
import static com.rusefi.output.GetConfigValueConsumer.FILE_HEADER;
|
||||
import static com.rusefi.output.GetConfigValueConsumer.getCompareName;
|
||||
|
||||
/**
|
||||
|
@ -75,7 +73,7 @@ public class GetOutputValueConsumer implements ConfigurationConsumer {
|
|||
|
||||
String fullSwitch = wrapSwitchStatement(switchBody);
|
||||
|
||||
return FILE_HEADER +
|
||||
return GetConfigValueConsumer.getHeader(getClass()) +
|
||||
"float getOutputValueByName(const char *name) {\n" +
|
||||
fullSwitch +
|
||||
getterBody + GetConfigValueConsumer.GET_METHOD_FOOTER;
|
||||
|
|
Loading…
Reference in New Issue