public class ItemContainer extends Object implements com.github.shynixn.petblocks.api.business.entity.GUIItemContainer
Do not remove this header!
Version 1.0
MIT License
Copyright (c) 2017
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
| Constructor and Description |
|---|
ItemContainer(boolean enabled,
int position,
com.github.shynixn.petblocks.api.business.enumeration.GUIPage page,
int id,
int damage,
String skin,
boolean unbreakable,
String name,
String[] lore)
Initializes a new itemContainer
|
ItemContainer(int orderNumber,
Map<String,Object> data)
Initializes a new itemContainer
|
| Modifier and Type | Method and Description |
|---|---|
Object |
generate(Object player,
String... permissions)
Generates a new itemStack for the player and his permissions
|
Optional<String> |
getDisplayName()
Returns the displayName of the itemStack if present
|
int |
getItemDamage()
Returns the damage of the item
|
int |
getItemId()
Returns the id of the item
|
Optional<String[]> |
getLore()
Returns the lore of the itemStack if present
|
com.github.shynixn.petblocks.api.business.enumeration.GUIPage |
getPage()
Returns the guiPage of this container
|
int |
getPosition()
Returns the position of the itemStack in the ui
|
String |
getSkin()
Returns the skin of the itemStack
|
boolean |
isEnabled()
Returns if the itemContainer is enabled
|
boolean |
isItemUnbreakable()
Returns if the item is unbreakable
|
void |
setDisplayName(String displayName) |
void |
setEnabled(boolean enabled)
Sets the itemContainer enabled
|
public ItemContainer(boolean enabled,
int position,
com.github.shynixn.petblocks.api.business.enumeration.GUIPage page,
int id,
int damage,
String skin,
boolean unbreakable,
String name,
String[] lore)
enabled - enabledposition - positionpage - pageid - iddamage - damageskin - skinunbreakable - unbreakablöename - namelore - lorepublic Object generate(Object player, String... permissions)
generate in interface com.github.shynixn.petblocks.api.business.entity.GUIItemContainerplayer - playerpermissions - permissionpublic void setDisplayName(String displayName)
public boolean isEnabled()
isEnabled in interface com.github.shynixn.petblocks.api.business.entity.GUIItemContainerpublic void setEnabled(boolean enabled)
setEnabled in interface com.github.shynixn.petblocks.api.business.entity.GUIItemContainerenabled - enabledpublic com.github.shynixn.petblocks.api.business.enumeration.GUIPage getPage()
getPage in interface com.github.shynixn.petblocks.api.business.entity.GUIItemContainerpublic String getSkin()
getSkin in interface com.github.shynixn.petblocks.api.business.entity.GUIItemContainerpublic int getItemId()
getItemId in interface com.github.shynixn.petblocks.api.business.entity.GUIItemContainerpublic int getItemDamage()
getItemDamage in interface com.github.shynixn.petblocks.api.business.entity.GUIItemContainerpublic boolean isItemUnbreakable()
isItemUnbreakable in interface com.github.shynixn.petblocks.api.business.entity.GUIItemContainerpublic Optional<String> getDisplayName()
getDisplayName in interface com.github.shynixn.petblocks.api.business.entity.GUIItemContainerpublic Optional<String[]> getLore()
getLore in interface com.github.shynixn.petblocks.api.business.entity.GUIItemContainerpublic int getPosition()
getPosition in interface com.github.shynixn.petblocks.api.business.entity.GUIItemContainerCopyright © 2017. All rights reserved.