$search

javax::jmdns::impl::DNSStatefulObject::DNSStatefulObjectSemaphore Class Reference

List of all members.

Public Member Functions

 DNSStatefulObjectSemaphore (String name)
void signalEvent ()
String toString ()
void waitForEvent (long timeout)

Private Attributes

final String _name
final ConcurrentMap< Thread,
Semaphore > 
_semaphores

Static Private Attributes

static Logger logger = Logger.getLogger(DNSStatefulObjectSemaphore.class.getName())

Detailed Description

This class define a semaphore. On this multiple threads can wait the arrival of one event. Thread wait for a maximum defined by the timeout.

Implementation note: this class is based on java.util.concurrent.Semaphore so that they can be released by the timeout timer.

Author:
Pierre Frisch

Definition at line 32 of file DNSStatefulObject.java.


Constructor & Destructor Documentation

javax::jmdns::impl::DNSStatefulObject::DNSStatefulObjectSemaphore::DNSStatefulObjectSemaphore ( String  name  )  [inline]
Parameters:
name Semaphore name for debugging purposes.

Definition at line 43 of file DNSStatefulObject.java.


Member Function Documentation

void javax::jmdns::impl::DNSStatefulObject::DNSStatefulObjectSemaphore::signalEvent (  )  [inline]

Signals the semaphore when the event arrives.

Definition at line 74 of file DNSStatefulObject.java.

String javax::jmdns::impl::DNSStatefulObject::DNSStatefulObjectSemaphore::toString (  )  [inline]

Definition at line 83 of file DNSStatefulObject.java.

void javax::jmdns::impl::DNSStatefulObject::DNSStatefulObjectSemaphore::waitForEvent ( long  timeout  )  [inline]

Blocks the current thread until the event arrives or the timeout expires.

Parameters:
timeout wait period for the event

Definition at line 55 of file DNSStatefulObject.java.


Member Data Documentation

Definition at line 35 of file DNSStatefulObject.java.

Definition at line 37 of file DNSStatefulObject.java.

Logger javax::jmdns::impl::DNSStatefulObject::DNSStatefulObjectSemaphore::logger = Logger.getLogger(DNSStatefulObjectSemaphore.class.getName()) [static, private]

Definition at line 33 of file DNSStatefulObject.java.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Friends


zeroconf_jmdns
Author(s): Daniel Stonier
autogenerated on Wed Jan 16 12:20:34 2013