Interface SettingForm
- All Superinterfaces:
Extensible, Identifiable, OsidBrowsableForm, OsidExtensibleForm, OsidForm, OsidIdentifiableForm, OsidObjectForm, OsidSubjugateableForm, Suppliable
- All Known Subinterfaces:
SettingBatchForm
This is the form for creating and updating settings. Like all
OsidForm objects, various data elements may be set here for use in the
create and update methods in the SettingAdminSession . For each
data element that may be set, metadata may be examined to provide display
hints or data constraints.
-
Method Summary
Modifier and TypeMethodDescriptionvoidRemoves the discreet state.voidclearOff()Removes the off status.voidclearOn()Removes the on status.voidRemoves the ramp rate.voidRemoves the variable amount.voidRemoves the percentage amount.Gets the metadata for the state.Gets the metadata for the off status.Gets the metadata for the on status.Gets the metadata for the ramp rate.getSettingFormRecord(Type settingRecordType) Gets theSettingFormRecordcorresponding to the given setting recordType.Gets the metadata for the variable amount.Gets the metadata for the percentage amount.voidsetDiscreetState(Id stateId) Sets the state.voidsetOff(boolean off) Sets the off status.voidsetOn(boolean on) Sets the on status.voidsetRampRate(Duration rate) Sets the ramp rate.voidsetVariableAmount(BigDecimal amount) Sets the variable amount.voidsetVariablePercentage(BigDecimal amount) Sets the percentage amount.Methods inherited from interface Extensible
getRecordTypes, hasRecordTypeModifier and TypeMethodDescriptionGets the record types available in this object.booleanhasRecordType(Type recordType) Tests if this object supports the given recordType.Methods inherited from interface Identifiable
getId, isCurrentMethods inherited from interface OsidExtensibleForm
getRequiredRecordTypesModifier and TypeMethodDescriptionGets the minimum required record types for successful submission of thisOsidForm.Methods inherited from interface OsidForm
getDefaultLocale, getInvalidMetadata, getJournalCommentMetadata, getLocales, getValidationMessages, isForUpdate, isValid, setJournalComment, setLocaleModifier and TypeMethodDescriptionGets a default locale for the form.Metadata[]Gets a list of metadata for the elements in this form which are not valid.Gets the metadata for the comment corresponding to this form submission.Gets the locales available for this form.Gets text messages corresponding to additional instructions to pass form validation.booleanTests if this form is for an update operation.booleanisValid()Tests if this form is in a valid state for submission.voidsetJournalComment(String comment) Sets a comment.voidSpecifies a language and script type for the form.Methods inherited from interface OsidObjectForm
clearDescription, clearDisplayName, clearGenusType, getDescriptionMetadata, getDisplayNameMetadata, getGenusTypeMetadata, setDescription, setDisplayName, setGenusTypeModifier and TypeMethodDescriptionvoidClears the description.voidClears the display name.voidClears the genus type.Gets the metadata for a description.Gets the metadata for a display name.Gets the metadata for a genus type.voidsetDescription(String description) Sets a description.voidsetDisplayName(String displayName) Sets a display name.voidsetGenusType(Type genusType) Sets a genus.
-
Method Details
-
getOnMetadata
Metadata getOnMetadata()Gets the metadata for the on status.- Returns:
- metadata for the on status
- Compliance:
mandatory- This method must be implemented.
-
setOn
void setOn(boolean on) Sets the on status.- Parameters:
on- the new on status- Throws:
InvalidArgumentException-onis invalidNoAccessException-Metadata.isReadOnly()istrue- Compliance:
mandatory- This method must be implemented.
-
clearOn
void clearOn()Removes the on status.- Throws:
NoAccessException-Metadata.isRequired()istrueorMetadata.isReadOnly()istrue- Compliance:
mandatory- This method must be implemented.
-
getOffMetadata
Metadata getOffMetadata()Gets the metadata for the off status.- Returns:
- metadata for the off status
- Compliance:
mandatory- This method must be implemented.
-
setOff
void setOff(boolean off) Sets the off status.- Parameters:
off- the new off status- Throws:
InvalidArgumentException-offis invalidNoAccessException-Metadata.isReadOnly()istrue- Compliance:
mandatory- This method must be implemented.
-
clearOff
void clearOff()Removes the off status.- Throws:
NoAccessException-Metadata.isRequired()istrueorMetadata.isReadOnly()istrue- Compliance:
mandatory- This method must be implemented.
-
getVariablePercentageMetadata
Metadata getVariablePercentageMetadata()Gets the metadata for the percentage amount.- Returns:
- metadata for the percentage amount
- Compliance:
mandatory- This method must be implemented.
-
setVariablePercentage
Sets the percentage amount.- Parameters:
amount- the new percentage amount- Throws:
InvalidArgumentException-amountis invalidNoAccessException-Metadata.isReadOnly()istrueNullArgumentException-amountisnull- Compliance:
mandatory- This method must be implemented.
-
clearVariablePercentage
void clearVariablePercentage()Removes the percentage amount.- Throws:
NoAccessException-Metadata.isRequired()istrueorMetadata.isReadOnly()istrue- Compliance:
mandatory- This method must be implemented.
-
getVariableAmountMetadata
Metadata getVariableAmountMetadata()Gets the metadata for the variable amount.- Returns:
- metadata for the variable amount
- Compliance:
mandatory- This method must be implemented.
-
setVariableAmount
Sets the variable amount.- Parameters:
amount- the new variable amount- Throws:
InvalidArgumentException-amountis invalidNoAccessException-Metadata.isReadOnly()istrueNullArgumentException-amountisnull- Compliance:
mandatory- This method must be implemented.
-
clearVariableAmount
void clearVariableAmount()Removes the variable amount.- Throws:
NoAccessException-Metadata.isRequired()istrueorMetadata.isReadOnly()istrue- Compliance:
mandatory- This method must be implemented.
-
getDiscreetMetadata
Metadata getDiscreetMetadata()Gets the metadata for the state.- Returns:
- metadata for the state
- Compliance:
mandatory- This method must be implemented.
-
setDiscreetState
Sets the state.- Parameters:
stateId- the new state- Throws:
InvalidArgumentException-stateIdis invalidNoAccessException-Metadata.isReadOnly()istrueNullArgumentException-stateIdisnull- Compliance:
mandatory- This method must be implemented.
-
clearDiscreetState
void clearDiscreetState()Removes the discreet state.- Throws:
NoAccessException-Metadata.isRequired()istrueorMetadata.isReadOnly()istrue- Compliance:
mandatory- This method must be implemented.
-
getRampRateMetadata
Metadata getRampRateMetadata()Gets the metadata for the ramp rate.- Returns:
- metadata for the ramp rate
- Compliance:
mandatory- This method must be implemented.
-
setRampRate
Sets the ramp rate.- Parameters:
rate- the new ramp rate- Throws:
InvalidArgumentException-rateis invalidNoAccessException-Metadata.isReadOnly()istrueNullArgumentException-rateisnull- Compliance:
mandatory- This method must be implemented.
-
clearRampRate
void clearRampRate()Removes the ramp rate.- Throws:
NoAccessException-Metadata.isRequired()istrueorMetadata.isReadOnly()istrue- Compliance:
mandatory- This method must be implemented.
-
getSettingFormRecord
Gets theSettingFormRecordcorresponding to the given setting recordType.- Parameters:
settingRecordType- a setting record type- Returns:
- the setting form record
- Throws:
NullArgumentException-settingRecordTypeisnullOperationFailedException- unable to complete requestUnsupportedException-hasRecordType(settingRecordType)isfalse- Compliance:
mandatory- This method must be implemented.
-