A grouping that rewards can be filed under so a rewards catalogue can be browsed by category, for example Travel or Electronics. Categories belong to one organisation and are unique by name within it. Deleting a category does not delete its rewards, it just clears the category from each of them.
Group: Database Entities
Implements: Serializable
Properties
| Property | Returns | Description |
|---|---|---|
| id | long | The database identifier of this reward category. |
| name | String | The portable, path-safe identifier for this category, unique within the organisation and used to look the category up. The human readable label is the title. Never null for a persisted category. |
| org | Organisation | The organisation this category belongs to. Categories and the rewards in them are scoped to this organisation, so names only need to be unique within it. Never null for a persisted category. |
| title | String | The display label shown for this category in a rewards catalogue. Free text with no uniqueness guarantee, unlike the name. Never null for a persisted category. |
Methods
getId()
Returns: long
The database identifier of this reward category.
setId(long id)
Returns: void
Sets the database identifier of this reward category. Normally left to Hibernate, which generates the value on save.
| Parameter | Description |
|---|---|
id | the primary key to assign |
getName()
Returns: String
The portable, path-safe identifier for this category, unique within the organisation and used to look the category up. The human readable label is the title. Never null for a persisted category.
setName(String name)
Returns: void
Sets the portable, path-safe identifier for this category.
| Parameter | Description |
|---|---|
name | the category's identifying name, unique within the organisation |
getTitle()
Returns: String
The display label shown for this category in a rewards catalogue. Free text with no uniqueness guarantee, unlike the name. Never null for a persisted category.
setTitle(String title)
Returns: void
Sets the display label shown for this category.
| Parameter | Description |
|---|---|
title | the category's display label |
getOrg()
Returns: Organisation
The organisation this category belongs to. Categories and the rewards in them are scoped to this organisation, so names only need to be unique within it. Never null for a persisted category.
setOrg(Organisation org)
Returns: void
Sets the organisation this category belongs to.
| Parameter | Description |
|---|---|
org | the owning organisation |