movement.java

来自「linux下用于移动节点的移动活动生成工具」· Java 代码 · 共 80 行

JAVA
80
字号
package de.uni_stuttgart.informatik.canu.mobisim.mobilitymodels;

import de.uni_stuttgart.informatik.canu.mobisim.core.*;

/**
 * Title:        Canu Mobility Simulation Environment
 * Description:
 * Copyright:    Copyright (c) 2001-2003
 * Company:      University of Stuttgart
 * @author Canu Research group
 * @version 1.1
 */

/**
 * This class is a base class for implementations of mobility models
 * @author Illya Stepanov
 */
public abstract class Movement extends ExtensionModule
{
  /**
   * Minimal speed (meters/ms)
   */
  protected float minSpeed = 0.0f;  // in meters/ms
  /**
   * Maximal speed (meters/ms)
   */
  protected float maxSpeed = 0.0f;  // in meters/ms

  /**
   * Constructor
   */
  public Movement()
  {
    super("Movement");
  }

  /**
   * Constructor. <br>
   * <br>
   * @param node parent {@link Node Node} object
   */
  public Movement(Node node)
  {
    super(node, "Movement");
  }

  /**
   * Gets the minimal movement speed. <br>
   * <br>
   * @return minimal movement speed
   */
  public float getMinSpeed()
  {
    return minSpeed;
  }

  /**
   * Gets the maximal movement speed. <br>
   * <br>
   * @return maximal movement speed
   */
  public float getMaxSpeed()
  {
    return maxSpeed;
  }

  /**
   * Initializes the object from XML tag. <br>
   * <br>
   * Child classes should override this method to implement
   * custom initialization procedure from tag.
   * @param element source tag
   * @throws Exception Exception if parameters are invalid
   */
  public void load(org.w3c.dom.Element element) throws Exception
  {
    super.load(element);
  }
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?