Class MediaRow
java.lang.Object
mil.nga.geopackage.user.UserCoreRow<TColumn,TTable>
mil.nga.geopackage.user.UserRow<UserCustomColumn,UserCustomTable>
mil.nga.geopackage.user.custom.UserCustomRow
mil.nga.geopackage.extension.related.media.MediaRow
- Direct Known Subclasses:
IconRow
User Media Row containing the values from a single cursor row
- Since:
- 3.0.1
-
Field Summary
Fields inherited from class mil.nga.geopackage.user.UserCoreRow
columns, columnTypes, table, values
-
Constructor Summary
ModifierConstructorDescriptionCopy Constructorprotected
MediaRow
(MediaTable table) Constructor to create an empty rowMediaRow
(UserCustomRow userCustomRow) Constructor -
Method Summary
Modifier and TypeMethodDescriptioncopy()
Copy the rowGet the content typeGet the content type columnint
Get the content type column indexbyte[]
getData()
Get the dataGet the data bitmapgetDataBitmap
(BitmapFactory.Options options) Get the data bitmap with decoding optionsRead the data bounds without allocating pixel memory.Get the data columnint
Get the data column indexlong
getId()
Get the idGet the id columnint
Get the id column indexgetTable()
void
setContentType
(String contentType) Set the content typevoid
setData
(byte[] data) Set the datavoid
setData
(Bitmap bitmap, Bitmap.CompressFormat format) Set the data from a full quality bitmapvoid
setData
(Bitmap bitmap, Bitmap.CompressFormat format, int quality) Set the data from a bitmapMethods inherited from class mil.nga.geopackage.user.custom.UserCustomRow
getColumns
Methods inherited from class mil.nga.geopackage.user.UserRow
columnToContentValue, isValid, setValid, toContentValues, toContentValues
Methods inherited from class mil.nga.geopackage.user.UserCoreRow
columnCount, copyValue, getAsMap, getColumn, getColumn, getColumnIndex, getColumnName, getColumnNames, getPkColumn, getPkColumnIndex, getRowColumnType, getRowColumnType, getRowColumnTypes, getValue, getValue, getValues, getValueString, getValueString, hasColumn, hasId, hasIdColumn, resetId, setId, setValue, setValue, validateValue
-
Constructor Details
-
MediaRow
Constructor- Parameters:
userCustomRow
- user custom row
-
Method Details
-
getTable
- Overrides:
getTable
in classUserCoreRow<UserCustomColumn,
UserCustomTable>
-
getIdColumnIndex
public int getIdColumnIndex()Get the id column index- Returns:
- id column index
-
getIdColumn
Get the id column- Returns:
- id column
-
getId
public long getId()Get the id- Overrides:
getId
in classUserCoreRow<UserCustomColumn,
UserCustomTable> - Returns:
- id
-
getDataColumnIndex
public int getDataColumnIndex()Get the data column index- Returns:
- data column index
-
getDataColumn
Get the data column- Returns:
- data column
-
getData
public byte[] getData()Get the data- Returns:
- data
-
setData
public void setData(byte[] data) Set the data- Parameters:
data
- data
-
getDataBounds
Read the data bounds without allocating pixel memory. Access values using:BitmapFactory.Options.outWidth
,BitmapFactory.Options.outHeight
,BitmapFactory.Options.outMimeType
,BitmapFactory.Options.outColorSpace
, andBitmapFactory.Options.outConfig
- Returns:
- bounds options
- Since:
- 3.2.0
-
getDataBitmap
Get the data bitmap- Returns:
- data bitmap
- Since:
- 3.2.0
-
getDataBitmap
Get the data bitmap with decoding options- Parameters:
options
- bitmap options- Returns:
- data bitmap
- Since:
- 3.2.0
-
setData
Set the data from a full quality bitmap- Parameters:
bitmap
- bitmapformat
- compress format- Throws:
IOException
- upon failure- Since:
- 3.2.0
-
setData
Set the data from a bitmap- Parameters:
bitmap
- bitmapformat
- compress formatquality
- quality- Throws:
IOException
- upon failure- Since:
- 3.2.0
-
getContentTypeColumnIndex
public int getContentTypeColumnIndex()Get the content type column index- Returns:
- content type column index
-
getContentTypeColumn
Get the content type column- Returns:
- content type column
-
getContentType
Get the content type- Returns:
- content type
-
setContentType
Set the content type- Parameters:
contentType
- content type
-
copy
Copy the row- Overrides:
copy
in classUserCustomRow
- Returns:
- row copy
-