public class CSMediaTypeMultiple extends CSItemMultiple
The CSMediaTypeMultiple
class provides a method, get()
, that retrieves several media
types from the database. This method requires that certain database and key information (media type IDs, for example)
be specified via the set
methods provided, prior to its invocation.
CSMediaType
,
CSMediaTypeContent
,
Serialized FormLEVEL_ALL, LEVEL_ALL_PLUS_RELATED, LEVEL_DETAIL, LEVEL_ID, LEVEL_SUMMARY
Constructor and Description |
---|
CSMediaTypeMultiple()
Creates an empty
CSMediaTypeMultiple object. |
CSMediaTypeMultiple(java.lang.String strPropertyFile)
Creates an empty
CSMediaTypeMultiple object, specifying a property file that contains all of the
database connection details. |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getMediaTypeList()
Get the list of media type IDs.
|
void |
setDetailLevel(int nDetailLevel)
Sets the level of detail to be handled by the
get method. |
void |
setMediaTypeList(java.lang.String strMediaTypeList)
Set the list of media type IDs.
|
void |
setSortOrder(java.lang.String strSortOrderList)
Set the order in which media types will be retrieved.
|
java.lang.String |
toString()
Output the contents of this
CSMediaTypeMultiple object to a String object in a
user-friendly format. |
delete, equals, exist, get, getItems, getMaxRows, getSortOrder, getStartRow, iterator, setItems, setMaxRows, setStartRow, update
clearRecordedGatewayMessages, clone, count, getCache, getCachingEnabled, getDatabaseVersion, getDatabaseVersion, getDebugOutput, getDetailLevel, getPreview, getPropertyFile, getPropertyFileExtension, getPropertyFilePathname, getRecordedGatewayMessages, getRecordGatewayMessages, getSendGatewayMessages, getUseCache, setDebugOutput, setPreview, setPropertyFile, setRecordGatewayMessages, setSendGatewayMessages, setUseCache
public CSMediaTypeMultiple()
CSMediaTypeMultiple
object.
Use the various set
methods to initialise the CSMediaTypeMultiple
object prior to
invoking get()
.
public CSMediaTypeMultiple(java.lang.String strPropertyFile)
CSMediaTypeMultiple
object, specifying a property file that contains all of the
database connection details.
Use the various set
methods to initialise the CSMediaTypeMultiple
object prior to
invoking get()
.
strPropertyFile
- the name of the property file from which the database connection details are to be read.public void setMediaTypeList(java.lang.String strMediaTypeList)
get
.
strMediaTypeList
- a String
containing a comma-separated list of IDs of the specific media types to be
retrieved.public java.lang.String getMediaTypeList()
String
containing a comma-separated list of IDs of the specific media types to be
retrieved.public void setSortOrder(java.lang.String strSortOrderList) throws CSParameterException
This method should not be used if the setMediaTypeList
is being used - in this
case the media types are retrieved in the same order as the supplied IDs. Otherwise, one or more of the available
sort orders may be specified as a comma-delimited list. Use ASC or DESC to indicate the direction of ordering for
a sort order. For example, "TYPE DESC" would order in descending media type name (directory) order. ASC is
assumed if neither ASC or DESC are specified
Available sort orders are :
MEDIATYPEID - order by media type ID
TYPE - order by media type name (directory)
DESCRIPTION - order by media type description
setSortOrder
in class CSItemMultiple
strSortOrderList
- a comma-separated list of one or more of the available sort orders.CSParameterException
- if an invalid sort order was specified.public void setDetailLevel(int nDetailLevel) throws CSParameterException
get
method.
Valid detail levels for media types are :
LEVEL_ID - the media type ID
LEVEL_SUMMARY - the type (directory)
LEVEL_ALL - the description, indexcontent flag and subtypes
Each detail level processes the information specified alongside it in addition to the information specified for all detail levels listed above it. The default detail level is LEVEL_ALL.
setDetailLevel
in class CSDatabaseItem
nDetailLevel
- the detail level to be used.CSParameterException
- if an invalid detail level is specified.public java.lang.String toString()
CSMediaTypeMultiple
object to a String
object in a
user-friendly format.
toString
in class CSItemMultiple
String
containing the user-friendly output.Copyright © 2022 Goss Interactive Ltd. All Rights Reserved.