|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.amoebaman.kitmaster.objects.Book
public class Book
User-friendly interface for manipulating book pages/titles/authors. Uses MC-native NBT tags to manage data.
| Constructor Summary | |
|---|---|
Book(java.io.File file)
Constructs a book by reading its contents from a file. |
|
Book(org.bukkit.inventory.ItemStack item)
Constructs the wrapper for an ItemStack. |
|
| Method Summary | |
|---|---|
void |
addPages(java.lang.String[] newPages)
Adds pages to the book. |
java.lang.String |
getAuthor()
Gets the author of this book. |
org.bukkit.inventory.ItemStack |
getItemStack()
Gets the ItemStack that this Book is currently wrapping. |
java.lang.String[] |
getPages()
Gets the pages contained by this book. |
java.lang.String |
getTitle()
Gets the title of this book. |
void |
saveToFile(java.io.File file)
Saves this book to a file. |
void |
setAuthor(java.lang.String author)
Sets the author of this book. |
void |
setPages(java.lang.String[] newPages)
Sets the book's pages. |
void |
setTitle(java.lang.String title)
Sets the title of this book. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Book(org.bukkit.inventory.ItemStack item)
ItemStack.
item - The item to wrap.public Book(java.io.File file)
file - The file to read from.| Method Detail |
|---|
public java.lang.String[] getPages()
public java.lang.String getAuthor()
public java.lang.String getTitle()
public void setPages(java.lang.String[] newPages)
newPages - The new pages.public void addPages(java.lang.String[] newPages)
newPages - The pages to add.public void setAuthor(java.lang.String author)
author - The new author.public void setTitle(java.lang.String title)
title - The new title.public void saveToFile(java.io.File file)
file - The file to save the book to.public org.bukkit.inventory.ItemStack getItemStack()
ItemStack that this Book represents.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||