- 使用 Spring Initializr 创建 Spring Boot 应用程序
- 在Spring Boot中配置Cassandra
- 在 Spring Boot 上配置 Tomcat 连接池
- 将Camel消息路由到嵌入WildFly的Artemis上
本文整理了Java中us.ihmc.yoVariables.parameters.YoParameter
类的一些代码示例,展示了YoParameter
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YoParameter
类的具体详情如下:
包路径:us.ihmc.yoVariables.parameters.YoParameter
类名称:YoParameter
[英]Base class for parameters. Parameters cannot be changed from code and are only changed by the user/operator. Available implementations - BooleanParameter - DoubleParameter - EnumParameter - IntegerParameter - LongParameter
[中]参数的基类。参数不能从代码中更改,只能由用户/操作员更改。可用实现-booleanparmeter-DoubleParameter-enumparmeter-IntegerParameter-longparmeter
代码示例来源:origin: us.ihmc/ihmc-yovariables
YoParameter(String name, String description)
{
checkForIllegalCharacters(name);
this.name = name;
this.description = description;
}
代码示例来源:origin: us.ihmc/ihmc-yovariables
public void setParameterFromThis(YoParameter<?> parameter)
{
parameter.load(value);
parameter.setSuggestedRange(min, max);
}
}
代码示例来源:origin: us.ihmc/ihmc-yovariables
public void writeParametersInRegistry(YoVariableRegistry registry)
{
List<YoParameter<?>> parameters = registry.getAllParameters();
for(int i = 0; i < parameters.size(); i++)
{
YoParameter<?> parameter = parameters.get(i);
NameSpace relativeNamespace = AbstractParameterReader.getRelativeNamespace(parameter.getNameSpace(), registry);
String value = parameter.getValueAsString();
String min = String.valueOf(parameter.getVariable().getManualScalingMin());
String max = String.valueOf(parameter.getVariable().getManualScalingMax());
setValue(relativeNamespace, parameter.getName(), parameter.getDescription(), parameter.getClass().getSimpleName(), value, min, max);
}
}
代码示例来源:origin: us.ihmc/ihmc-yovariables
NameSpace relativeNamespace = getRelativeNamespace(parameter.getNameSpace(), registry);
String fullName = relativeNamespace + "." + parameter.getName();
ParameterData data = localMap.remove(fullName);
parameter.loadDefault();
defaultParametersToPack.add(fullName);
代码示例来源:origin: us.ihmc/ihmc-yovariables
/**
*
* @return the namespace of this parameter
*/
public NameSpace getNameSpace()
{
return getVariable().getNameSpace();
}
代码示例来源:origin: us.ihmc/ekf
public static DoubleParameter findOrCreate(String name, YoVariableRegistry registry, double initialValue)
{
Optional<YoParameter<?>> parameter = registry.getParametersInThisRegistry().stream().filter(p -> p.getName().equals(name)).findFirst();
if (parameter.isPresent())
{
return (DoubleParameter) parameter.get();
}
return new DoubleParameter(name, registry, initialValue);
}
}
代码示例来源:origin: us.ihmc/ihmc-yovariables
/**
* Sets the suggested range for tuning purposes.
*
* The minimum and maximum will not be enforced and the parameter can be
* set to any value. This is just a suggestion to the user.
*
* @param min Lower end of the suggested range for this parameter.
* @param max Upper end of the suggested range for this parameter.
*/
public void setSuggestedRange(int min, int max)
{
super.setSuggestedRange(min, max);
}
代码示例来源:origin: us.ihmc/ihmc-robot-data-logger
if (variable.isParameter())
ParameterLoadStatus loadStatus = variable.getParameter().getLoadStatus();
switch (loadStatus)
代码示例来源:origin: us.ihmc/ihmc-yovariables
public static void readParameter(YoParameter<?> parameter, double doubleValue, ParameterLoadStatus loadStatus)
{
if (loadStatus == ParameterLoadStatus.UNLOADED)
{
throw new RuntimeException("Can not load parameter and set the status to unloaded.");
}
parameter.getVariable().setValueFromDouble(doubleValue);
parameter.loadStatus = loadStatus;
}
}
代码示例来源:origin: us.ihmc/ihmc-yovariables
/**
* Sets the suggested range for tuning purposes.
*
* The minimum and maximum will not be enforced and the parameter can be
* set to any value. This is just a suggestion to the user.
*
* @param min Lower end of the suggested range for this parameter.
* @param max Upper end of the suggested range for this parameter.
*/
public void setSuggestedRange(long min, long max)
{
super.setSuggestedRange(min, max);
}
代码示例来源:origin: us.ihmc/ihmc-yovariables
void setSuggestedRange(double min, double max)
{
getVariable().setManualScalingMinMax(min, max);
}
代码示例来源:origin: us.ihmc/ihmc-yovariables
/**
* Sets the suggested range for tuning purposes.
*
* The minimum and maximum will not be enforced and the parameter can be
* set to any value. This is just a suggestion to the user.
*
* @param min Lower end of the suggested range for this parameter.
* @param max Upper end of the suggested range for this parameter.
*/
@Override
public void setSuggestedRange(double min, double max)
{
super.setSuggestedRange(min, max);
}
代码示例来源:origin: us.ihmc/ihmc-yovariables
public double getManualScalingMax()
{
return getVariable().getManualScalingMax();
}
代码示例来源:origin: us.ihmc/ihmc-yovariables
public double getManualScalingMin()
{
return getVariable().getManualScalingMin();
}
代码示例来源:origin: us.ihmc/ihmc-yovariables
/**
* Attaches an object implementing {@link ParameterChangedListener} to this parameter's list of listeners.
*
*<p>Instantiates a new list of listeners if it is currently empty.</p>
*
* @param ParameterChangedListener ParameterChangedListener to attach
*/
public void addParameterChangedListener(ParameterChangedListener parameterChangedListener)
{
if (parameterChangedListenersHolder == null)
{
parameterChangedListenersHolder = new YoParameterChangedListenerHolder();
getVariable().addVariableChangedListener(parameterChangedListenersHolder);
}
this.parameterChangedListenersHolder.add(parameterChangedListener);
}
本文整理了Java中us.ihmc.yoVariables.parameters.YoParameter.getName()方法的一些代码示例,展示了YoParameter.getName()的具体用
我是一名优秀的程序员,十分优秀!