Codota Logo
PairList.add
Code IndexAdd Codota to your IDE (free)

How to use
add
method
in
us.ihmc.tools.lists.PairList

Best Java code snippets using us.ihmc.tools.lists.PairList.add (Showing top 10 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
BufferedReader b =
  • Codota IconInputStream in;new BufferedReader(new InputStreamReader(in))
  • Codota IconReader in;new BufferedReader(in)
  • Codota IconFile file;new BufferedReader(new FileReader(file))
  • Smart code suggestions by Codota
}
origin: us.ihmc/IHMCJavaToolkit

public void add(T first, V second)
{
 add(new ImmutablePair<T, V>(first, second));
}
origin: us.ihmc/ihmc-avatar-interfaces

public void add(L leftObjectToAdd, R rightObjectToAdd)
{
 PairList<L, R> existingList = getCopyForReading();
 PairList<L, R> updatedList = getCopyForWriting();
 updatedList.clear();
 if (existingList != null)
   updatedList.addAll(existingList);
 updatedList.add(new ImmutablePair<>(leftObjectToAdd, rightObjectToAdd));
 this.commit();
}
origin: us.ihmc/ihmc-java-toolkit

public void add(T first, V second)
{
 add(new ImmutablePair<T, V>(first, second));
}
origin: us.ihmc/SensorProcessing

public RawJointSensorDataHolderMapCopier(RawJointSensorDataHolderMap originalMap, RawJointSensorDataHolderMap targetMap)
{
 List<RawJointSensorDataHolder> originals = new ArrayList<RawJointSensorDataHolder>(originalMap.values());
 List<RawJointSensorDataHolder> targets = new ArrayList<RawJointSensorDataHolder>(targetMap.values());
 
 if(originals.size() != targets.size())
 {
   throw new RuntimeException("Original and Target are not of equal length");
 }
 
 for(int i = 0; i < originals.size(); i++)
 {
   RawJointSensorDataHolder original = originals.get(i);
   RawJointSensorDataHolder target = targets.get(i); 
   if(!original.getName().equals(target.getName()))
   {
    throw new RuntimeException("Original and Target don't match. Got: " + target.getName() + ", expected: " + original.getName());
   }
      originalAndTarget.add(original, target);
 }
}
origin: us.ihmc/ihmc-avatar-interfaces

@Override
public void setJointDesiredOutputList(JointDesiredOutputList lowLevelDataHolder)
{
 revoluteJoints.clear();
 for (int i = 0; i < lowLevelDataHolder.getNumberOfJointsWithDesiredOutput(); i++)
 {
   OneDoFJointBasics revoluteJoint = lowLevelDataHolder.getOneDoFJoint(i);
   JointDesiredOutputReadOnly data = lowLevelDataHolder.getJointDesiredOutput(i);
   String name = revoluteJoint.getName();
   OneDegreeOfFreedomJoint oneDoFJoint = robot.getOneDegreeOfFreedomJoint(name);
   ImmutablePair<OneDegreeOfFreedomJoint, JointDesiredOutputReadOnly> jointPair = new ImmutablePair<OneDegreeOfFreedomJoint, JointDesiredOutputReadOnly>(oneDoFJoint, data);
   this.revoluteJoints.add(jointPair);
 }
}
origin: us.ihmc/ihmc-whole-body-controller

@Override
public void setLowLevelControllerCoreOutput(FullHumanoidRobotModel controllerRobotModel,
                      JointDesiredOutputList lowLevelControllerCoreOutput,
                      RawJointSensorDataHolderMap rawJointSensorDataHolderMap)
{
 if (drcOutputWriter != null)
 {
   drcOutputWriter.setLowLevelControllerCoreOutput(controllerRobotModel, lowLevelControllerCoreOutput, rawJointSensorDataHolderMap);
 }
 torqueOffsetList = new PairList<>();
 torqueOffsetMap = new HashMap<>();
 for (int i = 0; i < lowLevelControllerCoreOutput.getNumberOfJointsWithDesiredOutput(); i++)
 {
   JointDesiredOutputBasics jointData = lowLevelControllerCoreOutput.getJointDesiredOutput(i);
   final YoDouble torqueOffset = new YoDouble("tauOffset_" + lowLevelControllerCoreOutput.getJointName(i), registry);
   torqueOffsetList.add(jointData, torqueOffset);
   torqueOffsetMap.put(lowLevelControllerCoreOutput.getOneDoFJoint(i), torqueOffset);
 }
}
origin: us.ihmc/ihmc-whole-body-controller

