模块 java.rmi

类 Lease

java.lang.Object
java.rmi.dgc.Lease
所有已实现的接口:
Serializable

public final class Lease extends Object implements Serializable
租约包含唯一的 VM 标识符和租约期限。 Lease 对象用于向远程对象引用请求和授予租约。
参见:
  • 构造方法详细信息

    • Lease

      public Lease(VMID  id, long duration)
      构造具有特定 VMID 和租约期限的租约。 vmid 可能为空。
      参数:
      id - 与此租约关联的 VMID
      duration - 租赁期限
  • 方法详情

    • getVMID

      public VMID  getVMID()
      返回与租约关联的客户端 VMID。
      返回:
      客户端VMID
    • getValue

      public long getValue()
      返回租约期限。
      返回:
      lease duration