本文整理了Java中us.ihmc.euclid.referenceFrame.ReferenceFrame.remove
方法的一些代码示例,展示了ReferenceFrame.remove
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ReferenceFrame.remove
方法的具体详情如下:
包路径:us.ihmc.euclid.referenceFrame.ReferenceFrame
类名称:ReferenceFrame
方法名:remove
[英]Will remove this frame from the frame tree.
This recursively disables all children of this frame also.
[中]将从帧树中删除此帧。
这会递归地禁用该帧的所有子帧。
代码示例来源:origin: us.ihmc/euclid-frame
/**
* Will remove the provided frame from the frame tree.
* <p>
* This recursively disables all children of this frame also. If the provided frame is a root frame
* this method will do nothing.
* </p>
*
* @param frame is the {@link ReferenceFrame} that will be removed from the tree.
* @deprecated Reference frames are automatically disposed of by the GC when no external reference
* exists.
* @since 0.9.4
*/
@Deprecated
public static void removeFrame(ReferenceFrame frame)
{
frame.remove();
}
代码示例来源:origin: us.ihmc/euclid-test
@Deprecated
@Test
public void testDisabeling() throws InstantiationException, IllegalAccessException
{
Random random = new Random(314114L);
ReferenceFrame[] someFrames = EuclidFrameRandomTools.nextReferenceFrameTree(random);
ReferenceFrame frameToDisable = someFrames[random.nextInt(someFrames.length - 1) + 1];
ReferenceFrame[] moreChildren = EuclidFrameRandomTools.nextReferenceFrameTree("AdditionalChild", random, frameToDisable, 10);
frameToDisable.remove();
checkDisabled(frameToDisable);
for (ReferenceFrame child : moreChildren)
{
checkDisabled(child);
}
}
代码示例来源:origin: us.ihmc/euclid-test
@Ignore
@Test
public void testUniqueNaming()
{
Random random = new Random(13L);
ReferenceFrame someFrame = EuclidFrameRandomTools.nextReferenceFrame(random);
String frameName = someFrame.getName();
ReferenceFrame parent = someFrame.getParent();
try
{
ReferenceFrameTools.constructFrameWithUnchangingTransformToParent(frameName, parent, new RigidBodyTransform());
fail("Should have thrown a RuntimeException");
}
catch (RuntimeException e)
{
// good
}
ReferenceFrameTools.removeFrame(someFrame);
someFrame = ReferenceFrameTools.constructFrameWithUnchangingTransformToParent(frameName, parent, new RigidBodyTransform());
someFrame.remove();
someFrame = ReferenceFrameTools.constructFrameWithUnchangingTransformToParent(frameName, parent, new RigidBodyTransform());
ReferenceFrameTools.clearFrameTree(someFrame);
someFrame = ReferenceFrameTools.constructFrameWithUnchangingTransformToParent(frameName, parent, new RigidBodyTransform());
ReferenceFrameTools.clearWorldFrameTree();
ReferenceFrameTools.constructFrameWithUnchangingTransformToParent(frameName, parent, new RigidBodyTransform());
}
内容来源于网络,如有侵权,请联系作者删除!