diff options
Diffstat (limited to 'BJC-Utils2/src/main/java/bjc/utils/ioutils/blocks/Block.java')
| -rw-r--r-- | BJC-Utils2/src/main/java/bjc/utils/ioutils/blocks/Block.java | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/BJC-Utils2/src/main/java/bjc/utils/ioutils/blocks/Block.java b/BJC-Utils2/src/main/java/bjc/utils/ioutils/blocks/Block.java index e92644e..b514d17 100644 --- a/BJC-Utils2/src/main/java/bjc/utils/ioutils/blocks/Block.java +++ b/BJC-Utils2/src/main/java/bjc/utils/ioutils/blocks/Block.java @@ -2,7 +2,7 @@ package bjc.utils.ioutils.blocks; /** * Represents a block of text read in from a source. - * + * * @author EVE * */ @@ -29,7 +29,7 @@ public class Block { /** * Create a new block. - * + * * @param blockNo * The number of this block. * @param contents @@ -39,7 +39,7 @@ public class Block { * @param endLine * The line this block ended. */ - public Block(int blockNo, String contents, int startLine, int endLine) { + public Block(final int blockNo, final String contents, final int startLine, final int endLine) { this.contents = contents; this.startLine = startLine; this.endLine = endLine; @@ -52,7 +52,7 @@ public class Block { int result = 1; result = prime * result + blockNo; - result = prime * result + ((contents == null) ? 0 : contents.hashCode()); + result = prime * result + (contents == null ? 0 : contents.hashCode()); result = prime * result + endLine; result = prime * result + startLine; @@ -60,21 +60,21 @@ public class Block { } @Override - public boolean equals(Object obj) { - if(this == obj) return true; - if(obj == null) return false; - if(!(obj instanceof Block)) return false; + public boolean equals(final Object obj) { + if (this == obj) return true; + if (obj == null) return false; + if (!(obj instanceof Block)) return false; - Block other = (Block) obj; + final Block other = (Block) obj; - if(blockNo != other.blockNo) return false; + if (blockNo != other.blockNo) return false; - if(contents == null) { - if(other.contents != null) return false; - } else if(!contents.equals(other.contents)) return false; + if (contents == null) { + if (other.contents != null) return false; + } else if (!contents.equals(other.contents)) return false; - if(endLine != other.endLine) return false; - if(startLine != other.startLine) return false; + if (endLine != other.endLine) return false; + if (startLine != other.startLine) return false; return true; } |