@Override
public void setLowLevelControllerCoreOutput(FullHumanoidRobotModel controllerRobotModel, JointDesiredOutputList lowLevelControllerCoreOutput, RawJointSensorDataHolderMap rawJointSensorDataHolderMap)
{
 if(drcOutputProcessor != null)
 {
   drcOutputProcessor.setLowLevelControllerCoreOutput(controllerRobotModel, lowLevelControllerCoreOutput, rawJointSensorDataHolderMap);
 }
 for (int i = 0; i < lowLevelControllerCoreOutput.getNumberOfJointsWithDesiredOutput(); i++)
 {
   JointDesiredOutputBasics jointData = lowLevelControllerCoreOutput.getJointDesiredOutput(i);
   String jointName = lowLevelControllerCoreOutput.getOneDoFJoint(i).getName();
   AlphaFilteredYoVariable jointTorqueSmoothedAtStateChange = new AlphaFilteredYoVariable("smoothed_tau_" + jointName, registry, alphaForJointTorqueForStateChanges);
   jointTorquesSmoothedAtStateChange.add(jointData, jointTorqueSmoothedAtStateChange);
 }
}
origin: us.ihmc/ihmc-whole-body-controller

  jointStateAndData.add(controllerRobotModel.getLegJoint(robotSide, jointName), lowLevelControllerCoreOutput.getJointDesiredOutput(controllerRobotModel.getLegJoint(robotSide, jointName)));
for (ArmJointName jointName : armJointsForIntegratingAcceleration)
  jointStateAndData.add(controllerRobotModel.getArmJoint(robotSide, jointName), lowLevelControllerCoreOutput.getJointDesiredOutput(controllerRobotModel.getArmJoint(robotSide, jointName)));
jointStateAndData.add(controllerRobotModel.getSpineJoint(jointName), lowLevelControllerCoreOutput.getJointDesiredOutput(controllerRobotModel.getSpineJoint(jointName)));
jointStateAndData.add(lowLevelControllerCoreOutput.getOneDoFJoint(i), lowLevelControllerCoreOutput.getJointDesiredOutput(lowLevelControllerCoreOutput.getOneDoFJoint(i)));
origin: us.ihmc/ihmc-whole-body-controller

controlledJoints.add(joint, lowLevelOutput.getJointDesiredOutput(joint));
origin: us.ihmc/valkyrie

public ValkyrieCalibrationControllerState(HighLevelHumanoidControllerToolbox highLevelControllerToolbox,
                     HighLevelControllerParameters highLevelControllerParameters,
                     JointDesiredOutputListReadOnly highLevelControlOutput,
                     ValkyrieCalibrationParameters calibrationParameters, TorqueOffsetPrinter torqueOffsetPrinter)
{
 super(controllerState, highLevelControllerParameters, MultiBodySystemTools.filterJoints(highLevelControllerToolbox.getControlledJoints(), OneDoFJoint.class));
 this.highLevelControlOutput = highLevelControlOutput;
 for (OneDoFJointBasics controlledJoint : controlledJoints)
 {
   String jointName = controlledJoint.getName();
   YoPolynomial trajectory = new YoPolynomial(jointName + "_CalibrationTrajectory", 4, registry);
   YoDouble initialPosition = new YoDouble(jointName + "_CalibrationInitialPosition", registry);
   jointsData.add(controlledJoint, new TrajectoryData(initialPosition, trajectory));
 }
 timeToMoveForCalibration.set(timeToMove);
 timeForEstimatingOffset.set(highLevelControllerParameters.getCalibrationDuration());
 jointTorqueOffsetEstimatorController = new JointTorqueOffsetEstimatorController(calibrationParameters, highLevelControllerToolbox, torqueOffsetPrinter);
 registry.addChild(jointTorqueOffsetEstimatorController.getYoVariableRegistry());
 lowLevelOneDoFJointDesiredDataHolder.registerJointsWithEmptyData(controlledJoints);
 
 StateMachineFactory<CalibrationStates, CalibrationState> factory = new StateMachineFactory<>(CalibrationStates.class);
 factory.setNamePrefix("calibrationState").setRegistry(registry).buildYoClock(highLevelControllerToolbox.getYoTime());
 factory.addStateAndDoneTransition(CalibrationStates.ENTRY, new CalibrationEntry(), CalibrationStates.CALIBRATE);
 factory.addStateAndDoneTransition(CalibrationStates.CALIBRATE, new Calibration(), CalibrationStates.EXIT);
 factory.addState(CalibrationStates.EXIT, new CalibrationExit());
 stateMachine = factory.build(CalibrationStates.ENTRY);
}
us.ihmc.tools.listsPairListadd

Popular methods of PairList

  • size
  • first
  • get
  • second
  • remove
  • <init>
  • addAll
  • clear
  • isEmpty
  • sort

Popular in Java

  • Creating JSON documents from java classes using gson
  • compareTo (BigDecimal)
  • putExtra (Intent)
  • setScale (BigDecimal)
    Returns a BigDecimal whose scale is the specified value, and whose value is numerically equal to thi
  • UnknownHostException (java.net)
    Thrown when a hostname can not be resolved.
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate(i
  • HashSet (java.util)
    This class implements the Set interface, backed by a hash table (actually a HashMap instance). It m
  • TimerTask (java.util)
    A task that can be scheduled for one-time or repeated execution by a Timer.
  • Annotation (javassist.bytecode.annotation)
    The annotation structure.An instance of this class is returned bygetAnnotations() in AnnotationsAttr
  • Project (org.apache.tools.ant)
    Central representation of an Ant project. This class defines an Ant project with all of its targets,
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now