`
onray
  • 浏览: 6207 次
  • 来自: ...
最近访客 更多访客>>
社区版块
存档分类
最新评论

Coordination Support in Class Object

阅读更多
Coordination Support in Class Object
Class Object declares five methods that enable programmers to access the Java virtual machine's support for the coordination aspect of synchronization. These methods are declared public and final, so they are inherited by all classes. They can only be invoked from within a synchronized method or statement. In other words, the lock associated with an object must already be acquired before any of these methods are invoked. The methods are listed in Table 20-2. Table 20-2. The wait and notify methods of class Object


Method  Description 
void wait();  Enter a monitor's wait set until notified by another thread
void wait(long timeout);  Enter a monitor's wait set until notified by another thread or timeout milliseconds elapses
void wait(long timeout, int nanos);  Enter a monitor's wait set until notified by another thread or timeout milliseconds plus nanos nanoseconds elapses
void notify(); Wake up one thread waiting in the monitor's wait set. (If no threads are waiting, do nothing.) 
void notifyAll();  Wake up all threads waiting in the monitor's wait set. (If no threads are waiting, do nothing.) 

Table 20-2. The wait and notify methods of class Object

On the CD-ROM
The CD-ROM contains the source code examples from this chapter in a subdirectory of the threads directory.

The Resources Page
For more information about the material presented in this chapter, visit the resources page: http://www.artima.com/insidejvm/resources.

分享到:
评论

相关推荐

    深入java虚拟机(inside the java virtual machine)

    Coordination Support in Class Object On the CD-ROM The Resources Page Appendix A. Instructions by Opcode Mnemonic Appendix B. Opcode Mnemonic by Functional Group Appendix C. Opcode Mnemonic by ...

    COORDINATION 2004

    - COORDINATION 2004是一个关于协调模型和语言的国际会议。 - 该会议是第六次举办,因此之前有过五次相关的会议。 - 会议地点位于意大利的比萨,日期为2004年2月24日至27日。 2. 出版物信息 - 会议的出版物为...

    WS-Coordination.pdf

    ### WS-Coordination 规范概述 #### 一、引言 《WS-Coordination》规范是一份关于如何在分布式环境中实现协调管理的标准文档。该规范由微软(Microsoft)、IBM、IONA Technologies、BEA Systems 和 Hitachi 等公司...

    matlab代码gca-Interference-Coordination-in-Full-Duplex-HetNet-with-Large-

    Interference-Coordination-in-Full-Duplex-HetNet-with-Large-Scale-Antenna-Arrays Paper about Small Cell, Massive MIMO and Full-duplex Introduction 这篇论文研究的是结合了Small Cell, Massive MIMO和Full-...

    AI Summit: Squad Coordination in 'Days Gone'

    在“AI Summit: Squad Coordination in 'Days Gone'”这一演讲中,来自Sony Bend Studio的高级AI程序员Tobias Karlsson分享了如何在开放世界游戏中实现人工智能群体的战斗协调。这个话题聚焦于游戏《Days Gone》中AI...

    Distributed coordination of multi-agent networks

    《Distributed coordination of multi-agent networks》一书由Wei Ren和Yongcan Cao共同撰写,是该领域内的一本经典教材。本书深入探讨了多智能体系统分布式协调控制的基本原理与技术方法,并结合丰富的案例研究,为...

    Robot team coordination for target tracking using fuzzy logic controller in game theoretic framework

    在理论框架中运用模糊逻辑控制目标跟踪 电子文档 word

    A curving ACC system with coordination control of longitudinal

    driver-in-the-loop tests on a driving simulator are conducted and the results show that the developed control system provides significant benefits in weakening the impact of DYC on ACC longitudinal ...

    Currency war or international policy coordination.pdf

    Currency war or international policy coordination by Barry Eichengreen

    Information sharing and coordination mechanisms for managing uncertainty

    ### 信息共享与协调机制在供应链不确定性管理中的应用 #### 引言 在全球化和数字化背景下,供应链变得越来越复杂和动态。供应链中的不确定因素(如需求波动、供应商延迟等)可能对企业的运营效率和盈利能力产生重大...

    WS-Coordination200411

    ### WS-Coordination200411:深入解析与理解 #### 一、概述 《WS-Coordination200411》是2004年11月发布的一项关于Web服务协调的技术规范。该文档由来自微软、IBM和BEA Systems等公司的多位专家共同撰写完成。此...

    Coordination

    ### 协调(Coordination)在生物系统与嵌入式机器人中的应用 #### 概述 协调(Coordination)作为生物学领域以及工程学领域的重要研究课题,在近年来引起了广泛关注。特别是对于移动自主代理(如车辆、移动传感器...

    Type 2 coordination

    标题中的"Type 2 coordination"指的是电气保护系统中的一种类型,即第二类协调保护。在电力系统中,电气保护是确保设备和人员安全的关键部分,它涉及到电流过载、短路、接地故障等情况下的自动断开电路。第二类电气...

    LS产电Metasol MS Type 2 coordination.pdf

    LS产电Metasol MS Type 2 coordinationpdf,

    psci.rar_coordination

    ARM Power State and Coordination Interface(PSCI)是嵌入式和服务器系统中广泛采用的一种标准接口,用于管理ARM架构处理器的电源状态和协调。PSCI的主要目标是提供一种统一的方法来控制系统的低功耗状态,如休眠...

    Power_State_Coordination_Interface_PDD_v1_1_DEN0022D.pdf

    This document defines a standard interface for power management that can be used by OS vendors for supervisory software working at different levels of privilege on an ARM device. Rich operating ...

    of_pci.rar_coordination

    "of_pci.rar_coordination"的主题显然与PCI设备的协调管理有关,特别是涉及了SMT(Simultaneous Multi-Threading)ECM(Entity Coordination Management)实体的硬件独立状态机。下面我们将深入探讨这些概念。 首先...

Global site tag (gtag.js) - Google Analytics