|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.dontdrinkandroot.lastfm.api.ws.FetchLimitEnforcer
public class FetchLimitEnforcer
Enforce last.fm fetch limit. "You will not make more than 5 requests per originating IP address per second, averaged over a 5 minute period".
| Constructor Summary | |
|---|---|
FetchLimitEnforcer()
|
|
| Method Summary | |
|---|---|
double |
getWebRequestsPerSecond()
Get the number of requests per second in the compliance interval. |
void |
waitForTimeslot()
Block as long as it is necessary to comply with the request/second limit. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public FetchLimitEnforcer()
| Method Detail |
|---|
public final double getWebRequestsPerSecond()
public final void waitForTimeslot()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||