gpt4 book ai didi

us.ihmc.yoVariables.registry.YoVariableRegistry.registerVariable()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-17 12:16:40 27 4
gpt4 key购买 nike

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

YoVariableRegistry.registerVariable介绍

暂无

代码示例

代码示例来源:origin: us.ihmc/ihmc-yovariables

/**
* Static function to register a YoVariable to a given {@link YoVariableRegistry}.
*
* <p>Will print to stderr if the given registry is null and {@link YoVariable#warnAboutNullRegistries} is true.</p>
* 
* @param registry YoVariableRegistry to register the given variable to
* @param variable YoVariable to register
*/
private static void registerVariable(YoVariableRegistry registry, YoVariable<?> variable)
{
 if (registry != null)
 {
   registry.registerVariable(variable);
 }
 else if (warnAboutNullRegistries)
 {
   System.err.println("[WARN] " + YoVariable.class.getSimpleName() + ": " + variable.getName() + " is getting created with a null registry");
 }
}

代码示例来源:origin: us.ihmc/ihmc-robot-data-visualizer

public VisualizerRobot(RobotDescription robotDescription)
{
 super(robotDescription, false, false);
 this.reducedRegistry = new YoVariableRegistry(robotDescription.getName());
 reducedRegistry.registerVariable(getRootJoint().getQx());
 reducedRegistry.registerVariable(getRootJoint().getQy());
 reducedRegistry.registerVariable(getRootJoint().getQz());
 reducedRegistry.registerVariable(getRootJoint().getQdx());
 reducedRegistry.registerVariable(getRootJoint().getQdy());
 reducedRegistry.registerVariable(getRootJoint().getQdz());
 reducedRegistry.registerVariable(getRootJoint().getQuaternionQs());
 reducedRegistry.registerVariable(getRootJoint().getQuaternionQx());
 reducedRegistry.registerVariable(getRootJoint().getQuaternionQy());
 reducedRegistry.registerVariable(getRootJoint().getQuaternionQz());
 reducedRegistry.registerVariable(getRootJoint().getAngularVelocityX());
 reducedRegistry.registerVariable(getRootJoint().getAngularVelocityY());
 reducedRegistry.registerVariable(getRootJoint().getAngularVelocityZ());
 for(OneDegreeOfFreedomJoint joint : getOneDegreeOfFreedomJoints())
 {
   reducedRegistry.registerVariable(joint.getQYoVariable());
   reducedRegistry.registerVariable(joint.getQDYoVariable());
 }
}

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