📄 semaphoreimpl.java
字号:
// Decompiled by Jad v1.5.8e2. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://kpdus.tripod.com/jad.html
// Decompiler options: packimports(3) fieldsfirst ansi space
// Source File Name: SemaphoreImpl.java
package org.gudy.azureus2.pluginsimpl.local.utils;
import org.gudy.azureus2.core3.util.AESemaphore;
import org.gudy.azureus2.plugins.PluginInterface;
import org.gudy.azureus2.plugins.utils.Semaphore;
public class SemaphoreImpl
implements Semaphore
{
private static long next_sem_id;
private AESemaphore sem;
protected SemaphoreImpl(PluginInterface pi)
{
synchronized (org/gudy/azureus2/pluginsimpl/local/utils/SemaphoreImpl)
{
sem = new AESemaphore((new StringBuilder()).append("Plugin ").append(pi.getPluginID()).append(":").append(next_sem_id++).toString());
}
}
public void reserve()
{
sem.reserve();
}
public boolean reserveIfAvailable()
{
return sem.reserveIfAvailable();
}
public boolean reserve(long timeout_millis)
{
return sem.reserve(timeout_millis);
}
public void release()
{
sem.release();
}
public void releaseAllWaiters()
{
sem.releaseAllWaiters();
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -