xyz.lazertechbuilds.poller.PollMethod Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of Poller Show documentation
Show all versions of Poller Show documentation
Poller uses annotation executes methods after the specified amount of time has passed.
The newest version!
/*
This library is called Poller. It will automatic run static methods that have an annotation.
Copyright (C) 2020 Breyon Gunn
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see .
*/
package xyz.lazertechbuilds.poller;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
import java.util.concurrent.TimeUnit;
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.METHOD)
public @interface PollMethod {
int time();
TimeUnit timeUnit() default TimeUnit.MINUTES;
}