Class KanbanCard
java.lang.Object
com.codename1.kanban.KanbanCard
A card of a board: a task, a ticket, a lead.
A card knows the column it is in and, on a board with swimlanes, its
lane. Change either through the model (KanbanModel.moveCard), which
keeps the order of the cards and tells the views.
-
Constructor Summary
ConstructorsConstructorDescriptionKanbanCard(String id, String title) A card with an id, unique in its model, and a title. -
Method Summary
Modifier and TypeMethodDescriptionAdds a tag.A card like this one under another id: the same texts, tags, style, lane and user data, in no column yet.getBadge()A short text at the trailing edge of the card's last line, such as an estimate or the initials of its owner, or null.The id of the column the card is in.A longer text under the title, or null.getId()The id, unique in the model.The id of the card's swimlane, or null.A key the renderer maps to a colour, such as a priority, or null.getTags()The tags, drawn as small labels.getTitle()The title.Whatever the application attached, or null.Sets the badge.voidsetColumnId(String columnId) Sets the column.setDescription(String description) Sets the text under the title.Sets the lane.setStyleKey(String styleKey) Sets the style key.Sets the title.setUserData(Object userData) Attaches an object of the application's to the card.toString()Returns a string representation of the object.
-
Constructor Details
-
KanbanCard
-
-
Method Details
-
getId
The id, unique in the model. -
getTitle
The title. -
setTitle
Sets the title. A model shown by a board is told throughKanbanModel.renameCard. -
getDescription
A longer text under the title, or null. -
setDescription
Sets the text under the title. -
getTags
-
addTag
Adds a tag. -
getBadge
A short text at the trailing edge of the card's last line, such as an estimate or the initials of its owner, or null. -
setBadge
Sets the badge. -
getStyleKey
A key the renderer maps to a colour, such as a priority, or null. -
setStyleKey
Sets the style key. -
getColumnId
The id of the column the card is in. -
setColumnId
Sets the column. For a model's own use: a card of a model is moved withKanbanModel.moveCard, and setting this on a card a model holds leaves the model filing it under the column it had. -
getLaneId
The id of the card's swimlane, or null. -
setLaneId
Sets the lane. On a card that is already in a model, useKanbanModel.moveCard. -
getUserData
Whatever the application attached, or null. -
setUserData
Attaches an object of the application's to the card. -
copy
A card like this one under another id: the same texts, tags, style, lane and user data, in no column yet. -
toString
Description copied from class:ObjectReturns a string representation of the object. In general, the toString method returns a string that "textually represents" this object. The result should be a concise but informative representation that is easy for a person to read. It is recommended that all subclasses override this method. The toString method for class Object returns a string consisting of the name of the class of which the object is an instance, the at-sign character `@', and the unsigned hexadecimal representation of the hash code of the object. In other words, this method returns a string equal to the value of: getClass().getName() + '@' + Integer.toHexString(hashCode())
-