gpt4 book ai didi

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

转载 作者:知者 更新时间:2024-03-17 00:22:40 26 4
gpt4 key购买 nike

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

YoInteger.decrement介绍

[英]Sets this YoInteger to its current value minus one.
[中]将此整数设置为其当前值减1。

代码示例

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

/**
* Removes the last element in the list. The underlying data object is not emptied or removed
*/
public void remove()
{
 nonEmptyCheck();
 position.decrement();
}

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

/** {@inheritDoc} */
@Override
public void removeVertex(int indexOfVertexToRemove)
{
 checkNonEmpty();
 checkIndexInBoundaries(indexOfVertexToRemove);
 if (indexOfVertexToRemove == numberOfVertices.getValue() - 1)
 {
   numberOfVertices.decrement();
   ;
   return;
 }
 isUpToDate = false;
 swap(vertexBuffer, indexOfVertexToRemove, numberOfVertices.getValue());
 numberOfVertices.decrement();
}

代码示例来源:origin: us.ihmc/ihmc-quadruped-robotics-test

@Override
public void doScript(double t)
{
 if(counter.getIntegerValue() == 0)
 {
   teleopManager.update();
   updateCounter();
 }
 else
 {
   counter.decrement();
 }
}

代码示例来源:origin: us.ihmc/simulation-construction-set-tools

@Override
public void doControl()
{
 if ((ticksTillNextWrite == null) || (ticksTillNextWrite.getIntegerValue() <= 0))
 {
   write();
      if (ticksTillNextWrite != null) ticksTillNextWrite.set(writeEveryNTicks-1);
 }
 else
 {
   ticksTillNextWrite.decrement();
 }
}

代码示例来源:origin: us.ihmc/simulation-construction-set-tools

@Override
public void doControl()
{
 if ((ticksTillNextRead == null) || (ticksTillNextRead.getIntegerValue() <= 0))
 {
   read(blockUntilNewDataIsAvailable);
   if (ticksTillNextRead != null)
    ticksTillNextRead.set(readEveryNTicks - 1);
 }
 else
 {
   ticksTillNextRead.decrement();
 }
}

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

/**
* Removes the element at the specified position in this list.
* Shifts any subsequent elements to the left (subtracts one from their
* indices).
*
* @param i the index of the element to be removed
*/
@Override
public T remove(int i)
{
 if (i == position.getIntegerValue())
 {
   remove();
   return values[i];
 }
 rangeCheck(i);
 T t = values[i];
 while (i < position.getIntegerValue())
 {
   values[i] = values[++i];
 }
 // Do not throw away the removed element, put it at the end of the list instead.
 values[position.getIntegerValue()] = t;
 position.decrement();
 return t;
}

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

@Override
public void doControl()
{
 if (pushCondition != null)
 {
   if (pushCondition.testCondition(yoTime.getDoubleValue()))
   {
    pushTimeSwitch.set(yoTime.getDoubleValue() + pushDelay.getDoubleValue());
    pushCondition = null;
   }
 }
 if (yoTime.getDoubleValue() <= pushTimeSwitch.getDoubleValue() + pushDuration.getDoubleValue()
    && yoTime.getDoubleValue() >= pushTimeSwitch.getDoubleValue())
 {
   isBeingPushed.set(true);
   forceVector.set(pushForce);
   pushNumber.decrement();
 }
 else
 {
   isBeingPushed.set(false);
   forceVector.set(0.0, 0.0, 0.0);
 }
 forcePoint.setForce(forceVector);
}

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