Class Preference
java.lang.Object
com.priint.pubserverapi.preferences.Preference
Represents a user preference with a name, value, description, and type.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the description of the preference if exists, otherwise it returns nullGets the name of the preference.getType()Gets the type of the preference.getValue()Gets the value of the preference.voidsetKeyName(String keyName) Sets the name of the preference.voidsetType(PreferenceType type) Sets the type of the preference.voidSets the value of the preference.
-
Constructor Details
-
Preference
public Preference()
-
-
Method Details
-
getKeyName
Gets the name of the preference.- Returns:
- the name of the preference
-
setKeyName
Sets the name of the preference.- Parameters:
keyName- the name to set
-
getValue
Gets the value of the preference.- Returns:
- the value of the preference
-
setValue
Sets the value of the preference.- Parameters:
value- the value to set
-
getType
Gets the type of the preference.- Returns:
- the type of the preference
-
setType
Sets the type of the preference.- Parameters:
type- the type to set
-
getDescription
Gets the description of the preference if exists, otherwise it returns null- Returns:
- the description of the preference
-