001    package org.bukkit.event.world;
002    
003    import org.bukkit.Chunk;
004    import org.bukkit.event.Cancellable;
005    import org.bukkit.event.HandlerList;
006    
007    /**
008     * Called when a chunk is unloaded
009     */
010    public class ChunkUnloadEvent extends ChunkEvent implements Cancellable {
011        private static final HandlerList handlers = new HandlerList();
012        private boolean cancel = false;
013    
014        public ChunkUnloadEvent(final Chunk chunk) {
015            super(chunk);
016        }
017    
018        public boolean isCancelled() {
019            return cancel;
020        }
021    
022        public void setCancelled(boolean cancel) {
023            this.cancel = cancel;
024        }
025    
026        @Override
027        public HandlerList getHandlers() {
028            return handlers;
029        }
030    
031        public static HandlerList getHandlerList() {
032            return handlers;
033        }
034    }