gpt4 book ai didi

us.ihmc.yoVariables.variable.YoVariable.getValueAsLongBits()方法的使用及代码示例

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

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

YoVariable.getValueAsLongBits介绍

[英]Retrieves this variable's value interpreted as a long.

Abstract; implemented by each extension of YoVariable to result in different interpretation.
[中]检索此变量的值,该值被解释为长字符串。
摘要通过变量的每个扩展来实现,从而产生不同的解释。

代码示例

代码示例来源:origin: us.ihmc/ihmc-avatar-interfaces-test

/**
* Finds the number of waypoints in a {@link RigidBodyTaskspaceControlState} for the body with the
* given name.
*/
public static int findControllerNumberOfWaypoints(String bodyName, String postfix, SimulationConstructionSet scs)
{
 String variableName = bodyName + postfix + "TaskspaceNumberOfPoints";
 return (int) scs.getVariable(variableName).getValueAsLongBits();
}

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

private ByteBuffer reconstructBuffer(long timestamp)
{
 dataBuffer.clear();
 dataBufferAsLong.clear();
 
 dataBufferAsLong.put(timestamp);
 for(int i = 0; i < variables.size();i++)
 {
   dataBufferAsLong.put(variables.get(i).getValueAsLongBits());
 }
 
 for(int i = 0; i < jointStates.size(); i++)
 {
   jointStates.get(i).get(dataBufferAsLong);
 }
 
 
 dataBufferAsLong.flip();
 dataBuffer.clear();
 return dataBuffer;
}

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

private void setAndNotify(YoVariable<?> variable, long newValue)
{
 long previousValue = variable.getValueAsLongBits();
 variable.setValueFromLongBits(newValue, false);
 if (previousValue != newValue)
 {
   ArrayList<VariableChangedListener> changedListeners = variable.getVariableChangedListeners();
   if (changedListeners != null)
   {
    for (int listener = 0; listener < changedListeners.size(); listener++)
    {
      VariableChangedListener changedListener = changedListeners.get(listener);
      if (!(changedListener instanceof VariableChangedProducer.VariableListener))
      {
       changedListener.notifyOfVariableChange(variable);
      }
    }
   }
 }
}

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

for (int i = offset; i < end; i++)
  this.data.put(variables[i].getValueAsLongBits());

代码示例来源:origin: us.ihmc/ihmc-avatar-interfaces-test

expectedNumberOfSteps += messages.get(messageIdx).getFootstepDataList().size();
  assertTrue(drcSimulationTestHelper.simulateAndBlockAndCatchExceptions(timeBetweenSendingMessages));
  assertEquals(expectedNumberOfSteps, (int) numberOfStepsInController.getValueAsLongBits());
  timeUntilDone -= timeBetweenSendingMessages;
assertEquals(0, (int) numberOfStepsInController.getValueAsLongBits());

代码示例来源:origin: us.ihmc/ihmc-avatar-interfaces-test

assertTrue(drcSimulationTestHelper.simulateAndBlockAndCatchExceptions(0.05));
assertEquals(0, (int) footsteps.getValueAsLongBits());
assertEquals(0, (int) handTrajectoryPoints.getValueAsLongBits());
assertTrue(drcSimulationTestHelper.simulateAndBlockAndCatchExceptions(0.1));
assertEquals(10, (int) footsteps.getValueAsLongBits());
assertEquals(0, (int) handTrajectoryPoints.getValueAsLongBits());

代码示例来源:origin: us.ihmc/ihmc-avatar-interfaces-test

assertEquals("Swing Trajectory did not execute.", points, currentWaypointIndex.getValueAsLongBits());

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