public interface ProductForm extends OsidObjectForm
This is the form for creating and updating Products.
Like all OsidForm
objects, various data elements may be set
here for use in the create and update methods in the
ProductAdminSession.
For each data element that may be set,
metadata may be examined to provide display hints or data constraints.
Modifier and Type | Method and Description |
---|---|
void |
clearAvailability()
Clears the availability.
|
void |
clearCode()
Clears the code.
|
void |
clearPriceSchedules()
Clears the price schedules.
|
Metadata |
getAvailabilityMetadata()
Gets the metadata for the availability.
|
Metadata |
getCodeMetadata()
Gets the metadata for the code.
|
Metadata |
getPriceSchedulesMetadata()
Gets the metadata for the price schedules.
|
ProductFormRecord |
getProductFormRecord(Type productRecordType)
Gets the
ProductFormRecord corresponding to the given
product record Type. |
void |
setAvailability(long availability)
Sets the availability.
|
void |
setCode(java.lang.String code)
Sets the code.
|
void |
setPriceSchedules(Id[] priceScheduleids)
Sets the price schedules.
|
clearDescription, clearDisplayName, clearGenusType, getDescriptionMetadata, getDisplayNameMetadata, getGenusTypeMetadata, setDescription, setDisplayName, setGenusType
getRequiredRecordTypes
getRecordTypes, hasRecordType
getDefaultLocale, getInvalidMetadata, getJournalCommentMetadata, getLocales, getValidationMessages, isForUpdate, isValid, setJournalComment, setLocale
getId, isCurrent
Metadata getCodeMetadata()
mandatory
- This method must be implemented. void setCode(java.lang.String code)
code
- the new codeInvalidArgumentException
- code
is
invalidNoAccessException
- Metadata.isReadOnly()
is true
NullArgumentException
- code
is
null
mandatory
- This method must be implemented. void clearCode()
NoAccessException
- Metadata.isRequired()
or Metadata.isReadOnly()
is true
mandatory
- This method must be implemented. Metadata getPriceSchedulesMetadata()
mandatory
- This method must be implemented. void setPriceSchedules(Id[] priceScheduleids)
priceScheduleids
- the new price schedulesInvalidArgumentException
- priceScheduleIds
is invalidNoAccessException
- Metadata.isReadOnly()
is true
NullArgumentException
- priceScheduleIds
is null
mandatory
- This method must be implemented. void clearPriceSchedules()
NoAccessException
- Metadata.isRequired()
or Metadata.isReadOnly()
is true
mandatory
- This method must be implemented. Metadata getAvailabilityMetadata()
mandatory
- This method must be implemented. void setAvailability(long availability)
availability
- the new availabilityInvalidArgumentException
- availability
is invalidNoAccessException
- Metadata.isReadOnly()
is true
mandatory
- This method must be implemented. void clearAvailability()
NoAccessException
- Metadata.isRequired()
or Metadata.isReadOnly()
is true
mandatory
- This method must be implemented. ProductFormRecord getProductFormRecord(Type productRecordType) throws OperationFailedException
ProductFormRecord
corresponding to the given
product record Type.
productRecordType
- the product record typeNullArgumentException
- productRecordType
is null
OperationFailedException
- unable to complete requestUnsupportedException
-
hasRecordType(productRecordType)
is false
mandatory
- This method must be implemented.