Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update Javadoc with throws annotations
  • Loading branch information
noah-livio committed Dec 7, 2021
commit c9da956212012e79b5e1aa95c99570022fa84791
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ public class SoftButtonObject implements Cloneable{
* @param initialStateName a String value represents the name for the initial state
* @param onEventListener a listener that has a callback that will be triggered when a button event happens
* Note: the initialStateName should match exactly the name of one of the states for the object. Otherwise an exception will be thrown.
* @throws IllegalStateException if states is an empty list
*/
public SoftButtonObject(@NonNull String name, @NonNull List<SoftButtonState> states, @NonNull String initialStateName, OnEventListener onEventListener) {

Expand Down Expand Up @@ -263,6 +264,7 @@ public List<SoftButtonState> getStates() {
* Set the the SoftButtonState list
*
* @param states a list of the object's soft button states. <strong>states should be unique for every SoftButtonObject. A SoftButtonState instance cannot be reused for multiple SoftButtonObjects.</strong>
* @throws IllegalStateException if states is an empty list
*/
public void setStates(@NonNull List<SoftButtonState> states) {
// Make sure the list of states is not empty
Expand Down