public class BlockRedstoneEvent extends BlockEvent implements Cancellable
Modifier and Type | Class and Description |
---|---|
static class |
BlockRedstoneEvent.Cause
Representing the cause of a redstone update
|
Constructor and Description |
---|
BlockRedstoneEvent(Block block,
int strength,
Block causer,
BlockRedstoneEvent.Cause cause) |
Modifier and Type | Method and Description |
---|---|
void |
cancel(boolean cancelled) |
BlockRedstoneEvent.Cause |
cause()
Returns the cause of the redstone update
|
Block |
causer()
Returns the block which caused the redstone update
|
boolean |
isIgnored() |
int |
strength()
Returns the strength (power level) of the redstone
|
block
public BlockRedstoneEvent(Block block, int strength, Block causer, BlockRedstoneEvent.Cause cause)
block
- Block which redstone state was updatedstrength
- Integer representing the strength (power level) of the redstonecauser
- Block which caused the redstone updatecause
- Cause for the redstone updatepublic Block causer()
public BlockRedstoneEvent.Cause cause()
public int strength()
public boolean isIgnored()
isIgnored
in interface Cancellable
public void cancel(boolean cancelled)
cancel
in interface Cancellable
cancelled
- set the cancellation state of the eventCopyright © 2016. All rights reserved.