Tree PREV CLASS NEXT CLASS SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD com.ibm.portal.resolver.data
Interface DataSource
- All Superinterfaces:
- Addressable, DataSourceFragment, Disposable, TimeStamped
- All Known Subinterfaces:
- ByteDataSource, CacheControlDataSource, CachedDataSourceFactory.UncacheableValue<T>, CachedDataSourceFactory.Value<T>, CharDataSource, ContentDispositionDataSource, ContentLengthDataSource, ConvertibleDataSource, DataSourceChecksum, JsonDataSource, MultipartDataSource, ProjectContextDataSource, RedirectDataSource, StatusCodeDataSource, UserContextDataSource, VaryDataSource, VirtualPortalContextDataSource, XmlDataSource
- All Known Implementing Classes:
- AbstractDataSource, AbstractStaticDataSource, DefaultDataSource, EarlyBindingDataSource
public interface DataSource- extends Addressable, TimeStamped, Disposable, DataSourceFragment
Base interface implemented by all data sources, independent on their actual stream type. This interface captures the metadata of the data source.
The assumption is that the metadata is constant across the lifetime of the DataSource, i.e. calling any of the methods multiple times must always return the same result.
The DataSource implementor may implement additional interfaces to describe properties of the data.
- Format
- Caching
- Additional properties
- Since:
- 6.1.0
- Note:
This interface is designed to be implemented by clients.
Field Summary static java.lang.String CONTENT_TYPE_UNKNOWN
Indicates an unknown content typestatic java.util.Date CREATION_UNKNOWN
Indicates an unknown creation datestatic java.util.Date EXPIRATION_UNKNOWN
Indicates an unknown expirationstatic java.util.Date LAST_MODIFICATION_UNKNOWN
Indicates an unknown last modified datestatic long MAX_AGE_INFINITE
Timespan for "infinite" lifetime in [ms], per default set to one (tropical) yearstatic long MAX_AGE_NONE
Timespan for immediate expiry in [ms]static java.util.Date ROOT_DATE
The earliest representable date.
Fields inherited from interface com.ibm.portal.resolver.data.Addressable EMPTY_PARAMETERS
Method Summary java.lang.String getContentType()
Mime type of the data.java.util.Date getCreated()
Return the creation date of the resource.java.util.Date getExpiration()
Absolute timestamp that indicates the time when the data represented by the source will expire.java.util.Date getLastModified()
Return the modification date of the resource.
Methods inherited from interface com.ibm.portal.resolver.data.Addressable getParameters, getURI
Methods inherited from interface com.ibm.portal.Disposable dispose
Field Detail CONTENT_TYPE_UNKNOWN
static final java.lang.String CONTENT_TYPE_UNKNOWN
- Indicates an unknown content type
- Since:
- 7.0
CREATION_UNKNOWN
static final java.util.Date CREATION_UNKNOWN
- Indicates an unknown creation date
- Since:
- 7.0
EXPIRATION_UNKNOWN
static final java.util.Date EXPIRATION_UNKNOWN
- Indicates an unknown expiration
- Since:
- 6.1.0.3
LAST_MODIFICATION_UNKNOWN
static final java.util.Date LAST_MODIFICATION_UNKNOWN
- Indicates an unknown last modified date
- Since:
- 7.0
MAX_AGE_INFINITE
static final long MAX_AGE_INFINITE
- Timespan for "infinite" lifetime in [ms], per default set to one (tropical) year
- Since:
- 7.0.0.2
- See Also:
- Constant Field Values
MAX_AGE_NONE
static final long MAX_AGE_NONE
- Timespan for immediate expiry in [ms]
- Since:
- 7.0.0.2
- See Also:
- Constant Field Values
ROOT_DATE
static final java.util.Date ROOT_DATE
- The earliest representable date. This would e.g. be used to describe the creation or last modification date of a data source that only contains computed information, without more current dependencies.
- Since:
- 7.0.0.2
Method Detail getContentType
java.lang.String getContentType()
- Mime type of the data. The return value must be a registered mime type or CONTENT_TYPE_UNKNOWN. A value of CONTENT_TYPE_UNKNOWN means that the data source does not contain any content.
- Returns:
- mime type string, or CONTENT_TYPE_UNKNOWN if the data source does not represent content
getCreated
java.util.Date getCreated()
- Returns the creation date of the resource.
- Specified by:
- getCreated in interface TimeStamped
- Returns:
- the creation dateor CREATION_UNKNOWN
getExpiration
java.util.Date getExpiration()
- Absolute timestamp that indicates the time when the data represented by the source will expire.
- Specified by:
- getExpiration in interface DataSourceFragment
- Returns:
- the date the data expires or EXPIRATION_UNKNOWN if the value is unknown
getLastModified
java.util.Date getLastModified()
- Returns the modification date of the resource.
- Specified by:
- getLastModified in interface TimeStamped
- Returns:
- the modification date or LAST_MODIFICATION_UNKNOWN
Tree PREV CLASS NEXT CLASS SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD